Deactivates an activated official MCP service in the current workspace. One Key MCP is not supported.
Endpoint
POST /api/v1/mcp/servers/{mcpCode}/deactivate
Supports official MCP only. One Key MCP is not supported. After deactivation, the status becomes INACTIVE and the status text is "Not activated".
Request parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| mcpCode | string | Yes | Official MCP code |
Response
Returns a DetailResponse with only mcp_code, server_status, and server_status_text populated. All other fields are null.
Errors
| HTTP status | error_code | Description |
|---|---|---|
| 400 | InvalidParameter | A query parameter or request body is provided |
| 400 | OperationNotSupported | The service is a custom MCP |
| 400 | DeActivateFailed | The service is a One Key MCP, or is deploying |
| 404 | McpServerNotFound | The MCP service does not exist |
| 404 | McpServerUnavailable | The MCP service is unavailable |