Base transaction preflight (paid, $0.005)
gas_preflightPAID $0.005: simulate an unsigned Base transaction with optional msg.sender. Returns success or a decoded revert, gas estimate and an indicative USDC sponsorship estimate. No signing or broadcast; provider failures are not charged.
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": {
"to": "<to>"
},
"name": "gas_preflight"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| to | Yes | Contract or wallet to call | |
| data | No | 0x calldata, up to 16 KiB | |
| from | No | Optional msg.sender | |
| value | No | Native value in wei |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| _paid | No | x402 receipt | |
| error | No | Revert details, when reverted | |
| chainId | No | Base chain ID | |
| success | No | Whether the call succeeded | |
| returnData | No | Return data | |
| blockNumber | No | Simulation block | |
| gasEstimate | No | Estimated gas | |
| sponsorshipEstimate | No | Indicative USDC gas estimate |