factor_swap_uniswap_exact_output
Swap tokens through Uniswap V3 via a Factor vault to receive an exact output amount. Set amountInMax to cap input spending or use "all" to spend the vault's full tokenIn balance.
Instructions
Swap tokens through Uniswap V3 via a Factor vault, specifying the exact output amount desired. Use amountInMax to set the maximum input you are willing to spend, or use "all" to allow spending the entire vault balance of tokenIn. Fee tiers: 100 (0.01%), 500 (0.05%), 3000 (0.3%), 10000 (1%).
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": {
"vaultAddress": "<vaultAddress>",
"tokenIn": "<tokenIn>",
"tokenOut": "<tokenOut>",
"amountOut": "<amountOut>"
},
"name": "factor_swap_uniswap_exact_output"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| fee | No | Uniswap V3 fee tier: 100 (0.01%), 500 (0.05%), 3000 (0.3%), 10000 (1%). Default: 3000 | |
| tokenIn | Yes | Address of the input token to swap from | |
| password | No | Wallet password if encrypted | |
| tokenOut | Yes | Address of the output token to receive | |
| amountOut | Yes | Exact amount of output token desired in base units (wei) | |
| amountInMax | No | Maximum amount of input token to spend in base units (wei), or "all" to use entire vault balance as maximum. If not provided when not using "all", defaults to "all". | |
| vaultAddress | Yes | The vault contract address |