RPC queries and synchronization
This page assumes the deployment binding and URL configuration in the service overview. Every method reads the selected chain; there is no cross-chain fallback.
Requests and integer encoding
POST to /v1/chains/{chainId} with Content-Type: application/json. Parameters are positional arrays; zero-argument methods use []. Use a non-null string or numeric id to correlate responses.
{"jsonrpc":"2.0","id":"status-1","method":"invisi_getStatus","params":[]}
Addresses are 20-byte 0x hex. Hashes, commitments, roots, and nullifiers are full 32-byte hex, never abbreviated integers. Block and tree-index arguments are JSON integers; chain IDs are decimal strings. ABI uint256/uint64 event values and settlement-operation integers are decimal strings. Use an integer-preserving JSON parser when needed to avoid JavaScript Number truncation of uint64 values.
Select a method
The parameter column is the content of params. The complete range shape follows below.
| Method | Parameters | Purpose |
|---|---|---|
invisi_getVersion / invisi_getDeployment / invisi_getStatus | [] | Versions, deployment, index, and native finality |
invisi_getBlock | [number] | Complete indexed block batch, or null before indexing |
invisi_getEvents | [range] | Decoded protocol events |
invisi_getRoots | [treeId] | Physical roots, at most 10,000, without a cursor |
invisi_getMembership | [treeId,leafIndex,root] | Membership with anchor and 16 siblings |
invisi_getNote | [commitment,atBlock] | Ordinary Note and membership, or null |
invisi_getNoteUpdates | [range] | Ordinary Note outputs as {blockHash,notes} |
invisi_getTransactionNoteUpdates | [transactionHash] | One transaction's ordinary Note outputs and availability |
invisi_isNoteSpent | [nullifier,atBlock] | Ordinary Note consumption |
invisi_getCreditState | [commitment,atBlock] | Credit state and membership, or null |
invisi_getCreditTransitions | [range] | Credit transition events |
invisi_getTransactionCreditUpdates | [transactionHash] | One transaction's states and transitions |
invisi_isCreditConsumed | [nullifier,atBlock] | Credit state consumption |
invisi_getCreditAllocation | [owner,token,atBlock] | Next original-grant shard / slot |
invisi_getCreditRevocationBitmap | [owner,token,shard,word,atBlock] | Original-grant revocation bitmap; shard is a positive decimal string |
invisi_getReceivingAddress | [ownerAddress] | Registered viewing public key, clueKey, nonce, and block, or null |
invisi_getBroadcasters | [{enabled?,after?,limit?,block?}] | Service discovery at a fixed snapshot |
invisi_getSettlementOperations / invisi_getProtocolTransactions | [{limit,fromBlock?,toBlock?,cursor?}] | Canonical logical-operation pages |
invisi_getTransactionOperations | [transactionHash] | One transaction's operations and status |
invisi_readChainState | [{kind,...}] | Restricted chain-read gateway |
Legacy invisi_getUpdates, invisi_getTransactionUpdates, invisi_detectOutputs, and invisi_isSpent are removed. Never send a detection key to the service.
Block synchronization and reorgs
A range is {fromBlock:100,toBlock:110,blockHash:"full hash of block 110"}. Bounds are inclusive, and the end hash must match indexed toBlock. Obtain a trusted end anchor, read the range, then atomically save the block number, hash, and recovery progress after local processing.
A request covers at most 10,000 blocks and an 8 MiB ranged response. Event queries conservatively reject at 10,000 records; Note output queries reject above 10,000. Limits produce errors rather than silent truncation. Narrow the range; this interface has no range-continuation cursor. When anchor validation fails, discard orphan-derived data and resume from a still-trusted anchor.
Settlement operation pages
This read-only continuation example requires a POSIX shell, curl, and the full chain-route variable PROTOCOL_RPC_URL. It reads up to 20 logical operations against the current indexed snapshot.
: "${PROTOCOL_RPC_URL:?Set the full trusted chain RPC URL}"
curl --fail-with-body -sS "$PROTOCOL_RPC_URL" \
-H 'Content-Type: application/json' \
--data '{"jsonrpc":"2.0","id":3,"method":"invisi_getSettlementOperations","params":[{"limit":20}]}'
Results include operations, snapshot, indexedHead, and optional nextCursor. Required limit is 1–100. Continue with the unchanged cursor and limit, omitting fromBlock/toBlock. Follow even an empty page until nextCursor is absent. Each page has a work budget of 16 blocks and 256 relevant receipts, so limit does not determine the page count.
Operations separate Note/Credit outputs and nullifiers. funding is public gross funding, not the receiver's net amount; private output amounts may be absent. invisi_getProtocolTransactions also returns logical operations; group by txHash for transaction rows. An operation with unsupportedReason must not be recognized as accepted settlement. Complete discovery of indirect reverted calls requires traces.
Registry records and gateway
Broadcaster pagination defaults to a maximum limit of 100. Pass next unchanged as after, together with the previous top-level block and the same enabled filter. A record's block is its last update; the top-level block anchors pagination. Registration and enabled status establish neither health, reputation, nor arbitrary token support.
invisi_readChainState supports restricted header, code, call, transaction, and receipt queries. Only pinned Protocol/Registry reads, selected Protocol simulations, and limited ERC20 methods are permitted. It neither submits transactions nor independently authenticates a node. Use the matching SDK's TrustedProvider adapter rather than treating this as unrestricted eth_call forwarding.