> For the complete documentation index, see [llms.txt](https://docs.cryptobox.ninja/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.cryptobox.ninja/withdrawals/withdrawal-events.md).

# Withdrawal Events

When the system performs a withdrawal that belongs to one of the customers' users, it will inform the customer through the customer's withdrawal callback URL.

{% hint style="info" %}
The system administrators manage the callback URLs for informing the withdrawals. You should contact our system administrators to set your callback URL.
{% endhint %}

{% hint style="success" %}
Every callback request will originate from the following IP addresses: **18.132.254.104,18.170.187.186**.

\
Our system signs the **withdrawal event object** with the customer's **HMAC secret** and sends the signature with the **x-payload-hash** header. So the customers can check the integrity of these requests by comparing the **x-payload-hash** with the one they calculated upon receiving the withdrawal information. The customer can also assume that the callbacks originate from our system if they arrive at their end from these IP addresses.
{% endhint %}

Once the system performs a withdrawal that belongs to one of the customers' users, the payment gateway calls their registered callback with the following event object.

```json
{
    "objectType": "withdrawEventObject",
    "txId": "BLOCKCHAIN TRANSACTION HASH OF THE WITHDRAWAL",
    "amount": AMOUNT OF THE TRANSACTION,
    "userId": "CUSTOMER'S USER ID",
    "userName": "CUSTOMER'S USER NAME",
    "operationNo": "OPERATION ID",
    "withdrawTime": EPOCH TIME OF THE EVENT,
    "currency": "CURRENCY OF THE WITHDRAWAL",
    "withdrawalState": "WITHDRAWAL STATE"
}
```

## Withdrawal Event Object Structure

| Field           | Type/Description                                                                                                                                                                                                                                          |
| --------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| objectType      | <p>STRING <br>Customers can use this field to create their object hierarchy. All objects sent by the system will have this field. For Withdrawal Event Object, this field can consist of a single value: <strong>withdrawEventObject</strong>.</p>        |
| amount          | <p>NUMBER <br>This field represents the amount of the withdrawal.</p>                                                                                                                                                                                     |
| userId          | <p>STRING <br>This field represents the user ID associated with the customer's withdrawal request.</p>                                                                                                                                                    |
| operationNo     | <p>STRING <br>This is the operation id of the withdrawal. The customer is responsible for sending a unique operation id in UUID format for each withdrawal request. When the system performs this request, the callback object consists of this UUID.</p> |
| withdrawTime    | <p>NUMBER <br>This field represents the epoch time of the withdrawal.</p>                                                                                                                                                                                 |
| currency        | <p>STRING <br>This field represents the blockchain currency of the withdrawal.</p>                                                                                                                                                                        |
| withdrawalState | <p>STRING<br>Please see <a href="/withdrawals/withdrawal-session.md#queries-the-withdrawal-request">GET Withdrawal</a> for further details.</p>                                                                                                           |

<br>
