Get WPAXG swap quote
Returns swap calldata for buying or selling WPAXG via DEX aggregators. Supports Optimism (chainId 10). The response includes the target contract, encoded calldata, and expected output amount.
Authorizations
API key in format: pxl_<public_id>_
Query Parameters
EVM chain ID. Supported: 10 (Optimism).
10 10
Token address to offer (sell).
"0x5cb5c4d5e8b184a364534bc688da0553ccf8f484"
Token address to receive (buy).
"0x0b2C639c533813f4Aa9D7837CAf62653d097Ff85"
Amount to offer, in the smallest unit of the token.
"1000000000000000000"
Wallet address executing the swap.
"0x1234567890abcdef1234567890abcdef12345678"
Authorization method. allowance_holder (recommended): standard approve flow. permit2: requires signing EIP-712 typed data.
allowance_holder, permit2 "allowance_holder"
Response
Expected output amount in buy token wei.
"2500000000"
Minimum acceptable output amount accounting for slippage. Use this to verify swap execution.
"2475000000"
Contract address to approve tokens to before swapping. AllowanceHolder for default auth, Permit2 for permit2 auth.
"0x0000000000001fF3684f28c67538d4D072C22734"
User's current allowance for the allowanceTarget contract. If less than sellAmount, approval is needed.
"0"
Present when authMethod=permit2. Contains EIP-712 typed data to sign before executing the swap.