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

# Return the caller's MCP tool-visibility diagnostic

> Reports which MCP tools the authenticated API key may invoke, and why any are hidden (insufficient scope, Project restriction, or a server feature gate). The `project` query parameter narrows Project-scoped tools; a key that cannot bind that Project reports them with `absence_reason: project_restriction`.



## OpenAPI

````yaml /api-reference/earnie/platform-openapi.json get /v1/mcp/diagnostic
openapi: 3.0.3
info:
  title: Earnie Platform API
  description: >-
    Authentication, session management, and API key lifecycle for the Earnie
    platform.
  version: 0.1.0
servers:
  - url: https://your-earnie.example
    description: Your Earnie deployment
security: []
paths:
  /v1/mcp/diagnostic:
    get:
      tags:
        - meta
      summary: Return the caller's MCP tool-visibility diagnostic
      description: >-
        Reports which MCP tools the authenticated API key may invoke, and why
        any are hidden (insufficient scope, Project restriction, or a server
        feature gate). The `project` query parameter narrows Project-scoped
        tools; a key that cannot bind that Project reports them with
        `absence_reason: project_restriction`.
      operationId: GetV1McpDiagnostic
      parameters:
        - name: project
          in: query
          description: >-
            Optional Project id or slug. When present, Project-scoped tools the
            key cannot bind are reported with absence_reason
            project_restriction. Global doctor omits this.
          schema:
            type: string
      responses:
        '200':
          description: Authenticated MCP capability diagnostic.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/MCPDiagnostic'
        '401':
          description: Not authenticated.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
      security:
        - bearerAuth: []
components:
  schemas:
    MCPDiagnostic:
      type: object
      required:
        - catalogue_version
        - tools
      properties:
        catalogue_version:
          type: string
          description: >-
            Digest of the registered MCP catalogue. The CLI must not ship a
            static copy of the tool list.
        tools:
          type: array
          items:
            $ref: '#/components/schemas/MCPToolDiagnostic'
    Error:
      type: object
      required:
        - code
        - message
      properties:
        code:
          type: string
        message:
          type: string
    MCPToolDiagnostic:
      type: object
      required:
        - name
        - visible
        - required_scopes
      properties:
        name:
          type: string
        visible:
          type: boolean
          description: >-
            Whether this key may invoke the tool. tools/list remains the live
            filtered catalogue.
        required_scopes:
          type: array
          items:
            type: string
        absence_reason:
          type: string
          enum:
            - scope
            - project_restriction
            - server_feature
          description: Why the tool is unavailable to this key. Omitted when visible.
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: API key prefixed with "sk_earnie_" passed as Bearer token.

````