Skip to main content

starknet_getBlockWithReceipts RPC Method

Returns detailed block information, including full transactions and receipts, corresponding to the provided block ID.

Updated on
Mar 18, 2024

starknet_getBlockWithReceipts RPC Method

Parameters

block_id
string
REQUIRED
The hash of the requested block, the block number (height) of the requested block, or a block tag (latest or pending)

Returns

result
string
The result object which can be one of the following object:
BLOCK_WITH_RECEIPTS
object
The block with receipts object which have the following fields
status
string
The block status, which can be one of - 'PENDING', 'ACCEPTED_ON_L2', 'ACCEPTED_ON_L1', 'REJECTED'
block_hash
string
The block hash
parent_hash
string
The parent block hash
block_number
string
The block number (its height)
new_root
string
The new global state root
timestamp
integer
The time in which the block was created, encoded in Unix time
sequencer_address
string
The StarkNet identity of the sequencer submitting this block
l1_gas_price
object
The price of l1 gas in the block
price_in_fri
string
The price of one unit of the given resource, denominated in fri (10^-18 strk)
price_in_wei
string
The price of one unit of the given resource, denominated in wei
l1_data_gas_price
object
The price of l1 data gas in the block
price_in_fri
string
The price of one unit of the given resource, denominated in fri (10^-18 strk)
price_in_wei
string
The price of one unit of the given resource, denominated in wei
l1_da_mode
string
It specifies whether the data of this block is published via blob data or calldata. It can be one of - 'BLOB' or 'CALLDATA'
starknet_version
string
The semver of the current Starknet protocol
transactions
object
The transaction object which contains the following objects:
transaction
object
The transaction object which can have one of the following object:
INVOKE_TXN
string
The Invoke transaction object which can have one of the following object:
INVOKE_TXN_V0
object
The invoke transaction V0 object which contains the following field:
type
string
The type of declare. It can take only one value - 'INVOKE'
max_fee
string
The maximal fee that can be charged for including the transaction
version
string
The version of the transaction scheme
signature
string
The signature associated with the transaction
contract_address
string
The address of the contract
entry_point_selector
string
The entry point selector
calldata
array
The parameters passed to the constructor
INVOKE_TXN_V1
object
The invoke transaction V1 object which contains the following field:
type
string
The type of declare. It can take only one value - 'INVOKE'
sender_address
string
The sender address
calldata
array
The parameters passed to the constructor
max_fee
string
The maximal fee that can be charged for including the transaction
version
string
The version of the transaction scheme
signature
string
The signature associated with the transaction
nonce
string
The nonce value
INVOKE_TXN_V3
object
The invoke transaction V3 object which contains the following field:
type
string
The type of declare. It can take only one value - 'INVOKE'
sender_address
string
The sender address
calldata
array
The parameters passed to the constructor
version
string
The version of the transaction scheme
signature
string
The signature associated with the transaction
nonce
string
The nonce value
resource_bounds
object
The resource bounds for the transaction execution
l1_gas
string
The max amount and max price per unit of L1 gas used in this tx
max_amount
string
The max amount of the resource that can be used in the tx
max_price_per_unit
string
The max price per unit of this resource for this tx
l2_gas
string
The max amount and max price per unit of L2 gas used in this tx
max_amount
string
The max amount of the resource that can be used in the tx
max_price_per_unit
string
The max price per unit of this resource for this tx
tip
string
The tip for the transaction
paymaster_data
array
The data needed to allow the paymaster to pay for the transaction in native tokens
account_deployment_data
array
The data needed to deploy the account contract from which this tx will be initiated
nonce_data_availability_mode
string
The storage domain of the account's nonce (an account has a nonce per DA mode). It can be one of 'L1' or 'L2'
fee_data_availability_mode
string
The storage domain of the account's balance from which fee will be charged. It can be one of 'L1' or 'L2'
L1_HANDLER_TXN
object
The L1 Handler transaction object which contains the following fields:
version
string
The version of the transaction scheme
type
string
The type of the L1 transaction handler('L1_HANDLER')
nonce
string
The L1->L2 message nonce field of the SN Core L1 contract at the time the transaction was sent
contract_address
string
The contract address
entry_point_selector
string
The entry point selector
calldata
array
The parameters passed to the function
DECLARE_TXN
object
The declare transaction object which can have one the following object:
DECLARE_TXN_V0
object
The declare contract transaction V0 which contains the following fields:
type
string
The type of declare. It can take only one value - 'DECLARE'
sender_address
string
The address of the account contract sending the declaration transaction
max_fee
string
The maximal fee that can be charged for including the transaction
version
string
The version of the transaction scheme
signature
string
The signature associated with the transaction
class_hash
string
The hash of the declared class
DECLARE_TXN_V1
object
The declare contract transaction V1 which contains the following fields:
type
string
The type of declare. It can take only one value - 'DECLARE'
sender_address
string
The address of the account contract sending the declaration transaction
max_fee
string
The maximal fee that can be charged for including the transaction
version
string
The version of the transaction scheme
signature
string
The signature associated with the transaction
nonce
string
The nonce
class_hash
string
The hash of the declared class
DECLARE_TXN_V2
object
The declare contract transaction V2 which contains the following fields:
type
string
The type of declare. It can take only one value - 'DECLARE'
sender_address
string
The address of the account contract sending the declaration transaction
max_fee
string
The maximal fee that can be charged for including the transaction
version
string
The version of the transaction scheme
signature
string
The signature associated with the transaction
nonce
string
The nonce
class_hash
string
The hash of the declared class
DECLARE_TXN_V3
object
The declare Contract Transaction V3 which have the following fields:
type
string
The type of declare. It can take only one value - 'DECLARE'
sender_address
string
The address of the account contract sending the declaration transaction
compiled_class_hash
string
The hash of the Cairo assembly resulting from the Sierra compilation
version
string
The version of the transaction scheme
signature
string
The signature associated with the transaction
nonce
string
The nonce value
class_hash
string
The hash of the declared class
resource_bounds
object
The resource bounds for the transaction execution
l1_gas
string
The max amount and max price per unit of L1 gas used in this tx
max_amount
string
The max amount of the resource that can be used in the tx
max_price_per_unit
string
The max price per unit of this resource for this tx
l2_gas
string
The max amount and max price per unit of L2 gas used in this tx
max_amount
string
The max amount of the resource that can be used in the tx
max_price_per_unit
string
The max price per unit of this resource for this tx
tip
string
The tip for the transaction
paymaster_data
array
The data needed to allow the paymaster to pay for the transaction in native tokens
account_deployment_data
array
The data needed to deploy the account contract from which this tx will be initiated
nonce_data_availability_mode
string
The storage domain of the account's nonce (an account has a nonce per DA mode). It can be one of 'L1' or 'L2'
fee_data_availability_mode
string
The storage domain of the account's balance from which fee will be charged. It can be one of 'L1' or 'L2'
DEPLOY_TXN
object
The structure of a deploy transaction. Note that this transaction type is deprecated and will no longer be supported in future versions. It contains the following fields:
version
string
The version of the transaction scheme
type
string
The type of the L1 transaction handler('L1_HANDLER')
contract_address_salt
string
The salt for the address of the deployed contract
constructor_calldata
string
The parameters passed to the constructor
class_hash
string
The hash of the deployed contract's class
DEPLOY_ACCOUNT_TXN
object
The deploy account transaction object which can have one of the following objects:
DEPLOY_ACCOUNT_TXN_V1
object
It deploys an account contract, charges fee from the pre-funded account addresses. It consist of following fields:
type
string
The type of declare. It can take only one value - 'DEPLOY_ACCOUNT'
max_fee
string
The maximal fee that can be charged for including the transaction
version
string
The version of the transaction scheme
signature
string
The signature associated with the transaction
nonce
string
The nonce value
contract_address_salt
string
The salt for the address of the deployed contract
constructor_calldata
array
The parameters passed to the constructor
class_hash
string
The hash of the deployed contract's class
DEPLOY_ACCOUNT_TXN_V3
object
It deploys an account contract, charges fee from the pre-funded account addresses. It consist of following fields:
type
string
The type of declare. It can take only one value - 'DEPLOY_ACCOUNT'
version
string
The version of the transaction scheme
signature
string
The signature associated with the transaction
nonce
string
The nonce value
contract_address_salt
string
The salt for the address of the deployed contract
constructor_calldata
array
The parameters passed to the constructor
class_hash
string
The hash of the deployed contract's class
resource_bounds
object
The resource bounds for the transaction execution
l1_gas
string
The max amount and max price per unit of L1 gas used in this tx
max_amount
string
The max amount of the resource that can be used in the tx
max_price_per_unit
string
The max price per unit of this resource for this tx
l2_gas
string
The max amount and max price per unit of L2 gas used in this tx
max_amount
string
The max amount of the resource that can be used in the tx
max_price_per_unit
string
The max price per unit of this resource for this tx
tip
string
The tip for the transaction
paymaster_data
array
The data needed to allow the paymaster to pay for the transaction in native tokens
account_deployment_data
array
The data needed to deploy the account contract from which this tx will be initiated
nonce_data_availability_mode
string
The storage domain of the account's nonce (an account has a nonce per DA mode). It can be one of 'L1' or 'L2'
fee_data_availability_mode
string
The storage domain of the account's balance from which fee will be charged. It can be one of 'L1' or 'L2'
receipt
object
The receipt object which can have one of the following object:
INVOKE_TXN_RECEIPT
object
The invoke transaction receipt object which contains one of the following object:
type
string
The type. The values it can take includes 'INVOKE'
transaction_hash
string
The hash identifying the transaction
actual_fee
string
The fee that was charged by the sequencer
amount
string
The amount paid
unit
string
The units in which the fee is given
execution_status
string
The execution status. Possible values includes - 'SUCCEEDED' or 'REVERTED'
finality_status
string
The finality status of the tx. Possible values includes - 'ACCEPTED_ON_L2' or 'ACCEPTED_ON_L1'
messages_sent
array
The Messages sent
from_address
string
The address of the L2 contract sending the message
to_address
string
The target L1 address the message is sent to
payload
string
The payload of the message
revert_reason
string
The revert reason for the failed execution
events
array
The events emitted as part of this transaction
from_address
string
The address of the L2 contract sending the message
keys
array
The keys associated with the event
data
array
The data associated with the event
execution_resources
string
The resources consumed by the transaction
data_availability
object
The data-availability resources of this transaction, which contains the following fields:
l1_gas
integer
The gas consumed by this transaction's data
l1_data_gas
integer
The data gas consumed by this transaction's data, 0 if it uses gas for DA
steps
integer
The number of Cairo steps used
memory_holes
integer
The number of unused memory cells (each cell is roughly equivalent to a step)
range_check_builtin_applications
integer
The number of RANGE_CHECK builtin instances
pedersen_builtin_applications
integer
The number of Pedersen builtin instances
poseidon_builtin_applications
integer
The number of Poseidon builtin instances
ec_op_builtin_applications
integer
The number of EC_OP builtin instances
ecdsa_builtin_applications
integer
The number of ECDSA builtin instances
bitwise_builtin_applications
integer
The number of BITWISE builtin instances
keccak_builtin_applications
integer
The number of KECCAK builtin instances
segment_arena_builtin
integer
The number of accesses to the segment arena
L1_HANDLER_TXN_RECEIPT
object
The L1 handler transaction receipt object which contains one of the following object:
type
string
The type. The values it can take includes 'L1_HANDLER'
message_hash
string
The message hash as it appears on the L1 core contract
transaction_hash
string
The hash identifying the transaction
actual_fee
string
The fee that was charged by the sequencer
amount
string
The amount paid
unit
string
The units in which the fee is given
execution_status
string
The execution status. Possible values includes - 'SUCCEEDED' or 'REVERTED'
finality_status
string
The finality status of the tx. Possible values includes - 'ACCEPTED_ON_L2' or 'ACCEPTED_ON_L1'
messages_sent
array
The Messages sent
from_address
string
The address of the L2 contract sending the message
to_address
string
The target L1 address the message is sent to
payload
string
The payload of the message
revert_reason
string
The revert reason for the failed execution
events
array
The events emitted as part of this transaction
from_address
string
The address of the L2 contract sending the message
keys
array
The keys associated with the event
data
array
The data associated with the event
execution_resources
string
The resources consumed by the transaction
data_availability
object
The data-availability resources of this transaction, which contains the following fields:
l1_gas
integer
The gas consumed by this transaction's data
l1_data_gas
integer
The data gas consumed by this transaction's data, 0 if it uses gas for DA
steps
integer
The number of Cairo steps used
memory_holes
integer
The number of unused memory cells (each cell is roughly equivalent to a step)
range_check_builtin_applications
integer
The number of RANGE_CHECK builtin instances
pedersen_builtin_applications
integer
The number of Pedersen builtin instances
poseidon_builtin_applications
integer
The number of Poseidon builtin instances
ec_op_builtin_applications
integer
The number of EC_OP builtin instances
ecdsa_builtin_applications
integer
The number of ECDSA builtin instances
bitwise_builtin_applications
integer
The number of BITWISE builtin instances
keccak_builtin_applications
integer
The number of KECCAK builtin instances
segment_arena_builtin
integer
The number of accesses to the segment arena
DECLARE_TXN_RECEIPT
object
The declare transaction receipt object which contains one of the following object:
type
string
The type. The values it can take includes 'DECLARE'
transaction_hash
string
The hash identifying the transaction
actual_fee
string
The fee that was charged by the sequencer
amount
string
The amount paid
unit
string
The units in which the fee is given
execution_status
string
The execution status. Possible values includes - 'SUCCEEDED' or 'REVERTED'
finality_status
string
The finality status of the tx. Possible values includes - 'ACCEPTED_ON_L2' or 'ACCEPTED_ON_L1'
messages_sent
array
The Messages sent
from_address
string
The address of the L2 contract sending the message
to_address
string
The target L1 address the message is sent to
payload
string
The payload of the message
revert_reason
string
The revert reason for the failed execution
events
array
The events emitted as part of this transaction
from_address
string
The address of the L2 contract sending the message
keys
array
The keys associated with the event
data
array
The data associated with the event
execution_resources
string
The resources consumed by the transaction
data_availability
object
The data-availability resources of this transaction, which contains the following fields:
l1_gas
integer
The gas consumed by this transaction's data
l1_data_gas
integer
The data gas consumed by this transaction's data, 0 if it uses gas for DA
steps
integer
The number of Cairo steps used
memory_holes
integer
The number of unused memory cells (each cell is roughly equivalent to a step)
range_check_builtin_applications
integer
The number of RANGE_CHECK builtin instances
pedersen_builtin_applications
integer
The number of Pedersen builtin instances
poseidon_builtin_applications
integer
The number of Poseidon builtin instances
ec_op_builtin_applications
integer
The number of EC_OP builtin instances
ecdsa_builtin_applications
integer
The number of ECDSA builtin instances
bitwise_builtin_applications
integer
The number of BITWISE builtin instances
keccak_builtin_applications
integer
The number of KECCAK builtin instances
segment_arena_builtin
integer
The number of accesses to the segment arena
DEPLOY_TXN_RECEIPT
object
The deploy transaction receipt object which contains one of the following object:
type
string
The type. The values it can take includes 'DEPLOY'
contract_address
string
The address of the deployed contract
transaction_hash
string
The hash identifying the transaction
actual_fee
string
The fee that was charged by the sequencer
amount
string
The amount paid
unit
string
The units in which the fee is given
execution_status
string
The execution status. Possible values includes - 'SUCCEEDED' or 'REVERTED'
finality_status
string
The finality status of the tx. Possible values includes - 'ACCEPTED_ON_L2' or 'ACCEPTED_ON_L1'
messages_sent
array
The Messages sent
from_address
string
The address of the L2 contract sending the message
to_address
string
The target L1 address the message is sent to
payload
string
The payload of the message
revert_reason
string
The revert reason for the failed execution
events
array
The events emitted as part of this transaction
from_address
string
The address of the L2 contract sending the message
keys
array
The keys associated with the event
data
array
The data associated with the event
execution_resources
string
The resources consumed by the transaction
data_availability
object
The data-availability resources of this transaction, which contains the following fields:
l1_gas
integer
The gas consumed by this transaction's data
l1_data_gas
integer
The data gas consumed by this transaction's data, 0 if it uses gas for DA
steps
integer
The number of Cairo steps used
memory_holes
integer
The number of unused memory cells (each cell is roughly equivalent to a step)
range_check_builtin_applications
integer
The number of RANGE_CHECK builtin instances
pedersen_builtin_applications
integer
The number of Pedersen builtin instances
poseidon_builtin_applications
integer
The number of Poseidon builtin instances
ec_op_builtin_applications
integer
The number of EC_OP builtin instances
ecdsa_builtin_applications
integer
The number of ECDSA builtin instances
bitwise_builtin_applications
integer
The number of BITWISE builtin instances
keccak_builtin_applications
integer
The number of KECCAK builtin instances
segment_arena_builtin
integer
The number of accesses to the segment arena
DEPLOY_ACCOUNT_TXN_RECEIPT
object
The deploy account transaction receipt object which contains one of the following object:
type
string
The type. The values it can take includes 'DEPLOY_ACCOUNT'
contract_address
string
The address of the deployed contract
transaction_hash
string
The hash identifying the transaction
actual_fee
string
The fee that was charged by the sequencer
amount
string
The amount paid
unit
string
The units in which the fee is given
execution_status
string
The execution status. Possible values includes - 'SUCCEEDED' or 'REVERTED'
finality_status
string
The finality status of the tx. Possible values includes - 'ACCEPTED_ON_L2' or 'ACCEPTED_ON_L1'
messages_sent
array
The Messages sent
from_address
string
The address of the L2 contract sending the message
to_address
string
The target L1 address the message is sent to
payload
string
The payload of the message
revert_reason
string
The revert reason for the failed execution
events
array
The events emitted as part of this transaction
from_address
string
The address of the L2 contract sending the message
keys
array
The keys associated with the event
data
array
The data associated with the event
execution_resources
string
The resources consumed by the transaction
data_availability
object
The data-availability resources of this transaction, which contains the following fields:
l1_gas
integer
The gas consumed by this transaction's data
l1_data_gas
integer
The data gas consumed by this transaction's data, 0 if it uses gas for DA
steps
integer
The number of Cairo steps used
memory_holes
integer
The number of unused memory cells (each cell is roughly equivalent to a step)
range_check_builtin_applications
integer
The number of RANGE_CHECK builtin instances
pedersen_builtin_applications
integer
The number of Pedersen builtin instances
poseidon_builtin_applications
integer
The number of Poseidon builtin instances
ec_op_builtin_applications
integer
The number of EC_OP builtin instances
ecdsa_builtin_applications
integer
The number of ECDSA builtin instances
bitwise_builtin_applications
integer
The number of BITWISE builtin instances
keccak_builtin_applications
integer
The number of KECCAK builtin instances
segment_arena_builtin
integer
The number of accesses to the segment arena
PENDING_BLOCK_WITH_TX_HASHES
object
The pending block with transaction hashes object which have the following fields. Note that this object will be deprecated upon decentralization
parent_hash
string
The parent block hash
timestamp
integer
The time in which the block was created, encoded in Unix time
sequencer_address
string
The StarkNet identity of the sequencer submitting this block
l1_gas_price
object
The price of l1 gas in the block
price_in_fri
string
The price of one unit of the given resource, denominated in fri (10^-18 strk)
price_in_wei
string
The price of one unit of the given resource, denominated in wei
l1_data_gas_price
object
The price of l1 data gas in the block
price_in_fri
string
The price of one unit of the given resource, denominated in fri (10^-18 strk)
price_in_wei
string
The price of one unit of the given resource, denominated in wei
l1_da_mode
string
It specifies whether the data of this block is published via blob data or calldata. It can be one of - 'BLOB' or 'CALLDATA'
starknet_version
string
The semver of the current Starknet protocol
transactions
object
The transaction object which contains the following objects:
transaction
object
The transaction object which can have one of the following object:
INVOKE_TXN
string
The Invoke transaction object which can have one of the following object:
INVOKE_TXN_V0
object
The invoke transaction V0 object which contains the following field:
type
string
The type of declare. It can take only one value - 'INVOKE'
max_fee
string
The maximal fee that can be charged for including the transaction
version
string
The version of the transaction scheme
signature
string
The signature associated with the transaction
contract_address
string
The address of the contract
entry_point_selector
string
The entry point selector
calldata
array
The parameters passed to the constructor
INVOKE_TXN_V1
object
The invoke transaction V1 object which contains the following field:
type
string
The type of declare. It can take only one value - 'INVOKE'
sender_address
string
The sender address
calldata
array
The parameters passed to the constructor
max_fee
string
The maximal fee that can be charged for including the transaction
version
string
The version of the transaction scheme
signature
string
The signature associated with the transaction
nonce
string
The nonce value
INVOKE_TXN_V3
object
The invoke transaction V3 object which contains the following field:
type
string
The type of declare. It can take only one value - 'INVOKE'
sender_address
string
The sender address
calldata
array
The parameters passed to the constructor
version
string
The version of the transaction scheme
signature
string
The signature associated with the transaction
nonce
string
The nonce value
resource_bounds
object
The resource bounds for the transaction execution
l1_gas
string
The max amount and max price per unit of L1 gas used in this tx
max_amount
string
The max amount of the resource that can be used in the tx
max_price_per_unit
string
The max price per unit of this resource for this tx
l2_gas
string
The max amount and max price per unit of L2 gas used in this tx
max_amount
string
The max amount of the resource that can be used in the tx
max_price_per_unit
string
The max price per unit of this resource for this tx
tip
string
The tip for the transaction
paymaster_data
array
The data needed to allow the paymaster to pay for the transaction in native tokens
account_deployment_data
array
The data needed to deploy the account contract from which this tx will be initiated
nonce_data_availability_mode
string
The storage domain of the account's nonce (an account has a nonce per DA mode). It can be one of 'L1' or 'L2'
fee_data_availability_mode
string
The storage domain of the account's balance from which fee will be charged. It can be one of 'L1' or 'L2'
L1_HANDLER_TXN
object
The L1 Handler transaction object which contains the following fields:
version
string
The version of the transaction scheme
type
string
The type of the L1 transaction handler('L1_HANDLER')
nonce
string
The L1->L2 message nonce field of the SN Core L1 contract at the time the transaction was sent
contract_address
string
The contract address
entry_point_selector
string
The entry point selector
calldata
array
The parameters passed to the function
DECLARE_TXN
object
The declare transaction object which can have one the following object:
DECLARE_TXN_V0
object
The declare contract transaction V0 which contains the following fields:
type
string
The type of declare. It can take only one value - 'DECLARE'
sender_address
string
The address of the account contract sending the declaration transaction
max_fee
string
The maximal fee that can be charged for including the transaction
version
string
The version of the transaction scheme
signature
string
The signature associated with the transaction
class_hash
string
The hash of the declared class
DECLARE_TXN_V1
object
The declare contract transaction V1 which contains the following fields:
type
string
The type of declare. It can take only one value - 'DECLARE'
sender_address
string
The address of the account contract sending the declaration transaction
max_fee
string
The maximal fee that can be charged for including the transaction
version
string
The version of the transaction scheme
signature
string
The signature associated with the transaction
nonce
string
The nonce
class_hash
string
The hash of the declared class
DECLARE_TXN_V2
object
The declare contract transaction V2 which contains the following fields:
type
string
The type of declare. It can take only one value - 'DECLARE'
sender_address
string
The address of the account contract sending the declaration transaction
max_fee
string
The maximal fee that can be charged for including the transaction
version
string
The version of the transaction scheme
signature
string
The signature associated with the transaction
nonce
string
The nonce
class_hash
string
The hash of the declared class
DECLARE_TXN_V3
object
The declare Contract Transaction V3 which have the following fields:
type
string
The type of declare. It can take only one value - 'DECLARE'
sender_address
string
The address of the account contract sending the declaration transaction
compiled_class_hash
string
The hash of the Cairo assembly resulting from the Sierra compilation
version
string
The version of the transaction scheme
signature
string
The signature associated with the transaction
nonce
string
The nonce value
class_hash
string
The hash of the declared class
resource_bounds
object
The resource bounds for the transaction execution
l1_gas
string
The max amount and max price per unit of L1 gas used in this tx
max_amount
string
The max amount of the resource that can be used in the tx
max_price_per_unit
string
The max price per unit of this resource for this tx
l2_gas
string
The max amount and max price per unit of L2 gas used in this tx
max_amount
string
The max amount of the resource that can be used in the tx
max_price_per_unit
string
The max price per unit of this resource for this tx
tip
string
The tip for the transaction
paymaster_data
array
The data needed to allow the paymaster to pay for the transaction in native tokens
account_deployment_data
array
The data needed to deploy the account contract from which this tx will be initiated
nonce_data_availability_mode
string
The storage domain of the account's nonce (an account has a nonce per DA mode). It can be one of 'L1' or 'L2'
fee_data_availability_mode
string
The storage domain of the account's balance from which fee will be charged. It can be one of 'L1' or 'L2'
DEPLOY_TXN
object
The structure of a deploy transaction. Note that this transaction type is deprecated and will no longer be supported in future versions. It contains the following fields:
version
string
The version of the transaction scheme
type
string
The type of the L1 transaction handler('L1_HANDLER')
contract_address_salt
string
The salt for the address of the deployed contract
constructor_calldata
string
The parameters passed to the constructor
class_hash
string
The hash of the deployed contract's class
DEPLOY_ACCOUNT_TXN
object
The deploy account transaction object which can have one of the following objects:
DEPLOY_ACCOUNT_TXN_V1
object
It deploys an account contract, charges fee from the pre-funded account addresses. It consist of following fields:
type
string
The type of declare. It can take only one value - 'DEPLOY_ACCOUNT'
max_fee
string
The maximal fee that can be charged for including the transaction
version
string
The version of the transaction scheme
signature
string
The signature associated with the transaction
nonce
string
The nonce value
contract_address_salt
string
The salt for the address of the deployed contract
constructor_calldata
array
The parameters passed to the constructor
class_hash
string
The hash of the deployed contract's class
DEPLOY_ACCOUNT_TXN_V3
object
It deploys an account contract, charges fee from the pre-funded account addresses. It consist of following fields:
type
string
The type of declare. It can take only one value - 'DEPLOY_ACCOUNT'
version
string
The version of the transaction scheme
signature
string
The signature associated with the transaction
nonce
string
The nonce value
contract_address_salt
string
The salt for the address of the deployed contract
constructor_calldata
array
The parameters passed to the constructor
class_hash
string
The hash of the deployed contract's class
resource_bounds
object
The resource bounds for the transaction execution
l1_gas
string
The max amount and max price per unit of L1 gas used in this tx
max_amount
string
The max amount of the resource that can be used in the tx
max_price_per_unit
string
The max price per unit of this resource for this tx
l2_gas
string
The max amount and max price per unit of L2 gas used in this tx
max_amount
string
The max amount of the resource that can be used in the tx
max_price_per_unit
string
The max price per unit of this resource for this tx
tip
string
The tip for the transaction
paymaster_data
array
The data needed to allow the paymaster to pay for the transaction in native tokens
account_deployment_data
array
The data needed to deploy the account contract from which this tx will be initiated
nonce_data_availability_mode
string
The storage domain of the account's nonce (an account has a nonce per DA mode). It can be one of 'L1' or 'L2'
fee_data_availability_mode
string
The storage domain of the account's balance from which fee will be charged. It can be one of 'L1' or 'L2'
receipt
object
The receipt object which can have one of the following object:
INVOKE_TXN_RECEIPT
object
The invoke transaction receipt object which contains one of the following object:
type
string
The type. The values it can take includes 'INVOKE'
transaction_hash
string
The hash identifying the transaction
actual_fee
string
The fee that was charged by the sequencer
amount
string
The amount paid
unit
string
The units in which the fee is given
execution_status
string
The execution status. Possible values includes - 'SUCCEEDED' or 'REVERTED'
finality_status
string
The finality status of the tx. Possible values includes - 'ACCEPTED_ON_L2' or 'ACCEPTED_ON_L1'
messages_sent
array
The Messages sent
from_address
string
The address of the L2 contract sending the message
to_address
string
The target L1 address the message is sent to
payload
string
The payload of the message
revert_reason
string
The revert reason for the failed execution
events
array
The events emitted as part of this transaction
from_address
string
The address of the L2 contract sending the message
keys
array
The keys associated with the event
data
array
The data associated with the event
execution_resources
string
The resources consumed by the transaction
data_availability
object
The data-availability resources of this transaction, which contains the following fields:
l1_gas
integer
The gas consumed by this transaction's data
l1_data_gas
integer
The data gas consumed by this transaction's data, 0 if it uses gas for DA
steps
integer
The number of Cairo steps used
memory_holes
integer
(Optional) The number of unused memory cells (each cell is roughly equivalent to a step)
range_check_builtin_applications
integer
(Optional) The number of RANGE_CHECK builtin instances
pedersen_builtin_applications
integer
(Optional) The number of Pedersen builtin instances
poseidon_builtin_applications
integer
(Optional) The number of Poseidon builtin instances
ec_op_builtin_applications
integer
(Optional) The number of EC_OP builtin instances
ecdsa_builtin_applications
integer
(Optional) The number of ECDSA builtin instances
bitwise_builtin_applications
integer
(Optional) The number of BITWISE builtin instances
keccak_builtin_applications
integer
(Optional) The number of KECCAK builtin instances
segment_arena_builtin
integer
(Optional) The number of accesses to the segment arena
L1_HANDLER_TXN_RECEIPT
object
The L1 handler transaction receipt object which contains one of the following object:
type
string
The type. The values it can take includes 'L1_HANDLER'
message_hash
string
The message hash as it appears on the L1 core contract
transaction_hash
string
The hash identifying the transaction
actual_fee
string
The fee that was charged by the sequencer
amount
string
The amount paid
unit
string
The units in which the fee is given
execution_status
string
The execution status. Possible values includes - 'SUCCEEDED' or 'REVERTED'
finality_status
string
The finality status of the tx. Possible values includes - 'ACCEPTED_ON_L2' or 'ACCEPTED_ON_L1'
messages_sent
array
The Messages sent
from_address
string
The address of the L2 contract sending the message
to_address
string
The target L1 address the message is sent to
payload
string
The payload of the message
revert_reason
string
The revert reason for the failed execution
events
array
The events emitted as part of this transaction
from_address
string
The address of the L2 contract sending the message
keys
array
The keys associated with the event
data
array
The data associated with the event
execution_resources
string
The resources consumed by the transaction
data_availability
object
The data-availability resources of this transaction, which contains the following fields:
l1_gas
integer
The gas consumed by this transaction's data
l1_data_gas
integer
The data gas consumed by this transaction's data, 0 if it uses gas for DA
steps
integer
The number of Cairo steps used
memory_holes
integer
(Optional) The number of unused memory cells (each cell is roughly equivalent to a step)
range_check_builtin_applications
integer
(Optional) The number of RANGE_CHECK builtin instances
pedersen_builtin_applications
integer
(Optional) The number of Pedersen builtin instances
poseidon_builtin_applications
integer
(Optional) The number of Poseidon builtin instances
ec_op_builtin_applications
integer
(Optional) The number of EC_OP builtin instances
ecdsa_builtin_applications
integer
(Optional) The number of ECDSA builtin instances
bitwise_builtin_applications
integer
(Optional) The number of BITWISE builtin instances
keccak_builtin_applications
integer
(Optional) The number of KECCAK builtin instances
segment_arena_builtin
integer
(Optional) The number of accesses to the segment arena
DECLARE_TXN_RECEIPT
object
The declare transaction receipt object which contains one of the following object:
type
string
The type. The values it can take includes 'DECLARE'
transaction_hash
string
The hash identifying the transaction
actual_fee
string
The fee that was charged by the sequencer
amount
string
The amount paid
unit
string
The units in which the fee is given
execution_status
string
The execution status. Possible values includes - 'SUCCEEDED' or 'REVERTED'
finality_status
string
The finality status of the tx. Possible values includes - 'ACCEPTED_ON_L2' or 'ACCEPTED_ON_L1'
messages_sent
array
The Messages sent
from_address
string
The address of the L2 contract sending the message
to_address
string
The target L1 address the message is sent to
payload
string
The payload of the message
revert_reason
string
The revert reason for the failed execution
events
array
The events emitted as part of this transaction
from_address
string
The address of the L2 contract sending the message
keys
array
The keys associated with the event
data
array
The data associated with the event
execution_resources
string
The resources consumed by the transaction
data_availability
object
The data-availability resources of this transaction, which contains the following fields:
l1_gas
integer
The gas consumed by this transaction's data
l1_data_gas
integer
The data gas consumed by this transaction's data, 0 if it uses gas for DA
steps
integer
The number of Cairo steps used
memory_holes
integer
(Optional) The number of unused memory cells (each cell is roughly equivalent to a step)
range_check_builtin_applications
integer
(Optional) The number of RANGE_CHECK builtin instances
pedersen_builtin_applications
integer
(Optional) The number of Pedersen builtin instances
poseidon_builtin_applications
integer
(Optional) The number of Poseidon builtin instances
ec_op_builtin_applications
integer
(Optional) The number of EC_OP builtin instances
ecdsa_builtin_applications
integer
(Optional) The number of ECDSA builtin instances
bitwise_builtin_applications
integer
(Optional) The number of BITWISE builtin instances
keccak_builtin_applications
integer
(Optional) The number of KECCAK builtin instances
segment_arena_builtin
integer
(Optional) The number of accesses to the segment arena
DEPLOY_TXN_RECEIPT
object
The deploy transaction receipt object which contains one of the following object:
type
string
The type. The values it can take includes 'DEPLOY'
contract_address
string
The address of the deployed contract
transaction_hash
string
The hash identifying the transaction
actual_fee
string
The fee that was charged by the sequencer
amount
string
The amount paid
unit
string
The units in which the fee is given
execution_status
string
The execution status. Possible values includes - 'SUCCEEDED' or 'REVERTED'
finality_status
string
The finality status of the tx. Possible values includes - 'ACCEPTED_ON_L2' or 'ACCEPTED_ON_L1'
messages_sent
array
The Messages sent
from_address
string
The address of the L2 contract sending the message
to_address
string
The target L1 address the message is sent to
payload
string
The payload of the message
revert_reason
string
The revert reason for the failed execution
events
array
The events emitted as part of this transaction
from_address
string
The address of the L2 contract sending the message
keys
array
The keys associated with the event
data
array
The data associated with the event
execution_resources
string
The resources consumed by the transaction
data_availability
object
The data-availability resources of this transaction, which contains the following fields:
l1_gas
integer
The gas consumed by this transaction's data
l1_data_gas
integer
The data gas consumed by this transaction's data, 0 if it uses gas for DA
steps
integer
The number of Cairo steps used
memory_holes
integer
(Optional) The number of unused memory cells (each cell is roughly equivalent to a step)
range_check_builtin_applications
integer
(Optional) The number of RANGE_CHECK builtin instances
pedersen_builtin_applications
integer
(Optional) The number of Pedersen builtin instances
poseidon_builtin_applications
integer
(Optional) The number of Poseidon builtin instances
ec_op_builtin_applications
integer
(Optional) The number of EC_OP builtin instances
ecdsa_builtin_applications
integer
(Optional) The number of ECDSA builtin instances
bitwise_builtin_applications
integer
(Optional) The number of BITWISE builtin instances
keccak_builtin_applications
integer
(Optional) The number of KECCAK builtin instances
segment_arena_builtin
integer
(Optional) The number of accesses to the segment arena
DEPLOY_ACCOUNT_TXN_RECEIPT
object
The deploy account transaction receipt object which contains one of the following object:
type
string
The type. The values it can take includes 'DEPLOY_ACCOUNT'
contract_address
string
The address of the deployed contract
transaction_hash
string
The hash identifying the transaction
actual_fee
string
The fee that was charged by the sequencer
amount
string
The amount paid
unit
string
The units in which the fee is given
execution_status
string
The execution status. Possible values includes - 'SUCCEEDED' or 'REVERTED'
finality_status
string
The finality status of the tx. Possible values includes - 'ACCEPTED_ON_L2' or 'ACCEPTED_ON_L1'
messages_sent
array
The Messages sent
from_address
string
The address of the L2 contract sending the message
to_address
string
The target L1 address the message is sent to
payload
string
The payload of the message
revert_reason
string
The revert reason for the failed execution
events
array
The events emitted as part of this transaction
from_address
string
The address of the L2 contract sending the message
keys
array
The keys associated with the event
data
array
The data associated with the event
execution_resources
string
The resources consumed by the transaction
data_availability
object
The data-availability resources of this transaction, which contains the following fields:
l1_gas
integer
The gas consumed by this transaction's data
l1_data_gas
integer
The data gas consumed by this transaction's data, 0 if it uses gas for DA
steps
integer
The number of Cairo steps used
memory_holes
integer
(Optional) The number of unused memory cells (each cell is roughly equivalent to a step)
range_check_builtin_applications
integer
(Optional) The number of RANGE_CHECK builtin instances
pedersen_builtin_applications
integer
(Optional) The number of Pedersen builtin instances
poseidon_builtin_applications
integer
(Optional) The number of Poseidon builtin instances
ec_op_builtin_applications
integer
(Optional) The number of EC_OP builtin instances
ecdsa_builtin_applications
integer
(Optional) The number of ECDSA builtin instances
bitwise_builtin_applications
integer
(Optional) The number of BITWISE builtin instances
keccak_builtin_applications
integer
(Optional) The number of KECCAK builtin instances
segment_arena_builtin
integer
(Optional) The number of accesses to the segment arena
Request
1
curl --location 'https://docs-demo.strk-mainnet.quiknode.pro/' \
2
--header 'accept: application/json' \
3
--header 'content-type: application/json' \
4
--data '{
5
"id": 1,
6
"jsonrpc": "2.0",
7
"method": "starknet_getBlockWithReceipts",
8
"params": [
9
"latest"
10
]
11
}'
Don't have an account yet?
Create your QuickNode endpoint in seconds and start building
Get started for free