{
  "$id": "https://schema.nfh.global/TravelDocument/v2.0",
  "x-iri": "https://schema.nfh.global/TravelDocument/v2.0",
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "title": "TravelDocument",
  "type": "object",
  "description": "A document (physical or digital) issued to a passenger proving entitlement to travel, used for validation or inspection.",
  "properties": {
    "documentType": {
      "description": "Type of travel document (e.g. E_TICKET, PDF_TICKET, SMARTCARD, BARCODE)",
      "type": "string"
    },
    "documentNumber": {
      "description": "Unique document number or serial",
      "type": "string"
    },
    "issuingAuthority": {
      "description": "The operator or authority that issued this document",
      "$ref": "https://schema.nfh.global/Operator/v2.0/schema.json"
    },
    "validFrom": {
      "description": "Start date of the document validity",
      "type": "string",
      "format": "date-time"
    },
    "validUntil": {
      "description": "Expiry date of the document",
      "type": "string",
      "format": "date-time"
    },
    "id": {
      "description": "Unique identifier for the entitlement",
      "type": "string"
    },
    "descriptor": {
      "description": "Human-readable information about the entitlement",
      "$ref": "https://schema.nfh.global/Descriptor/v2.1/schema.json"
    },
    "resource": {
      "description": "The resource being accessed against this entitlement",
      "$ref": "https://schema.nfh.global/ContractItem/v2.0/schema.json"
    },
    "credentials": {
      "description": "Credential descriptors for the entitlement",
      "$ref": "https://schema.nfh.global/Descriptor/v2.1/schema.json"
    }
  },
  "additionalProperties": false,
  "x-tags": [
    "mobility",
    "schema-org",
    "ride-hailing"
  ]
}
