{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/commentary-dev/json-schema/commentary-dev-interaction-guidance-schema.json",
  "title": "InteractionGuidance",
  "description": "Immutable future-facing human guidance plus an optional content-free agent acknowledgment receipt.",
  "x-generated": "2026-11-10",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/commentary-dev-interactions-api-openapi.yml#/components/schemas/InteractionGuidance",
  "type": "object",
  "required": [
    "id",
    "interactionId",
    "revisionId",
    "scope",
    "body",
    "deliveredAt",
    "status",
    "acknowledgment"
  ],
  "additionalProperties": false,
  "properties": {
    "id": {
      "type": "string",
      "pattern": "^ixg_[A-Za-z0-9_-]{16,}$"
    },
    "interactionId": {
      "type": "string"
    },
    "revisionId": {
      "type": "string"
    },
    "scope": {
      "type": "string",
      "enum": [
        "similar_items",
        "same_source",
        "agent_behavior",
        "general"
      ]
    },
    "body": {
      "type": [
        "string",
        "null"
      ],
      "maxLength": 16384
    },
    "deliveredAt": {
      "type": "string",
      "format": "date-time"
    },
    "contentPurgedAt": {
      "type": [
        "string",
        "null"
      ],
      "format": "date-time"
    },
    "status": {
      "type": "string",
      "enum": [
        "delivered",
        "acknowledged"
      ]
    },
    "acknowledgment": {
      "oneOf": [
        {
          "type": "null"
        },
        {
          "type": "object",
          "required": [
            "acknowledgedAt",
            "acknowledgedByAgentId"
          ],
          "additionalProperties": false,
          "properties": {
            "acknowledgedAt": {
              "type": "string",
              "format": "date-time"
            },
            "acknowledgedByAgentId": {
              "type": "string"
            }
          }
        }
      ]
    }
  }
}