> For the complete documentation index, see [llms.txt](https://docs.shredpay.xyz/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.shredpay.xyz/developers/agent-wallet/guides/swap.md).

# Swap Tokens

Outline:

* Quote first with `POST /api/swap/quote` — slippage, fee preview, expected out.
* Execute with `POST /api/swap/execute` — runs through Router, ShredPay sponsors gas.
* Worked example: 100 USDC → ETH on Base.
* Handling slippage failures and re-quoting.
* Why this is Base-only today (Router availability).

See [Gas Model](/developers/agent-wallet/concepts/gas-model.md) for the sponsorship rules.
