{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/whatsapp/json-schema/whatsapp-message-history-events-response-schema.json",
  "title": "MessageHistoryEventsResponse",
  "description": "Paginated response containing message history events",
  "x-generated": "2026-11-10",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/whatsapp-message-history-events-api-openapi.yml#/components/schemas/MessageHistoryEventsResponse",
  "type": "object",
  "properties": {
    "data": {
      "type": "array",
      "description": "Array of message history event edges",
      "items": {
        "$ref": "#/$defs/WhatsAppMessageHistoryEventsEdge"
      }
    },
    "paging": {
      "$ref": "#/$defs/PaginationInfo"
    }
  },
  "$defs": {
    "ApplicationNode": {
      "type": "object",
      "description": "Meta application that owns the Multi-Partner Solution",
      "properties": {
        "id": {
          "type": "string",
          "description": "Unique identifier for the Meta application"
        },
        "name": {
          "type": "string",
          "description": "Name of the Meta application"
        }
      }
    },
    "PaginationInfo": {
      "type": "object",
      "description": "Pagination information for navigating through results",
      "properties": {
        "cursors": {
          "type": "object",
          "description": "Pagination cursors for navigation",
          "properties": {
            "before": {
              "type": "string",
              "description": "Cursor for the previous page of results"
            },
            "after": {
              "type": "string",
              "description": "Cursor for the next page of results"
            }
          }
        },
        "previous": {
          "type": "string",
          "format": "uri",
          "description": "URL for the previous page of results"
        },
        "next": {
          "type": "string",
          "format": "uri",
          "description": "URL for the next page of results"
        }
      }
    },
    "WhatsAppBusinessMessageDeliveryStatusOccurrence": {
      "type": "object",
      "description": "Message delivery status occurrence with detailed event information",
      "required": [
        "id",
        "delivery_status",
        "occurrence_timestamp"
      ],
      "properties": {
        "id": {
          "type": "string",
          "description": "Unique identifier for the message delivery status occurrence"
        },
        "delivery_status": {
          "$ref": "#/$defs/WhatsAppMessageDeliveryStatus"
        },
        "error_description": {
          "type": "string",
          "description": "Error description if the delivery encountered an error"
        },
        "occurrence_timestamp": {
          "type": "integer",
          "format": "int64",
          "description": "Unix timestamp when the delivery status occurrence happened"
        },
        "status_timestamp": {
          "type": "integer",
          "format": "int64",
          "description": "Unix timestamp when the status was recorded"
        },
        "application": {
          "$ref": "#/$defs/ApplicationNode"
        }
      }
    },
    "WhatsAppMessageDeliveryStatus": {
      "type": "string",
      "description": "Message delivery status",
      "enum": [
        "SENT",
        "DELIVERED",
        "READ",
        "FAILED",
        "DELETED"
      ]
    },
    "WhatsAppMessageHistoryEventsEdge": {
      "type": "object",
      "description": "Edge containing message delivery status occurrence with pagination cursor",
      "required": [
        "node"
      ],
      "properties": {
        "cursor": {
          "type": "string",
          "description": "Pagination cursor for this edge"
        },
        "node": {
          "$ref": "#/$defs/WhatsAppBusinessMessageDeliveryStatusOccurrence"
        }
      }
    }
  }
}