> For the complete documentation index, see [llms.txt](https://relampago.gitbook.io/rayo-apis/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://relampago.gitbook.io/rayo-apis/reference/rayo-instant-ln-payouts-to-latam/webhook.md).

# Webhook

Designates a webhook where the client can receive real time payout updates.

## Designates a webhook to receive payout status updates

<mark style="color:green;">`POST`</mark> `https://api.relampago.cash/webhook`

#### Headers

| Name                                            | Type   | Description                            |
| ----------------------------------------------- | ------ | -------------------------------------- |
| X-API-KEY<mark style="color:red;">\*</mark>     | String | the api key must be part of the header |
| Authorization<mark style="color:red;">\*</mark> | String | the session token                      |

#### Request Body

| Name                                  | Type   | Description     |
| ------------------------------------- | ------ | --------------- |
| url<mark style="color:red;">\*</mark> | String | The webhook url |

{% tabs %}
{% tab title="200: OK Successful Response" %}

{% endtab %}
{% endtabs %}

The webhook must be able to accept a request body in the following format:

```
{
    event: String, //"SUCCESS" or "FAILURE"
    txId: String, //the txId of the payout
}
```
