Create exchange
Create a new exchange (swap). Use type: "private" or type: "standard" for centralized exchanges or type: "dex" for decentralized exchanges.
Authorizations
Body
Request body for creating a new exchange
Destination wallet address where funds will be sent
1 - 200Quote ID from a prior quote response. Amount, from token, to token, and swap provider are retrieved from the provided quote. For CEX exchanges, if the exchange fails with the chosen swap provider, it will fallback to the next best route.
Source wallet address (required for DEX, ignored for CEX)
Sender's wallet address for refunds if a fixed-rate swap fails. Required when the quote was created with fixed: true.
200EIP-712 signatures for permit-based approvals (DEX only)
Destination tag / memo (e.g. for XRP, XLM)
64Wallet info string
256Response
Exchange created
From T, pick a set of properties whose keys are in the union K
The CEX deposit address where the user must send funds
- -2 Order is being initialized (label: INITIALIZING)
- -1 Order initialized (label: NEW)
- 0 Waiting for deposit confirmation (label: WAITING)
- 1 Deposit is being confirmed (label: CONFIRMING)
- 2 Exchange is in progress (label: EXCHANGING)
- 3 Order is going through anonymization (label: ANONYMIZING)
- 4 Order completed successfully (label: FINISHED)
- 5 Order has expired (label: EXPIRED)
- 6 Order failed (label: FAILED)
- 7 Order was refunded (label: REFUNDED)
- 8 Order was deleted (label: DELETED)
-2, -1, 0, 1, 2, 3, 4, 5, 6, 7, 8 ETA time, depending on swap
USD value of the input amount at order creation time.
- 0 New swap
- 1 Waiting for confirmation
- 2 Being confirmed
- 3 Exchange in progress
- 4 Sending to destination
- 5 Swap completed
- 6 Swap failed
- 7 Swap refunded
- 8 Verifying swap
- 9 Swap expired
- 10 Fallback mode
0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10 - 0 New swap
- 1 Waiting for confirmation
- 2 Being confirmed
- 3 Exchange in progress
- 4 Sending to destination
- 5 Swap completed
- 6 Swap failed
- 7 Swap refunded
- 8 Verifying swap
- 9 Swap expired
- 10 Fallback mode
0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10 WAITING_FOR_DEPOSIT, DEPOSIT_DETECTED, EXCHANGE_IN_PROGRESS, SENDING_TO_INTERMEDIARY, REACHED_INTERMEDIARY, INITIATING_SECOND_EXCHANGE, SECOND_EXCHANGE_IN_PROGRESS, SENDING_TO_RECEIVER, SWAP_COMPLETED, EXPIRED, FAILED, REFUNDED, DELETED Memo/tag required when depositing funds for assets that use one