MEXICOP2P

GET /webhooks

List webhook delivery history with status and retry info.

GET /webhooks

Retrieve the history of webhook deliveries for your partner account. Use this to debug delivery issues or verify event receipt.

Request

curl -H "X-API-Key: mp2p_test_xxx" \
  "https://mexicop2p.org/api/v1/webhooks?status=FAILED&limit=10"

Query parameters

ParameterTypeDefaultDescription
statusstringFilter: PENDING, DELIVERED, FAILED
orderIdstringFilter by order ID
eventTypestringFilter by event type (e.g. order.completed)
limitnumber20Max results (1–100)
offsetnumber0Pagination offset

Response 200

{
  "deliveries": [
    {
      "id": "del_abc123",
      "orderId": "ord_xyz789",
      "eventType": "order.completed",
      "status": "DELIVERED",
      "attempts": 1,
      "maxAttempts": 5,
      "lastAttemptAt": "2025-06-15T12:35:01.000Z",
      "nextAttemptAt": null,
      "deliveredAt": "2025-06-15T12:35:01.000Z",
      "errorMessage": null,
      "createdAt": "2025-06-15T12:35:00.000Z"
    },
    {
      "id": "del_def456",
      "orderId": "ord_xyz789",
      "eventType": "order.locked",
      "status": "FAILED",
      "attempts": 5,
      "maxAttempts": 5,
      "lastAttemptAt": "2025-06-15T14:35:00.000Z",
      "nextAttemptAt": null,
      "deliveredAt": null,
      "errorMessage": "Connection timeout after 10s",
      "createdAt": "2025-06-15T12:15:00.000Z"
    }
  ],
  "total": 2,
  "limit": 10,
  "offset": 0,
  "hasMore": false
}

Delivery fields

FieldTypeDescription
idstringUnique delivery ID
orderIdstringRelated order
eventTypestringWebhook event type
statusstringPENDING, DELIVERED, or FAILED
attemptsnumberNumber of delivery attempts made
maxAttemptsnumberMaximum attempts (5)
lastAttemptAtstring|nullLast attempt timestamp
nextAttemptAtstring|nullNext retry timestamp (if pending)
deliveredAtstring|nullSuccessful delivery timestamp
errorMessagestring|nullError details (if failed)
createdAtstringWhen the delivery was queued

On this page