diff --git a/src/eth/execute.yaml b/src/eth/execute.yaml index c5e527074..e7ceeb08e 100644 --- a/src/eth/execute.yaml +++ b/src/eth/execute.yaml @@ -54,3 +54,14 @@ gasUsed: title: Gas used $ref: '#/components/schemas/uint' +- name: eth_multicall + summary: Executes a sequence of message calls building on eachother's state immediately without creating transactions on the block chain. + params: + - name: Arguments + required: true + schema: + $ref: '#/components/schemas/MulticallArgs' + result: + name: Result of calls + schema: + $ref: '#/components/schemas/CallResults' diff --git a/src/schemas/execute.yaml b/src/schemas/execute.yaml new file mode 100644 index 000000000..258714071 --- /dev/null +++ b/src/schemas/execute.yaml @@ -0,0 +1,112 @@ +MulticallArgs: + title: Arguments for multi call + type: object + required: + - block + - calls + properties: + block: + title: Block tag + $ref: '#/components/schemas/BlockNumberOrTag' + stateOverrides: + title: State overrides + $ref: '#/components/schemas/StateOverrides' + blockOverrides: + title: Overrides for block metadata + $ref: '#/components/schemas/BlockOverrides' + calls: + title: List of calls + $ref: '#/components/schemas/Calls' +Calls: + title: List of message calls + type: array + items: + $ref: '#/components/schemas/GenericTransaction' +StateOverrides: + title: Accounts in state to be overridden + type: object + additionalProperties: + $ref: '#/components/schemas/AccountOverride' +AccountOverride: + title: Details of an account to be overridden + type: object + oneOf: + - $ref: '#/components/schemas/AccountOverrideState' + - $ref: '#/components/schemas/AccountOverrideStateDiff' +AccountOverrideState: + title: Account override with whole storage replacement + properties: + nonce: + title: Nonce + $ref: '#/components/schemas/uint64' + balance: + title: Balance + $ref: '#/components/schemas/uint256' + code: + title: Code + $ref: '#/components/schemas/bytes' + state: + title: Storage + $ref: '#/components/schemas/AccountStorage' +AccountOverrideStateDiff: + title: Account override with partial storage modification + properties: + nonce: + title: Nonce + $ref: '#/components/schemas/uint64' + balance: + title: Balance + $ref: '#/components/schemas/uint256' + code: + title: Code + $ref: '#/components/schemas/bytes' + stateDiff: + title: Storage difference + $ref: '#/components/schemas/AccountStorage' +AccountStorage: + title: Storage slots for an account + type: object + additionalProperties: + - $ref: '#/components/schemas/hash32' +BlockOverrides: + title: Context fields related to the block being executed + type: object + properties: + number: + title: Number + $ref: '#/components/schemas/uint256' + prevRandao: + title: Randomness beacon + $ref: '#/components/schemas/uint256' + time: + title: Time + $ref: '#/components/schemas/uint256' + gasLimit: + title: Gas limit + $ref: '#/components/schemas/uint64' + coinbase: + title: Coinbase + $ref: '#/components/schemas/address' + random: + title: Random + $ref: '#/components/schemas/hash32' + baseFee: + title: Base fee + $ref: '#/components/schemas/uint256' +CallResults: + title: Results of multi call + type: array + items: + $ref: '#/components/schemas/CallResult' +CallResult: + title: Result of a call + type: object + required: + - return + properties: + return: + title: Return data + $ref: '#/components/schemas/bytes' + error: + title: Execution error + type: string diff --git a/wordlist.txt b/wordlist.txt index b941e83af..69d0611f4 100644 --- a/wordlist.txt +++ b/wordlist.txt @@ -42,3 +42,4 @@ ipc cli besu graphql +prevRandao