{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/nothumansearch-ai/json-schema/nothumansearch-ai-provider-claim-schema.json",
  "title": "ProviderClaim",
  "description": "Provider ownership state. NHS never returns the persisted challenge-token hash or raw DNS answers.",
  "x-generated": "2026-11-19",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/nothumansearch-ai-openapi.yaml#/components/schemas/ProviderClaim",
  "type": "object",
  "required": [
    "id",
    "site_id",
    "domain",
    "verification_method",
    "verification_record_name",
    "status",
    "challenge_expires_at",
    "verification_consecutive_failures",
    "created_at",
    "updated_at"
  ],
  "properties": {
    "id": {
      "type": "string",
      "format": "uuid"
    },
    "site_id": {
      "type": "string",
      "format": "uuid"
    },
    "domain": {
      "type": "string"
    },
    "verification_method": {
      "type": "string",
      "enum": [
        "dns_txt"
      ]
    },
    "verification_record_name": {
      "type": "string",
      "description": "TXT record name that must remain published while the claim is verified"
    },
    "status": {
      "type": "string",
      "enum": [
        "pending",
        "verified",
        "revoked"
      ]
    },
    "challenge_expires_at": {
      "type": "string",
      "format": "date-time",
      "description": "Expiry for a pending one-time challenge; it does not authorize removal of a verified TXT record"
    },
    "verified_at": {
      "type": [
        "string",
        "null"
      ],
      "format": "date-time"
    },
    "verification_last_succeeded_at": {
      "type": [
        "string",
        "null"
      ],
      "format": "date-time",
      "description": "Last successful DNS ownership check; paid actions require this to remain within the freshness window"
    },
    "verification_last_attempted_at": {
      "type": [
        "string",
        "null"
      ],
      "format": "date-time"
    },
    "verification_consecutive_failures": {
      "type": "integer",
      "minimum": 0,
      "description": "Consecutive automatic or owner-triggered DNS failures since the last success"
    },
    "verification_next_check_at": {
      "type": [
        "string",
        "null"
      ],
      "format": "date-time",
      "description": "Next scheduled automatic DNS ownership check"
    },
    "revoked_at": {
      "type": [
        "string",
        "null"
      ],
      "format": "date-time"
    },
    "created_at": {
      "type": "string",
      "format": "date-time"
    },
    "updated_at": {
      "type": "string",
      "format": "date-time"
    }
  }
}