actions.preview
Simulate a list of transactions in sequence against the latest Base block, as if the wallet sent them one after the other, before anything is signed. Each step sees the state the previous ones left (an approval before a mint works). Returns, per step, whether it would succeed, the gas it uses, whether the gas limit it carries is enough, and the decoded revert reason with a hint when it fails; and the net token and ETH movements for the wallet. Pass the steps exactly as prepare_action, invest_usdc_to_gblin or swap_gblin_to_usdc_jit return them. State can change before your transactions land: a successful preview is evidence, not a guarantee.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| from | Yes | The wallet that will send the steps. | |
| steps | Yes | The steps, in order: target, calldata, value in wei (optional), gas (optional). |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| from | No | ||
| note | No | ||
| block | No | The block the simulation ran on. | |
| steps | Yes | Per step: success, gas used, whether the given limit is enough, recommended limit, revert reason. | |
| would_succeed | Yes | True only if every step succeeds in the simulation. | |
| balance_changes | Yes | Net token and ETH movements for the wallet. | |
| first_failing_step | No |