{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/glyt-net/json-schema/glyt-net-request-view-schema.json",
  "title": "RequestView",
  "x-generated": "2026-11-10",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/glyt-net-openapi.json#/components/schemas/RequestView",
  "type": "object",
  "properties": {
    "request_id": {
      "type": "string",
      "format": "uuid"
    },
    "state": {
      "type": "string",
      "enum": [
        "pending",
        "approved",
        "denied",
        "expired"
      ]
    },
    "action_digest": {
      "type": "string"
    },
    "stake_tier": {
      "type": "string",
      "enum": [
        "low",
        "medium",
        "high"
      ]
    },
    "expires_at": {
      "type": "string",
      "format": "date-time"
    },
    "receipt_id": {
      "type": "string",
      "format": "uuid"
    },
    "receipt": {
      "$ref": "#/$defs/ReceiptEnvelope"
    }
  },
  "$defs": {
    "ReceiptEnvelope": {
      "type": "object",
      "description": "A signed, offline-verifiable attestation. Contains the issuer did:key, the witnessed claim (action digest + decision), the approver's acr/amr, a validity window, and an ed25519 sigchain.",
      "additionalProperties": true
    }
  }
}