Skip to main content
Version: Alpha / Testnet (v5.0.0-rc.1)

Node JSON RPC API reference

This document provides a complete reference for the Aztec Node JSON RPC API. All methods are exposed via JSON RPC on the node's configured ports.

API endpoint​

Public RPC URL: http://localhost:8080

Admin URL: http://localhost:8880

Note that the above ports are only defaults, and can be modified by setting --port and --admin-port flags upon startup.

All methods use standard JSON RPC 2.0 format with methods prefixed by aztec_ or aztecAdmin_.

Block queries​

aztec_getBlockNumber​

Returns the block number at a given chain tip, or the latest proposed block number when tip is omitted.

Parameters:

  1. tip - ChainTip | undefined

Returns: number

Example:

curl -X POST http://localhost:8080 \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","method":"aztec_getBlockNumber","params":["0x1234..."],"id":1}'

aztec_getCheckpointNumber​

Returns the checkpoint number at a given chain tip, or the latest checkpoint number when tip is omitted.

Remarks: Semantic foot-gun: block-side 'proposed' means "latest proposed block" (chain head), but checkpoint-side 'proposed' means "latest confirmed checkpoint" — pre-L1-confirm checkpoints are not exposed over RPC. 'checkpointed' on the checkpoint side is equivalent.

Parameters:

  1. tip - ChainTip | undefined

Returns: number

Example:

curl -X POST http://localhost:8080 \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","method":"aztec_getCheckpointNumber","params":["0x1234..."],"id":1}'

aztec_getChainTips​

Returns the tips of the L2 chain.

Parameters: None

Returns: ChainTips

Example:

curl -X POST http://localhost:8080 \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","method":"aztec_getChainTips","params":[],"id":1}'

aztec_getL1Constants​

Returns the rollup constants for the current chain.

Parameters: None

Returns: L1RollupConstants

Example:

curl -X POST http://localhost:8080 \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","method":"aztec_getL1Constants","params":[],"id":1}'

aztec_getSyncedL2SlotNumber​

Returns the last L2 slot number for which the node has all L1 data needed to build the next checkpoint.

Parameters: None

Returns: SlotNumber | undefined

Example:

curl -X POST http://localhost:8080 \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","method":"aztec_getSyncedL2SlotNumber","params":[],"id":1}'

aztec_getSyncedL2EpochNumber​

Returns the last L2 epoch number that has been fully synchronized from L1.

Parameters: None

Returns: number | undefined

Example:

curl -X POST http://localhost:8080 \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","method":"aztec_getSyncedL2EpochNumber","params":[],"id":1}'

aztec_getSyncedL1Timestamp​

Returns the latest L1 timestamp according to the archiver's synced L1 view.

Parameters: None

Returns: bigint | undefined

Example:

curl -X POST http://localhost:8080 \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","method":"aztec_getSyncedL1Timestamp","params":[],"id":1}'

aztec_getBlock​

Unified block fetch. Returns the block identified by param, with optional fields controlled by options.

Parameters:

  1. param - BlockHash | number | "latest" - A block number, block hash, archive root, chain-tip name, or object variant.
  2. options - BlockIncludeOptions | undefined - Narrowing options: includeTransactions, includeL1PublishInfo, includeAttestations.

Returns: BlockResponse | undefined

Example:

curl -X POST http://localhost:8080 \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","method":"aztec_getBlock","params":["latest","0x1234..."],"id":1}'

aztec_getBlockData​

Lightweight block-metadata fetch. Returns the block identified by param without transaction bodies or other optional context. Cheaper than getBlock for header-only access.

Parameters:

  1. param - BlockHash | number | "latest" - A block number, block hash, archive root, chain-tip name, or object variant.

Returns: BlockData | undefined

Example:

curl -X POST http://localhost:8080 \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","method":"aztec_getBlockData","params":["latest"],"id":1}'

aztec_getBlocks​

Returns up to limit blocks starting from from, projected to the shape determined by options.

Parameters:

  1. from - number
  2. limit - number
  3. options - BlocksIncludeOptions | undefined

Returns: BlockResponse[]

Example:

curl -X POST http://localhost:8080 \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","method":"aztec_getBlocks","params":[1,100,"0x1234..."],"id":1}'

aztec_getCheckpoint​

Unified checkpoint fetch. Returns the checkpoint identified by param, with optional fields controlled by options.

Parameters:

  1. param - CheckpointParameter
  2. options - CheckpointIncludeOptions | undefined

Returns: CheckpointResponse | undefined

Example:

curl -X POST http://localhost:8080 \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","method":"aztec_getCheckpoint","params":["0x1234...","0x1234..."],"id":1}'

aztec_getCheckpoints​

Returns up to limit checkpoints starting from from, projected to the shape determined by options.

Parameters:

  1. from - number
  2. limit - number
  3. options - CheckpointIncludeOptions | undefined

Returns: CheckpointResponse[]

Example:

curl -X POST http://localhost:8080 \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","method":"aztec_getCheckpoints","params":[1,100,"0x1234..."],"id":1}'

aztec_getCheckpointsData​

Gets lightweight checkpoint metadata for a contiguous range or for an entire epoch.

Parameters:

  1. query - CheckpointsQuery - Either { from, limit } or { epoch }.

Returns: CheckpointData[]

Example:

curl -X POST http://localhost:8080 \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","method":"aztec_getCheckpointsData","params":["0x1234..."],"id":1}'

Transaction operations​

aztec_sendTx​

Method to submit a transaction to the p2p pool.

Parameters:

  1. tx - Tx - The transaction to be submitted.

Returns: void - Nothing.

Example:

curl -X POST http://localhost:8080 \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","method":"aztec_sendTx","params":[{"data":"0x..."}],"id":1}'

aztec_getTxReceipt​

Fetches a transaction receipt for a given transaction hash. Always resolves to one of the lifecycle variants of the union: a if the tx was included in a block, a if it's still in the mempool of the connected Aztec node, or a if not found.

Parameters:

  1. txHash - TxHash - The transaction hash.
  2. options - GetTxReceiptOptions | undefined - Optional flags controlling which extra data is attached: includeTxEffect attaches the full to a mined receipt, includePendingTx attaches the pending to a pending receipt, and includeProof keeps the proof on that attached pending tx (only meaningful with includePendingTx).

Returns: TxReceipt - A receipt of the transaction.

Example:

curl -X POST http://localhost:8080 \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","method":"aztec_getTxReceipt","params":["0x1234...","0x1234..."],"id":1}'

aztec_getTxEffect​

Gets a tx effect.

Deprecated: Use getTxReceipt(txHash, { includeTxEffect: true }) and read the .txEffect field instead.

Parameters:

  1. txHash - TxHash - The hash of the tx corresponding to the tx effect.

Returns: IndexedTxEffect | undefined - The requested tx effect with block info (or undefined if not found).

Example:

curl -X POST http://localhost:8080 \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","method":"aztec_getTxEffect","params":["0x1234..."],"id":1}'

aztec_getTxByHash​

Method to retrieve a single pending tx. The tx's proof is stripped unless includeProof is set.

Parameters:

  1. txHash - TxHash - The transaction hash to return.
  2. options - GetTxByHashOptions | undefined - Options for the returned tx (eg whether to include its proof).

Returns: Tx | undefined - The pending tx if it exists.

Example:

curl -X POST http://localhost:8080 \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","method":"aztec_getTxByHash","params":["0x1234...","0x1234..."],"id":1}'

aztec_getTxsByHash​

Method to retrieve multiple pending txs. The txs' proofs are stripped unless includeProof is set.

Parameters:

  1. txHashes - TxHash[]
  2. options - GetTxByHashOptions | undefined - Options for the returned txs (eg whether to include their proofs).

Returns: Tx[] - The pending txs if exist.

Example:

curl -X POST http://localhost:8080 \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","method":"aztec_getTxsByHash","params":[["0x1234..."],"0x1234..."],"id":1}'

aztec_getPendingTxs​

Method to retrieve pending txs. The txs' proofs are stripped unless includeProof is set.

Parameters:

  1. limit - number | undefined - The number of items to return.
  2. after - TxHash | undefined - The last known pending tx. Used for pagination.
  3. options - GetTxByHashOptions | undefined - Options for the returned txs (eg whether to include their proofs).

Returns: Tx[] - The pending txs.

Example:

curl -X POST http://localhost:8080 \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","method":"aztec_getPendingTxs","params":[100,"0x1234...","0x1234..."],"id":1}'

aztec_getPendingTxCount​

Retrieves the number of pending txs

Parameters: None

Returns: number - The number of pending txs.

Example:

curl -X POST http://localhost:8080 \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","method":"aztec_getPendingTxCount","params":[],"id":1}'

aztec_isValidTx​

Returns true if the transaction is valid for inclusion at the current state. Valid transactions can be made invalid by other transactions if e.g. they emit the same nullifiers, or come become invalid due to e.g. the expiration_timestamp property.

Parameters:

  1. tx - Tx - The transaction to validate for correctness.
  2. options - object | undefined

Returns: TxValidationResult

Example:

curl -X POST http://localhost:8080 \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","method":"aztec_isValidTx","params":[{"data":"0x..."},{}],"id":1}'

aztec_simulatePublicCalls​

Simulates the public part of a transaction with the current state. This currently just checks that the transaction execution succeeds.

Parameters:

  1. tx - Tx - The transaction to simulate.
  2. skipFeeEnforcement - boolean | undefined - If true, fee enforcement is skipped.
  3. overrides - SimulationOverrides | undefined - Optional pre-simulation overrides applied to the ephemeral fork and contract DB (publicStorage writes, contract instance overrides).

Returns: PublicSimulationOutput

Example:

curl -X POST http://localhost:8080 \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","method":"aztec_simulatePublicCalls","params":[{"data":"0x..."},true,"0x1234..."],"id":1}'

State queries​

aztec_getPublicStorageAt​

Gets the storage value at the given contract storage slot.

Remarks: The storage slot here refers to the slot as it is defined in Noir not the index in the merkle tree. Aztec's version of eth_getStorageAt.

Parameters:

  1. referenceBlock - BlockHash | number | "latest" - The block parameter (block number, block hash, or 'latest') at which to get the data.
  2. contract - AztecAddress - Address of the contract to query.
  3. slot - Fr - Slot to query.

Returns: Fr - Storage value at the given contract slot.

Example:

curl -X POST http://localhost:8080 \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","method":"aztec_getPublicStorageAt","params":["latest","0x1234...","0x1234..."],"id":1}'

aztec_getWorldStateSyncStatus​

Returns the sync status of the node's world state

Parameters: None

Returns: WorldStateSyncStatus

Example:

curl -X POST http://localhost:8080 \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","method":"aztec_getWorldStateSyncStatus","params":[],"id":1}'

Membership witnesses​

aztec_findLeavesIndexes​

Find the indexes of the given leaves in the given tree along with a block metadata pointing to the block in which the leaves were inserted.

Parameters:

  1. referenceBlock - BlockHash | number | "latest" - The block parameter (block number, block hash, or 'latest') at which to get the data.
  2. treeId - MerkleTreeId - The tree to search in.
  3. leafValues - Fr[] - The values to search for.

Returns: (DataInBlock<bigint> | undefined)[] - The indices of leaves and the block metadata of a block in which the leaves were inserted.

Example:

curl -X POST http://localhost:8080 \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","method":"aztec_findLeavesIndexes","params":["latest",1,["0x1234..."]],"id":1}'

aztec_getNullifierMembershipWitness​

Returns a nullifier membership witness for a given nullifier at a given block.

Parameters:

  1. referenceBlock - BlockHash | number | "latest" - The block parameter (block number, block hash, or 'latest') at which to get the data.
  2. nullifier - Fr - Nullifier we try to find witness for.

Returns: NullifierMembershipWitness | undefined - The nullifier membership witness (if found).

Example:

curl -X POST http://localhost:8080 \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","method":"aztec_getNullifierMembershipWitness","params":["latest","0x1234..."],"id":1}'

aztec_getLowNullifierMembershipWitness​

Returns a low nullifier membership witness for a given nullifier at a given block.

Remarks: Low nullifier witness can be used to perform a nullifier non-inclusion proof by leveraging the "linked list structure" of leaves and proving that a lower nullifier is pointing to a bigger next value than the nullifier we are trying to prove non-inclusion for.

Parameters:

  1. referenceBlock - BlockHash | number | "latest" - The block parameter (block number, block hash, or 'latest') at which to get the data.
  2. nullifier - Fr - Nullifier we try to find the low nullifier witness for.

Returns: NullifierMembershipWitness | undefined - The low nullifier membership witness (if found).

Example:

curl -X POST http://localhost:8080 \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","method":"aztec_getLowNullifierMembershipWitness","params":["latest","0x1234..."],"id":1}'

aztec_getPublicDataWitness​

Returns a public data tree witness for a given leaf slot at a given block.

Remarks: The witness can be used to compute the current value of the public data tree leaf. If the low leaf preimage corresponds to an "in range" slot, means that the slot doesn't exist and the value is 0. If the low leaf preimage corresponds to the exact slot, the current value is contained in the leaf preimage.

Parameters:

  1. referenceBlock - BlockHash | number | "latest" - The block parameter (block number, block hash, or 'latest') at which to get the data.
  2. leafSlot - Fr - The leaf slot we try to find the witness for.

Returns: PublicDataWitness | undefined - The public data witness (if found).

Example:

curl -X POST http://localhost:8080 \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","method":"aztec_getPublicDataWitness","params":["latest","0x1234..."],"id":1}'

aztec_getBlockHashMembershipWitness​

Returns a membership witness for a given block hash in the archive tree.

Block hashes are the leaves of the archive tree. Each time a new block is added to the chain, its block hash is appended as a new leaf to the archive tree. This method finds the membership witness (leaf index and sibling path) for a given block hash, which can be used to prove that a specific block exists in the chain's history.

Parameters:

  1. referenceBlock - BlockHash | number | "latest" - The block parameter (block number, block hash, or 'latest') at which to get the data (which contains the root of the archive tree in which we are searching for the block hash).
  2. blockHash - BlockHash - The block hash to find in the archive tree.

Returns: MembershipWitness | undefined

Example:

curl -X POST http://localhost:8080 \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","method":"aztec_getBlockHashMembershipWitness","params":["latest","0x1234..."],"id":1}'

aztec_getNoteHashMembershipWitness​

Returns a membership witness for a given note hash at a given block.

Parameters:

  1. referenceBlock - BlockHash | number | "latest" - The block parameter (block number, block hash, or 'latest') at which to get the data.
  2. noteHash - Fr - The note hash we try to find the witness for.

Returns: MembershipWitness | undefined

Example:

curl -X POST http://localhost:8080 \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","method":"aztec_getNoteHashMembershipWitness","params":["latest","0x1234..."],"id":1}'

L1 to L2 messages​

aztec_getL1ToL2MessageMembershipWitness​

Returns the index and a sibling path for a leaf in the committed l1 to l2 data tree.

Parameters:

  1. referenceBlock - BlockHash | number | "latest" - The block parameter (block number, block hash, or 'latest') at which to get the data.
  2. l1ToL2Message - Fr - The l1ToL2Message to get the index / sibling path for.

Returns: [bigint, SiblingPath] | undefined - A tuple of the index and the sibling path of the L1ToL2Message (undefined if not found).

Example:

curl -X POST http://localhost:8080 \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","method":"aztec_getL1ToL2MessageMembershipWitness","params":["latest","0x1234..."],"id":1}'

aztec_getL1ToL2MessageCheckpoint​

Returns the L2 checkpoint number in which this L1 to L2 message becomes available, or undefined if not found.

Parameters:

  1. l1ToL2Message - Fr

Returns: number | undefined

Example:

curl -X POST http://localhost:8080 \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","method":"aztec_getL1ToL2MessageCheckpoint","params":["0x1234..."],"id":1}'

aztec_getL2ToL1MembershipWitness​

Returns the L2-to-L1 membership witness for message emitted by tx txHash. The node selects the smallest partial-proof root on the Outbox that covers the tx's checkpoint and builds the witness against it.

The node reads the Outbox roots lazily, pinned to its synced L1 block, so the witness reflects the node's synced view. Returns undefined if the tx isn't yet in a block/epoch or no covering root has landed on L1 as of the synced block.

Caveat: cached roots that are sealed and L1-finalized are not re-validated. A reorg deeper than L1 finality could leave the node serving a witness against a no-longer-canonical root.

Parameters:

  1. txHash - TxHash - The tx whose L2-to-L1 message we want a witness for.
  2. message - Fr - The message hash to prove inclusion of.
  3. messageIndexInTx - object | undefined - Optional index of the message within the tx's L2-to-L1 messages; pass this when the same message hash appears multiple times in the tx.

Returns: L2ToL1MembershipWitness | undefined

Example:

curl -X POST http://localhost:8080 \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","method":"aztec_getL2ToL1MembershipWitness","params":["0x1234...","0x1234...",{}],"id":1}'

aztec_getL2ToL1Messages​

Returns all the L2 to L1 messages in an epoch.

Deprecated: Use to get an L2-to-L1 message witness directly.

Parameters:

  1. epoch - number - The epoch at which to get the data.

Returns: Fr[][][][] - A nested array of the L2 to L1 messages in each tx of each block in each checkpoint in the epoch (empty array if the epoch is not found).

Example:

curl -X POST http://localhost:8080 \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","method":"aztec_getL2ToL1Messages","params":[12345],"id":1}'

Log queries​

aztec_getPrivateLogsByTags​

Gets private logs matching the given tags. Returns one inner array per element of query.tags, in input order. An empty inner array means no logs matched that tag. Set query.includeEffects to also receive the tx's note hashes and nullifiers.

The return type is the widest shape — noteHashes/nullifiers are typed as optional even when includeEffects: true is set. JSON-RPC validation can't preserve a stricter narrowing across the wire. Callers that want a narrowed type at the call site should use the typed helpers in pxe/src/tagging/get_all_logs_by_tags.ts.

Parameters:

  1. query - PrivateLogsQuery

Returns: LogResult[][]

Example:

curl -X POST http://localhost:8080 \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","method":"aztec_getPrivateLogsByTags","params":["0x1234..."],"id":1}'

aztec_getPublicLogsByTags​

Gets public logs matching the given tags for the given contract. Returns one inner array per element of query.tags, in input order. An empty inner array means no logs matched that tag. Set query.includeEffects to also receive the tx's note hashes and nullifiers.

The return type is the widest shape — see .

Parameters:

  1. query - PublicLogsQuery

Returns: LogResult[][]

Example:

curl -X POST http://localhost:8080 \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","method":"aztec_getPublicLogsByTags","params":["0x1234..."],"id":1}'

Contract queries​

aztec_getContractClass​

Returns a registered contract class given its id.

Parameters:

  1. id - Fr - Id of the contract class.

Returns: ContractClassPublic | undefined

Example:

curl -X POST http://localhost:8080 \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","method":"aztec_getContractClass","params":["0x1234..."],"id":1}'

aztec_getContract​

Returns a publicly deployed contract instance given its address.

Parameters:

  1. address - AztecAddress - Address of the deployed contract.

Returns: ContractInstanceWithAddress | undefined

Example:

curl -X POST http://localhost:8080 \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","method":"aztec_getContract","params":["0x1234..."],"id":1}'

Fee queries​

aztec_getCurrentMinFees​

Method to fetch the current min fees.

Parameters: None

Returns: GasFees - The current min fees.

Example:

curl -X POST http://localhost:8080 \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","method":"aztec_getCurrentMinFees","params":[],"id":1}'

aztec_getPredictedMinFees​

Returns predicted min fees for the current slot and next N slots. Each entry accounts for the L1 gas oracle transition and congestion growth based on the given mana usage estimate. Defaults to target usage (steady state).

Parameters:

  1. manaUsage - ManaUsageEstimate | undefined - Expected mana usage per checkpoint (none, target, or limit).

Returns: GasFees[] - An array of GasFees with current min fees first, followed by one entry per predicted slot.

Example:

curl -X POST http://localhost:8080 \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","method":"aztec_getPredictedMinFees","params":["target"],"id":1}'

aztec_getMaxPriorityFees​

Method to fetch the current max priority fee of txs in the mempool.

Parameters: None

Returns: GasFees - The current max priority fees.

Example:

curl -X POST http://localhost:8080 \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","method":"aztec_getMaxPriorityFees","params":[],"id":1}'

Node information​

aztec_isReady​

Method to determine if the node is ready to accept transactions.

Parameters: None

Returns: boolean - Flag indicating the readiness for tx submission.

Example:

curl -X POST http://localhost:8080 \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","method":"aztec_isReady","params":[],"id":1}'

aztec_getNodeInfo​

Returns the information about the server's node. Includes current Node version, compatible Noir version, L1 chain identifier, protocol version, and L1 address of the rollup contract.

Parameters: None

Returns: NodeInfo - The node information.

Example:

curl -X POST http://localhost:8080 \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","method":"aztec_getNodeInfo","params":[],"id":1}'

aztec_getNodeVersion​

Method to fetch the version of the package.

Parameters: None

Returns: string - The node package version

Example:

curl -X POST http://localhost:8080 \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","method":"aztec_getNodeVersion","params":[],"id":1}'

aztec_getVersion​

Method to fetch the version of the rollup the node is connected to.

Parameters: None

Returns: number - The rollup version.

Example:

curl -X POST http://localhost:8080 \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","method":"aztec_getVersion","params":[],"id":1}'

aztec_getChainId​

Method to fetch the chain id of the base-layer for the rollup.

Parameters: None

Returns: number - The chain id.

Example:

curl -X POST http://localhost:8080 \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","method":"aztec_getChainId","params":[],"id":1}'

aztec_getL1ContractAddresses​

Method to fetch the currently deployed l1 contract addresses.

Parameters: None

Returns: L1ContractAddresses - The deployed contract addresses.

Example:

curl -X POST http://localhost:8080 \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","method":"aztec_getL1ContractAddresses","params":[],"id":1}'

aztec_getProtocolContractAddresses​

Method to fetch the protocol contract addresses.

Parameters: None

Returns: ProtocolContractAddresses

Example:

curl -X POST http://localhost:8080 \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","method":"aztec_getProtocolContractAddresses","params":[],"id":1}'

aztec_getEncodedEnr​

Returns the ENR of this node for peer discovery, if available.

Parameters: None

Returns: string | undefined

Example:

curl -X POST http://localhost:8080 \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","method":"aztec_getEncodedEnr","params":[],"id":1}'

Validator queries​

aztec_getValidatorsStats​

Returns stats for validators if enabled.

Parameters: None

Returns: ValidatorsStats

Example:

curl -X POST http://localhost:8080 \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","method":"aztec_getValidatorsStats","params":[],"id":1}'

aztec_getValidatorStats​

Returns stats for a single validator if enabled.

Parameters:

  1. validatorAddress - EthAddress
  2. fromSlot - SlotNumber | undefined
  3. toSlot - SlotNumber | undefined

Returns: SingleValidatorStats | undefined

Example:

curl -X POST http://localhost:8080 \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","method":"aztec_getValidatorStats","params":["0x1234...","100","100"],"id":1}'

P2P queries​

aztec_getPeers​

Returns info for all connected, dialing, and cached peers. Only available when P2P is enabled.

Parameters:

  1. includePending - boolean | undefined - If true, also include peers in the pending state.

Returns: PeerInfo[]

Example:

curl -X POST http://localhost:8080 \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","method":"aztec_getPeers","params":[true],"id":1}'

aztec_getCheckpointAttestationsForSlot​

Queries the attestation pool for checkpoint attestations for the given slot.

Parameters:

  1. slot - SlotNumber - The slot to query.
  2. proposalPayloadHash - string | undefined - Hex-encoded keccak256 of the target proposal's signed payload hash. When provided, only attestations whose payload hash matches are returned. When omitted, all attestations for the slot are returned.

Returns: CheckpointAttestation[]

Example:

curl -X POST http://localhost:8080 \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","method":"aztec_getCheckpointAttestationsForSlot","params":["100","0x1234..."],"id":1}'

aztec_getProposalsForSlot​

Returns block and checkpoint proposals retained in the attestation pool for the given slot. Only available when P2P is enabled.

Parameters:

  1. slot - SlotNumber

Returns: ProposalsForSlot

Example:

curl -X POST http://localhost:8080 \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","method":"aztec_getProposalsForSlot","params":["100"],"id":1}'

Debug operations​

aztec_registerContractFunctionSignatures​

Registers contract function signatures for debugging purposes.

Parameters:

  1. functionSignatures - string[] - An array of function signatures to register by selector.

Returns: void

Example:

curl -X POST http://localhost:8080 \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","method":"aztec_registerContractFunctionSignatures","params":[["0x1234..."]],"id":1}'

aztec_getAllowedPublicSetup​

Returns the list of allowed public setup elements configured for this node.

Parameters: None

Returns: AllowedElement[] - The list of allowed elements.

Example:

curl -X POST http://localhost:8080 \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","method":"aztec_getAllowedPublicSetup","params":[],"id":1}'

Admin API​

Administrative operations are exposed on port 8880 under the aztecAdmin_ namespace.

Security: Admin API Access

For security reasons, the admin port (8880) should not be exposed to the host machine in Docker deployments. The examples below show both CLI and Docker methods:

CLI Method (when running with aztec start directly):

curl -X POST http://localhost:8880 ...

Docker Method (when running with Docker Compose):

docker exec -it <container-name> curl -X POST http://localhost:8880 ...

Replace <container-name> with your container name (e.g., aztec-node, aztec-sequencer, prover-node).

aztecAdmin_getConfig​

Retrieves the configuration of this node.

Parameters: None

Returns: AztecNodeAdminConfig

Example (CLI):

curl -X POST http://localhost:8880 \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","method":"aztecAdmin_getConfig","params":[],"id":1}'

Example (Docker):

docker exec -it aztec-node curl -X POST http://localhost:8880 \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","method":"aztecAdmin_getConfig","params":[],"id":1}'

aztecAdmin_setConfig​

Updates the configuration of this node.

Parameters:

  1. config - object - Updated configuration to be merged with the current one.

Returns: void

Example (CLI):

curl -X POST http://localhost:8880 \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","method":"aztecAdmin_setConfig","params":[{}],"id":1}'

Example (Docker):

docker exec -it aztec-node curl -X POST http://localhost:8880 \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","method":"aztecAdmin_setConfig","params":[{}],"id":1}'

aztecAdmin_pauseSync​

Pauses archiver and world state syncing.

Parameters: None

Returns: void

Example (CLI):

curl -X POST http://localhost:8880 \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","method":"aztecAdmin_pauseSync","params":[],"id":1}'

Example (Docker):

docker exec -it aztec-node curl -X POST http://localhost:8880 \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","method":"aztecAdmin_pauseSync","params":[],"id":1}'

aztecAdmin_resumeSync​

Resumes archiver and world state syncing.

Parameters: None

Returns: void

Example (CLI):

curl -X POST http://localhost:8880 \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","method":"aztecAdmin_resumeSync","params":[],"id":1}'

Example (Docker):

docker exec -it aztec-node curl -X POST http://localhost:8880 \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","method":"aztecAdmin_resumeSync","params":[],"id":1}'

aztecAdmin_pauseSequencer​

Pauses block production. Pending txs remain in the mempool; no new blocks will be produced until is called. Throws if no sequencer is running.

Parameters: None

Returns: void

Example (CLI):

curl -X POST http://localhost:8880 \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","method":"aztecAdmin_pauseSequencer","params":[],"id":1}'

Example (Docker):

docker exec -it aztec-node curl -X POST http://localhost:8880 \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","method":"aztecAdmin_pauseSequencer","params":[],"id":1}'

aztecAdmin_resumeSequencer​

Resumes block production previously paused via .

Parameters: None

Returns: void

Example (CLI):

curl -X POST http://localhost:8880 \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","method":"aztecAdmin_resumeSequencer","params":[],"id":1}'

Example (Docker):

docker exec -it aztec-node curl -X POST http://localhost:8880 \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","method":"aztecAdmin_resumeSequencer","params":[],"id":1}'

aztecAdmin_rollbackTo​

Pauses syncing and rolls back the database to the target L2 block number.

Parameters:

  1. targetBlockNumber - number - The block number to roll back to.
  2. force - boolean | undefined - If true, clears the world state db and p2p dbs if rolling back to behind the finalized block.
  3. resumeSync - boolean | undefined - If true (default), resumes archiver and world state sync after rollback.

Returns: void

Example (CLI):

curl -X POST http://localhost:8880 \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","method":"aztecAdmin_rollbackTo","params":[12345,true,true],"id":1}'

Example (Docker):

docker exec -it aztec-node curl -X POST http://localhost:8880 \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","method":"aztecAdmin_rollbackTo","params":[12345,true,true],"id":1}'

aztecAdmin_startSnapshotUpload​

Pauses syncing, creates a backup of archiver and world-state databases, and uploads them. Returns immediately.

Parameters:

  1. location - string - The location to upload the snapshot to.

Returns: void

Example (CLI):

curl -X POST http://localhost:8880 \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","method":"aztecAdmin_startSnapshotUpload","params":["0x1234..."],"id":1}'

Example (Docker):

docker exec -it aztec-node curl -X POST http://localhost:8880 \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","method":"aztecAdmin_startSnapshotUpload","params":["0x1234..."],"id":1}'

aztecAdmin_getSlashOffenses​

Returns all offenses applicable for the given round.

Parameters:

  1. round - bigint | 'all' | 'current'

Returns: Offense[]

Example (CLI):

curl -X POST http://localhost:8880 \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","method":"aztecAdmin_getSlashOffenses","params":["current"],"id":1}'

Example (Docker):

docker exec -it aztec-node curl -X POST http://localhost:8880 \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","method":"aztecAdmin_getSlashOffenses","params":["current"],"id":1}'

aztecAdmin_reloadKeystore​

Reloads keystore configuration from disk.

What is updated:

  • Validator attester keys
  • Coinbase address per validator
  • Fee recipient address per validator

What is NOT updated (requires node restart):

  • L1 publisher signers (the funded accounts that send L1 transactions)
  • Prover keys
  • HA signer PostgreSQL connections

Notes:

  • New validators must use a publisher key that was already configured at node startup (or omit the publisher field to fall back to the attester key). A validator with an unknown publisher key will cause the reload to be rejected.

Parameters: None

Returns: void

Example (CLI):

curl -X POST http://localhost:8880 \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","method":"aztecAdmin_reloadKeystore","params":[],"id":1}'

Example (Docker):

docker exec -it aztec-node curl -X POST http://localhost:8880 \
-H 'Content-Type: application/json' \
-d '{"jsonrpc":"2.0","method":"aztecAdmin_reloadKeystore","params":[],"id":1}'

Next steps​