Bundle simulation with Jito
Triton offers support for Jito RPC on dedicated nodes. This primarily gives access to the improved simulation support that Jito offers and allows you to simulate bundles of transactions.
🔧 Note: Triton One provides the Jito-enabled RPC node only. It is the customer's responsibility to have their IP whitelisted with Jito’s Block Engine in order to use certain features.
The sendBundle
method is a Jito-exclusive RPC call and requires an active connection to the Jito Block Engine.
Resources
simulateBundle
POST
https://xyz.mainnet.rpcpool.com/
Simulates a transaction bundle.
Request Body
transactions*
Vector
List of transactions to simulate.
config
Object
(optional) Object of type RpcSimulateBundleConfig, provide configuration for the transaction simulation. See description of this parameter below.
Returns a JSON RPC response corresponding to the following Rust struct:
pub struct RpcSimulateBundleResult {
pub summary: RpcBundleSimulationSummary,
pub transaction_results: Vec<RpcSimulateBundleTransactionResult>,
}
pub enum RpcBundleSimulationSummary {
/// error and offending transaction signature if applicable
Failed {
error: RpcBundleExecutionError,
tx_signature: Option<String>,
},
Succeeded,
}
pub enum RpcBundleExecutionError {
#[error("The bank has hit the max allotted time for processing transactions")]
BankProcessingTimeLimitReached,
#[error("Error locking bundle because a transaction is malformed")]
BundleLockError,
#[error("Bundle execution timed out")]
BundleExecutionTimeout,
#[error("The bundle exceeds the cost model")]
ExceedsCostModel,
#[error("Invalid pre or post accounts")]
InvalidPreOrPostAccounts,
#[error("PoH record error: {0}")]
PohRecordError(String),
#[error("Tip payment error: {0}")]
TipError(String),
#[error("A transaction in the bundle failed to execute: [signature={0}, error={1}]")]
TransactionFailure(Signature, String),
}
pub struct RpcSimulateBundleTransactionResult {
pub err: Option<TransactionError>,
pub logs: Option<Vec<String>>,
pub pre_execution_accounts: Option<Vec<UiAccount>>,
pub post_execution_accounts: Option<Vec<UiAccount>>,
pub units_consumed: Option<u64>,
pub return_data: Option<UiTransactionReturnData>,
}
Last updated
Was this helpful?