API ReferenceGuidesChangelog
Solidity

Run simulation

Create a new transaction simulation. The simulation body should be included in the request body. Your simulations will be saved, and a unique ID for each simulation is included in the response. It will be useful for fetching simulation details.

POST
/v1/solidity/{owner}/{slug}/{chainId}/simulation

Authorization

api-key<token>

In: header

Path Parameters

owner*string
slug*string
chainId*string

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Response Body

application/json

curl -X POST "https://example.com/v1/solidity/string/string/string/simulation" \  -H "Content-Type: application/json" \  -d '{    "simulation": {      "blockNumber": "17415072",      "blockOverride": {        "baseFee": "0x0"      },      "from": "0x5e8bb488e85ea732e17150862b1acfc213a7c13d",      "gas": "0x31ae2",      "gasPrice": "0xe59a1adbe",      "input": "0x3593564c000000000000000000000000000000000000000000000000000000000000006000000000000000000000000000000000000000000000000000000000000000a000000000000000000000000000000000000000000000000000000000647dffef0000000000000000000000000000000000000000000000000000000000000002080c000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000200000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000160000000000000000000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000000020000000000000000000000000000000000000003077b58d5d378391980000000000000000000000000000000000000000000000000000000032b2ced3e40e9d100000000000000000000000000000000000000000000000000000000000000a000000000000000000000000000000000000000000000000000000000000000010000000000000000000000000000000000000000000000000000000000000002000000000000000000000000082646b22a3960da69ef7a778c16dd6fb85dd999000000000000000000000000c02aaa39b223fe8d0a0e5c4f27ead9083c756cc200000000000000000000000000000000000000000000000000000000000000400000000000000000000000000000000000000000000000000000000000000001000000000000000000000000000000000000000000000000032b2ced3e40e9d1",      "networkId": "1",      "stateOverrides": {        "0x0811fd1808e14f0b93f0514313965a5f142c5539": {          "balance": "0x1111111111111111"        }      },      "to": "0xef1c6e67703c7bd7107eed8303fbe6ec2554bf6b",      "transactionIndex": "97",      "value": "0x0"    }  }'
{  "simulation": {    "accessList": [      {        "address": "string",        "storageKeys": [          "string"        ]      }    ],    "blockNumber": "string",    "blockOverride": {      "baseFee": "string",      "blockHash": {        "property1": "string",        "property2": "string"      },      "blockNumber": "string",      "difficulty": "string",      "gasLimit": "string",      "timestamp": "string"    },    "bundleId": "string",    "chainId": "string",    "chainSpec": {      "chainId": "string",      "forkId": "string"    },    "createAt": "string",    "debugDeployment": true,    "from": "string",    "gas": "string",    "gasPrice": "string",    "id": "string",    "input": "string",    "label": "string",    "maxFeePerGas": "string",    "maxPriorityFeePerGas": "string",    "networkId": "string",    "originTxHash": "string",    "result": {      "transaction": {        "accessList": [          {            "address": "string",            "storageKeys": [              "string"            ]          }        ],        "blockHash": "string",        "blockNumber": "string",        "chainId": "string",        "from": "string",        "gas": "string",        "gasPrice": "string",        "hash": "string",        "input": "string",        "maxFeePerGas": "string",        "maxPriorityFeePerGas": "string",        "nonce": "string",        "to": "string",        "transactionIndex": "string",        "type": "string",        "value": "string"      },      "transactionReceipt": {        "cumulativeGasUsed": "string",        "effectiveGasPrice": "string",        "error": "string",        "gasUsed": "string",        "logs": [          {}        ],        "revertReason": "string",        "status": "string"      }    },    "sharing": {      "id": "string",      "isPublic": true,      "simulationId": "string"    },    "sourceOverrides": {      "property1": "string",      "property2": "string"    },    "stateOverrides": {      "property1": {        "balance": "string",        "code": "string",        "state": {          "property1": "string",          "property2": "string"        }      },      "property2": {        "balance": "string",        "code": "string",        "state": {          "property1": "string",          "property2": "string"        }      }    },    "to": "string",    "transactionIndex": "string",    "value": "string"  }}