TheDocumentation Index
Fetch the complete documentation index at: https://mintlify.com/BlockRazorinc/docs_en/llms.txt
Use this file to discover all available pages before exploring further.
eth_callBundle method simulates the execution of a bundle against a specified BSC chain state without submitting any transactions on-chain. This gives you a gas-free, risk-free way to verify that your bundle will execute as intended before committing to eth_sendBundle. The response provides per-transaction results including gas consumed, return values, and revert reasons, enabling your system to catch errors and optimize gas parameters before they cost real funds.
Bundle simulation via
eth_callBundle is available to registered users on BSC. See Pricing for subscription tier details.Endpoint
Authorization header.
Request
The request follows the standard JSON-RPC 2.0 envelope. The single element ofparams is a simulation configuration object.
Simulation Parameters
An ordered array of signed raw transactions encoded as hex strings (each prefixed with
0x). The transactions are simulated in the order provided against the specified chain state, mirroring how they would execute if submitted as a live bundle.The block number against which the bundle is simulated, expressed as a hex string (e.g.,
"0xE4E1C0"). This controls which block context (base fee, block hash, coinbase) the simulation uses.The block number or the string
"latest" that determines which world state snapshot is used during simulation. Use "latest" to simulate against the current chain tip, or specify a historical block number to replay against past state.Optional. A Unix timestamp override (in seconds) to use as the simulated block’s timestamp. Useful for testing time-dependent logic such as TWAP calculations or time-locked contracts.
Code Examples
Response
The response contains the bundle hash and an array of per-transaction simulation results. Each entry inresults corresponds to a transaction in the input txs array, in the same order.
A hash derived from the simulated bundle. This value matches the hash that would be returned by
eth_sendBundle if you submit the same bundle, allowing you to correlate simulation results with live submissions.An array of simulation result objects, one per transaction in the input
txs array.Response Example
Interpreting Simulation Results
Each entry inresults maps directly to the corresponding transaction in your txs input. A missing error field indicates the transaction succeeded. An error field with a revert message indicates the transaction would revert under the simulated conditions.
Simulation results reflect the state at
stateBlockNumber, not necessarily the state at the block when you submit a live bundle. Chain state may change between simulation and actual block building, particularly for DeFi positions sensitive to price movements. Re-simulate close to the time of submission for the most accurate results.