# webhookEvents

```graphql
query WebhookEvents($projectReference: ID!, $webhookId: ID!) {
  webhookEvents(projectReference: $projectReference, webhookId: $webhookId) {
    data {
      id
      webhookId
      projectId
      status
      duplicate
      payload
      conversationId
      messageId
      runId
      canonicalRunId
      latestEventId
      errorCode
      errorMessage
      invokedBy
      manualInvokedByUserId
      receivedAt
      completedAt
      createdAt
    }
    pageInfo {
      hasNextPage
      hasPreviousPage
      startCursor
      endCursor
    }
  }
}
```

List the events a webhook received, newest first, to check deliveries, manual runs and replays; returns one page of webhook events, each with the run it started, if any, and an event that the filter stopped has the status ignored. Requires project.agents.read.

## Arguments

| Name               | Type               | Required | Description                                                                                    |
| ------------------ | ------------------ | -------- | ---------------------------------------------------------------------------------------------- |
| `projectReference` | ID!                | Yes      | Project UUID or slug.                                                                          |
| `webhookId`        | ID!                | Yes      | The webhook id. A missing webhook fails with not\_found.                                       |
| `input`            | WebhookEventsInput |          |                                                                                                |
| `input.limit`      | Int                |          | Maximum webhook events to return, 1 to 100; default 50.                                        |
| `input.cursor`     | ID                 |          | The previous page's pageInfo.endCursor. Keep sortOrder the same across pages.                  |
| `input.sortOrder`  | WebhookSortOrder   |          | Creation order; default desc (newest first). Ties break by id ascending. One of `asc`, `desc`. |

## Variables

```json
{
  "projectReference": "string",
  "webhookId": "string"
}
```

## Responses

| Status | Description                                  |
| ------ | -------------------------------------------- |
| 200    | The WebhookEventPage! in data.webhookEvents. |

## Call it

```bash
curl -X POST "https://api.veryfront.com/graphql" \
  -H "Authorization: Bearer $VERYFRONT_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
  "query": "query WebhookEvents($projectReference: ID!, $webhookId: ID!) {\n  webhookEvents(projectReference: $projectReference, webhookId: $webhookId) {\n    data {\n      id\n      webhookId\n      projectId\n      status\n      duplicate\n      payload\n      conversationId\n      messageId\n      runId\n      canonicalRunId\n      latestEventId\n      errorCode\n      errorMessage\n      invokedBy\n      manualInvokedByUserId\n      receivedAt\n      completedAt\n      createdAt\n    }\n    pageInfo {\n      hasNextPage\n      hasPreviousPage\n      startCursor\n      endCursor\n    }\n  }\n}",
  "variables": {
    "projectReference": "string",
    "webhookId": "string"
  }
}'
```

## Example response

```json
{
  "data": {
    "webhookEvents": {
      "data": [
        {
          "id": "string",
          "webhookId": "string",
          "projectId": "string",
          "status": "received",
          "duplicate": false,
          "payload": {},
          "conversationId": "string",
          "messageId": "string",
          "runId": "string",
          "canonicalRunId": "string",
          "latestEventId": 0,
          "errorCode": "string",
          "errorMessage": "string",
          "invokedBy": "string",
          "manualInvokedByUserId": "string",
          "receivedAt": "2026-01-01T00:00:00Z",
          "completedAt": "2026-01-01T00:00:00Z",
          "createdAt": "2026-01-01T00:00:00Z"
        }
      ],
      "pageInfo": {
        "hasNextPage": false,
        "hasPreviousPage": false,
        "startCursor": "string",
        "endCursor": "string"
      }
    }
  }
}
```
