Get MCP details

Updated at:

Gets details, status, and configuration of an official MCP or a custom MCP in the current workspace.

Endpoint

GET/api/v1/mcp/servers/{mcpCode}

Path parameters

mcpCodestringRequired

MCP code

Response fields

Returns a complete DetailResponse. For a custom MCP, mcp_config is returned as saved; if the configuration cannot be restored, it is null. For an official MCP, mcp_config is always null.

mcp_codestring

MCP code

server_namestring

MCP name

descriptionstring

MCP description

typestring

OFFICIAL or CUSTOMER

server_typestring

STDIO, HTTP, SSE, or OPENAPI

server_statusstring

Service status

server_status_textstring

Status text

dashscope_endpointstring / null

MCP endpoint. Returned only when the service is enabled or activating

meta_infoobject / null

Service metadata

mcp_configobject / null

Saved configuration of a custom MCP

For meta_info fields, see MCP API overview.

Example

curl "https://{workspace_id}.cn-beijing.maas.aliyuncs.com/api/v1/mcp/servers/mcp-a1b2c3d4e5f6g7h8" \
  -H "Authorization: Bearer $DASHSCOPE_API_KEY"

Response example

{
  "success": true,
  "error_code": null,
  "error_msg": null,
  "data": {
    "mcp_code": "mcp-a1b2c3d4e5f6g7h8",
    "server_name": "weather-mcp",
    "description": "Weather query MCP",
    "type": "CUSTOMER",
    "server_type": "HTTP",
    "server_status": "ACTIVATED",
    "server_status_text": "已启用",
    "dashscope_endpoint": "https://{workspace_id}.cn-beijing.maas.aliyuncs.com/api/v1/mcps/mcp-a1b2c3d4e5f6g7h8/mcp",
    "meta_info": {
      "console_detail_url": "https://bailian.console.aliyun.com/flow-agent/mcp-manage/detail/mcp-a1b2c3d4e5f6g7h8/custom",
      "classification": "生活服务",
      "activate_user_count": 10,
      "call_total_count": 1200,
      "average_call_time": 125,
      "call_success_rate": 0.99
    },
    "mcp_config": {
      "url": "https://mcp.example.com/mcp",
      "headers": {
        "Authorization": "Bearer sk-xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"
      }
    }
  },
  "request_id": "6f1c2a8e-3b0d-4c55-9a0e-2f7d1c9b8a11"
}

Error codes

HTTP statuserror_codeDescription
400InvalidParameterA query parameter or request body is provided
404McpServerNotFoundThe MCP service does not exist or does not belong to the current workspace
404McpServerUnavailableThe MCP service is deleted or unavailable

Warningmcp_config.headers is returned as saved and may contain sensitive information such as API keys. Protect the response content.