{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://humbleagents.local/schema/retired-artifact-inventory.schema.json",
  "title": "Signed retired artifact inventory payload",
  "type": "object",
  "additionalProperties": false,
  "required": ["schemaVersion", "releases"],
  "properties": {
    "schemaVersion": { "const": "1.0.0" },
    "releases": {
      "type": "array",
      "items": {
        "type": "object",
        "additionalProperties": false,
        "required": ["sourceVersion", "artifacts"],
        "properties": {
          "sourceVersion": { "type": "string", "minLength": 1 },
          "artifacts": {
            "type": "array",
            "items": {
              "type": "object",
              "additionalProperties": false,
              "required": ["path", "runtime", "component", "sha256"],
              "properties": {
                "path": { "type": "string", "minLength": 1 },
                "runtime": { "enum": ["shared", "claude", "codex", "gemini", "cursor"] },
                "component": { "enum": ["agents", "commands", "knowledge", "knowledge-discovery", "templates", "connectors", "security-core"] },
                "sha256": { "type": "string", "pattern": "^[a-f0-9]{64}$" }
              }
            }
          }
        }
      }
    }
  }
}
