chat.config.ts. It is parsed and exported as config from @/lib/config.
Config Structure
chat.config.ts
Integrations
Toggle features on/off. Set totrue to enable. Missing env vars are caught at build time via bun run prebuild.
| Integration | Config Key | Env Dependency |
|---|---|---|
| Code Sandbox | integrations.sandbox | VERCEL_OIDC_TOKEN (on Vercel) or VERCEL_TEAM_ID + VERCEL_PROJECT_ID + VERCEL_TOKEN |
| Web Search | integrations.webSearch | TAVILY_API_KEY or FIRECRAWL_API_KEY |
| MCP Connectors | integrations.mcp | MCP_ENCRYPTION_KEY |
| Image Generation | integrations.imageGeneration | BLOB_READ_WRITE_TOKEN |
| Attachments | integrations.attachments | BLOB_READ_WRITE_TOKEN |
Authentication
Set totrue to enable providers. Missing env vars are caught at server startup.
Branding
Customize app name and organization details:Using Config in Components
Import directly in both server and client components:Type Definition
Full type reference:ModelsConfig, AnonymousConfig, and AttachmentsConfig.