Simulate
Pre-execution simulation of a transaction, predicting its execution cost and resource usage without committing any changes.
This method typically returns information like estimated gas fees or other transaction-related metrics to anticipate the impact of operations before they are executed on the blockchain.
Method Declaration
Python
async def simulate(self, transaction: Tx)Unification Plan
- Some extra parameters in TypeScript? What to do with them?
Parameters
| Parameter | Location | Type | Required | Description |
|---|---|---|---|---|
transaction | query | Tx | true | The transaction to simulate. |
Response
| Status | Meaning | Schema | |
|---|---|---|---|
200 | OK | GasInfo | |
400 | Bad Request | The request was malformed or invalid. |
Examples: Python | TypeScript | Rust