Owner tx: withdraw idle funds
prepare_withdrawReturns an UNSIGNED transaction {chainId, to, data, value} plus simulation — an eth_call of exactly it from from (ok, or the revert decoded by name) — warnings and next. This server signs nothing: the sender signs and sends it with their own wallet and pays the gas. Owner only. Moves idle balance (not in a position) out of the manager to recipient, one row per token, through the owner escape hatch executeEncodedTxBatch. Liquidity inside positions is withdrawn in the app's Withdraw page, which plans it against live prices.
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": {
"chainId": "<chainId>",
"manager": "<manager>",
"recipient": "<recipient>",
"items": "<items>",
"from": "<from>"
},
"name": "prepare_withdraw"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| from | Yes | The address that will send the transaction — the manager owner (ownerOf(1)). The simulation runs from it. | |
| items | Yes | Idle balances to take out, one row per token | |
| chainId | Yes | EVM chain id: 8453 Base, 42161 Arbitrum, 130 Unichain (1 = Ethereum mainnet, your gas) | |
| manager | Yes | Manager NFT contract address | |
| recipient | Yes | Where the funds go |