State queries are read-only JSON-RPC methods that inspect the chain’s state at the latest finalised block (default) or at a specified historical height. Reads do not consume gas and are not rate-limited beyond the global RPC limit.

Accounts and balances

MethodReturns
sigil_getBalanceNative balance for a DID.
sigil_getAccountFull account record (balance, nonce, bonded stake, mandates).
sigil_getAccountAtAccount record at a specified height.
curl -s https://rpc.sigil.ml/rpc \
  -H 'content-type: application/json' \
  -d '{
    "jsonrpc":"2.0","id":1,
    "method":"sigil_getBalance",
    "params":{"did":"did:oas:sigil:agent:alice"}
  }'

Validators and staking

MethodReturns
sigil_getValidatorsActive and candidate validator set.
sigil_getValidatorA single validator’s full record.
sigil_getDelegationsAll delegations for a delegator DID.
sigil_getEpochCurrent epoch number and remaining blocks.
sigil_getNetworkActivationStatusActivation phase, block height, eligible stake.

DEX

MethodReturns
sigil_getDexPoolSingle pool record by pool id.
sigil_listDexPoolsPaginated list of pools.
sigil_getDexPositionLP position for a DID and pool.
sigil_quoteDexSwapExactInQuote for an exact-in swap.
sigil_quoteDexSwapExactOutQuote for an exact-out swap.

Names and usernames

MethodReturns
sigil_resolveNameResolve <name>.sigil to records.
sigil_getNameRecordsAll resolver records for a name.
sigil_resolveMailResolve a name to its mailbox policy.
sigil_resolveWebsiteResolve a name to its website record.
sigil_resolveUsernameResolve @username to a DID record.
sigil_lookupUsernameReverse-lookup a DID’s primary username.

NFTs

MethodReturns
sigil_getCollectionCollection record.
sigil_listCollectionsByCreatorCollections created by a DID.
sigil_getNftA single NFT record.
sigil_listNftsByOwnerNFTs owned by a DID.

Mail

MethodReturns
sigil_getMailboxMailbox capability record.
sigil_getMailPolicyVersioned receive policy for a mailbox.
sigil_listDeliveriesDelivery commitments for a mailbox.
sigil_getMailKeyActive signing or encryption key for a DID.

Compute and storage markets

MethodReturns
sigil_listComputeProvidersActive compute providers.
sigil_getComputeJobJob state and receipts.
sigil_listStorageProvidersActive storage providers.
sigil_getStoragePinContractPin contract record.
sigil_getStorageChallengeStorage challenge record.

Labor

MethodReturns
sigil_listLaborOffersOpen named contracts and bounty offers.
sigil_getLaborContractA single contract record.
sigil_getLaborDisputeDispute record.

Vigils

MethodReturns
sigil_getVigilSubscriptionSubscription record.
sigil_listIngestorsActive ingestors.
sigil_getVigilDeliveryDelivery record by (subscription_id, event_id).

Historical reads

Most methods accept an optional at_height parameter to read state at a specific finalised block:
{
  "jsonrpc":"2.0","id":1,
  "method":"sigil_getBalance",
  "params":{"did":"did:oas:sigil:agent:alice", "at_height": 1000000}
}
Historical reads are answered by the LSM tree’s MVCC layer without blocking writes. Reads at heights older than the snapshot horizon may require an archive node; query sigil_getNodeInfo to confirm mode = "archive" before relying on deep history. The canonical method table is node/sigil-rpc/src/methods.rs and is asserted by node/sigil-node/tests/rpc_conformance.rs.