> ## Documentation Index
> Fetch the complete documentation index at: https://docs.agentscope.io/llms.txt
> Use this file to discover all available pages before exploring further.

# List Mcps

> Return all MCP clients with live tool list and health status.



## OpenAPI

````yaml /versions/2.0.2/en/deploy/openapi.json get /workspace/mcp
openapi: 3.1.0
info:
  title: AgentScope
  version: 2.0.1
servers: []
security: []
paths:
  /workspace/mcp:
    get:
      tags:
        - workspace
      summary: List Mcps
      description: Return all MCP clients with live tool list and health status.
      operationId: list_mcps_workspace_mcp_get
      parameters:
        - name: agent_id
          in: query
          required: true
          schema:
            type: string
            title: Agent Id
        - name: session_id
          in: query
          required: true
          schema:
            type: string
            title: Session Id
        - name: x-user-id
          in: header
          required: true
          schema:
            type: string
            description: >-
              Caller's user ID. Temporary header-based identity; will be
              replaced by JWT auth.
            title: X-User-Id
          description: >-
            Caller's user ID. Temporary header-based identity; will be replaced
            by JWT auth.
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                type: array
                items:
                  $ref: '#/components/schemas/MCPClientStatus'
                title: Response List Mcps Workspace Mcp Get
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
components:
  schemas:
    MCPClientStatus:
      properties:
        name:
          type: string
          title: MCP Name
          description: The MCP name.
        is_stateful:
          type: boolean
          title: Stateful
          description: >-
            Whether this is a stateful connection that requires explicit
            connect() and close(). STDIO MCP must be stateful. HTTP MCP can be
            either stateful or stateless.
        mcp_config:
          oneOf:
            - $ref: '#/components/schemas/StdioMCPConfig'
            - $ref: '#/components/schemas/HttpMCPConfig'
          title: MCP Config
          description: The MCP server configuration.
          discriminator:
            propertyName: type
            mapping:
              http_mcp:
                $ref: '#/components/schemas/HttpMCPConfig'
              stdio_mcp:
                $ref: '#/components/schemas/StdioMCPConfig'
        enable_tools:
          anyOf:
            - items:
                type: string
              type: array
            - type: 'null'
          title: Enable Tools
        disable_tools:
          anyOf:
            - items:
                type: string
              type: array
            - type: 'null'
          title: Disable Tools
        execution_timeout:
          anyOf:
            - type: number
            - type: 'null'
          title: Execution Timeout
        is_healthy:
          type: boolean
          title: Is Healthy
          default: false
        tools:
          items:
            $ref: '#/components/schemas/ToolInfo'
          type: array
          title: Tools
      type: object
      required:
        - name
        - is_stateful
        - mcp_config
      title: MCPClientStatus
      description: MCPClient enriched with live tool list and health status.
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          type: array
          title: Detail
      type: object
      title: HTTPValidationError
    StdioMCPConfig:
      properties:
        type:
          type: string
          const: stdio_mcp
          title: Type
          default: stdio_mcp
        command:
          type: string
          title: Command
          description: The command to start the MCP server.
        args:
          anyOf:
            - items:
                type: string
              type: array
            - type: 'null'
          title: Args
          description: The command line arguments to pass to the MCP server.
        env:
          anyOf:
            - additionalProperties:
                type: string
              type: object
            - type: 'null'
          title: Environment Variables
          description: The environment variables to pass to the MCP server.
        cwd:
          anyOf:
            - type: string
            - type: string
              format: path
            - type: 'null'
          title: CWD
          description: The working directory to use when spawning the process.
        encoding_error_handler:
          type: string
          enum:
            - strict
            - ignore
            - replace
          title: Encoding Error Handler
          description: The text encoding error handler.
          default: strict
      type: object
      required:
        - command
      title: StdioMCPConfig
      description: The STDIO MCP server configuration.
    HttpMCPConfig:
      properties:
        type:
          type: string
          const: http_mcp
          title: Type
          default: http_mcp
        url:
          type: string
          title: URL
          description: The URL of the MCP server.
        headers:
          anyOf:
            - additionalProperties:
                type: string
              type: object
            - type: 'null'
          title: Headers
          description: The additional headers to include in the HTTP request.
        timeout:
          anyOf:
            - type: number
            - type: 'null'
          title: Timeout
          description: The HTTP request timeout in seconds.
          default: 30
      type: object
      required:
        - url
      title: HttpMCPConfig
      description: The HTTP MCP server configuration.
    ToolInfo:
      properties:
        name:
          type: string
          title: Name
        description:
          anyOf:
            - type: string
            - type: 'null'
          title: Description
      type: object
      required:
        - name
      title: ToolInfo
      description: The tool info.
    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

````