Blockchain Operations
Swap Tokens
Execute token swaps via CowSwap or 1inch from a Safe wallet.
Swap tokens from a Safe wallet using decentralized exchange aggregators (CowSwap, 1inch).
Uses the two-step POST /v1.2/safes/operations → PUT /v1.2/safes/operations flow.
Operation Schema
| Field | Type | Required | Description |
|---|---|---|---|
type | string | Yes | Must be "SWAP_FROM_QUOTE" |
quoteId | string | Yes | Quote ID obtained from GET /v1.2/safes/quote |
slippage | number | No | Slippage tolerance in percent (default: 0.5) |
Flow
- Get a quote —
GET /v1.2/safes/quote?from=0x...&to=0x...&amount=1.0 - Execute the swap — Use the
quoteIdfrom the quote response in aSWAP_FROM_QUOTEoperation