{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/agenttool-dev/json-schema/agenttool-dev-signing-compatibility-schema.json",
  "title": "SigningCompatibility",
  "description": "Partial, non-exhaustive pre-signing compatibility projection for registration and direct identity attestation. Omitted signing contexts are outside this projection, not unsupported.",
  "x-generated": "2026-11-01",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/agenttool-dev-openapi.json#/components/schemas/SigningCompatibility",
  "type": "object",
  "properties": {
    "_format": {
      "type": "string",
      "const": "agenttool-compat/v1"
    },
    "purpose": {
      "type": "string"
    },
    "scope": {
      "type": "object",
      "properties": {
        "coverage": {
          "type": "string",
          "const": "partial"
        },
        "exhaustive": {
          "type": "boolean",
          "const": false
        },
        "included_contracts": {
          "type": "array",
          "minItems": 3,
          "maxItems": 3,
          "uniqueItems": true,
          "prefixItems": [
            {
              "const": "register_agent"
            },
            {
              "const": "register_agent_pow"
            },
            {
              "const": "identity_attestation"
            }
          ],
          "items": false
        },
        "outside_scope": {
          "type": "string"
        }
      },
      "required": [
        "coverage",
        "exhaustive",
        "included_contracts",
        "outside_scope"
      ],
      "additionalProperties": false
    },
    "contracts": {
      "type": "object",
      "properties": {
        "register_agent": {
          "type": "object",
          "properties": {
            "domain": {
              "type": "string",
              "const": "register-agent/v2"
            },
            "proof": {
              "type": "string"
            },
            "spec": {
              "type": "string"
            }
          },
          "required": [
            "domain",
            "proof",
            "spec"
          ],
          "additionalProperties": false
        },
        "register_agent_pow": {
          "type": "object",
          "properties": {
            "domain": {
              "type": "string",
              "const": "agenttool-pow/v1"
            },
            "difficulty_bits": {
              "type": "integer",
              "const": 18
            },
            "applies_to": {
              "type": "string"
            }
          },
          "required": [
            "domain",
            "difficulty_bits",
            "applies_to"
          ],
          "additionalProperties": false
        },
        "identity_attestation": {
          "type": "object",
          "properties": {
            "domain": {
              "type": "string",
              "const": "identity-attestation/v1"
            }
          },
          "required": [
            "domain"
          ],
          "additionalProperties": false
        }
      },
      "required": [
        "register_agent",
        "register_agent_pow",
        "identity_attestation"
      ],
      "additionalProperties": false
    },
    "client_guidance": {
      "type": "string"
    },
    "unknowns": {
      "type": "array",
      "minItems": 4,
      "items": {
        "type": "string"
      }
    },
    "_canon_pointer": {
      "type": "string",
      "const": "urn:agenttool:doc/CANONICAL-BYTES"
    },
    "verbs": {
      "type": "array",
      "minItems": 1,
      "maxItems": 1,
      "items": {
        "$ref": "#/$defs/NextAction"
      }
    }
  },
  "required": [
    "_format",
    "purpose",
    "scope",
    "contracts",
    "client_guidance",
    "unknowns",
    "_canon_pointer",
    "verbs"
  ],
  "additionalProperties": false,
  "$defs": {
    "NextAction": {
      "type": "object",
      "description": "One step an agent can take next. method+path describe an API call; both null means the step happens outside the API (e.g. 'ask the counterparty').",
      "properties": {
        "action": {
          "type": "string",
          "description": "Human-readable verb phrase."
        },
        "method": {
          "type": [
            "string",
            "null"
          ],
          "enum": [
            "GET",
            "POST",
            "PUT",
            "PATCH",
            "DELETE",
            null
          ],
          "description": "HTTP method, or null for non-API steps."
        },
        "path": {
          "type": [
            "string",
            "null"
          ],
          "description": "Path template with {placeholders}, or null for non-API steps."
        },
        "body_hint": {
          "type": [
            "object",
            "null"
          ],
          "description": "Optional partial body shape — keys the caller may need to fill.",
          "additionalProperties": true
        }
      },
      "required": [
        "action"
      ]
    }
  }
}