{"record":{"id":"e946cbf17c744d80","repo":"BerriAI/litellm","slug":"invalid-config-for-mcp-server-server-name-or-ser-e946cb","errorCode":null,"errorMessage":"Invalid config for MCP server '{server_name or server_id}': dcr_bridge must be a boolean (got {config_dcr_bridge!r}).","messagePattern":"Invalid config for MCP server '(.+?)': dcr_bridge must be a boolean \\(got (.+?)\\)\\.","errorType":"validation","errorClass":"ValueError","httpStatus":null,"severity":"error","filePath":"litellm/proxy/_experimental/mcp_server/mcp_server_manager.py","lineNumber":1716,"sourceCode":"            )\n            effective_issuer = manual_issuer or discovered_issuer\n\n            if auth_type == MCPAuth.oauth2 and config_oauth2_flow not in (\n                \"client_credentials\",\n                \"authorization_code\",\n            ):\n                raise ValueError(\n                    f\"Invalid config for MCP server '{server_name or server_id}': auth_type oauth2 \"\n                    f\"requires an explicit oauth2_flow (got {config_oauth2_flow!r}). Set \"\n                    \"oauth2_flow: client_credentials for machine-to-machine servers (the proxy mints \"\n                    \"a shared token at token_url using client_id/client_secret, no user interaction) \"\n                    \"or oauth2_flow: authorization_code for interactive servers (per-user tokens via \"\n                    \"browser sign-in, including delegate_auth_to_upstream).\"\n                )\n\n            config_dcr_bridge = server_config.get(\"dcr_bridge\", None)\n            if config_dcr_bridge is not None and not isinstance(config_dcr_bridge, bool):\n                raise ValueError(\n                    f\"Invalid config for MCP server '{server_name or server_id}': dcr_bridge \"\n                    f\"must be a boolean (got {config_dcr_bridge!r}).\"\n                )\n            if config_dcr_bridge and auth_type not in (\n                MCPAuth.true_passthrough,\n                MCPAuth.oauth_delegate,\n            ):\n                raise ValueError(\n                    f\"Invalid config for MCP server '{server_name or server_id}': dcr_bridge is only \"\n                    f\"supported for auth_type true_passthrough or oauth_delegate (got {auth_type!r}). \"\n                    \"The DCR bridge serves gateway-hosted OAuth discovery for the client-forwarded \"\n                    \"token modes; interactive oauth2 servers already run the gateway \"\n                    \"authorization-code flow.\"\n                )\n\n            _warn_oauth_endpoints_unresolved(\n                server_ref=server_name or server_id,\n                server_url=server_url,","sourceCodeStart":1698,"sourceCodeEnd":1734,"githubUrl":"https://github.com/BerriAI/litellm/blob/77b7c6c40c0c5aa5fbcb1d6a1825ac39ca8829b8/litellm/proxy/_experimental/mcp_server/mcp_server_manager.py#L1698-L1734","documentation":"Config-load type check: the dcr_bridge field in an MCP server definition arrived as something other than a boolean. Raising at load time keeps the flag's truthiness semantics unambiguous instead of letting any non-empty string count as true.","triggerScenarios":"Thrown at litellm/proxy/_experimental/mcp_server/mcp_server_manager.py:1716 when the library encounters an invalid state.","commonSituations":"See trigger scenarios.","solutions":["Set dcr_bridge to a boolean (true/false) in the server config."],"exampleFix":"dcr_bridge: true","handlingStrategy":"validation","validationCode":null,"typeGuard":null,"tryCatchPattern":null,"preventionTips":[],"tags":[],"backgroundTag":null,"analyzedSha":"77b7c6c40c0c5aa5fbcb1d6a1825ac39ca8829b8","analyzedAt":"2026-08-18T11:44:31.656Z","contentChangedAt":null,"schemaVersion":2},"datasetVersion":"2026-09-14T05:17:10.506Z"}