Webhooks

Webhooks Events

Webhooks Settings

After webhook token generation you will be able to configure trigger events depending on their type.

General Webhook Settings

Webhooks Settings

Withdrawals

  • Withdrawal is completed - withdrawal transaction was successful and its status was changed to COMPLETE. ("event_type": "withdrawal::completed")

  • Withdrawal is declined - withdrawal transaction was declined for any reason and its status was changed to CANCELLED or DECLINED. ("event_type": "withdrawal::declined")

Other

  • Rollback to account - overpayment amount was transferred to the account. ("event_type": "rollback::to_merchant")
  • Rollback to client - overpayment amount was transferred to the client. ("event_type": "rollback::to_client")

Events

Withdrawal Complete/Declined

Event will be triggered when Withdrawal status changes to COMPLETE or CANCELLED.

Request Body

{
  "transaction": {
    "id": "11ee8f2c-ffa1-4785-a14e-707dc011f959",
    "order_id": null,
    "external_order_id": null,
    "stock_orders": [],
    "currency": "USDT",
    "value": "11.2",
    "is_internal": true,
    "type": "WITHDRAWAL",
    "status": "COMPLETE",
    "hash": "internal_transaction_c69b0b13-118a-4b45-9160-19ab9ffb6539",
    "created_at": "2024-07-26 14:36:19",
    "completed_at": "2024-07-26 15:00:06",
    "external_id": "12345rtg234",
    "comment": "lorem ipsum"
  },
  "event_type": "withdrawal::completed"
}

Rollback to client/account

Event will be triggered when overpaid invoice amount is transferred to merchant or client.

Request Body

{
  "transaction": {
    "id": "167785a3-7461-47d5-8a08-05c3e71f657a",
    "order_id": "20afc64b-492f-4a73-a9d5-73373f8c0f2f",
    "external_order_id": null,
    "stock_orders": [],
    "currency": "USDT",
    "value": "16",
    "is_internal": true,
    "type": "ROLLBACK_TO_CLIENT",
    "status": "COMPLETE",
    "hash": "internal_transaction_21b35af1-4550-498d-bd92-26bca62e976a",
    "created_at": "2024-08-08 11:10:39",
    "completed_at": "2024-08-08 11:30:06"
  },
  "event_type": "rollback::to_merchant/rollback::to_client"
}

Payment page webhook settings

Payment page webhook settings

Invoices

  • Invoice is completed - full amount on specified invoice was received and order status was changed to COMPLETE. ("event_type": "order::completed")
  • Invoice is declined - invoice wasn’t completed in time and its status was changed to DECLINED. ("event_type": "order::declined")
  • Invoice is partially paid - invoice was partially paid and the order changed its status to PARTIALLY_FULFILLED. ("event_type": "order::partially_fulfilled")
  • Final amount was received - invoice was completed and all exchange operations minus fees have been finished. ("event_type": "order::final_amount_was_received")

Transactions

  • Transaction is completed - deposit transaction was received and its status was changed to COMPLETE. ("event_type": "transaction::completed")
  • Transaction is declined - deposit transactions was cancelled for any reason and its status was changed to DECLINED. ("event_type": "transaction::declined")
  • Transaction exchange is completed - amount received via transaction was successfully exchanged. ("event_type": "transaction::was_final_exchange")

Events

Invoice Status Changed

Event will be triggered when Invoice Status changed.

Request Body

{
  "order": {
    "id": "20e0ae15-a66f-48a9-8395-0ac6cfeb171a",
    "currency": "USDT",
    "order_number": "947861844",
    "value": "19.9",
    "expected_amount": "0.0075",
    "received_total": "0",
    "is_internal": true,
    "exchange_rate": "2653.33333333333333333333",
    "clean_exchange_rate": "2669.91",
    "deposited_currency": "ETH",
    "received_currency": "USDT",
    "status": "COMPLETE",
    "external_order_id": null,
    "created_at": "2024-08-23 10:37:23",
    "completed_at": "2024-08-23 10:38:15",
    "acquiring_url": "https://merchant.pay.whitepay.com/crypto-orders/20e0ae15-a66f-48a9-8395-0ac6cfeb171a"
  },
  "event_type": "order::completed"
}

Invoice final amount was received

Event will be triggered when invoice final amount was received.

Request Body

{
  "order": {
    "id": "20e0ae15-a66f-48a9-8395-0ac6cfeb171a",
    "currency": "USDT",
    "order_number": "947861844",
    "value": "19.9",
    "expected_amount": "0.0075",
    "received_total": "19.7",
    "is_internal": true,
    "exchange_rate": "2653.33333333333333333333",
    "clean_exchange_rate": "2669.91",
    "deposited_currency": "ETH",
    "received_currency": "USDT",
    "status": "COMPLETE",
    "external_order_id": null,
    "created_at": "2024-08-23 10:37:23",
    "completed_at": "2024-08-23 10:38:15",
    "acquiring_url": "https://merchant.pay.whitepay.com/crypto-orders/20e0ae15-a66f-48a9-8395-0ac6cfeb171a"
  },
  "event_type": "order::final_amount_was_received"
}

Transaction Status Changed

Event will be triggered when Transaction Status changed.

Request Body

{
  "transaction": {
    "id": "d6e08d0d-7c11-4212-bb2d-f555f47f0b1a",
    "order_id": "20e0ae15-a66f-48a9-8395-0ac6cfeb171a",
    "external_order_id": null,
    "stock_orders": [],
    "currency": "ETH",
    "value": "0.0075",
    "is_internal": true,
    "type": "DEPOSIT",
    "status": "COMPLETE",
    "hash": "WB_PAY_27aa7c61-439c-4bad-8b33-10fd0693dfda",
    "created_at": "2024-08-23 10:38:15",
    "completed_at": "2024-08-23 10:38:15"
  },
  "event_type": "transaction::completed"
}

Transaction final amount was received

Event will be triggered when final exchange of transaction amount was completed.

Request Body

{
  "transaction": {
    "id": "e2628ab6-30ed-47d5-bd6c-c600e010252a",
    "order_id": "015262e4-ac53-449c-a2de-604fdaf129ea",
    "external_order_id": null,
    "stock_orders": [
      {
        "id": "8e9faa04-855c-4c2b-950a-1c4ad0462f9a",
        "amount": "0.0065",
        "result_amount": "17.31630708",
        "status": "CLOSED",
        "pair": "ETH_USDT",
        "currency_from_ticker": "ETH",
        "currency_to_ticker": "USDT",
        "date": "2024-08-23",
        "time": "10:41:22",
        "exchange_rate": "2664.04724307",
        "created_at": "2024-08-23 10:41:22"
      }
    ],
    "currency": "ETH",
    "value": "0.0065",
    "is_internal": true,
    "type": "DEPOSIT",
    "status": "COMPLETE",
    "hash": "WB_PAY_8a140dc0-29bc-46a4-86fa-69279f9a23fa",
    "created_at": "2024-08-23 10:41:19",
    "completed_at": "2024-08-23 10:41:19",
    "fee_amount": "0.17",
    "fee_currency": "USDT",
    "external_currencies": [
      {
        "currency": "USD",
        "amount": "17.14"
      },
      {
        "currency": "EUR",
        "amount": "15.41"
      },
      {
        "currency": "NGN",
        "amount": "27031.85"
      }
    ],
    "received_total": "17.1431440092",
    "received_currency": "USDT",
    "transaction_received_total": "17.143"
  },
  "event_type": "transaction::was_final_exchange"
}
Previous
Authorization