Skip to main content
Every HTTP request that reaches an inbox is stored as an event. Events contain the complete, unmodified request — method, path, all headers, the raw body, and query string — along with a timestamp. Use the Events API to retrieve those records programmatically and feed them into your tests, logging pipelines, or debugging tools.

List events for an inbox

Returns captured events for the specified inbox, ordered newest first. Results are paginated; use limit and offset to page through large sets.

Path parameters

id
string
required
The unique ID of the inbox whose events you want to retrieve. You receive this value when you create an inbox.

Query parameters

limit
number
Maximum number of events to return. Defaults to 20. Cannot exceed 100.
offset
number
Number of events to skip before returning results. Defaults to 0. Use this to implement pagination alongside limit.

Authentication

Authentication is required for saved inboxes. Pass your Bearer token in the Authorization header. Anonymous inboxes can be read without a token while they are still active.

Request

curl -X GET "https://api.webhooktrap.dev/api/v1/inboxes/xK9m2pQ7nR4a/events?limit=20&offset=0" \
  -H "Authorization: Bearer YOUR_API_TOKEN"

Response

{
  "data": {
    "events": [
      {
        "id": "evt_abc123",
        "inboxId": "xK9m2pQ7nR4a",
        "method": "POST",
        "path": "/i/xK9m2pQ7nR4a",
        "headers": {
          "content-type": "application/json",
          "stripe-signature": "t=...,v1=..."
        },
        "body": "{\"type\":\"checkout.session.completed\"}",
        "queryString": "",
        "receivedAt": "2024-01-15T10:30:00Z"
      }
    ],
    "total": 1
  }
}
events
array
An array of event objects, ordered newest first.
total
number
The total number of events stored for this inbox, regardless of the current limit and offset. Use this value to calculate how many pages of results are available.