> For the complete documentation index, see [llms.txt](https://docs.0xprocessing.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.0xprocessing.com/0xprocessing-api-v1/webhooks/webhooks-for-withdrawals.md).

# Webhooks for Withdrawals

Configure webhooks to get real-time updates on withdrawal processes, ensuring seamless tracking and reliable operations for your payment gateway.

## Webhook response

Withdrawal status updates are delivered through webhooks.

For more information on setting up Webhooks, see the **Setting up Webhooks.**

Set the Webhook URL in the menu **Settings → API → Webhook URL**. **HTTPS (TLS/SSL) is required.**

**Webhook password** - password required to verify the withdrawal signature

**Webhook URL** - the endpoint where 0xProcessing sends withdrawal status notifications.

**Request method:** POST

**Response Type:** JSON

**Parameters:**

<table><thead><tr><th width="185">Name</th><th width="454">Description</th><th>Type</th></tr></thead><tbody><tr><td>ID</td><td>Withdrawal ID in the 0xProcessing system</td><td>Integer</td></tr><tr><td>MerchantID</td><td>Merchant Id in 0xProcessing system</td><td>String</td></tr><tr><td>Date</td><td>Date of withdrawal request</td><td>DateTime</td></tr><tr><td>Amount</td><td>Withdrawal amount in cryptocurrency</td><td>Double</td></tr><tr><td>AmountUSD</td><td>Withdrawal amount in USD equivalent</td><td>Double</td></tr><tr><td>Fee</td><td>Withdrawal fee in token equivalent</td><td>Double</td></tr><tr><td>Currency</td><td>Withdrawal currency</td><td>String</td></tr><tr><td>Address</td><td>Withdrawal address</td><td>String</td></tr><tr><td>Status</td><td><p>Withdrawal status</p><p>Possible values are:</p><p><strong>Success</strong> - withdrawal has been executed successfully</p><p><strong>Canceled</strong> - withdrawal has not been executed</p></td><td>String</td></tr><tr><td>Reason</td><td>Reason for rejection</td><td>String</td></tr><tr><td>ExternalID</td><td>Unique withdrawal identifier in the system from which the withdrawal is made</td><td>String</td></tr><tr><td>Signature</td><td>Checksum to verify the authenticity of the request (to ensure that the request came from 0xProcessing)</td><td>String</td></tr><tr><td>ClientID</td><td>Unique client ID in your system</td><td>String</td></tr><tr><td>Hash</td><td>Successful transaction hash</td><td>String</td></tr></tbody></table>

**Signature check:**

1\. A string of the following form must be generated: **"ID":"MerchantID":"Address":"Currency":"Password"** (WebhookURL link password)

Without quotation marks through a colon. **Example:** 12345:Qtfxhgy43:0xa36740e327726fA05F720b10Ec2D71E0CD4Ae2A5:ETH:qwerty

2\. Hash the resulting string using the MD5 algorithm.

3\. Compare the resulting string with the one received in the webhook

```javascript
"Signature":"a5510c8c3e657ffd8229813749cd20ec"
```

4\. If the strings are the same, **return HTTP Status 200** (Required). Our server expects a response to the webhook within a 3-second timeout period. If the response is not received within these 3 seconds, the system considers the delivery failed.

If the webhook is not delivered successfully, the system retries delivery for a total of 31 attempts, with a 15-second interval between attempts. If the webhook still fails to be delivered, the system sends a notification to the Merchant's account email indicating a problem with the WebhookURL.

**Example Webhook JSON:**

```json
                        {
                        "ID":33683,
                        "MerchantID":"0xMR000000",
                        "Date":"2023-03-06T16:37:38.547046Z",
                        "Amount":500.0,
                        "Fee":2.6,
                        "Currency":"ETH",
                        "Address":"0x......",
                        "Status":"Success",
                        "Reason":null,
                        "Signature":"3a16086f49eb11c2e8c426a7b3649caa",
                        "ExternalID":"abcd1234",
                        "ClientID":"abcd1234",
                        "AmountUSD":0.0,
                        "Hash":"a45172f319ec4561871bf195f17f85e69a4bc842b5c1085dbe000098217fffb7"
                        }
```

{% hint style="warning" %}
When processing webhooks, you MUST use the **ID** parameter **from the 0xProcessing webhook** as an additional validation factor.
{% endhint %}
