{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/derive-to/json-schema/derive-to-delivery-schema.json",
  "title": "Delivery",
  "x-generated": "2026-11-10",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/derive-to-webhooks-api-openapi.yml#/components/schemas/Delivery",
  "type": "object",
  "properties": {
    "id": {
      "type": "string"
    },
    "event_type": {
      "type": "string"
    },
    "status": {
      "type": "string",
      "enum": [
        "pending",
        "delivered",
        "dead"
      ],
      "description": "Delivery state: pending (awaiting/retrying), delivered (succeeded), dead (gave up)"
    },
    "attempts": {
      "type": "number",
      "description": "Number of delivery attempts made so far"
    },
    "last_error": {
      "type": [
        "string",
        "null"
      ],
      "description": "The most recent failure message, or null if none"
    },
    "created_at": {
      "type": "string"
    }
  },
  "required": [
    "id",
    "event_type",
    "status",
    "attempts",
    "last_error",
    "created_at"
  ]
}