Trading V2 reuses the Sports & Contracts balance and Funding Hub. There are no /api/trading/deposits or /api/trading/withdrawals endpoints, and API credentials cannot withdraw. Split moves USDC into market backing and creates equal UP and DOWN; merge reverses complete sets.
Clients use the Funding API for deposits and status reads. The external funding wallet authorizes onboarding and sensitive actions; Reso separately manages the Trading Account owner and deposit wallet. Withdrawals require a WITHDRAW challenge signed by the bound funding wallet, always pay that wallet, and are executed by platform Provider/vault executors. Callers cannot supply Provider authorization or withdrawal wallet calls.
Choose the funding domain
Deposit
Code example
# 1. Select an enabled asset whose targetAccounts allows your target.GET /api/funding/assets# 2. Choose the product funding domain, then sign the exact JSON bytes with Reso L2 HMAC.# Sports and BTC 3m: targetAccount=adi_vault (ADI Mainnet USDC).# Crypto: targetAccount=polymarket_collateral (Polygon pUSD).POST /api/funding/intentsIdempotency-Key: deposit-0001{"flow":"deposit","targetAccount":"adi_vault","gasReady":true,"quote":{ "fromAmountBaseUnit":"10000000","fromChainId":"137", "fromTokenAddress":"0x3c499c542cef5e3811e1192ce70d8cc03d5c3359"}}# Response amountUsdc is gross, feeUsdc is the fixed fee, and netAmountUsdc# is the credited amount. Use the returned depositAddress and statusAddress.# {"intent":{"intentId":"...","amountUsdc":10,"feeUsdc":1,"netAmountUsdc":9,# "depositAddress":{"evm":"0x..."},"statusAddress":"0x..."},"replayed":false}# 3. Crypto only: wait for polymarketFunderWallet, register the CLOB Credential,# and approve pUSD spenders from that wallet through the official relayer WALLET flow.# 4. Transfer the selected token to intent.depositAddress only from an allowedSenderWallet.# If wallet preparation returns 409, retry these exact bytes with the same key.# Poll the returned statusAddress every 10-30 seconds until DONE or FAILED.GET /api/funding/status?address=<statusAddress>
Crypto redeem
Code example
# Resolved Crypto positions cannot be sold on the CLOB. Sign this body with Reso L2:POST /api/funding/redeem{"providerId":"polymarket","marketId":"<public market id>","side":"YES"}# If execution.calls is non-empty, submit it as one official relayer WALLET batch:const redeemed = await relayer.executeDepositWalletBatch( response.execution.calls, response.execution.sourceWallet, String(Math.floor(Date.now() / 1000) + 600)).then((pending) => pending.wait());if (!redeemed?.transactionHash) throw new Error("redeem was not confirmed");# Then refresh /api/portfolio until redeemable is false and pUSD is available.
Withdrawal
Code example
# 1. Read the managed owner, then issue WITHDRAW. Reso fixes destinationWallet to the bound funding wallet.POST /api/trading/auth/challenges{"fundingWallet":"0x...","action":"WITHDRAW","resource":{ "ownerWallet":"0x<managed-owner>","targetAccount":"adi_vault","amountBaseUnit":"2000000", "fromChainId":"36900","fromTokenAddress":"0x9cb8142aebbcdc60af7c97af897a67a8f3ca71c2", "toChainId":"137","toTokenAddress":"0x3c499c542cef5e3811e1192ce70d8cc03d5c3359", "destinationWallet":"0x<bound-funding-wallet>","idempotencyKey":"withdraw-0001"}}# 2. Sign only the Reso challenge with the bound funding wallet.const resoSignature = await ownerAccount.signTypedData(challenge.typedData);# 3. No L2 headers. Reso executes Provider/vault actions after risk and ledger checks.POST /api/funding/intentsIdempotency-Key: withdraw-0001{"fundingWallet":"0x...","challengeId":"0x...","signature":"<resoSignature>", "flow":"withdraw","targetAccount":"adi_vault","gasReady":true, "quote":{"fromAmountBaseUnit":"2000000","fromChainId":"36900","fromTokenAddress":"0x9cb8142aebbcdc60af7c97af897a67a8f3ca71c2", "toChainId":"137","toTokenAddress":"0x3c499c542cef5e3811e1192ce70d8cc03d5c3359"}}# Crypto uses targetAccount=polymarket_collateral and Polygon pUSD as the source.# For both domains, poll statusAddress until DONE or FAILED; callers receive no Provider wallet calls.GET /api/funding/status?address=<statusAddress>
Withdrawal authorization and Crypto confirmation errors
Funding status