Webhook
Webhook is a kind of feedback method for payout information.
When payout status changes, a POST request is sent to the url_callback specified when creating the payout.
When payout status changes, a POST request is sent to the url_callback specified when creating the payout.
Response
Response parameters
| Name | Parameter type | Definition |
|---|---|---|
| type | string | Type. Only payout is available |
| uuid | string | uuid of the payout |
| order_id | string|null | Order ID in your system (to identify the payout) |
| amount | string | The amount of the payout |
| merchant_amount | string|null | The amount that is debited from the merchant's balance, including all commissions. |
| commission | string|null | Cryptomus commission amount |
| is_final | boolean | Whether the payment is completedIf the payout is not final and failed, its still possible to resend it through the support.When payout is finalized it's either paid or failed. |
| status | string | Payment status see |
| fail_reason | string|null | 1. aml - Reason for payment rejection: recipient did not pass AML verification.2. system_error - Reason for rejection: server error.3. address_error - Reason for rejection: invalid recipient address. |
| txid | string|null | Transaction hash on the blockchain.The txid field will not exist if1) Payout was paid by p2p to Cryptomus address2) Payout failed. |
| currency | string | Invoice currency |
| network | string|null | The blockchain network in which the payment was made |
| payer_currency | string|null | Cryptocurrency code in which the payout will be actually made. The payout address will receive the payout currency. |
| payer_amount | string|null | Amount in payer_currency of the payout. |
| sign | string | Signature to verify that webhook was from Cryptomus |
Parameter type
stringDefinition
Type. Only payout is availableParameter type
stringDefinition
uuid of the payoutParameter type
string|nullDefinition
Order ID in your system (to identify the payout)Parameter type
stringDefinition
The amount of the payoutParameter type
string|nullDefinition
The amount that is debited from the merchant's balance, including all commissions.Parameter type
string|nullDefinition
Cryptomus commission amountParameter type
booleanDefinition
Whether the payment is completedIf the payout is not final and failed, its still possible to resend it through the support.When payout is finalized it's either paid or failed.Parameter type
stringParameter type
string|nullDefinition
1. aml - Reason for payment rejection: recipient did not pass AML verification.2. system_error - Reason for rejection: server error.3. address_error - Reason for rejection: invalid recipient address.Parameter type
string|nullDefinition
Transaction hash on the blockchain.The txid field will not exist if1) Payout was paid by p2p to Cryptomus address2) Payout failed.Parameter type
stringDefinition
Invoice currencyParameter type
string|nullDefinition
The blockchain network in which the payment was madeParameter type
string|nullDefinition
Cryptocurrency code in which the payout will be actually made. The payout address will receive the payout currency.Parameter type
string|nullDefinition
Amount in payer_currency of the payout.Parameter type
stringDefinition
Signature to verify that webhook was from Cryptomus
Response example
1{
2 "type": "payout",
3 "uuid": "2b852d86-3cf1-43fb-b1bb-36f0b7d12151",
4 "order_id": "129359",
5 "amount": "207.00000000",
6 "merchant_amount": "207.30000000",
7 "commission": "0.30000000",
8 "is_final": true,
9 "status": "fail",
10 "fail_reason": "AML",
11 "txid": null,
12 "currency": "USDT",
13 "network": "bsc",
14 "payer_currency": "USDT",
15 "payer_amount": "207.00000000",
16 "sign": "eff3afba8600af59c98b74155934da2d"
17}Copy