MCPcopy Index your code
hub / github.com/simstudioai/sim / getChatStorageConfig

Function getChatStorageConfig

apps/sim/app/api/files/authorization.ts:783–803  ·  view source on GitHub ↗

* Get chat storage configuration based on current storage provider

()

Source from the content-addressed store, hash-verified

781 * Get chat storage configuration based on current storage provider
782 */
783async function getChatStorageConfig(): Promise<StorageConfig> {
784 const { USE_S3_STORAGE, USE_BLOB_STORAGE } = await import('@/lib/uploads/config')
785
786 if (USE_BLOB_STORAGE) {
787 return {
788 containerName: BLOB_CHAT_CONFIG.containerName,
789 accountName: BLOB_CHAT_CONFIG.accountName,
790 accountKey: BLOB_CHAT_CONFIG.accountKey,
791 connectionString: BLOB_CHAT_CONFIG.connectionString,
792 }
793 }
794
795 if (USE_S3_STORAGE) {
796 return {
797 bucket: S3_CHAT_CONFIG.bucket,
798 region: S3_CHAT_CONFIG.region,
799 }
800 }
801
802 return {}
803}

Callers 1

verifyChatFileAccessFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected