get_fee_estimate
Estimate the total fee in mojos required for a Chia transaction to be included within specified target times, using transaction cost or a spend bundle.
Instructions
Estimate the fee required for a transaction to be included within target times. Provide target times in seconds (e.g., [60, 300, 600] for 1min, 5min, 10min). Returns the total estimated fee in mojos for the given cost at each target time. current_fee_rate is mojos per CLVM cost unit. If neither cost nor spend_bundle is provided, cost defaults to 5,000,000 (the node's default sample bucket). A standard two-input two-output XCH send costs approximately 17,000,000 CLVM cost units (this is the standalone single-bundle cost; in-block cost is lower due to generator compression, but fee estimation uses the standalone figure); use that for realistic fee estimation.
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": {
"target_times": "<target_times>"
},
"name": "get_fee_estimate"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| cost | No | Optional transaction cost in CLVM cost units (alternative to providing spend_bundle). Defaults to 5,000,000 (fee-estimation sample bucket) if neither cost nor spend_bundle is provided. | |
| spend_bundle | No | Optional spend bundle to estimate fees for (provides accurate cost calculation) | |
| target_times | Yes | Array of target times in seconds (e.g., [60, 300, 600]) |