openapi: 3.2.0 info: title: LiteLLM MCP API description: 'Proxy Server to call 100+ LLMs in the OpenAI format. **Customize Swagger Docs** ๐Ÿ‘‰ ```LiteLLM Admin Panel on /ui```. Create, Edit Keys with SSO. Having issues? Try ```Fallback Login``` ๐Ÿ’ธ ```LiteLLM Model Cost Map```. ๐Ÿ”Ž ```LiteLLM Model Hub```. See available models on the proxy. **Docs**' version: 1.102.1 tags: - name: MCP paths: /mcp/proxy: get: summary: Proxy Mcp Route description: Serve the fixed three-tool MCP proxy surface. operationId: proxy_mcp_route_mcp_proxy_get responses: '200': description: Successful Response content: application/json: schema: {} tags: - MCP put: summary: Proxy Mcp Route description: Serve the fixed three-tool MCP proxy surface. operationId: proxy_mcp_route_mcp_proxy_put responses: '200': description: Successful Response content: application/json: schema: {} tags: - MCP post: summary: Proxy Mcp Route description: Serve the fixed three-tool MCP proxy surface. operationId: proxy_mcp_route_mcp_proxy_post responses: '200': description: Successful Response content: application/json: schema: {} tags: - MCP delete: summary: Proxy Mcp Route description: Serve the fixed three-tool MCP proxy surface. operationId: proxy_mcp_route_mcp_proxy_delete responses: '200': description: Successful Response content: application/json: schema: {} tags: - MCP options: summary: Proxy Mcp Route description: Serve the fixed three-tool MCP proxy surface. operationId: proxy_mcp_route_mcp_proxy_options responses: '200': description: Successful Response content: application/json: schema: {} tags: - MCP head: summary: Proxy Mcp Route description: Serve the fixed three-tool MCP proxy surface. operationId: proxy_mcp_route_mcp_proxy_head responses: '200': description: Successful Response content: application/json: schema: {} tags: - MCP patch: summary: Proxy Mcp Route description: Serve the fixed three-tool MCP proxy surface. operationId: proxy_mcp_route_mcp_proxy_patch responses: '200': description: Successful Response content: application/json: schema: {} tags: - MCP /mcp: get: summary: Aggregate Mcp Route description: 'Serve the aggregate MCP endpoint on the bare ``/mcp`` spelling: the ``/mcp`` mount cannot match its bare prefix, and the resulting 307 breaks MCP clients behind TLS-terminating proxies.' operationId: aggregate_mcp_route_mcp_get responses: '200': description: Successful Response content: application/json: schema: {} tags: - MCP put: summary: Aggregate Mcp Route description: 'Serve the aggregate MCP endpoint on the bare ``/mcp`` spelling: the ``/mcp`` mount cannot match its bare prefix, and the resulting 307 breaks MCP clients behind TLS-terminating proxies.' operationId: aggregate_mcp_route_mcp_put responses: '200': description: Successful Response content: application/json: schema: {} tags: - MCP post: summary: Aggregate Mcp Route description: 'Serve the aggregate MCP endpoint on the bare ``/mcp`` spelling: the ``/mcp`` mount cannot match its bare prefix, and the resulting 307 breaks MCP clients behind TLS-terminating proxies.' operationId: aggregate_mcp_route_mcp_post responses: '200': description: Successful Response content: application/json: schema: {} tags: - MCP delete: summary: Aggregate Mcp Route description: 'Serve the aggregate MCP endpoint on the bare ``/mcp`` spelling: the ``/mcp`` mount cannot match its bare prefix, and the resulting 307 breaks MCP clients behind TLS-terminating proxies.' operationId: aggregate_mcp_route_mcp_delete responses: '200': description: Successful Response content: application/json: schema: {} tags: - MCP options: summary: Aggregate Mcp Route description: 'Serve the aggregate MCP endpoint on the bare ``/mcp`` spelling: the ``/mcp`` mount cannot match its bare prefix, and the resulting 307 breaks MCP clients behind TLS-terminating proxies.' operationId: aggregate_mcp_route_mcp_options responses: '200': description: Successful Response content: application/json: schema: {} tags: - MCP head: summary: Aggregate Mcp Route description: 'Serve the aggregate MCP endpoint on the bare ``/mcp`` spelling: the ``/mcp`` mount cannot match its bare prefix, and the resulting 307 breaks MCP clients behind TLS-terminating proxies.' operationId: aggregate_mcp_route_mcp_head responses: '200': description: Successful Response content: application/json: schema: {} tags: - MCP patch: summary: Aggregate Mcp Route description: 'Serve the aggregate MCP endpoint on the bare ``/mcp`` spelling: the ``/mcp`` mount cannot match its bare prefix, and the resulting 307 breaks MCP clients behind TLS-terminating proxies.' operationId: aggregate_mcp_route_mcp_patch responses: '200': description: Successful Response content: application/json: schema: {} tags: - MCP /{mcp_server_name}/mcp: put: summary: Dynamic Mcp Route description: 'Handle /{name}/mcp for MCP server aliases, toolsets, MCP access group tags, and comma-separated lists. Resolution order: 1. Registered MCP server alias / name 2. Comma-separated list (short-circuits before any DB call) 3. Toolset name (DB lookup, cached) 4. MCP access group tag (DB lookup, cached)' operationId: dynamic_mcp_route__mcp_server_name__mcp_put parameters: - name: mcp_server_name in: path required: true schema: type: string title: Mcp Server Name responses: '200': description: Successful Response content: application/json: schema: {} '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' tags: - MCP patch: summary: Dynamic Mcp Route description: 'Handle /{name}/mcp for MCP server aliases, toolsets, MCP access group tags, and comma-separated lists. Resolution order: 1. Registered MCP server alias / name 2. Comma-separated list (short-circuits before any DB call) 3. Toolset name (DB lookup, cached) 4. MCP access group tag (DB lookup, cached)' operationId: dynamic_mcp_route__mcp_server_name__mcp_patch parameters: - name: mcp_server_name in: path required: true schema: type: string title: Mcp Server Name responses: '200': description: Successful Response content: application/json: schema: {} '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' tags: - MCP options: summary: Dynamic Mcp Route description: 'Handle /{name}/mcp for MCP server aliases, toolsets, MCP access group tags, and comma-separated lists. Resolution order: 1. Registered MCP server alias / name 2. Comma-separated list (short-circuits before any DB call) 3. Toolset name (DB lookup, cached) 4. MCP access group tag (DB lookup, cached)' operationId: dynamic_mcp_route__mcp_server_name__mcp_options parameters: - name: mcp_server_name in: path required: true schema: type: string title: Mcp Server Name responses: '200': description: Successful Response content: application/json: schema: {} '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' tags: - MCP get: summary: Dynamic Mcp Route description: 'Handle /{name}/mcp for MCP server aliases, toolsets, MCP access group tags, and comma-separated lists. Resolution order: 1. Registered MCP server alias / name 2. Comma-separated list (short-circuits before any DB call) 3. Toolset name (DB lookup, cached) 4. MCP access group tag (DB lookup, cached)' operationId: dynamic_mcp_route__mcp_server_name__mcp_get parameters: - name: mcp_server_name in: path required: true schema: type: string title: Mcp Server Name responses: '200': description: Successful Response content: application/json: schema: {} '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' tags: - MCP head: summary: Dynamic Mcp Route description: 'Handle /{name}/mcp for MCP server aliases, toolsets, MCP access group tags, and comma-separated lists. Resolution order: 1. Registered MCP server alias / name 2. Comma-separated list (short-circuits before any DB call) 3. Toolset name (DB lookup, cached) 4. MCP access group tag (DB lookup, cached)' operationId: dynamic_mcp_route__mcp_server_name__mcp_head parameters: - name: mcp_server_name in: path required: true schema: type: string title: Mcp Server Name responses: '200': description: Successful Response content: application/json: schema: {} '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' tags: - MCP post: summary: Dynamic Mcp Route description: 'Handle /{name}/mcp for MCP server aliases, toolsets, MCP access group tags, and comma-separated lists. Resolution order: 1. Registered MCP server alias / name 2. Comma-separated list (short-circuits before any DB call) 3. Toolset name (DB lookup, cached) 4. MCP access group tag (DB lookup, cached)' operationId: dynamic_mcp_route__mcp_server_name__mcp_post parameters: - name: mcp_server_name in: path required: true schema: type: string title: Mcp Server Name responses: '200': description: Successful Response content: application/json: schema: {} '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' tags: - MCP delete: summary: Dynamic Mcp Route description: 'Handle /{name}/mcp for MCP server aliases, toolsets, MCP access group tags, and comma-separated lists. Resolution order: 1. Registered MCP server alias / name 2. Comma-separated list (short-circuits before any DB call) 3. Toolset name (DB lookup, cached) 4. MCP access group tag (DB lookup, cached)' operationId: dynamic_mcp_route__mcp_server_name__mcp_delete parameters: - name: mcp_server_name in: path required: true schema: type: string title: Mcp Server Name responses: '200': description: Successful Response content: application/json: schema: {} '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' tags: - MCP /v1/mcp/tools: get: tags: - MCP summary: Get Mcp Tools description: Get all MCP tools available for the current key, including those from access groups operationId: get_mcp_tools_v1_mcp_tools_get responses: '200': description: Successful Response content: application/json: schema: {} security: - APIKeyHeader: [] /v1/mcp/access_groups: get: tags: - MCP summary: Get Mcp Access Groups description: Get all available MCP access groups from the database AND config operationId: get_mcp_access_groups_v1_mcp_access_groups_get responses: '200': description: Successful Response content: application/json: schema: {} security: - APIKeyHeader: [] /v1/mcp/network/client-ip: get: tags: - MCP summary: Get Client Ip description: Returns the caller's IP address as seen by the proxy. operationId: get_client_ip_v1_mcp_network_client_ip_get responses: '200': description: Successful Response content: application/json: schema: {} security: - APIKeyHeader: [] /v1/mcp/registry.json: get: tags: - MCP summary: Get Mcp Registry description: 'MCP registry endpoint. Spec: https://github.com/modelcontextprotocol/registry' operationId: get_mcp_registry_v1_mcp_registry_json_get responses: '200': description: Successful Response content: application/json: schema: {} /v1/mcp/server: get: tags: - MCP summary: Fetch All Mcp Servers description: Returns the mcp server list with associated teams operationId: fetch_all_mcp_servers_v1_mcp_server_get security: - APIKeyHeader: [] parameters: - name: team_id in: query required: false schema: anyOf: - type: string - type: 'null' description: Filter MCP servers by team scope. When provided, returns only servers the team has access to plus globally available (allow_all_keys) servers. Used by the Create Key UI to show team-scoped MCP servers. title: Team Id description: Filter MCP servers by team scope. When provided, returns only servers the team has access to plus globally available (allow_all_keys) servers. Used by the Create Key UI to show team-scoped MCP servers. - name: connected_app_view in: query required: false schema: type: boolean description: 'Annotate each returned server with connected_app_reachable: whether a connected app authorized by the calling user (a gateway OAuth session) is served this server on the aggregate MCP endpoint.' default: false title: Connected App View description: 'Annotate each returned server with connected_app_reachable: whether a connected app authorized by the calling user (a gateway OAuth session) is served this server on the aggregate MCP endpoint.' responses: '200': description: Successful Response content: application/json: schema: type: array items: $ref: '#/components/schemas/LiteLLM_MCPServerTable' title: Response Fetch All Mcp Servers V1 Mcp Server Get '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' post: tags: - MCP summary: Add Mcp Server description: Allows creation of mcp servers operationId: add_mcp_server_v1_mcp_server_post security: - APIKeyHeader: [] parameters: - name: litellm-changed-by in: header required: false schema: anyOf: - type: string - type: 'null' description: The litellm-changed-by header enables tracking of actions performed by authorized users on behalf of other users, providing an audit trail for accountability title: Litellm-Changed-By description: The litellm-changed-by header enables tracking of actions performed by authorized users on behalf of other users, providing an audit trail for accountability requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/NewMCPServerRequest' responses: '201': description: Successful Response content: application/json: schema: $ref: '#/components/schemas/LiteLLM_MCPServerTable' '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' put: tags: - MCP summary: Edit Mcp Server description: Allows deleting mcp serves in the db operationId: edit_mcp_server_v1_mcp_server_put security: - APIKeyHeader: [] parameters: - name: litellm-changed-by in: header required: false schema: anyOf: - type: string - type: 'null' description: The litellm-changed-by header enables tracking of actions performed by authorized users on behalf of other users, providing an audit trail for accountability title: Litellm-Changed-By description: The litellm-changed-by header enables tracking of actions performed by authorized users on behalf of other users, providing an audit trail for accountability requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/UpdateMCPServerRequest' responses: '202': description: Successful Response content: application/json: schema: $ref: '#/components/schemas/LiteLLM_MCPServerTable' '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' /v1/mcp/server/health: get: tags: - MCP summary: Health Check Servers description: Health check for MCP servers operationId: health_check_servers_v1_mcp_server_health_get security: - APIKeyHeader: [] parameters: - name: server_ids in: query required: false schema: anyOf: - type: array items: type: string - type: 'null' description: Server IDs to check. If not provided, checks all accessible servers. title: Server Ids description: Server IDs to check. If not provided, checks all accessible servers. responses: '200': description: Successful Response content: application/json: schema: {} '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' /v1/mcp/server/register: post: tags: - MCP summary: Register Mcp Server description: Submit a new MCP server for admin review (non-admin users). Mirrors POST /guardrails/register. operationId: register_mcp_server_v1_mcp_server_register_post requestBody: content: application/json: schema: $ref: '#/components/schemas/NewMCPServerRequest' required: true responses: '201': description: Successful Response content: application/json: schema: $ref: '#/components/schemas/LiteLLM_MCPServerTable' '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' security: - APIKeyHeader: [] /v1/mcp/server/submissions: get: tags: - MCP summary: Get Mcp Server Submissions description: Returns all MCP servers submitted by non-admin users (admin review queue). Mirrors GET /guardrails/submissions. operationId: get_mcp_server_submissions_v1_mcp_server_submissions_get responses: '200': description: Successful Response content: application/json: schema: $ref: '#/components/schemas/MCPSubmissionsSummary' security: - APIKeyHeader: [] /v1/mcp/server/{server_id}/approve: put: tags: - MCP summary: Approve Mcp Server Submission description: Approve a pending MCP server submission (admin only). Mirrors PUT /guardrails/{id}/approve. operationId: approve_mcp_server_submission_v1_mcp_server__server_id__approve_put security: - APIKeyHeader: [] parameters: - name: server_id in: path required: true schema: type: string title: Server Id responses: '200': description: Successful Response content: application/json: schema: $ref: '#/components/schemas/LiteLLM_MCPServerTable' '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' /v1/mcp/server/{server_id}/reject: put: tags: - MCP summary: Reject Mcp Server Submission description: Reject a pending MCP server submission (admin only). Mirrors PUT /guardrails/{id}/reject. operationId: reject_mcp_server_submission_v1_mcp_server__server_id__reject_put security: - APIKeyHeader: [] parameters: - name: server_id in: path required: true schema: type: string title: Server Id requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/RejectMCPServerRequest' responses: '200': description: Successful Response content: application/json: schema: $ref: '#/components/schemas/LiteLLM_MCPServerTable' '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' /v1/mcp/server/{server_id}: get: tags: - MCP summary: Fetch Mcp Server description: Returns the mcp server info operationId: fetch_mcp_server_v1_mcp_server__server_id__get security: - APIKeyHeader: [] parameters: - name: server_id in: path required: true schema: type: string title: Server Id responses: '200': description: Successful Response content: application/json: schema: $ref: '#/components/schemas/LiteLLM_MCPServerTable' '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' delete: tags: - MCP summary: Remove Mcp Server description: Allows deleting mcp serves in the db operationId: remove_mcp_server_v1_mcp_server__server_id__delete security: - APIKeyHeader: [] parameters: - name: server_id in: path required: true schema: type: string title: Server Id - name: litellm-changed-by in: header required: false schema: anyOf: - type: string - type: 'null' description: The litellm-changed-by header enables tracking of actions performed by authorized users on behalf of other users, providing an audit trail for accountability title: Litellm-Changed-By description: The litellm-changed-by header enables tracking of actions performed by authorized users on behalf of other users, providing an audit trail for accountability responses: '202': description: Successful Response content: application/json: schema: {} '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' /v1/mcp/server/import: post: tags: - MCP summary: Import Mcp Servers description: Bulk-import MCP connectors from Anthropic mcpServers or mcp_servers JSON operationId: import_mcp_servers_v1_mcp_server_import_post requestBody: content: application/json: schema: $ref: '#/components/schemas/MCPConnectorImportRequest' required: true responses: '200': description: Successful Response content: application/json: schema: $ref: '#/components/schemas/MCPConnectorImportResponse' '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' security: - APIKeyHeader: [] /v1/mcp/server/oauth/session: post: tags: - MCP summary: Add Session Mcp Server description: Temporarily cache an MCP server in memory without writing to the database operationId: add_session_mcp_server_v1_mcp_server_oauth_session_post security: - APIKeyHeader: [] parameters: - name: litellm-changed-by in: header required: false schema: anyOf: - type: string - type: 'null' description: The litellm-changed-by header enables tracking of actions performed by authorized users on behalf of other users, providing an audit trail for accountability title: Litellm-Changed-By description: The litellm-changed-by header enables tracking of actions performed by authorized users on behalf of other users, providing an audit trail for accountability requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/NewMCPServerRequest' responses: '200': description: Successful Response content: application/json: schema: {} '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' /v1/mcp/server/{server_id}/user-credential: post: tags: - MCP summary: Store Mcp User Credential description: Store or update the calling user's API key for a BYOK MCP server operationId: store_mcp_user_credential_v1_mcp_server__server_id__user_credential_post security: - APIKeyHeader: [] parameters: - name: server_id in: path required: true schema: type: string title: Server Id requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/MCPUserCredentialRequest' responses: '200': description: Successful Response content: application/json: schema: $ref: '#/components/schemas/MCPUserCredentialResponse' '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' delete: tags: - MCP summary: Delete Mcp User Credential description: Delete the calling user's stored API key for a BYOK MCP server operationId: delete_mcp_user_credential_v1_mcp_server__server_id__user_credential_delete security: - APIKeyHeader: [] parameters: - name: server_id in: path required: true schema: type: string title: Server Id responses: '200': description: Successful Response content: application/json: schema: $ref: '#/components/schemas/MCPUserCredentialResponse' '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' /v1/mcp/server/{server_id}/oauth-user-credential: post: tags: - MCP summary: Store Mcp Oauth User Credential description: Store the calling user's OAuth2 token for an OpenAPI MCP server operationId: store_mcp_oauth_user_credential_v1_mcp_server__server_id__oauth_user_credential_post security: - APIKeyHeader: [] parameters: - name: server_id in: path required: true schema: type: string title: Server Id requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/MCPOAuthUserCredentialRequest' responses: '200': description: Successful Response content: application/json: schema: $ref: '#/components/schemas/MCPOAuthUserCredentialStatus' '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' delete: tags: - MCP summary: Delete Mcp Oauth User Credential description: Revoke the calling user's stored OAuth2 token for an MCP server operationId: delete_mcp_oauth_user_credential_v1_mcp_server__server_id__oauth_user_credential_delete security: - APIKeyHeader: [] parameters: - name: server_id in: path required: true schema: type: string title: Server Id responses: '200': description: Successful Response content: application/json: schema: $ref: '#/components/schemas/MCPOAuthUserCredentialStatus' '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' /v1/mcp/server/{server_id}/oauth-user-credential/status: get: tags: - MCP summary: Get Mcp Oauth User Credential Status description: Check whether the calling user has a stored OAuth2 credential for this MCP server operationId: get_mcp_oauth_user_credential_status_v1_mcp_server__server_id__oauth_user_credential_status_get security: - APIKeyHeader: [] parameters: - name: server_id in: path required: true schema: type: string title: Server Id responses: '200': description: Successful Response content: application/json: schema: $ref: '#/components/schemas/MCPOAuthUserCredentialStatus' '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' /v1/mcp/user-credentials: get: tags: - MCP summary: List Mcp User Credentials description: List all OAuth2 MCP credentials stored for the calling user operationId: list_mcp_user_credentials_v1_mcp_user_credentials_get responses: '200': description: Successful Response content: application/json: schema: items: $ref: '#/components/schemas/MCPUserCredentialListItem' type: array title: Response List Mcp User Credentials V1 Mcp User Credentials Get security: - APIKeyHeader: [] /v1/mcp/server/{server_id}/user-env-vars: get: tags: - MCP summary: Get Mcp User Env Vars description: Return the calling user's per-user MCP env var status for this server. operationId: get_mcp_user_env_vars_v1_mcp_server__server_id__user_env_vars_get security: - APIKeyHeader: [] parameters: - name: server_id in: path required: true schema: type: string title: Server Id responses: '200': description: Successful Response content: application/json: schema: $ref: '#/components/schemas/MCPUserEnvVarsStatus' '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' post: tags: - MCP summary: Store Mcp User Env Vars description: Store the calling user's per-user MCP env var values for this server. Submitted values are merged over any previously stored values, so you only send the fields you want to set or change; a variable omitted (or sent empty) keeps its stored value. Use DELETE to clear all stored values. operationId: store_mcp_user_env_vars_v1_mcp_server__server_id__user_env_vars_post security: - APIKeyHeader: [] parameters: - name: server_id in: path required: true schema: type: string title: Server Id requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/MCPUserEnvVarsRequest' responses: '200': description: Successful Response content: application/json: schema: $ref: '#/components/schemas/MCPUserEnvVarsStatus' '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' delete: tags: - MCP summary: Clear Mcp User Env Vars description: Clear the calling user's per-user MCP env var values for this server. operationId: clear_mcp_user_env_vars_v1_mcp_server__server_id__user_env_vars_delete security: - APIKeyHeader: [] parameters: - name: server_id in: path required: true schema: type: string title: Server Id responses: '200': description: Successful Response content: application/json: schema: $ref: '#/components/schemas/MCPUserEnvVarsStatus' '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' /v1/mcp/user-env-vars/status: get: tags: - MCP summary: List Mcp User Env Var Status description: Per-user MCP env var status across every server the user can access. Used by the dashboard to highlight servers with missing per-user vars. operationId: list_mcp_user_env_var_status_v1_mcp_user_env_vars_status_get responses: '200': description: Successful Response content: application/json: schema: items: $ref: '#/components/schemas/MCPUserEnvVarsStatus' type: array title: Response List Mcp User Env Var Status V1 Mcp User Env Vars Status Get security: - APIKeyHeader: [] /v1/mcp/make_public: post: tags: - MCP summary: Make Mcp Servers Public description: Allows making MCP servers public for AI Hub operationId: make_mcp_servers_public_v1_mcp_make_public_post requestBody: content: application/json: schema: $ref: '#/components/schemas/MakeMCPServersPublicRequest' required: true responses: '202': description: Successful Response content: application/json: schema: {} '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' security: - APIKeyHeader: [] /v1/mcp/discover: get: tags: - MCP summary: Discover Mcp Servers description: Returns a curated list of well-known MCP servers for discovery UI operationId: discover_mcp_servers_v1_mcp_discover_get security: - APIKeyHeader: [] parameters: - name: query in: query required: false schema: anyOf: - type: string - type: 'null' description: Search filter for server names and descriptions title: Query description: Search filter for server names and descriptions - name: category in: query required: false schema: anyOf: - type: string - type: 'null' description: Filter by category title: Category description: Filter by category responses: '200': description: Successful Response content: application/json: schema: {} '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' /v1/mcp/openapi-registry: get: tags: - MCP summary: Get Openapi Registry description: Returns well-known OpenAPI APIs with OAuth 2.0 metadata for the OpenAPI MCP picker operationId: get_openapi_registry_v1_mcp_openapi_registry_get responses: '200': description: Successful Response content: application/json: schema: {} security: - APIKeyHeader: [] /v1/mcp/toolset: post: tags: - MCP summary: Add Mcp Toolset description: Create a new MCP toolset (admin only) operationId: add_mcp_toolset_v1_mcp_toolset_post security: - APIKeyHeader: [] parameters: - name: litellm-changed-by in: header required: false schema: anyOf: - type: string - type: 'null' title: Litellm-Changed-By requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/NewMCPToolsetRequest' responses: '201': description: Successful Response content: application/json: schema: {} '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' get: tags: - MCP summary: Fetch Mcp Toolsets description: List MCP toolsets accessible to the calling key operationId: fetch_mcp_toolsets_v1_mcp_toolset_get security: - APIKeyHeader: [] responses: '200': description: Successful Response content: application/json: schema: {} put: tags: - MCP summary: Edit Mcp Toolset description: Update an existing MCP toolset (admin only) operationId: edit_mcp_toolset_v1_mcp_toolset_put security: - APIKeyHeader: [] parameters: - name: litellm-changed-by in: header required: false schema: anyOf: - type: string - type: 'null' title: Litellm-Changed-By requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/UpdateMCPToolsetRequest' responses: '200': description: Successful Response content: application/json: schema: {} '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' /v1/mcp/toolset/{toolset_id}: get: tags: - MCP summary: Fetch Mcp Toolset description: Get a specific MCP toolset by ID operationId: fetch_mcp_toolset_v1_mcp_toolset__toolset_id__get security: - APIKeyHeader: [] parameters: - name: toolset_id in: path required: true schema: type: string title: Toolset Id responses: '200': description: Successful Response content: application/json: schema: {} '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' delete: tags: - MCP summary: Remove Mcp Toolset description: Delete an MCP toolset (admin only) operationId: remove_mcp_toolset_v1_mcp_toolset__toolset_id__delete security: - APIKeyHeader: [] parameters: - name: toolset_id in: path required: true schema: type: string title: Toolset Id - name: litellm-changed-by in: header required: false schema: anyOf: - type: string - type: 'null' title: Litellm-Changed-By responses: '202': description: Successful Response content: application/json: schema: {} '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' /authorize/mcp-session: get: tags: - MCP summary: Authorize Mcp Session operationId: authorize_mcp_session_authorize_mcp_session_get parameters: - name: redirect_uri in: query required: true schema: type: string title: Redirect Uri - name: client_id in: query required: true schema: type: string title: Client Id - name: state in: query required: false schema: type: string default: '' title: State - name: code_challenge in: query required: false schema: anyOf: - type: string - type: 'null' title: Code Challenge - name: code_challenge_method in: query required: false schema: anyOf: - type: string - type: 'null' title: Code Challenge Method - name: response_type in: query required: false schema: anyOf: - type: string - type: 'null' title: Response Type - name: resource in: query required: false schema: anyOf: - type: string - type: 'null' title: Resource responses: '200': description: Successful Response content: application/json: schema: {} '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' /authorize: get: tags: - MCP summary: Authorize operationId: authorize_authorize_get parameters: - name: redirect_uri in: query required: true schema: type: string title: Redirect Uri - name: client_id in: query required: false schema: anyOf: - type: string - type: 'null' title: Client Id - name: state in: query required: false schema: type: string default: '' title: State - name: mcp_server_name in: query required: false schema: anyOf: - type: string - type: 'null' title: Mcp Server Name - name: code_challenge in: query required: false schema: anyOf: - type: string - type: 'null' title: Code Challenge - name: code_challenge_method in: query required: false schema: anyOf: - type: string - type: 'null' title: Code Challenge Method - name: response_type in: query required: false schema: anyOf: - type: string - type: 'null' title: Response Type - name: scope in: query required: false schema: anyOf: - type: string - type: 'null' title: Scope - name: resource in: query required: false schema: anyOf: - type: string - type: 'null' title: Resource responses: '200': description: Successful Response content: application/json: schema: {} '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' /{mcp_server_name}/authorize: get: tags: - MCP summary: Authorize operationId: authorize__mcp_server_name__authorize_get parameters: - name: mcp_server_name in: path required: true schema: anyOf: - type: string - type: 'null' title: Mcp Server Name - name: redirect_uri in: query required: true schema: type: string title: Redirect Uri - name: client_id in: query required: false schema: anyOf: - type: string - type: 'null' title: Client Id - name: state in: query required: false schema: type: string default: '' title: State - name: code_challenge in: query required: false schema: anyOf: - type: string - type: 'null' title: Code Challenge - name: code_challenge_method in: query required: false schema: anyOf: - type: string - type: 'null' title: Code Challenge Method - name: response_type in: query required: false schema: anyOf: - type: string - type: 'null' title: Response Type - name: scope in: query required: false schema: anyOf: - type: string - type: 'null' title: Scope - name: resource in: query required: false schema: anyOf: - type: string - type: 'null' title: Resource responses: '200': description: Successful Response content: application/json: schema: {} '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' /token: post: tags: - MCP summary: Token Endpoint description: 'Accept the authorization code from client and exchange it for OAuth token. Supports PKCE flow by forwarding code_verifier to upstream provider. 1. Call the token endpoint with PKCE parameters 2. Store the user''s token in the db - and generate a LiteLLM virtual key 3. Return the token 4. Return a virtual key in this response' operationId: token_endpoint_token_post parameters: - name: mcp_server_name in: query required: false schema: anyOf: - type: string - type: 'null' title: Mcp Server Name requestBody: required: true content: application/x-www-form-urlencoded: schema: $ref: '#/components/schemas/Body_token_endpoint_token_post' responses: '200': description: Successful Response content: application/json: schema: {} '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' /{mcp_server_name}/token: post: tags: - MCP summary: Token Endpoint description: 'Accept the authorization code from client and exchange it for OAuth token. Supports PKCE flow by forwarding code_verifier to upstream provider. 1. Call the token endpoint with PKCE parameters 2. Store the user''s token in the db - and generate a LiteLLM virtual key 3. Return the token 4. Return a virtual key in this response' operationId: token_endpoint__mcp_server_name__token_post parameters: - name: mcp_server_name in: path required: true schema: anyOf: - type: string - type: 'null' title: Mcp Server Name requestBody: required: true content: application/x-www-form-urlencoded: schema: $ref: '#/components/schemas/Body_token_endpoint__mcp_server_name__token_post' responses: '200': description: Successful Response content: application/json: schema: {} '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' /authorize/flow: get: tags: - MCP summary: Authorize Flow operationId: authorize_flow_authorize_flow_get parameters: - name: flow in: query required: true schema: type: string title: Flow responses: '200': description: Successful Response content: application/json: schema: {} '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' /authorize/complete: post: tags: - MCP summary: Authorize Complete description: 'Finish an aggregate connect flow: mint the gateway authorization code for the signed-in user and hand it back to the DCR client, by 303 redirect (default) or, for a loopback client on a different machine, as a copyable callback URL (``delivery=manual``). POST plus the per-flow HttpOnly cookie set at /authorize; an anonymous or bad-flow request just 400s. The native-client consent page adds ``decision`` (approve or deny) and the ``team_id`` the credential is attributed to.' operationId: authorize_complete_authorize_complete_post requestBody: content: application/x-www-form-urlencoded: schema: $ref: '#/components/schemas/Body_authorize_complete_authorize_complete_post' required: true responses: '200': description: Successful Response content: application/json: schema: {} '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' /revoke: post: tags: - MCP summary: Revoke Endpoint description: 'RFC 7009 revocation for the gateway''s refresh tokens (``lite logout``): 200 for a known client whatever the token''s state, 503 when the shared single-use record cannot be written; access tokens expire on their own.' operationId: revoke_endpoint_revoke_post requestBody: content: application/x-www-form-urlencoded: schema: $ref: '#/components/schemas/Body_revoke_endpoint_revoke_post' required: true responses: '200': description: Successful Response content: application/json: schema: {} '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' /introspect: post: tags: - MCP summary: Introspect Endpoint description: 'RFC 7662 introspection for gateway-issued session tokens (``llm_session_`` / ``llm_srefresh_``), so an external gateway can validate them without the signing secret. The caller authenticates with a LiteLLM virtual key (section 2.1, enforced by the route dependency); any token the gateway cannot vouch for answers ``{"active": false}`` with no further detail.' operationId: introspect_endpoint_introspect_post requestBody: content: application/x-www-form-urlencoded: schema: $ref: '#/components/schemas/Body_introspect_endpoint_introspect_post' required: true responses: '200': description: Successful Response content: application/json: schema: {} '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' security: - APIKeyHeader: [] /.well-known/litellm-cli-auth: get: tags: - MCP summary: Native Client Auth Discovery description: 'The versioned contract a native client (``lite login --pkce``, or a CLI in any other language) reads to sign a user in through the browser and obtain a proxy credential.' operationId: native_client_auth_discovery__well_known_litellm_cli_auth_get responses: '200': description: Successful Response content: application/json: schema: {} /callback: get: tags: - MCP summary: Callback description: 'OAuth 2.0 authorization response handler for MCP loopback clients. Accepts either: - A successful authorization response (``code`` + ``state``), which is forwarded back to the validated client ``redirect_uri`` with the original (un-wrapped) ``state``. - An error response (``error``[+``error_description``/``error_uri``]), per RFC 6749 ยง4.1.2.1. When ``state`` is present and decodes to a trusted ``redirect_uri``, the error params are propagated back to the client so its OAuth library can surface them. Otherwise we render an HTML error page so the user is not left on an opaque 422 / blank screen.' operationId: callback_callback_get parameters: - name: code in: query required: false schema: anyOf: - type: string - type: 'null' title: Code - name: state in: query required: false schema: anyOf: - type: string - type: 'null' title: State - name: error in: query required: false schema: anyOf: - type: string - type: 'null' title: Error - name: error_description in: query required: false schema: anyOf: - type: string - type: 'null' title: Error Description - name: error_uri in: query required: false schema: anyOf: - type: string - type: 'null' title: Error Uri responses: '200': description: Successful Response content: application/json: schema: {} '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' /.well-known/oauth-protected-resource: get: tags: - MCP summary: Oauth Protected Resource Root operationId: oauth_protected_resource_root__well_known_oauth_protected_resource_get responses: '200': description: Successful Response content: application/json: schema: additionalProperties: anyOf: - type: string - items: type: string type: array type: object title: Response Oauth Protected Resource Root Well Known Oauth Protected Resource Get /.well-known/oauth-protected-resource/mcp: get: tags: - MCP summary: Oauth Protected Resource Aggregate description: 'OAuth protected resource discovery for the aggregate /mcp endpoint. The single-segment ``/mcp`` path does not collide with any per-server PRM pattern (those are two-segment: ``/mcp/{server}`` or ``/{server}/mcp``), so this unambiguously describes the aggregate resource.' operationId: oauth_protected_resource_aggregate__well_known_oauth_protected_resource_mcp_get responses: '200': description: Successful Response content: application/json: schema: {} /.well-known/oauth-authorization-server/mcp: get: tags: - MCP summary: Oauth Authorization Server Aggregate description: 'OAuth authorization server discovery for the aggregate /mcp endpoint, the RFC 8414 path-inserted form for a client that treats {base}/mcp as its authorization base URL. The single-segment /mcp is reserved for the aggregate so the discovery chain stays consistent: the aggregate protected-resource document advertises {base}/mcp as its authorization server, so the document served here must have issuer {base}/mcp. A server literally named ``mcp`` therefore does not take this route; it keeps its standard two-segment discovery at /.well-known/oauth-authorization-server/mcp/mcp. Letting the per-server row win here instead would serve an issuer of {base} against a resource that advertised {base}/mcp, which fails the RFC 8414 issuer check and breaks the front door.' operationId: oauth_authorization_server_aggregate__well_known_oauth_authorization_server_mcp_get responses: '200': description: Successful Response content: application/json: schema: {} /.well-known/oauth-protected-resource/mcp/{mcp_server_name}: get: tags: - MCP summary: Oauth Protected Resource Mcp Standard description: 'OAuth protected resource discovery endpoint using standard MCP URL pattern. Standard pattern: /mcp/{server_name} Discovery path: /.well-known/oauth-protected-resource/mcp/{server_name} This endpoint is compliant with MCP specification and works with standard MCP clients like mcp-inspector and VSCode Copilot.' operationId: oauth_protected_resource_mcp_standard__well_known_oauth_protected_resource_mcp__mcp_server_name__get parameters: - name: mcp_server_name in: path required: true schema: type: string title: Mcp Server Name responses: '200': description: Successful Response content: application/json: schema: {} '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' /.well-known/oauth-protected-resource/{mcp_server_name}/mcp: get: tags: - MCP summary: Oauth Protected Resource Mcp description: 'OAuth protected resource discovery endpoint using LiteLLM legacy URL pattern. Legacy pattern: /{server_name}/mcp Discovery path: /.well-known/oauth-protected-resource/{server_name}/mcp This endpoint is kept for backward compatibility. New integrations should use the standard MCP pattern (/mcp/{server_name}) instead.' operationId: oauth_protected_resource_mcp__well_known_oauth_protected_resource__mcp_server_name__mcp_get parameters: - name: mcp_server_name in: path required: true schema: anyOf: - type: string - type: 'null' title: Mcp Server Name responses: '200': description: Successful Response content: application/json: schema: {} '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' /.well-known/oauth-authorization-server/mcp/{mcp_server_name}: get: tags: - MCP summary: Oauth Authorization Server Mcp Standard description: 'OAuth authorization server discovery endpoint using standard MCP URL pattern. Standard pattern: /mcp/{server_name} Discovery path: /.well-known/oauth-authorization-server/mcp/{server_name}' operationId: oauth_authorization_server_mcp_standard__well_known_oauth_authorization_server_mcp__mcp_server_name__get parameters: - name: mcp_server_name in: path required: true schema: type: string title: Mcp Server Name responses: '200': description: Successful Response content: application/json: schema: {} '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' /.well-known/oauth-authorization-server: get: tags: - MCP summary: Oauth Authorization Server Mcp description: 'OAuth authorization server discovery endpoint. Supports both legacy pattern (/{server_name}) and root endpoint.' operationId: oauth_authorization_server_mcp__well_known_oauth_authorization_server_get parameters: - name: mcp_server_name in: query required: false schema: anyOf: - type: string - type: 'null' title: Mcp Server Name responses: '200': description: Successful Response content: application/json: schema: {} '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' /.well-known/oauth-authorization-server/{mcp_server_name}: get: tags: - MCP summary: Oauth Authorization Server Mcp description: 'OAuth authorization server discovery endpoint. Supports both legacy pattern (/{server_name}) and root endpoint.' operationId: oauth_authorization_server_mcp__well_known_oauth_authorization_server__mcp_server_name__get parameters: - name: mcp_server_name in: path required: true schema: anyOf: - type: string - type: 'null' title: Mcp Server Name responses: '200': description: Successful Response content: application/json: schema: {} '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' /.well-known/openid-configuration: get: tags: - MCP summary: Openid Configuration operationId: openid_configuration__well_known_openid_configuration_get responses: '200': description: Successful Response content: application/json: schema: {} /.well-known/jwks.json: get: tags: - MCP summary: Jwks Json description: 'JSON Web Key Set endpoint. Returns the RSA public key used by MCPJWTSigner to sign outbound MCP tokens. MCP servers and gateways use this endpoint to verify liteLLM-issued JWTs. Returns an empty key set if MCPJWTSigner is not configured.' operationId: jwks_json__well_known_jwks_json_get responses: '200': description: Successful Response content: application/json: schema: {} /.well-known/oauth-authorization-server/{mcp_server_name}/mcp: get: tags: - MCP summary: Oauth Authorization Server Legacy description: OAuth authorization server discovery for legacy /{server_name}/mcp pattern. operationId: oauth_authorization_server_legacy__well_known_oauth_authorization_server__mcp_server_name__mcp_get parameters: - name: mcp_server_name in: path required: true schema: type: string title: Mcp Server Name responses: '200': description: Successful Response content: application/json: schema: {} '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' /register: post: tags: - MCP summary: Register Client operationId: register_client_register_post parameters: - name: mcp_server_name in: query required: false schema: anyOf: - type: string - type: 'null' title: Mcp Server Name responses: '200': description: Successful Response content: application/json: schema: {} '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' /{mcp_server_name}/register: post: tags: - MCP summary: Register Client operationId: register_client__mcp_server_name__register_post parameters: - name: mcp_server_name in: path required: true schema: anyOf: - type: string - type: 'null' title: Mcp Server Name responses: '200': description: Successful Response content: application/json: schema: {} '422': description: Validation Error content: application/json: schema: $ref: '#/components/schemas/HTTPValidationError' components: schemas: ValidationError: properties: loc: items: anyOf: - type: string - type: integer type: array title: Location msg: type: string title: Message type: type: string title: Error Type input: title: Input ctx: type: object title: Context type: object required: - loc - msg - type title: ValidationError HTTPValidationError: properties: detail: items: $ref: '#/components/schemas/ValidationError' type: array title: Detail type: object title: HTTPValidationError MCPToolsetTool: properties: server_id: type: string title: Server Id tool_name: type: string title: Tool Name type: object required: - server_id - tool_name title: MCPToolsetTool RejectMCPServerRequest: properties: review_notes: anyOf: - type: string - type: 'null' title: Review Notes type: object title: RejectMCPServerRequest NewMCPToolsetRequest: properties: toolset_name: type: string title: Toolset Name description: anyOf: - type: string - type: 'null' title: Description tools: items: $ref: '#/components/schemas/MCPToolsetTool' type: array title: Tools default: [] type: object required: - toolset_name title: NewMCPToolsetRequest Body_token_endpoint__mcp_server_name__token_post: properties: grant_type: type: string title: Grant Type code: type: string title: Code redirect_uri: type: string title: Redirect Uri client_id: type: string title: Client Id client_secret: anyOf: - type: string - type: 'null' title: Client Secret code_verifier: type: string title: Code Verifier refresh_token: anyOf: - type: string - type: 'null' title: Refresh Token scope: anyOf: - type: string - type: 'null' title: Scope resource: anyOf: - type: string - type: 'null' title: Resource type: object required: - grant_type - client_id title: Body_token_endpoint__mcp_server_name__token_post UpdateMCPToolsetRequest: properties: toolset_id: type: string title: Toolset Id toolset_name: anyOf: - type: string - type: 'null' title: Toolset Name description: anyOf: - type: string - type: 'null' title: Description tools: anyOf: - items: $ref: '#/components/schemas/MCPToolsetTool' type: array - type: 'null' title: Tools type: object required: - toolset_id title: UpdateMCPToolsetRequest MCPOAuthUserCredentialRequest: properties: access_token: type: string title: Access Token refresh_token: anyOf: - type: string - type: 'null' title: Refresh Token expires_in: anyOf: - type: integer - type: 'null' title: Expires In scopes: anyOf: - items: type: string type: array - type: 'null' title: Scopes type: object required: - access_token title: MCPOAuthUserCredentialRequest description: Stores a user's OAuth2 token for an OpenAPI MCP server. MCPUserEnvVarsStatus: properties: server_id: type: string title: Server Id server_name: anyOf: - type: string - type: 'null' title: Server Name alias: anyOf: - type: string - type: 'null' title: Alias required: items: $ref: '#/components/schemas/MCPUserEnvVarSpec' type: array title: Required missing_count: type: integer title: Missing Count default: 0 setup_url: anyOf: - type: string - type: 'null' title: Setup Url type: object required: - server_id title: MCPUserEnvVarsStatus description: Per-user env var status for a single MCP server. MakeMCPServersPublicRequest: properties: mcp_server_ids: items: type: string type: array title: Mcp Server Ids type: object required: - mcp_server_ids title: MakeMCPServersPublicRequest MCPUserCredentialRequest: properties: credential: type: string title: Credential save: type: boolean title: Save default: true type: object required: - credential title: MCPUserCredentialRequest Body_authorize_complete_authorize_complete_post: properties: flow: type: string title: Flow delivery: anyOf: - type: string - type: 'null' title: Delivery team_id: anyOf: - type: string - type: 'null' title: Team Id decision: anyOf: - type: string - type: 'null' title: Decision type: object required: - flow title: Body_authorize_complete_authorize_complete_post Body_token_endpoint_token_post: properties: grant_type: type: string title: Grant Type code: type: string title: Code redirect_uri: type: string title: Redirect Uri client_id: type: string title: Client Id client_secret: anyOf: - type: string - type: 'null' title: Client Secret code_verifier: type: string title: Code Verifier refresh_token: anyOf: - type: string - type: 'null' title: Refresh Token scope: anyOf: - type: string - type: 'null' title: Scope resource: anyOf: - type: string - type: 'null' title: Resource type: object required: - grant_type - client_id title: Body_token_endpoint_token_post MCPConnectorEntry: properties: name: anyOf: - type: string - type: 'null' title: Name type: anyOf: - type: string - type: 'null' title: Type url: anyOf: - type: string - type: 'null' title: Url authorization_token: anyOf: - type: string - type: 'null' title: Authorization Token headers: anyOf: - additionalProperties: type: string type: object - type: 'null' title: Headers command: anyOf: - type: string - type: 'null' title: Command args: items: type: string type: array title: Args env: additionalProperties: type: string type: object title: Env description: anyOf: - type: string - type: 'null' title: Description type: object title: MCPConnectorEntry MCPConnectorImportResult: properties: name: type: string title: Name server_id: type: string title: Server Id alias: type: string title: Alias type: object required: - name - server_id - alias title: MCPConnectorImportResult MCPConnectorImportSkipped: properties: name: type: string title: Name reason: type: string title: Reason type: object required: - name - reason title: MCPConnectorImportSkipped MCPConnectorImportRequest: properties: mcp_servers: anyOf: - additionalProperties: $ref: '#/components/schemas/MCPConnectorEntry' type: object - items: $ref: '#/components/schemas/MCPConnectorEntry' type: array title: Mcp Servers type: object required: - mcp_servers title: MCPConnectorImportRequest NewMCPServerRequest: properties: server_id: anyOf: - type: string - type: 'null' title: Server Id server_name: anyOf: - type: string - type: 'null' title: Server Name alias: anyOf: - type: string - type: 'null' title: Alias description: anyOf: - type: string - type: 'null' title: Description transport: type: string enum: - sse - http - stdio title: Transport default: sse auth_type: anyOf: - type: string enum: - none - api_key - bearer_token - basic - authorization - oauth2 - aws_sigv4 - token - oauth2_token_exchange - oauth2_id_jag - true_passthrough - oauth_delegate - type: 'null' title: Auth Type credentials: anyOf: - $ref: '#/components/schemas/MCPCredentials' - type: 'null' url: anyOf: - type: string - type: 'null' title: Url spec_path: anyOf: - type: string - type: 'null' title: Spec Path mcp_info: anyOf: - additionalProperties: true type: object - type: 'null' title: Mcp Info mcp_access_groups: items: type: string type: array title: Mcp Access Groups allowed_tools: anyOf: - items: type: string type: array - type: 'null' title: Allowed Tools tool_name_to_display_name: anyOf: - additionalProperties: type: string type: object - type: 'null' title: Tool Name To Display Name tool_name_to_description: anyOf: - additionalProperties: type: string type: object - type: 'null' title: Tool Name To Description extra_headers: anyOf: - items: type: string type: array - type: 'null' title: Extra Headers static_headers: anyOf: - additionalProperties: type: string type: object - type: 'null' title: Static Headers env_vars: anyOf: - items: $ref: '#/components/schemas/MCPEnvVar' type: array - type: 'null' title: Env Vars instructions: anyOf: - type: string - type: 'null' title: Instructions command: anyOf: - type: string - type: 'null' title: Command args: items: type: string type: array title: Args env: additionalProperties: type: string type: object title: Env issuer: anyOf: - type: string - type: 'null' title: Issuer authorization_url: anyOf: - type: string - type: 'null' title: Authorization Url token_url: anyOf: - type: string - type: 'null' title: Token Url registration_url: anyOf: - type: string - type: 'null' title: Registration Url oauth2_flow: anyOf: - type: string enum: - client_credentials - authorization_code - type: 'null' title: Oauth2 Flow token_exchange_endpoint: anyOf: - type: string - type: 'null' title: Token Exchange Endpoint audience: anyOf: - type: string - type: 'null' title: Audience subject_token_type: anyOf: - type: string - type: 'null' title: Subject Token Type token_exchange_profile: anyOf: - type: string - type: 'null' title: Token Exchange Profile allow_all_keys: type: boolean title: Allow All Keys default: false available_on_public_internet: type: boolean title: Available On Public Internet default: true delegate_auth_to_upstream: type: boolean title: Delegate Auth To Upstream default: false oauth_passthrough: type: boolean title: Oauth Passthrough default: false dcr_bridge: anyOf: - type: boolean - type: 'null' title: Dcr Bridge per_server_oauth_discovery: type: boolean title: Per Server Oauth Discovery default: false is_byok: type: boolean title: Is Byok default: false byok_description: items: type: string type: array title: Byok Description byok_api_key_help_url: anyOf: - type: string - type: 'null' title: Byok Api Key Help Url source_url: anyOf: - type: string - type: 'null' title: Source Url timeout: anyOf: - type: number - type: 'null' title: Timeout max_concurrent_requests: anyOf: - type: integer - type: 'null' title: Max Concurrent Requests approval_status: anyOf: - type: string - type: 'null' title: Approval Status description: 'Server-managed: set by the endpoint; caller values are overridden.' submitted_by: anyOf: - type: string - type: 'null' title: Submitted By description: 'Server-managed: set by the endpoint; caller values are overridden.' submitted_at: anyOf: - type: string format: date-time - type: 'null' title: Submitted At description: 'Server-managed: set by the endpoint; caller values are overridden.' type: object title: NewMCPServerRequest MCPOAuthUserCredentialStatus: properties: server_id: type: string title: Server Id has_credential: type: boolean title: Has Credential expires_at: anyOf: - type: string - type: 'null' title: Expires At is_expired: type: boolean title: Is Expired default: false connected_at: anyOf: - type: string - type: 'null' title: Connected At type: object required: - server_id - has_credential title: MCPOAuthUserCredentialStatus description: Describes whether the calling user has a stored OAuth credential. LiteLLM_MCPServerTable: properties: server_id: type: string title: Server Id server_name: anyOf: - type: string - type: 'null' title: Server Name alias: anyOf: - type: string - type: 'null' title: Alias description: anyOf: - type: string - type: 'null' title: Description url: anyOf: - type: string - type: 'null' title: Url spec_path: anyOf: - type: string - type: 'null' title: Spec Path transport: type: string enum: - sse - http - stdio title: Transport auth_type: anyOf: - type: string enum: - none - api_key - bearer_token - basic - authorization - oauth2 - aws_sigv4 - token - oauth2_token_exchange - oauth2_id_jag - true_passthrough - oauth_delegate - type: 'null' title: Auth Type credentials: anyOf: - $ref: '#/components/schemas/MCPCredentials' - type: 'null' instructions: anyOf: - type: string - type: 'null' title: Instructions created_at: anyOf: - type: string format: date-time - type: 'null' title: Created At created_by: anyOf: - type: string - type: 'null' title: Created By updated_at: anyOf: - type: string format: date-time - type: 'null' title: Updated At updated_by: anyOf: - type: string - type: 'null' title: Updated By teams: items: additionalProperties: anyOf: - type: string - type: 'null' type: object type: array title: Teams mcp_access_groups: items: type: string type: array title: Mcp Access Groups allowed_tools: items: type: string type: array title: Allowed Tools tool_name_to_display_name: anyOf: - additionalProperties: type: string type: object - type: 'null' title: Tool Name To Display Name tool_name_to_description: anyOf: - additionalProperties: type: string type: object - type: 'null' title: Tool Name To Description extra_headers: items: type: string type: array title: Extra Headers mcp_info: anyOf: - additionalProperties: true type: object - type: 'null' title: Mcp Info static_headers: anyOf: - additionalProperties: type: string type: object - type: 'null' title: Static Headers env_vars: anyOf: - items: $ref: '#/components/schemas/MCPEnvVar' type: array - type: 'null' title: Env Vars status: anyOf: - type: string enum: - healthy - unhealthy - unknown - type: 'null' title: Status description: 'Health status: ''healthy'', ''unhealthy'', ''unknown''' default: unknown last_health_check: anyOf: - type: string format: date-time - type: 'null' title: Last Health Check health_check_error: anyOf: - type: string - type: 'null' title: Health Check Error command: anyOf: - type: string - type: 'null' title: Command args: items: type: string type: array title: Args env: additionalProperties: type: string type: object title: Env issuer: anyOf: - type: string - type: 'null' title: Issuer authorization_url: anyOf: - type: string - type: 'null' title: Authorization Url token_url: anyOf: - type: string - type: 'null' title: Token Url registration_url: anyOf: - type: string - type: 'null' title: Registration Url oauth2_flow: anyOf: - type: string enum: - client_credentials - authorization_code - type: 'null' title: Oauth2 Flow token_exchange_endpoint: anyOf: - type: string - type: 'null' title: Token Exchange Endpoint audience: anyOf: - type: string - type: 'null' title: Audience subject_token_type: anyOf: - type: string - type: 'null' title: Subject Token Type token_exchange_profile: anyOf: - type: string - type: 'null' title: Token Exchange Profile allow_all_keys: type: boolean title: Allow All Keys default: false available_on_public_internet: type: boolean title: Available On Public Internet default: true delegate_auth_to_upstream: type: boolean title: Delegate Auth To Upstream default: false oauth_passthrough: type: boolean title: Oauth Passthrough default: false dcr_bridge: anyOf: - type: boolean - type: 'null' title: Dcr Bridge per_server_oauth_discovery: type: boolean title: Per Server Oauth Discovery default: false is_byok: type: boolean title: Is Byok default: false byok_description: items: type: string type: array title: Byok Description byok_api_key_help_url: anyOf: - type: string - type: 'null' title: Byok Api Key Help Url has_user_credential: anyOf: - type: boolean - type: 'null' title: Has User Credential connected_app_reachable: anyOf: - type: boolean - type: 'null' title: Connected App Reachable source_url: anyOf: - type: string - type: 'null' title: Source Url timeout: anyOf: - type: number - type: 'null' title: Timeout max_concurrent_requests: anyOf: - type: integer - type: 'null' title: Max Concurrent Requests approval_status: anyOf: - type: string - type: 'null' title: Approval Status description: 'Approval status: ''pending_review'', ''active'', ''rejected''' default: active submitted_by: anyOf: - type: string - type: 'null' title: Submitted By submitted_at: anyOf: - type: string format: date-time - type: 'null' title: Submitted At reviewed_at: anyOf: - type: string format: date-time - type: 'null' title: Reviewed At review_notes: anyOf: - type: string - type: 'null' title: Review Notes type: object required: - server_id - transport title: LiteLLM_MCPServerTable description: Represents a LiteLLM_MCPServerTable record Body_introspect_endpoint_introspect_post: properties: token: type: string title: Token type: object required: - token title: Body_introspect_endpoint_introspect_post MCPConnectorImportResponse: properties: imported: items: $ref: '#/components/schemas/MCPConnectorImportResult' type: array title: Imported skipped: items: $ref: '#/components/schemas/MCPConnectorImportSkipped' type: array title: Skipped errors: items: $ref: '#/components/schemas/MCPConnectorImportFailure' type: array title: Errors type: object required: - imported - skipped - errors title: MCPConnectorImportResponse Body_revoke_endpoint_revoke_post: properties: token: type: string title: Token client_id: type: string title: Client Id type: object required: - token - client_id title: Body_revoke_endpoint_revoke_post MCPEnvVarScope: type: string enum: - global - user title: MCPEnvVarScope description: "Scope for an MCP server environment variable.\n\n- ``global``: value is provided by the admin and used for all users.\n- ``user``: each user must provide their own value via the per-user\n env-var endpoint. The admin-supplied ``value`` is treated as a\n placeholder/hint and is not used at request time." MCPUserCredentialListItem: properties: server_id: type: string title: Server Id server_name: anyOf: - type: string - type: 'null' title: Server Name alias: anyOf: - type: string - type: 'null' title: Alias credential_type: type: string title: Credential Type has_credential: type: boolean title: Has Credential expires_at: anyOf: - type: string - type: 'null' title: Expires At connected_at: anyOf: - type: string - type: 'null' title: Connected At type: object required: - server_id - credential_type - has_credential title: MCPUserCredentialListItem description: One entry in the /user-credentials list. MCPEnvVar: properties: name: type: string title: Name value: type: string title: Value default: '' scope: $ref: '#/components/schemas/MCPEnvVarScope' default: global description: anyOf: - type: string - type: 'null' title: Description type: object required: - name title: MCPEnvVar description: 'One environment variable for an MCP server. Variables can be interpolated into ``static_headers`` using ``${NAME}`` syntax. ``scope=global`` values are stored on the server. ``scope=user`` values are stored per-user in ``LiteLLM_MCPUserEnvVars`` and supplied by each user.' MCPUserEnvVarSpec: properties: name: type: string title: Name description: anyOf: - type: string - type: 'null' title: Description is_set: type: boolean title: Is Set default: false type: object required: - name title: MCPUserEnvVarSpec description: 'Describes one per-user env var slot for the calling user. Stored values are write-only: the status only reports whether a value ``is_set`` and never echoes the decrypted secret back to the client.' MCPUserCredentialResponse: properties: server_id: type: string title: Server Id has_credential: type: boolean title: Has Credential type: object required: - server_id - has_credential title: MCPUserCredentialResponse MCPUserEnvVarsRequest: properties: values: additionalProperties: type: string type: object title: Values type: object required: - values title: MCPUserEnvVarsRequest description: Payload for storing the calling user's per-user env var values. MCPSubmissionsSummary: properties: total: type: integer title: Total pending_review: type: integer title: Pending Review active: type: integer title: Active rejected: type: integer title: Rejected items: items: $ref: '#/components/schemas/LiteLLM_MCPServerTable' type: array title: Items type: object required: - total - pending_review - active - rejected - items title: MCPSubmissionsSummary UpdateMCPServerRequest: properties: server_id: type: string title: Server Id server_name: anyOf: - type: string - type: 'null' title: Server Name alias: anyOf: - type: string - type: 'null' title: Alias description: anyOf: - type: string - type: 'null' title: Description transport: type: string enum: - sse - http - stdio title: Transport default: sse auth_type: anyOf: - type: string enum: - none - api_key - bearer_token - basic - authorization - oauth2 - aws_sigv4 - token - oauth2_token_exchange - oauth2_id_jag - true_passthrough - oauth_delegate - type: 'null' title: Auth Type credentials: anyOf: - $ref: '#/components/schemas/MCPCredentials' - type: 'null' url: anyOf: - type: string - type: 'null' title: Url spec_path: anyOf: - type: string - type: 'null' title: Spec Path mcp_info: anyOf: - additionalProperties: true type: object - type: 'null' title: Mcp Info mcp_access_groups: items: type: string type: array title: Mcp Access Groups allowed_tools: anyOf: - items: type: string type: array - type: 'null' title: Allowed Tools tool_name_to_display_name: anyOf: - additionalProperties: type: string type: object - type: 'null' title: Tool Name To Display Name tool_name_to_description: anyOf: - additionalProperties: type: string type: object - type: 'null' title: Tool Name To Description extra_headers: anyOf: - items: type: string type: array - type: 'null' title: Extra Headers static_headers: anyOf: - additionalProperties: type: string type: object - type: 'null' title: Static Headers env_vars: anyOf: - items: $ref: '#/components/schemas/MCPEnvVar' type: array - type: 'null' title: Env Vars instructions: anyOf: - type: string - type: 'null' title: Instructions command: anyOf: - type: string - type: 'null' title: Command args: items: type: string type: array title: Args env: additionalProperties: type: string type: object title: Env issuer: anyOf: - type: string - type: 'null' title: Issuer authorization_url: anyOf: - type: string - type: 'null' title: Authorization Url token_url: anyOf: - type: string - type: 'null' title: Token Url registration_url: anyOf: - type: string - type: 'null' title: Registration Url oauth2_flow: anyOf: - type: string enum: - client_credentials - authorization_code - type: 'null' title: Oauth2 Flow token_exchange_endpoint: anyOf: - type: string - type: 'null' title: Token Exchange Endpoint audience: anyOf: - type: string - type: 'null' title: Audience subject_token_type: anyOf: - type: string - type: 'null' title: Subject Token Type token_exchange_profile: anyOf: - type: string - type: 'null' title: Token Exchange Profile allow_all_keys: type: boolean title: Allow All Keys default: false available_on_public_internet: type: boolean title: Available On Public Internet default: true delegate_auth_to_upstream: type: boolean title: Delegate Auth To Upstream default: false oauth_passthrough: type: boolean title: Oauth Passthrough default: false dcr_bridge: anyOf: - type: boolean - type: 'null' title: Dcr Bridge per_server_oauth_discovery: type: boolean title: Per Server Oauth Discovery default: false is_byok: type: boolean title: Is Byok default: false byok_description: items: type: string type: array title: Byok Description byok_api_key_help_url: anyOf: - type: string - type: 'null' title: Byok Api Key Help Url source_url: anyOf: - type: string - type: 'null' title: Source Url timeout: anyOf: - type: number - type: 'null' title: Timeout max_concurrent_requests: anyOf: - type: integer - type: 'null' title: Max Concurrent Requests type: object required: - server_id title: UpdateMCPServerRequest MCPConnectorImportFailure: properties: name: type: string title: Name error: type: string title: Error type: object required: - name - error title: MCPConnectorImportFailure MCPCredentials: properties: auth_value: anyOf: - type: string - type: 'null' title: Auth Value client_id: anyOf: - type: string - type: 'null' title: Client Id client_secret: anyOf: - type: string - type: 'null' title: Client Secret scopes: anyOf: - items: type: string type: array - type: 'null' title: Scopes aws_access_key_id: anyOf: - type: string - type: 'null' title: Aws Access Key Id aws_secret_access_key: anyOf: - type: string - type: 'null' title: Aws Secret Access Key aws_session_token: anyOf: - type: string - type: 'null' title: Aws Session Token aws_region_name: anyOf: - type: string - type: 'null' title: Aws Region Name aws_service_name: anyOf: - type: string - type: 'null' title: Aws Service Name aws_role_name: anyOf: - type: string - type: 'null' title: Aws Role Name aws_session_name: anyOf: - type: string - type: 'null' title: Aws Session Name audience: anyOf: - type: string - type: 'null' title: Audience token_exchange_endpoint: anyOf: - type: string - type: 'null' title: Token Exchange Endpoint subject_token_type: anyOf: - type: string - type: 'null' title: Subject Token Type id_jag_resource_token_endpoint: anyOf: - type: string - type: 'null' title: Id Jag Resource Token Endpoint id_jag_resource: anyOf: - type: string - type: 'null' title: Id Jag Resource upstream_resource: anyOf: - type: string - type: 'null' title: Upstream Resource upstream_token_header: anyOf: - type: string - type: 'null' title: Upstream Token Header client_private_key: anyOf: - type: string - type: 'null' title: Client Private Key client_private_key_id: anyOf: - type: string - type: 'null' title: Client Private Key Id client_assertion_signing_alg: anyOf: - type: string - type: 'null' title: Client Assertion Signing Alg token_endpoint_auth_method: anyOf: - type: string enum: - client_secret_basic - client_secret_post - type: 'null' title: Token Endpoint Auth Method redirect_uris: anyOf: - items: type: string type: array - type: 'null' title: Redirect Uris token_exchange_profile: anyOf: - type: string - type: 'null' title: Token Exchange Profile type: object title: MCPCredentials securitySchemes: APIKeyHeader: type: apiKey description: Bearer token in: header name: x-litellm-api-key