# List webhook deliveries

List webhook deliveries

`GET https://api.cadmospay.com/machine/v1/gateway/webhooks/deliveries`

Newest first, including test events and manual redeliveries. Follow the exclusive next cursor.

## Authentication

`Authorization: Bearer <accessToken>`

The `accessToken` from `POST /v1/external-auth/token`, valid 15 minutes.

## Example requests

```bash
curl --fail-with-body 'https://api.cadmospay.com/machine/v1/gateway/webhooks/deliveries' \
  -H "Authorization: Bearer ${CADMOS_ACCESS_TOKEN:?Set CADMOS_ACCESS_TOKEN}"
```

```javascript
const { CADMOS_ACCESS_TOKEN } = process.env;
if (!CADMOS_ACCESS_TOKEN) {
  throw new Error("Set CADMOS_ACCESS_TOKEN");
}

const url = new URL("https://api.cadmospay.com/machine/v1/gateway/webhooks/deliveries");
const response = await fetch(url, {
  method: "GET",
  redirect: "error",
  headers: {
    Authorization: "Bearer " + CADMOS_ACCESS_TOKEN,
  },
});
console.log(response.status, await response.json());
```

```python
from http.client import HTTPSConnection
import os

conn = HTTPSConnection("api.cadmospay.com", timeout=30)
path = "/machine/v1/gateway/webhooks/deliveries"
headers = {
    "Authorization": "Bearer " + os.environ["CADMOS_ACCESS_TOKEN"],
}
conn.request("GET", path, headers=headers)
response = conn.getresponse()
print(response.status, response.read().decode())
conn.close()
```

## Parameters

- `cursor` (string, query, optional, pattern ^[1-9]\d{0,9}$). 
- `limit` (integer, query, optional, value 1 to 100). 

## Responses

### 200

List webhook deliveries

[DeliveryPage](https://cadmospay.com/developers/schemas/delivery-page.md)

### 401

No token, or a token that is expired or not for this route: sign in again.

[Error](https://cadmospay.com/developers/schemas/error.md)

### 403

Your identity is not allowed this route, or has no business wallet.

[Error](https://cadmospay.com/developers/schemas/error.md)

### 422

The request does not match this contract: `VALIDATION_ERROR` lists each field and the rule it broke. An amount outside $0.50 to $1,000,000 is refused here too.

[Error](https://cadmospay.com/developers/schemas/error.md)

### 429

Over a limit. Wait and retry.

[Error](https://cadmospay.com/developers/schemas/error.md)
