{
  "$schema": "https://abhcr.github.io/comcom-protocol/releases/v0.2.0/schemas/comcom-meta.schema.json",
  "$id": "https://abhcr.github.io/comcom-protocol/releases/v0.2.0/profiles/v0.2/operations.logistics/comcom-proof-of-delivery-get/schemas/resource.schema.json",
  "title": "ProofOfDelivery resource for comcom.proof.of.delivery.get",
  "type": "object",
  "additionalProperties": false,
  "required": [
    "id",
    "type",
    "state",
    "revision",
    "createdAt",
    "updatedAt"
  ],
  "properties": {
    "id": {
      "type": "string",
      "description": "Globally unique resource URI.",
      "format": "uri-reference"
    },
    "type": {
      "const": "ProofOfDelivery"
    },
    "state": {
      "type": "string",
      "description": "Profile-defined state.",
      "pattern": "^[a-z][a-zA-Z0-9.-]{0,63}$"
    },
    "revision": {
      "type": "integer",
      "minimum": 0
    },
    "createdAt": {
      "type": "string",
      "description": "Creation instant.",
      "format": "date-time"
    },
    "updatedAt": {
      "type": "string",
      "description": "Last update instant.",
      "format": "date-time"
    },
    "statusCode": {
      "type": "string",
      "description": "Profile-defined business state.",
      "pattern": "^[a-z][a-zA-Z0-9.-]{0,63}$"
    },
    "shipmentId": {
      "type": "string",
      "description": "Shipment URI.",
      "format": "uri-reference"
    },
    "carrierId": {
      "type": "string",
      "description": "Carrier URI.",
      "format": "uri-reference"
    },
    "trackingCode": {
      "type": "string",
      "description": "Carrier tracking code.",
      "maxLength": 100
    },
    "originLocationId": {
      "type": "string",
      "description": "Origin location URI.",
      "format": "uri-reference"
    },
    "destinationLocationId": {
      "type": "string",
      "description": "Destination location URI.",
      "format": "uri-reference"
    },
    "estimatedAt": {
      "type": "string",
      "description": "Estimated event instant.",
      "format": "date-time"
    },
    "occurredAt": {
      "type": "string",
      "description": "Actual event instant.",
      "format": "date-time"
    },
    "packageCount": {
      "type": "integer",
      "minimum": 1,
      "maximum": 100000
    }
  }
}
