---
title: "Edit Mcp Server"
method: PUT
path: "/v1/mcp/server"
tags: ["mcp_management"]
---

# Edit Mcp Server

`PUT /v1/mcp/server`

Allows deleting mcp serves in the db

## Headers

- `litellm-changed-by` string, nullable — The litellm-changed-by header enables tracking of actions performed by authorized users on behalf of other users, providing an audit trail for accountability

## Request body

- UpdateMCPServerRequest
  - `alias` string, nullable
  - `allow_all_keys` boolean
  - `allowed_tools` string[], nullable
  - `args` string[]
  - `audience` string, nullable
  - `auth_type` 'none' | 'api_key' | 'bearer_token' | 'basic' | 'authorization' | 'oauth2' | 'aws_sigv4' | 'token' | 'oauth2_token_exchange' | 'oauth2_id_jag' | 'true_passthrough' | 'oauth_delegate', nullable
  - `authorization_url` string, nullable
  - `available_on_public_internet` boolean
  - `byok_api_key_help_url` string, nullable
  - `byok_description` string[]
  - `command` string, nullable
  - `credentials` MCPCredentials
    - `audience` string, nullable
    - `auth_value` string, nullable
    - `aws_access_key_id` string, nullable
    - `aws_region_name` string, nullable
    - `aws_role_name` string, nullable
    - `aws_secret_access_key` string, nullable
    - `aws_service_name` string, nullable
    - `aws_session_name` string, nullable
    - `aws_session_token` string, nullable
    - `client_assertion_signing_alg` string, nullable
    - `client_id` string, nullable
    - `client_private_key` string, nullable
    - `client_private_key_id` string, nullable
    - `client_secret` string, nullable
    - `id_jag_resource` string, nullable
    - `id_jag_resource_token_endpoint` string, nullable
    - `redirect_uris` string[], nullable
    - `scopes` string[], nullable
    - `subject_token_type` string, nullable
    - `token_endpoint_auth_method` 'client_secret_basic' | 'client_secret_post', nullable
    - `token_exchange_endpoint` string, nullable
    - `token_exchange_profile` string, nullable
    - `upstream_resource` string, nullable
    - `upstream_token_header` string, nullable
  - `dcr_bridge` boolean, nullable
  - `delegate_auth_to_upstream` boolean
  - `description` string, nullable
  - `env` object
  - `env_vars` MCPEnvVar[], nullable
    - `description` string, nullable
    - `name` string, required
    - `scope` 'global' | 'user' — Scope for an MCP server environment variable. - ``global``: value is provided by the admin and used for all users. - ``user``: each user must provide their own value via the per-user env-var endpoint. The admin-supplied ``value`` is treated as a placeholder/hint and is not used at request time.
    - `value` string
  - `extra_headers` string[], nullable
  - `instructions` string, nullable
  - `is_byok` boolean
  - `issuer` string, nullable
  - `max_concurrent_requests` integer, nullable
  - `mcp_access_groups` string[]
  - `mcp_info` object, nullable
  - `oauth2_flow` 'client_credentials' | 'authorization_code', nullable
  - `oauth_passthrough` boolean
  - `registration_url` string, nullable
  - `server_id` string, required
  - `server_name` string, nullable
  - `source_url` string, nullable
  - `spec_path` string, nullable
  - `static_headers` object, nullable
  - `subject_token_type` string, nullable
  - `timeout` number, nullable
  - `token_exchange_endpoint` string, nullable
  - `token_exchange_profile` string, nullable
  - `token_url` string, nullable
  - `tool_name_to_description` object, nullable
  - `tool_name_to_display_name` object, nullable
  - `transport` 'sse' | 'http' | 'stdio'
  - `url` string, nullable

## Response `202`

Successful Response

- LiteLLMMCPServerTable — Represents a LiteLLM_MCPServerTable record
  - `alias` string, nullable
  - `allow_all_keys` boolean
  - `allowed_tools` string[]
  - `approval_status` string, nullable — Approval status: 'pending_review', 'active', 'rejected'
  - `args` string[]
  - `audience` string, nullable
  - `auth_type` 'none' | 'api_key' | 'bearer_token' | 'basic' | 'authorization' | 'oauth2' | 'aws_sigv4' | 'token' | 'oauth2_token_exchange' | 'oauth2_id_jag' | 'true_passthrough' | 'oauth_delegate', nullable
  - `authorization_url` string, nullable
  - `available_on_public_internet` boolean
  - `byok_api_key_help_url` string, nullable
  - `byok_description` string[]
  - `command` string, nullable
  - `connected_app_reachable` boolean, nullable
  - `created_at` string, date-time, nullable
  - `created_by` string, nullable
  - `credentials` MCPCredentials
    - `audience` string, nullable
    - `auth_value` string, nullable
    - `aws_access_key_id` string, nullable
    - `aws_region_name` string, nullable
    - `aws_role_name` string, nullable
    - `aws_secret_access_key` string, nullable
    - `aws_service_name` string, nullable
    - `aws_session_name` string, nullable
    - `aws_session_token` string, nullable
    - `client_assertion_signing_alg` string, nullable
    - `client_id` string, nullable
    - `client_private_key` string, nullable
    - `client_private_key_id` string, nullable
    - `client_secret` string, nullable
    - `id_jag_resource` string, nullable
    - `id_jag_resource_token_endpoint` string, nullable
    - `redirect_uris` string[], nullable
    - `scopes` string[], nullable
    - `subject_token_type` string, nullable
    - `token_endpoint_auth_method` 'client_secret_basic' | 'client_secret_post', nullable
    - `token_exchange_endpoint` string, nullable
    - `token_exchange_profile` string, nullable
    - `upstream_resource` string, nullable
    - `upstream_token_header` string, nullable
  - `dcr_bridge` boolean, nullable
  - `delegate_auth_to_upstream` boolean
  - `description` string, nullable
  - `env` object
  - `env_vars` MCPEnvVar[], nullable
    - `description` string, nullable
    - `name` string, required
    - `scope` 'global' | 'user' — Scope for an MCP server environment variable. - ``global``: value is provided by the admin and used for all users. - ``user``: each user must provide their own value via the per-user env-var endpoint. The admin-supplied ``value`` is treated as a placeholder/hint and is not used at request time.
    - `value` string
  - `extra_headers` string[]
  - `has_user_credential` boolean, nullable
  - `health_check_error` string, nullable
  - `instructions` string, nullable
  - `is_byok` boolean
  - `issuer` string, nullable
  - `last_health_check` string, date-time, nullable
  - `max_concurrent_requests` integer, nullable
  - `mcp_access_groups` string[]
  - `mcp_info` object, nullable
  - `oauth2_flow` 'client_credentials' | 'authorization_code', nullable
  - `oauth_passthrough` boolean
  - `registration_url` string, nullable
  - `review_notes` string, nullable
  - `reviewed_at` string, date-time, nullable
  - `server_id` string, required
  - `server_name` string, nullable
  - `source_url` string, nullable
  - `spec_path` string, nullable
  - `static_headers` object, nullable
  - `status` 'healthy' | 'unhealthy' | 'unknown', nullable — Health status: 'healthy', 'unhealthy', 'unknown'
  - `subject_token_type` string, nullable
  - `submitted_at` string, date-time, nullable
  - `submitted_by` string, nullable
  - `teams` object[]
  - `timeout` number, nullable
  - `token_exchange_endpoint` string, nullable
  - `token_exchange_profile` string, nullable
  - `token_url` string, nullable
  - `tool_name_to_description` object, nullable
  - `tool_name_to_display_name` object, nullable
  - `transport` 'sse' | 'http' | 'stdio', required
  - `updated_at` string, date-time, nullable
  - `updated_by` string, nullable
  - `url` string, nullable

## Other responses

- `422` — Validation Error

## Changes

- **2026-09-23** `7ed45f30a5f0` — 2 info
  - api tag `mcp_management` added
  - api tag `mcp` removed
- **2026-09-21** `6246f8d427b7` — 2 info
  - api tag `mcp` added
  - api tag `mcp_management` removed
- **2026-09-19** `c357baf422ab` — 2 info
  - api tag `mcp_management` added
  - api tag `mcp` removed
- **2026-09-18** `082b5fabd909` — 1 info
  - endpoint added
- **2026-09-16** `7afc3544d64d` — 1 breaking
  - api path removed without deprecation

[Full history](https://skmtc.dev/flock/apis/litellm-api/changes/v1/mcp/server/put.md)

---

[API](https://skmtc.dev/flock/apis/litellm-api.md) · [All operations](https://skmtc.dev/flock/apis/litellm-api/llms.txt) · [OpenAPI document](https://skmtc.dev/flock/apis/litellm-api/revisions/7ed45f30a5f0?raw)
