Start Swap
start_swapStart a cross-chain swap. Returns the deposit address where you should send your source asset. API key is optional.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"sourceAsset": "<sourceAsset>",
"destinationAsset": "<destinationAsset>",
"destinationAddress": "<destinationAddress>",
"refundAddress": "<refundAddress>"
},
"name": "start_swap"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| apiKey | No | Optional partner API key. | |
| sourceAsset | Yes | Source asset identifier (e.g., 'btc.btc', 'eth.eth', 'usdc.eth') | |
| minimumPrice | No | Optional minimum accepted price as a destination-per-source ratio (e.g., for a btc.btc to eth.eth swap, 28.5 means 1 BTC gets at least 28.5 ETH). When omitted, automatically calculated from current pool prices with 2% slippage tolerance. Set to 0 to accept any price. | |
| refundAddress | Yes | Refund address on the source chain, used if minimum price cannot be met | |
| destinationAsset | Yes | Destination asset identifier (e.g., 'eth.eth', 'btc.btc', 'sol.sol') | |
| destinationAddress | Yes | Destination address on the target chain | |
| livePriceSlippageTolerancePercent | No | Optional live price protection: how far, in percent (0 to 100, at most 2 decimals, e.g. 0.5), the execution price may fall below Chainflip's oracle price before the swap is retried and then refunded. Use a quote's recommendedLivePriceSlippageTolerancePercent. When either asset has no oracle price on Chainflip, live price protection is omitted and the swap proceeds without it. When omitted, Chainflip's default protection for the pair applies. |