Wallet Infrastructure
Wallet Infrastructure
Swaps & Transfers

Swaps

Swap between USD₮ and gold (XAUT).

What you can swap

USD₮ and XAUT, in either direction, within the same EVM wallet. Swaps run on Ethereum; other networks are refused with chain_unavailable.

Flow

  1. Quote swap for the price and gas.
  2. Get max swap amount for the most the wallet can swap after gas. belowMinimum: true means the balance is too low to swap.
  3. Prepare swap. It returns a userOpHash.
  4. Have the customer sign the userOpHash with their passkey.
  5. Submit swap with the signature.

Fees

The customer pays gas, in the token being sold.

Retries

A swap is never retried automatically. If the response has no transactionHash, pendingUserOp: true means the outcome is still being resolved; read it from List transactions.

Errors

CodeStatusCause
chain_unavailable400, 409A network other than Ethereum (400), or the wallet is not yet deployed on it (409).
validation_failed400Malformed body, or an amount below the minimum.
forbidden409The wallet is under recovery, so swaps are blocked.
passkey_credential_invalid409The passkey does not own this wallet.
upstream_unavailable502No swap route could be found or reached; retry.

On this page