{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://workflows.dubspeak.com/schemas/narrated-presentation-inquiry.schema.json",
  "title": "Narrated presentation inquiry DRAFT (metadata only, custom)",
  "description": "A metadata-only draft that an agent may prepare for a human to review. It is never submitted automatically; there is no endpoint. No uploads and no contact details belong in it.",
  "type": "object",
  "additionalProperties": false,
  "required": [
    "$schema",
    "documentStatus",
    "submitted",
    "executed",
    "uploadsIncluded",
    "capability",
    "deck",
    "script",
    "languages",
    "targetDurationSeconds",
    "permissions",
    "humanReview"
  ],
  "properties": {
    "$schema": {
      "const": "https://workflows.dubspeak.com/schemas/narrated-presentation-inquiry.schema.json"
    },
    "documentStatus": {
      "enum": [
        "example",
        "draft"
      ]
    },
    "submitted": {
      "const": false
    },
    "executed": {
      "const": false
    },
    "uploadsIncluded": {
      "const": false
    },
    "capability": {
      "const": "https://workflows.dubspeak.com/capabilities/narrated-presentation.json"
    },
    "deck": {
      "type": "object",
      "additionalProperties": false,
      "required": [
        "format",
        "pageCount"
      ],
      "properties": {
        "format": {
          "type": "string",
          "maxLength": 40
        },
        "pageCount": {
          "type": [
            "integer",
            "null"
          ],
          "minimum": 1
        }
      }
    },
    "script": {
      "type": "object",
      "additionalProperties": false,
      "required": [
        "pageMapped"
      ],
      "properties": {
        "pageMapped": {
          "type": "boolean"
        }
      }
    },
    "languages": {
      "type": "array",
      "minItems": 1,
      "items": {
        "type": "string",
        "pattern": "^[a-z]{2,3}(-[A-Za-z0-9]{2,8})*$"
      }
    },
    "targetDurationSeconds": {
      "type": [
        "number",
        "null"
      ],
      "exclusiveMinimum": 0
    },
    "permissions": {
      "type": "object",
      "additionalProperties": false,
      "required": [
        "sourceRights",
        "voiceConsent",
        "embeddedMediaRights"
      ],
      "properties": {
        "sourceRights": {
          "type": [
            "boolean",
            "null"
          ]
        },
        "voiceConsent": {
          "type": [
            "boolean",
            "null"
          ]
        },
        "embeddedMediaRights": {
          "type": [
            "boolean",
            "null"
          ]
        }
      }
    },
    "humanReview": {
      "type": "object",
      "additionalProperties": false,
      "required": [
        "reviewerAvailable"
      ],
      "properties": {
        "reviewerAvailable": {
          "type": [
            "boolean",
            "null"
          ]
        }
      }
    },
    "notes": {
      "type": "string",
      "maxLength": 1000
    },
    "handoff": {
      "type": "string",
      "maxLength": 500
    }
  }
}
