Callback Integration

The essential information to implement a callback handler.

How to distinguish between deposit and withdrawal callbacks?

  • Deposit Callback (callback type 1)

    • The combination of txid and vout_index of the callback is unique, use this combined ID to identify the deposit request, not to use only the transaction ID (txid field). Because multiple deposit callbacks may have the same transaction ID, for example, BTC many-to-many transactions.
  • Withdrawal Callback (callback type 2)

    • The order_id of the callback is unique, use this ID to identify the withdrawal request.

To ensure that the callbacks have processed by callback handler, the CYBAVO SOFA system will continue to send the callbacks to the callback URL until a callback confirmation (HTTP/1.1 200 OK) is received or exceeds the number of retries (retry time interval: 1-3-5-15-45 mins).

  • If all attempts fail, the callback will be set to a failed state, for deposit callbacks the callback handler can call the resend API to request CYBAVO SOFA system to resend such kind of callback(s) or through the web control panel. For withdrawal callbacks, the resend operation must be completed on the web control panel.

Refer to Callback Definition for detailed definition.

Please refer to the code snippet on the github project to know how to validate the callback payload.