{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://aegis.haloforge.dev/spec/mcp-catalog.schema.json",
  "title": "Aegis MCP Talent Catalog",
  "type": "object",
  "additionalProperties": false,
  "required": ["schemaVersion", "updatedAt", "entries"],
  "properties": {
    "schemaVersion": {
      "const": "2026-06-07"
    },
    "updatedAt": {
      "type": "string",
      "format": "date-time"
    },
    "source": {
      "type": "string"
    },
    "entries": {
      "type": "array",
      "items": { "$ref": "#/$defs/mcpEntry" }
    }
  },
  "$defs": {
    "mcpEntry": {
      "type": "object",
      "additionalProperties": false,
      "required": ["id", "displayName", "description", "transport"],
      "properties": {
        "id": {
          "type": "string",
          "pattern": "^[a-z0-9][a-z0-9._-]+$"
        },
        "displayName": { "type": "string", "minLength": 1 },
        "description": { "type": "string" },
        "homepage": { "type": "string", "format": "uri" },
        "transport": {
          "enum": ["streamable_http", "sse", "http_json_rpc", "stdio"]
        },
        "endpoint": { "type": "string" },
        "command": { "type": "string" },
        "args": {
          "type": "array",
          "items": { "type": "string" }
        },
        "requiredSecrets": {
          "type": "array",
          "items": { "type": "string", "pattern": "^[A-Z0-9_]+$" },
          "uniqueItems": true
        },
        "requiredRuntime": {
          "type": "array",
          "items": {
            "enum": ["node", "npm", "npx", "python", "uvx", "docker", "custom"]
          },
          "uniqueItems": true
        },
        "tags": {
          "type": "array",
          "items": { "type": "string" },
          "uniqueItems": true
        }
      }
    }
  }
}
