List tools

Updated at:

Lists the tool names, descriptions, and input schemas provided by an MCP service.

Endpoint

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

Returns the tools currently available in the specified MCP service.

Path parameters

mcpCodestringRequired

MCP code

Response fields

data is an array of tools. Each tool contains the following fields:

namestring / null

Tool name

descriptionstring / null

Tool description

inputSchemaobject / null

Tool input schema

inputSchema.typestring / null

Usually object

inputSchema.propertiesmap<string,object> / null

Parameter definitions

inputSchema.requiredarray<string> / null

Required parameter names

inputSchema.additionalPropertiesboolean / null

Whether additional parameters are allowed

Example

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

Response example

{
  "success": true,
  "error_code": null,
  "error_msg": null,
  "data": [
    {
      "name": "get_weather",
      "description": "Queries the weather in a specified city",
      "inputSchema": {
        "type": "object",
        "properties": {
          "city": {
            "type": "string",
            "description": "City name"
          }
        },
        "required": ["city"],
        "additionalProperties": false
      }
    }
  ],
  "request_id": "6f1c2a8e-3b0d-4c55-9a0e-2f7d1c9b8a11"
}

Error codes

HTTP statuserror_codeDescription
400-The service is not activated, the instance is abnormal, or the tool list is empty. The error code is returned by the MCP service
500InternalErrorInternal service error

NoteOne Key MCP services do not need to be activated in advance. The service may be activated automatically when tools are first listed or called.