Skip to main content

eth_createAccessList


Method

  • JSON-RPC method name: eth_createAccessList
  • JSON-RPC version: 2.0

Parameters

NameTypeRequiredDescription
Transactionobjectyes
BlockoneOfno

Parameter schema

{
"Transaction": {
"required": true,
"schema": {
"type": "object",
"title": "Transaction object generic to all types",
"additionalProperties": false,
"properties": {
"type": {
"title": "type",
"type": "string",
"pattern": "^0x([0-9a-fA-F]?){1,2}$"
},
"nonce": {
"title": "nonce",
"type": "string",
"pattern": "^0x([1-9a-f]+[0-9a-f]*|0)$"
},
"to": {
"title": "to address",
"oneOf": [
{
"title": "Contract Creation (null)",
"type": "null"
},
{
"title": "Address",
"type": "string",
"pattern": "^0x[0-9a-fA-F]{40}$"
}
]
},
"from": {
"title": "from address",
"type": "string",
"pattern": "^0x[0-9a-fA-F]{40}$"
},
"gas": {
"title": "gas limit",
"type": "string",
"pattern": "^0x([1-9a-f]+[0-9a-f]*|0)$"
},
"value": {
"title": "value",
"type": "string",
"pattern": "^0x([1-9a-f]+[0-9a-f]*|0)$"
},
"input": {
"title": "input data",
"type": "string",
"pattern": "^0x[0-9a-f]*$"
},
"gasPrice": {
"title": "gas price",
"type": "string",
"pattern": "^0x([1-9a-f]+[0-9a-f]*|0)$",
"description": "The gas price willing to be paid by the sender in wei"
},
"maxPriorityFeePerGas": {
"title": "max priority fee per gas",
"type": "string",
"pattern": "^0x([1-9a-f]+[0-9a-f]*|0)$",
"description": "Maximum fee per gas the sender is willing to pay to miners in wei"
},
"maxFeePerGas": {
"title": "max fee per gas",
"type": "string",
"pattern": "^0x([1-9a-f]+[0-9a-f]*|0)$",
"description": "The maximum total fee per gas the sender is willing to pay (includes the network / base fee and miner / priority fee) in wei"
},
"maxFeePerBlobGas": {
"title": "max fee per blob gas",
"type": "string",
"pattern": "^0x([1-9a-f]+[0-9a-f]*|0)$",
"description": "The maximum total fee per gas the sender is willing to pay for blob gas in wei"
},
"accessList": {
"title": "accessList",
"type": "array",
"items": {
"title": "Access list entry",
"type": "object",
"additionalProperties": false,
"properties": {
"address": {
"title": "hex encoded address",
"type": "string",
"pattern": "^0x[0-9a-fA-F]{40}$"
},
"storageKeys": {
"type": "array",
"items": {
"title": "32 byte hex value",
"type": "string",
"pattern": "^0x[0-9a-f]{64}$"
}
}
}
},
"description": "EIP-2930 access list"
},
"blobVersionedHashes": {
"title": "blobVersionedHashes",
"description": "List of versioned blob hashes associated with the transaction's EIP-4844 data blobs.",
"type": "array",
"items": {
"title": "32 byte hex value",
"type": "string",
"pattern": "^0x[0-9a-f]{64}$"
}
},
"blobs": {
"title": "blobs",
"description": "Raw blob data.",
"type": "array",
"items": {
"title": "hex encoded bytes",
"type": "string",
"pattern": "^0x[0-9a-f]*$"
}
},
"chainId": {
"title": "chainId",
"type": "string",
"pattern": "^0x([1-9a-f]+[0-9a-f]*|0)$",
"description": "Chain ID that this transaction is valid on."
}
}
}
},
"Block": {
"required": false,
"schema": {
"title": "Block number or tag",
"oneOf": [
{
"title": "Block number",
"type": "string",
"pattern": "^0x([1-9a-f]+[0-9a-f]*|0)$"
},
{
"title": "Block tag",
"type": "string",
"enum": [
"earliest",
"finalized",
"safe",
"latest",
"pending"
],
"description": "`earliest`: The lowest numbered block the client has available; `finalized`: The most recent crypto-economically secure block, cannot be re-orged outside of manual intervention driven by community coordination; `safe`: The most recent block that is safe from re-orgs under honest majority and certain synchronicity assumptions; `latest`: The most recent block in the canonical chain observed by the client, this block may be re-orged out of the canonical chain even under healthy/normal conditions; `pending`: A sample next block built by the client on top of `latest` and containing the set of transactions usually taken from local mempool. Before the merge transition is finalized, any call querying for `finalized` or `safe` block MUST be responded to with `-39001: Unknown block` error"
}
]
}
}
}

Result

  • Name: Gas used
  • Type: object

Result schema

{
"title": "Access list result",
"type": "object",
"additionalProperties": false,
"properties": {
"accessList": {
"title": "accessList",
"type": "array",
"items": {
"title": "Access list entry",
"type": "object",
"additionalProperties": false,
"properties": {
"address": {
"title": "hex encoded address",
"type": "string",
"pattern": "^0x[0-9a-fA-F]{40}$"
},
"storageKeys": {
"type": "array",
"items": {
"title": "32 byte hex value",
"type": "string",
"pattern": "^0x[0-9a-f]{64}$"
}
}
}
}
},
"error": {
"title": "error",
"type": "string"
},
"gasUsed": {
"title": "Gas used",
"type": "string",
"pattern": "^0x([1-9a-f]+[0-9a-f]*|0)$"
}
}
}

Positional parameters

Parameter order:

  1. Transaction
  2. Block

Errors

This method may return JSON-RPC standard errors (e.g. -32600, -32601, -32602, -32603) as well as application-specific errors.

TODO: Document method-specific error codes and conditions.