hookr_prepare_swap
Build ONE unsigned swap call through Hookr's router for your own wallet to sign and send. Checks the wallet's balance and simulates it first. Amount and slippage are capped; risky trades are refused, not overridden. Nothing is signed or sent here.
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": {
"poolId": "<poolId>",
"side": "<side>",
"amount": "<amount>",
"wallet": "<wallet>"
},
"name": "hookr_prepare_swap"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| side | Yes | ||
| amount | Yes | ||
| poolId | Yes | ||
| wallet | Yes | 0x wallet address | |
| recipient | No | 0x wallet address | |
| slippageBps | No |