Move trading balances to the Funding account
SubmitPOST /account/transfer/sub-account with a nonzero source, target 0, the destination token address and chain, and an amount in the source balance’s units at 18 decimals. A nonzero token balance for that token is spent first and must cover the entire amount; an insufficient token balance rejects the request. Only a zero token balance selects conversion of the native balance into the named representation. The transfer needs the Low permission level of the account multisig.
An immediate completion returns the committed debit, token credit, conversion and fee. A queued acceptance does not credit the Funding account. Read GET /account/transfer/queue/{user_id} and consume the per-fill SubAccountAssetTransferred events. Each fill reports its actual quantities and cumulative filled/remaining principal. Principal waiting in the Funding transfer queue remains collateral; it is not locked.
Transfers wait for their redemption delay and for representation liquidity. Fillable transfers run FIFO per token. A partial fill must cover at least half of the remaining principal. The margin check runs again at each fill; an unsafe remainder ends without undoing prior fills.
The gross native debit includes the rebalancing fee on each committed fill. At identity rate, a gross debit of 100 with fee 2 credits 98 tokens and charges 2 native units; representation liquidity limits the net token credit. Chain withdrawals have no additional rebalancing fee. Admissions can earn a rebalancing reward when they succeed; a deposit alone does not.
Redemption delay and cancellation
How much you have recently moved out of trading accounts determines the redemption delay, subject to the configured minimum, maximum and tiers. Representation liquidity comes from admitted backing; depositing tokens into the Funding account does not admit them. Cancel an unfilled remainder withPOST /account/transfer/cancel, identifying the user, source trading account, token and nonce. The filled portion stays credited and its fee stays charged. There is no principal refund because unfilled principal was never debited. Queued transfers do not expire.
Chain withdrawal
- Subscribe to
/account/events/{user_id}and wait for a successful subscription acknowledgement. - Submit a signed request at the High permission level to
POST /withdrawal/init, specifying the token, amount at 18 decimals, destination, optional withdrawal nonce and optionalmax_fee. Chain withdrawals are fee-free, so the actual zero fee satisfies any nonnegativemax_fee; the field remains signed. - The clearing engine places a withdrawal lock on the tokens in the Funding account and on the matching tokens in the deposit contract. It does not apply a redemption delay, partial-fill rule, margin check or rebalancing fee to this chain leg.
- Read
GET /withdrawal/status/{user_id}after initialization, after eachWithdrawalSignatureAvailableor acknowledged reconnect, and every few seconds until a row isapprovedwith at least as many signatures as the deposit contract’swithdrawalQuorum(). Retry a status read whose error is markedretryable. Status isawaiting_signatureorapproved. - Once the row holds the withdrawal quorum, submit
withdraw(...)to the deposit contract with those signatures, signed chain amount, withdrawal nonce, expiry and epoch hash. The approval amount is a chain amount, in the token’s own decimals; use it exactly rather than the 18-decimal request amount.