Creating a Withdrawal Transaction Request

Create a transaction to withdrawal crypto from your asset pool and send it to an external wallet.

This guide outlines the process for integrating withdrawals into your platform. It provides a detailed walkthrough of the withdrawal process, including how it interacts with the respective blockchain, which endpoint is used to create the payout, the data that needs to be sent to the endpoint, and what that data represents. Additionally, it covers the webhooks sent out during the withdrawal process.

Before proceeding with the withdrawal integration, ensure that you have completed the following steps:

  • Set up a webhook destination: Set up the webhooks destination as described in Set Up a Webhook Destination, with special focus on the layer1:crypto:withdrawal:status-change and layer1:digital:balance:updated webhooks.
  • Created an Asset Pool: If you have not created one yet, you can go back to create one from the previous step Create an Asset Pool.
  • Have Funds Available: Ensure that funds are available in the asset pool to withdraw. This can be done using the deposit process detailed earlier in the guides, as shown in Create a new address and Receive Deposit and Ingest the Webhooks.

This guide will then delve into:

  • Understanding the Withdrawal Flow: Before creating the transaction, it is best to first understand the withdrawal flow to see how this transaction will interact with the blockchain.
  • Creating a Withdrawal Transaction: Use the Create transaction request endpoint to create a withdrawal transaction. The outbound wallet address will be sent in the request.
  • Ingest and Deserialize Webhooks: Ingest and deserialize the resulting webhooks to keep track of your pool funds and the status of the withdrawal.

To sumamrize, this withdrawal process involves taking crypto from the master wallet on the asset pool. By following these steps, you will be able to integrate the withdrawal functionality into your platform efficiently. Ensure that you understand each part of the process to handle the transactions and webhooks correctly.