Callback
The webhook notification is sent only when the deposit has been successfully completed. You need to:
receive the notification;
check the signature;
check the amount — it can be changed if the user has paid another amount;
send funds to the user’s balance if the verification is successful.
We consider the notification delivered if your server has answered with status
200
andOK
message.It is important to consider the possibility of follow-up notifications and changes in the amount in disputes.
The webhook sends a POST request to the URL specified in the cashier settings if webhook_url
has not been provided. If webhook_url
has been provided when creating a deposit, the request should be sent to the URL from the passed parameter.
Response
Example of a successful response
{
"deal_id": "7a2ab81c-b041-4638-be6e-437049e7a8eb",
"state": "completed",
"amount": "300",
"currency": "RUB",
"amount_usdt_income": "28.1",
"signature": "md5 signature",
"order_id": "string"
}
deal_id
string
Unique transaction identifier
state
string
Current status of transaction
amount
string (number)
Amount of transaction in fiat currency
currency
string
Fiat currency of transaction. Only currency supported by your cashier can be used
RUB
amount_usdt_income
string (number)
Received amount of transaction in USDT (cryptocurrency)
signature
string
Signature for the verification of the request authenticity (formed using a secret word)
order_id
string
ID you provided when creating a transaction
Signature verification
To authenticate the notification, you must generate an MD5 signature using the following line:
md5(deal_id:amount:secret_word_2)
Compare with the signature received in the notification. If the signatures match, the notification is authentic and you can send funds to user's balance.
Last updated