ThisDocumentation Index
Fetch the complete documentation index at: https://docs.openxswitch.com/llms.txt
Use this file to discover all available pages before exploring further.
Wallet-as-a-Service webhook is fired when an instant swap has been create and completed successfully.
- Parent Method:
instant_swap - Sub-Methods:
completed: Triggered when the internal transfer is successfully processed.
Example Payload for Instant Swap:
instant-swap.completed
Reference
| Field | Description | Type |
|---|---|---|
requestId | Unique identifier for the webhook event | string |
method | Name of the webhook method | string |
params.fee | Swap fee charged for the transaction | number |
params.fromCoin | The coin swapped from (input coin) | string |
params.fromAmount | The amount of fromCoin used in the swap | number |
params.toCoin | The coin swapped to (output coin) | string |
params.toAmount | The amount of toCoin received from the swap | number |
params.swapPrice | Effective price of the swap (toAmount / fromAmount) | number |
params.ts | Timestamp of the swap event (likely in milliseconds since epoch) | string (or number) |
params.quoteId | Unique identifier for the swap quote used | string |
params.walletId | ID of the wallet involved in the transaction | string |
params.workspaceId | ID of the associated workspace or organization | string |
params.createdAt | Timestamp when the transfer was created | string (ISO datetime) |
params.wallet.id | Wallet ID (redundant with walletId, likely the master wallet ID) | string |
params.wallet.clientUserId | Optional external user identifier for the wallet | string or null |
params.wallet.email | Email address associated with the wallet | string |
params.wallet.name | Display name of the wallet | string |
params.wallet.assets | List of assets and their balances after the swap | array of objects |
params.wallet.assets[].coin | Coin symbol (e.g., USDT, TRX) | string |
params.wallet.assets[].balance | Balance of the coin after the swap | number |
params.wallet.assets[].frozen | Frozen amount of the coin (if any) | number |
params.wallet.assets[].updatedAt | Last update time of the asset balance | string (ISO datetime) |
params.wallet.isSubWallet | Whether the wallet is a subwallet | boolean |
.png?fit=max&auto=format&n=ML35RDblT1Ol-zJb&q=85&s=062e79ad9c4540929eec204aff020178)
.png?fit=max&auto=format&n=ML35RDblT1Ol-zJb&q=85&s=f6328956931c9664a2a070c2edb6e9b3)