List webhook deliveries

GET

GET https://external-api.lia.com.br/external_api/v1/webhook_deliveries

Query Parameters

NameDescriptionRequiredType
webhook_idFilter deliveries by webhook configuration IDfalseString
pagePage number for paginationfalseNumber
per_pageNumber of records per page (default: 20, max: 100)falseNumber

Example request

curl --location 'https://external-api-sandbox.lia.com.br/external_api/v1/webhook_deliveries?webhook_id=8a7b9c5d-1234-5678-9abc-def012345678&page=1&per_page=10' \
--header 'Authorization: Bearer YOUR_API_TOKEN'

Example response

{
  "data": [
    {
      "id": "f47ac10b-58cc-4372-a567-0e02b2c3d479",
      "entity_id": "9b1deb4d-3b7d-4bad-9bdd-2b0d7b3dcb6d",
      "entity_type": "Payment",
      "webhook_id": "8a7b9c5d-1234-5678-9abc-def012345678",
      "event": "payment.paid",
      "created_at": "2024-05-20T14:30:00.000-03:00",
      "updated_at": "2024-05-20T14:30:05.123-03:00",
      "response_code": 200,
      "request_headers": {
        "Content-Type": "application/json",
        "X-Lia-Signature": "sha256=abc123def456...",
        "User-Agent": "Lia-Webhooks/1.0"
      },
      "request_body": {
        "event": "payment.paid",
        "data": {
          "id": "9b1deb4d-3b7d-4bad-9bdd-2b0d7b3dcb6d",
          "amount_cents": 10000,
          "status": "paid",
          "paid_at": "2024-05-20T14:29:55.000-03:00"
        }
      },
      "response_headers": {
        "Content-Type": "application/json",
        "X-Request-Id": "req_abc123"
      },
      "response_body": "{\"success\":true,\"message\":\"Webhook received\"}"
    },
    {
      "id": "c8d91f2e-4a5b-6c7d-8e9f-0a1b2c3d4e5f",
      "entity_id": "7e8f9a0b-1c2d-3e4f-5a6b-7c8d9e0f1a2b",
      "entity_type": "Bill",
      "webhook_id": "8a7b9c5d-1234-5678-9abc-def012345678",
      "event": "bill.overdue",
      "created_at": "2024-05-19T10:15:00.000-03:00",
      "updated_at": "2024-05-19T10:15:02.456-03:00",
      "response_code": 500,
      "request_headers": {
        "Content-Type": "application/json",
        "X-Lia-Signature": "sha256=xyz789abc123...",
        "User-Agent": "Lia-Webhooks/1.0"
      },
      "request_body": {
        "event": "bill.overdue",
        "data": {
          "id": "7e8f9a0b-1c2d-3e4f-5a6b-7c8d9e0f1a2b",
          "due_date": "2024-05-15",
          "status": "overdue"
        }
      },
      "response_headers": {
        "Content-Type": "text/plain"
      },
      "response_body": "Internal Server Error"
    }
  ],
  "meta": {
    "current_page": 1,
    "next_page": 2,
    "prev_page": null,
    "total_pages": 5,
    "total_count": 47
  }
}

Response codes

CodeDescription
200Successfully retrieved webhook deliveries list
401Unauthorized - Invalid or missing API token
404Webhook configuration not found (if webhook_id provided)