Write a sell for my wallet to sign
prepare_sellWrites a sell as unsigned transactions for your own wallet to sign. The nest holds no keys and sends nothing. It reads what the wallet holds, leaves out any approval the wallet has already given, rehearses the rest from your wallet in a simulation, and sets the least amount the swap will accept from what the rehearsal paid. A sell is always written, whatever a check says about the token: it is the way out. Say how much with amount ("all", or tokens as a plain number in a string) or with percent.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| from | Yes | The wallet that holds it and will sign. | |
| token | Yes | The token to sell. | |
| amount | No | "all", or how many tokens, as a plain number in a string. | |
| percent | No | Instead of amount: this share of what the wallet holds. | |
| slippageBps | No | How far below the rehearsed amount the swap may fill before it reverts. 100, one percent, when left out. |