> ## Documentation Index
> Fetch the complete documentation index at: https://docs.hookstream.io/llms.txt
> Use this file to discover all available pages before exploring further.

# List delivery attempts

List delivery attempts with optional filters for event, connection, destination, and status.

` GET /delivery-attempts `

List delivery attempts

List delivery attempts with optional filters for event, connection, destination, and status.

## Servers

- ` https://hookstream.io/v1 ` — Production

## Authentication

The operation accepts these alternatives. Schemes within one alternative are required together.

### Alternative 1

- ` apiKey `: ` apiKey `

  - Credential: ` X-API-Key ` in ` header `

  - API key (format: hs_live_<64hex> or hs_test_<64hex>)

### Alternative 2

- ` cookieAuth `: ` apiKey `

  - Credential: ` better-auth.session_token ` in ` cookie `

  - Session cookie (browser auth)

## Parameters

### ` limit ` (query, optional)

Max results (default 50, max 100)

- ` value `: type ` string ` — Max results (default 50, max 100)

  - example: ` "50" `

Example:

```json
"50"
```

### ` offset ` (query, optional)

Offset for pagination

- ` value `: type ` string ` — Offset for pagination

  - example: ` "0" `

Example:

```json
"0"
```

### ` event_id ` (query, optional)

Filter by event ID

- ` value `: type ` string ` — Filter by event ID

### ` connection_id ` (query, optional)

Filter by connection ID

- ` value `: type ` string ` — Filter by connection ID

### ` destination_id ` (query, optional)

Filter by destination ID

- ` value `: type ` string ` — Filter by destination ID

### ` status ` (query, optional)

Filter by delivery status

- ` value `: type ` string ` — Filter by delivery status

### ` is_dlq ` (query, optional)

Filter by DLQ status (1 = DLQ only)

- ` value `: type ` string ` — Filter by DLQ status (1 = DLQ only)

  - enum: ` ["0","1"] `

## Responses

### ` 200 ` — Paginated list of delivery attempts

Content type: ` application/json `

- ` value `: type ` object `

  - Required fields: ` delivery_attempts `, ` pagination `

  - ` delivery_attempts `: type ` array `

    - ` array item `: type ` object `

      - Required fields: ` id `, ` org_id `, ` env_id `, ` event_id `, ` connection_id `, ` destination_id `, ` request_url `, ` request_method `, ` request_headers `, ` request_body_size `, ` response_status `, ` response_headers `, ` response_body `, ` duration_ms `, ` status `, ` error `, ` created_at `, ` attempt_number `, ` next_retry_at `, ` is_dlq `, ` dlq_at `, ` trigger_type `, ` connection_name `, ` destination_name `

      - ` id `: type ` string `

      - ` org_id `: type ` string `

      - ` env_id `: type ` string `

      - ` event_id `: type ` string `

      - ` connection_id `: type ` string `

      - ` destination_id `: type ` string `

      - ` request_url `: type ` string `

      - ` request_method `: type ` string `

      - ` request_headers `: type ` string `; nullable

      - ` request_body_size `: type ` integer `

      - ` response_status `: type ` integer `; nullable

      - ` response_headers `: type ` string `; nullable

      - ` response_body `: type ` string `; nullable

      - ` duration_ms `: type ` integer `; nullable

      - ` status `: type ` string `

      - ` error `: type ` string `; nullable

      - ` created_at `: type ` string `

      - ` attempt_number `: type ` integer `; nullable

      - ` next_retry_at `: type ` string `; nullable

      - ` is_dlq `: type ` integer `; nullable

      - ` dlq_at `: type ` string `; nullable

      - ` trigger_type `: type ` string `; nullable

      - ` connection_name `: type ` string `; nullable

      - ` destination_name `: type ` string `; nullable

  - ` pagination `: type ` object `

    - Required fields: ` total `, ` limit `, ` offset `, ` has_more `

    - ` total `: type ` number `

    - ` limit `: type ` number `

    - ` offset `: type ` number `

    - ` has_more `: type ` boolean `

    - ` next_cursor `: type ` string `; nullable

    - ` prev_cursor `: type ` string `; nullable

### ` 401 ` — Unauthorized

Content type: ` application/json `

- ` value `: type ` object `

  - Required fields: ` error `

  - ` error `: type ` string ` — Error message

## Request examples

### cURL

```curl
curl -X GET 'https://hookstream.io/v1/delivery-attempts' \
  -H 'Authorization: Bearer YOUR_API_TOKEN'
```

### JavaScript

```javascript
const response = await fetch('https://hookstream.io/v1/delivery-attempts', {
  method: 'GET',
  headers: {
      "Authorization": "Bearer YOUR_API_TOKEN"
  }
});

const data = await response.json();
console.log(data);
```

### Python

```python
import requests

headers = {
    'Authorization': 'Bearer YOUR_API_TOKEN'
}

response = requests.get('https://hookstream.io/v1/delivery-attempts', headers=headers)
print(response.json())
```

### Go

```go
package main

import (
	"fmt"
	"io"
	"net/http"
)

func main() {
	req, _ := http.NewRequest("GET", "https://hookstream.io/v1/delivery-attempts", nil)
	req.Header.Set("Authorization", "Bearer YOUR_API_TOKEN")

	resp, _ := http.DefaultClient.Do(req)
	defer resp.Body.Close()
	result, _ := io.ReadAll(resp.Body)
	fmt.Println(string(result))
}
```