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

# List Event Types | Webhooks API

> List event types via the Atoa Webhooks API, request parameters, response schema and code samples in cURL, Python, JavaScript, PHP, Go and Java.

Returns all available event types that can be used when creating or updating a webhook endpoint.

### Authorization

Bearer `<token>`

**Response**

Array of event type objects.

**event** `string`

Event type name to use in create/update requests (e.g. `PAYMENTS_STATUS`).

**label** `string`

Human-readable label (e.g. `Payment Status`).

**description** `string`

A short description of when this event is triggered.

**requiresSigningSecret** `boolean`

When `true`, a webhook signing key must be generated before subscribing to this event type. See [Webhook Signing Key](https://docs.paywithatoa.com/api-reference/webhook/introduction.md#signature-verification).

```bash cURL theme={null}
curl --request GET \
  --url https://api.atoa.me/api/webhook/v2/event-types \
  --header 'Authorization: Bearer <token>'
```

```python Python theme={null}
import requests

url = "https://api.atoa.me/api/webhook/v2/event-types"
headers = { "Authorization": "Bearer <token>" }

response = requests.request("GET", url, headers=headers)
print(response.text)
```

```javascript JavaScript theme={null}
fetch('https://api.atoa.me/api/webhook/v2/event-types', {
  method: 'GET',
  headers: { Authorization: 'Bearer <token>' }
})
  .then(response => response.json())
  .then(response => console.log(response))
  .catch(err => console.error(err));
```

```php PHP theme={null}
<?php

$curl = curl_init();

curl_setopt_array($curl, [
  CURLOPT_URL => "https://api.atoa.me/api/webhook/v2/event-types",
  CURLOPT_RETURNTRANSFER => true,
  CURLOPT_ENCODING => "",
  CURLOPT_MAXREDIRS => 10,
  CURLOPT_TIMEOUT => 30,
  CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
  CURLOPT_CUSTOMREQUEST => "GET",
  CURLOPT_HTTPHEADER => [
    "Authorization: Bearer <token>"
  ],
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
  echo "cURL Error #:" . $err;
} else {
  echo $response;
}
```

```go Go theme={null}
package main

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

func main() {

	url := "https://api.atoa.me/api/webhook/v2/event-types"

	req, _ := http.NewRequest("GET", url, nil)

	req.Header.Add("Authorization", "Bearer <token>")

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(string(body))

}
```

```java Java theme={null}
HttpResponse<String> response = Unirest.get("https://api.atoa.me/api/webhook/v2/event-types")
  .header("Authorization", "Bearer <token>")
  .asString();
```

```json 200 theme={null}
[
  { "event": "PAYMENTS_STATUS", "label": "Payment Status", "description": "Triggered when a payment is completed successfully.", "requiresSigningSecret": false },
  { "event": "EXPIRED_STATUS", "label": "Expired Status", "description": "Triggered when a payment request expires without completion.", "requiresSigningSecret": false },
  { "event": "REFUND_STATUS", "label": "Refund Status", "description": "Triggered when a refund is initiated or completed.", "requiresSigningSecret": false },
  { "event": "POS_PAYMENT_STATUS", "label": "POS Payment Status", "description": "Triggered when a POS payment status changes. Requires a webhook signing secret.", "requiresSigningSecret": true },
  { "event": "PAYMENT_METHOD_STATUS", "label": "Payment Method Status", "description": "Triggered when a customer's card is saved for future payments or removed from their saved cards", "requiresSigningSecret": false }
]
```

```json 401 theme={null}
{
  "name": "UNAUTHORIZED",
  "message": "Unauthorized",
  "status": 401,
  "errors": "[]"
}
```


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.