{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/communicate-so/json-schema/communicate-so-capability-document-schema.json",
  "title": "CapabilityDocument",
  "x-generated": "2026-11-10",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/communicate-so-discovery-api-openapi.yml#/components/schemas/CapabilityDocument",
  "type": "object",
  "properties": {
    "schemaVersion": {
      "type": "string",
      "const": "1.0.0"
    },
    "coverage": {
      "type": "string",
      "enum": [
        "partial",
        "complete"
      ]
    },
    "operations": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "operationId": {
            "type": "string"
          },
          "summary": {
            "type": "string"
          },
          "credentialKind": {
            "type": "string",
            "enum": [
              "public",
              "password-proof",
              "workspace-key-or-oauth-token",
              "verified-session",
              "verified-session-with-fresh-proof",
              "account-key-or-session"
            ]
          },
          "scopes": {
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "readOnly": {
            "type": "boolean"
          },
          "api": {
            "type": "object",
            "properties": {
              "supported": {
                "type": "boolean"
              },
              "method": {
                "type": "string",
                "enum": [
                  "GET",
                  "POST",
                  "PUT",
                  "PATCH",
                  "DELETE"
                ]
              },
              "path": {
                "type": "string"
              },
              "successStatus": {
                "type": "integer",
                "minimum": -9007199254740991,
                "maximum": 9007199254740991
              },
              "successStatuses": {
                "type": "array",
                "items": {
                  "type": "integer",
                  "minimum": -9007199254740991,
                  "maximum": 9007199254740991
                }
              },
              "requestBodyProperty": {
                "type": "string"
              },
              "requestMediaType": {
                "type": "string",
                "enum": [
                  "application/json",
                  "multipart/form-data"
                ]
              }
            },
            "required": [
              "supported",
              "method",
              "path"
            ],
            "additionalProperties": false
          },
          "cli": {
            "type": "object",
            "properties": {
              "supported": {
                "type": "boolean"
              },
              "command": {
                "type": "string"
              }
            },
            "required": [
              "supported",
              "command"
            ],
            "additionalProperties": false
          },
          "mcp": {
            "type": "object",
            "properties": {
              "supported": {
                "type": "boolean"
              },
              "tool": {
                "type": "string"
              }
            },
            "required": [
              "supported",
              "tool"
            ],
            "additionalProperties": false
          },
          "inputSchema": {
            "type": "object",
            "propertyNames": {
              "type": "string"
            },
            "additionalProperties": {}
          },
          "outputSchema": {
            "type": "object",
            "propertyNames": {
              "type": "string"
            },
            "additionalProperties": {}
          }
        },
        "required": [
          "operationId",
          "summary",
          "credentialKind",
          "scopes",
          "readOnly",
          "api",
          "cli",
          "mcp",
          "inputSchema",
          "outputSchema"
        ],
        "additionalProperties": false
      }
    }
  },
  "required": [
    "schemaVersion",
    "coverage",
    "operations"
  ],
  "additionalProperties": false
}