Skip to main content

Complete API reference

Generated by tools/generate_documentation.py. Do not edit this page by hand.

This reference is generated from the installed Python classes and the stable RPC result registry. Parameters are positional on the wire even when Python callers use keyword arguments.

Conventions

  • RPC methods perform I/O and return a validated typed result.
  • AccountBlock builder methods are synchronous, perform no I/O, and return an unsigned block.
  • Subscription helper methods require WsClient and return an async iterator.
  • Page indices are zero-based unless a method explicitly accepts a block height.
  • Decimal-string RPC results are converted to arbitrary-precision Python int values.

LedgerApi

Account blocks, momentums, balances, and transaction publication.

Import: znn.api.ledger.LedgerApi

Constructor: LedgerApi(ws_client=None)

Python signatureKindWire methodDeclared result
async publish_raw_transaction(account_block: znn.model.nom.account_block.AccountBlock)RPCledger.publishRawTransactionnull
async get_unconfirmed_blocks_by_address(address: str, page_index=0, page_size=50)RPCledger.getUnconfirmedBlocksByAddressAccountBlockList
async get_unreceived_blocks_by_address(address: str, page_index=0, page_size=50)RPCledger.getUnreceivedBlocksByAddressAccountBlockList
async get_frontier_account_block(address: str)RPCledger.getFrontierAccountBlockAccountBlock or null
async get_account_block_by_hash(hashstr: str)RPCledger.getAccountBlockByHashAccountBlock or null
async get_account_blocks_by_height(address: str, height=1, count=1024)RPCledger.getAccountBlocksByHeightAccountBlockList
async get_account_blocks_by_page(address: str, page_index=0, page_size=1024)RPCledger.getAccountBlocksByPageAccountBlockList
async get_frontier_momentum()RPCledger.getFrontierMomentumMomentum
async get_momentum_before_time(time: int)RPCledger.getMomentumBeforeTimeMomentum or null
async get_momentum_by_hash(hashstr: str)RPCledger.getMomentumByHashMomentum or null
async get_momentums_by_page(page_index=0, page_size=1024)RPCledger.getMomentumsByPageMomentumList
async get_momentums_by_height(height=1, count=1024)RPCledger.getMomentumsByHeightMomentumList
async get_detailed_momentums_by_height(height=1, count=1024)RPCledger.getDetailedMomentumsByHeightDetailedMomentumList or null
async get_account_info_by_address(address: str)RPCledger.getAccountInfoByAddressAccountInfo or null

StatsApi

Node operating-system, process, network, and synchronization state.

Import: znn.api.stats.StatsApi

Constructor: StatsApi(ws_client=None)

Python signatureKindWire methodDeclared result
async os_info()RPCstats.osInfoOsInfo
async process_info()RPCstats.processInfoProcessInfo
async network_info()RPCstats.networkInfoNetworkInfo
async sync_info()RPCstats.syncInfoSyncInfo

SubscribeApi

Canonical WebSocket subscription topics and normalized async iterators.

Import: znn.api.subscribe.SubscribeApi

Constructor: SubscribeApi(ws_client=None)

Python signatureKindWire methodDeclared result
async subscribe_to(topic: str, address: str | None = None)Subscription helperledger.subscribeSubscription
async to_momentums()Subscription helperSubscription
async to_all_account_blocks()Subscription helperSubscription
async to_account_blocks_by_address(address: str)Subscription helperSubscription
async to_unreceived_account_blocks_by_address(address: str)Subscription helperSubscription

AcceleratorApi

Accelerator projects, phases, votes, donations, and updates.

Import: znn.api.embedded.accelerator.AcceleratorApi

Constructor: AcceleratorApi(ws_client=None)

Python signatureKindWire methodDeclared result
async get_all(page_index=0, page_size=1024)RPCembedded.accelerator.getAllProjectList
async get_account_blocks_by_page(page_index=0, page_size=1024)Compatibility aliasSame as canonical method
async get_project_by_id(project_id: str)RPCembedded.accelerator.getProjectByIdProject
async get_phase_by_id(phase_id: str)RPCembedded.accelerator.getPhaseByIdPhase
async get_pillar_votes(name: str, hashes)RPCembedded.accelerator.getPillarVotesarray
async get_vote_breakdown(hash_id: str)RPCembedded.accelerator.getVoteBreakdownVoteBreakdown
create_project(name: str, description: str, url: str, znn_funds_needed: int, qsr_funds_needed: int)AccountBlock builderAccountBlock
add_phase(hash_id: znn.model.primitives.hash.Hash, name: str, description: str, url: str, znn_funds_needed: int, qsr_funds_needed: int)AccountBlock builderAccountBlock
update_phase(hash_id: znn.model.primitives.hash.Hash, name: str, description: str, url: str, znn_funds_needed: int, qsr_funds_needed: int)AccountBlock builderAccountBlock
donate(amount: int, zts: znn.model.primitives.token_standard.TokenStandard)AccountBlock builderAccountBlock
vote_by_name(hash_id: znn.model.primitives.hash.Hash, pillar_name: str, vote: int)AccountBlock builderAccountBlock
vote_by_prod_address(hash_id: znn.model.primitives.hash.Hash, vote: int)AccountBlock builderAccountBlock

BridgeApi

Bridge networks, wrap/unwrap requests, security, and administration.

Import: znn.api.embedded.bridge.BridgeApi

Constructor: BridgeApi(ws_client=None)

Python signatureKindWire methodDeclared result
async get_all_networks(page_index=0, page_size=1024)RPCembedded.bridge.getAllNetworksBridgeNetworkInfoList
async get_all_unsigned_wrap_token_requests(page_index=0, page_size=1024)RPCembedded.bridge.getAllUnsignedWrapTokenRequestsWrapTokenRequestList
async get_all_unwrap_token_requests(page_index=0, page_size=1024)RPCembedded.bridge.getAllUnwrapTokenRequestsUnwrapTokenRequestList
async get_all_unwrap_token_requests_by_to_address(to_address: str, page_index=0, page_size=1024)RPCembedded.bridge.getAllUnwrapTokenRequestsByToAddressUnwrapTokenRequestList
async get_all_wrap_token_requests(page_index=0, page_size=1024)RPCembedded.bridge.getAllWrapTokenRequestsWrapTokenRequestList
async get_all_wrap_token_requests_by_to_address(to_address: str, page_index=0, page_size=1024)RPCembedded.bridge.getAllWrapTokenRequestsByToAddressWrapTokenRequestList
async get_all_wrap_token_requests_by_to_address_network_class_and_chain_id(to_address: str, network_class: int, chain_id: int, page_index=0, page_size=1024)RPCembedded.bridge.getAllWrapTokenRequestsByToAddressNetworkClassAndChainIdWrapTokenRequestList
async get_bridge_info()RPCembedded.bridge.getBridgeInfoBridgeInfo
async get_fee_token_pair(zts: znn.model.primitives.token_standard.TokenStandard)RPCembedded.bridge.getFeeTokenPairZtsFeesInfo
async get_network_info(network_class: int, chain_id: int)RPCembedded.bridge.getNetworkInfoBridgeNetworkInfo
async get_orchestrator_info()RPCembedded.bridge.getOrchestratorInfoOrchestratorInfo
async get_security_info()RPCembedded.bridge.getSecurityInfoSecurityInfo
async get_time_challenges_info()RPCembedded.bridge.getTimeChallengesInfoTimeChallengesList
async get_unwrap_token_request_by_hash_and_log(tx_hash: znn.model.primitives.hash.Hash, log_index: int)RPCembedded.bridge.getUnwrapTokenRequestByHashAndLogUnwrapTokenRequest
async get_wrap_token_request_by_id(id: znn.model.primitives.hash.Hash)RPCembedded.bridge.getWrapTokenRequestByIdWrapTokenRequest
change_administrator(administrator: znn.model.primitives.address.Address)AccountBlock builderAccountBlock
change_tss_e_c_d_s_a_pub_key(pub_key: str, old_pub_key_signature: str, new_pub_key_signature: str)AccountBlock builderAccountBlock
emergency()AccountBlock builderAccountBlock
halt(signature: str)AccountBlock builderAccountBlock
nominate_guardians(guardians: list)AccountBlock builderAccountBlock
propose_administrator(address: znn.model.primitives.address.Address)AccountBlock builderAccountBlock
redeem(transaction_hash: znn.model.primitives.hash.Hash, log_index: int)AccountBlock builderAccountBlock
remove_network(network_class: int, chain_id: int)AccountBlock builderAccountBlock
remove_token_pair(network_class: int, chain_id: int, token_standard: znn.model.primitives.token_standard.TokenStandard, token_address: str)AccountBlock builderAccountBlock
revoke_unwrap_request(transaction_hash: znn.model.primitives.hash.Hash, log_index: int)AccountBlock builderAccountBlock
set_allow_key_gen(allow_key_gen: bool)AccountBlock builderAccountBlock
set_bridge_metadata(metadata: str)AccountBlock builderAccountBlock
set_network(network_class: int, chain_id: int, name: str, contract_address: str, metadata: str)AccountBlock builderAccountBlock
set_network_metadata(network_class: int, chain_id: int, metadata: str)AccountBlock builderAccountBlock
set_orchestrator_info(window_size: int, key_gen_threshold: int, confirmations_to_finality: int, estimated_momentum_time: int)AccountBlock builderAccountBlock
set_token_pair(network_class: int, chain_id: int, token_standard: znn.model.primitives.token_standard.TokenStandard, token_address: str, bridgeable: bool, redeemable: bool, owned: bool, min_amount: int, fee_percentage: int, redeem_delay: int, metadata: str)AccountBlock builderAccountBlock
unhalt()AccountBlock builderAccountBlock
unwrap_token(network_class: int, chain_id: int, transaction_hash: znn.model.primitives.hash.Hash, log_index: int, to_address: znn.model.primitives.address.Address, token_address: str, amount: int, signature: str)AccountBlock builderAccountBlock
update_wrap_request(id: znn.model.primitives.hash.Hash, signature: str)AccountBlock builderAccountBlock
wrap_token(network_class: int, chain_id: int, to_address: str, amount: int, token_standard: znn.model.primitives.token_standard.TokenStandard)AccountBlock builderAccountBlock

HtlcApi

HTLC lookup, proxy-unlock policy, creation, reclaim, and unlock.

Import: znn.api.embedded.htlc.HtlcApi

Constructor: HtlcApi(ws_client=None)

Python signatureKindWire methodDeclared result
async get_by_id(id: znn.model.primitives.hash.Hash)RPCembedded.htlc.getByIdHtlcInfo
async get_proxy_unlock_status(address: znn.model.primitives.address.Address)RPCembedded.htlc.getProxyUnlockStatusboolean
allow_proxy_unlock()AccountBlock builderAccountBlock
create(token: znn.model.primitives.token_standard.TokenStandard, amount: int, hash_locked: znn.model.primitives.address.Address, expiration_time: int, hash_type: int, key_max_size: int, hash_lock: bytes | None)AccountBlock builderAccountBlock
deny_proxy_unlock()AccountBlock builderAccountBlock
reclaim(id: znn.model.primitives.hash.Hash)AccountBlock builderAccountBlock
unlock(id: znn.model.primitives.hash.Hash, preimage: bytes | None)AccountBlock builderAccountBlock

LiquidityApi

Liquidity state, rewards, stakes, security, and administration.

Import: znn.api.embedded.liquidity.LiquidityApi

Constructor: LiquidityApi(ws_client=None)

Python signatureKindWire methodDeclared result
async get_frontier_reward_by_page(address: znn.model.primitives.address.Address, page_index=0, page_size=1024)RPCembedded.liquidity.getFrontierRewardByPageRewardHistoryList
async get_liquidity_info()RPCembedded.liquidity.getLiquidityInfoLiquidityInfo
async get_liquidity_stake_entries_by_address(address: znn.model.primitives.address.Address, page_index=0, page_size=50)RPCembedded.liquidity.getLiquidityStakeEntriesByAddressLiquidityStakeList
async get_security_info()RPCembedded.liquidity.getSecurityInfoSecurityInfo
async get_time_challenges_info()RPCembedded.liquidity.getTimeChallengesInfoTimeChallengesList
async get_uncollected_reward(address: znn.model.primitives.address.Address)RPCembedded.liquidity.getUncollectedRewardRewardDeposit
cancel_liquidity_stake(id: znn.model.primitives.hash.Hash)AccountBlock builderAccountBlock
change_administrator(administrator: znn.model.primitives.address.Address)AccountBlock builderAccountBlock
collect_reward()AccountBlock builderAccountBlock
emergency()AccountBlock builderAccountBlock
liquidity_stake(duration_in_sec: int, amount: int, zts: znn.model.primitives.token_standard.TokenStandard)AccountBlock builderAccountBlock
nominate_guardians(guardians: list)AccountBlock builderAccountBlock
propose_administrator(address: znn.model.primitives.address.Address)AccountBlock builderAccountBlock
set_additional_reward(znn_reward: int, qsr_reward: int)AccountBlock builderAccountBlock
set_is_halted(is_halted: bool)AccountBlock builderAccountBlock
set_token_tuple(token_standards: list, znn_percentages: list, qsr_percentages: list, min_amounts: list)AccountBlock builderAccountBlock
unlock_liquidity_stake_entries(zts: znn.model.primitives.token_standard.TokenStandard)AccountBlock builderAccountBlock

PillarApi

Pillar discovery, registration, delegation, rewards, and QSR management.

Import: znn.api.embedded.pillar.PillarApi

Constructor: PillarApi(ws_client=None)

Python signatureKindWire methodDeclared result
async get_deposited_qsr(pillar_address: znn.model.primitives.address.Address)RPCembedded.pillar.getDepositedQsrdecimal-string
async get_uncollected_reward(pillar_address: znn.model.primitives.address.Address)RPCembedded.pillar.getUncollectedRewardUncollectedReward
async get_frontier_reward_by_page(pillar_address: znn.model.primitives.address.Address, page_index=0, page_size=1024)RPCembedded.pillar.getFrontierRewardByPageRewardHistoryList
async get_qsr_registration_cost()RPCembedded.pillar.getQsrRegistrationCostdecimal-string
async get_all(page_index=0, page_size=1024)RPCembedded.pillar.getAllPillarInfoList
async get_by_owner(pillar_address: znn.model.primitives.address.Address)RPCembedded.pillar.getByOwnerarray
async get_by_name(pillar_name: str)RPCembedded.pillar.getByNamePillarInfo or null
async check_name_availability(name: str)RPCembedded.pillar.checkNameAvailabilityboolean
async get_delegated_pillar(pillar_address: znn.model.primitives.address.Address)RPCembedded.pillar.getDelegatedPillarDelegationInfo or null
async get_pillar_epoch_history(name: str, page_index=0, page_size=1024)RPCembedded.pillar.getPillarEpochHistoryPillarEpochHistoryList
async get_pillars_history_by_epoch(epoch: int, page_index=0, page_size=1024)RPCembedded.pillar.getPillarsHistoryByEpochPillarEpochHistoryList
register(name: str, producer_address: znn.model.primitives.address.Address, reward_address: znn.model.primitives.address.Address, give_block_reward_percentage: int = 0, give_delegate_reward_percentage: int = 100)AccountBlock builderAccountBlock
register_legacy(name: str, producer_address: znn.model.primitives.address.Address, reward_address: znn.model.primitives.address.Address, public_key: str, signature: str, give_block_reward_percentage: int = 0, give_delegate_reward_percentage: int = 100)AccountBlock builderAccountBlock
update_pillar(name: str, producer_address: znn.model.primitives.address.Address, reward_address: znn.model.primitives.address.Address, give_block_reward_percentage: int = 0, give_delegate_reward_percentage: int = 100)AccountBlock builderAccountBlock
revoke(name: str)AccountBlock builderAccountBlock
delegate(name: str)AccountBlock builderAccountBlock
undelegate()AccountBlock builderAccountBlock
collect_reward()AccountBlock builderAccountBlock
deposit_qsr(amount: int)AccountBlock builderAccountBlock
withdraw_qsr()AccountBlock builderAccountBlock

PlasmaApi

Plasma state, fusion entries, PoW requirements, fuse, and cancel.

Import: znn.api.embedded.plasma.PlasmaApi

Constructor: PlasmaApi(ws_client=None)

Python signatureKindWire methodDeclared result
get_plasma_by_qsr(qsr_amount)Local calculationint
async get(address: znn.model.primitives.address.Address)RPCembedded.plasma.getPlasmaInfo
async get_entries_by_address(address: znn.model.primitives.address.Address, page_index=0, page_size=1024)RPCembedded.plasma.getEntriesByAddressFusionEntryList
async get_required_fusion_amount(required_plasma: int)Removed compatibility stubRaises NotImplementedError
async get_internal_required_pow_for_account_block(account_block: znn.model.nom.account_block.AccountBlock)RPCembedded.plasma.getRequiredPoWForAccountBlockGetRequiredPowResponse
async get_required_pow_for_account_block(pow_param)RPCembedded.plasma.getRequiredPoWForAccountBlockGetRequiredPowResponse
fuse(beneficiary: znn.model.primitives.address.Address, amount: int)AccountBlock builderAccountBlock
cancel(hash_id: znn.model.primitives.hash.Hash)AccountBlock builderAccountBlock

SentinelApi

Sentinel discovery, registration, rewards, and QSR management.

Import: znn.api.embedded.sentinel.SentinelApi

Constructor: SentinelApi(ws_client=None)

Python signatureKindWire methodDeclared result
async get_all_active(page_index=0, page_size=1024)RPCembedded.sentinel.getAllActiveSentinelInfoList
async get_by_owner(address: znn.model.primitives.address.Address)RPCembedded.sentinel.getByOwnerSentinelInfo or null
async get_deposited_qsr(address: znn.model.primitives.address.Address)RPCembedded.sentinel.getDepositedQsrdecimal-string
async get_uncollected_reward(pillar_address: znn.model.primitives.address.Address)RPCembedded.sentinel.getUncollectedRewardUncollectedReward
async get_frontier_reward_by_page(address: znn.model.primitives.address.Address, page_index=0, page_size=1024)RPCembedded.sentinel.getFrontierRewardByPageRewardHistoryList
register()AccountBlock builderAccountBlock
revoke()AccountBlock builderAccountBlock
collect_reward()AccountBlock builderAccountBlock
deposit_qsr(amount: int)AccountBlock builderAccountBlock
withdraw_qsr()AccountBlock builderAccountBlock

SporkApi

Spork discovery, creation, and activation.

Import: znn.api.embedded.spork.SporkApi

Constructor: SporkApi(ws_client=None)

Python signatureKindWire methodDeclared result
async get_all(page_index=0, page_size=1024)RPCembedded.spork.getAllSporkList
activate_spork(id: znn.model.primitives.hash.Hash)AccountBlock builderAccountBlock
create_spork(name: str, description: str)AccountBlock builderAccountBlock

StakeApi

Stake entries, rewards, staking, cancellation, and collection.

Import: znn.api.embedded.stake.StakeApi

Constructor: StakeApi(ws_client=None)

Python signatureKindWire methodDeclared result
async get_entries_by_address(address: znn.model.primitives.address.Address, page_index=0, page_size=1024)RPCembedded.stake.getEntriesByAddressStakeList
async get_uncollected_reward(address: znn.model.primitives.address.Address)RPCembedded.stake.getUncollectedRewardUncollectedReward
async get_frontier_reward_by_page(address: znn.model.primitives.address.Address, page_index=0, page_size=1024)RPCembedded.stake.getFrontierRewardByPageRewardHistoryList
stake(duration_in_sec: int, amount: int)AccountBlock builderAccountBlock
cancel(hash_id: znn.model.primitives.hash.Hash)AccountBlock builderAccountBlock
collect_reward()AccountBlock builderAccountBlock

SwapApi

Swap assets, legacy pillars, and asset retrieval.

Import: znn.api.embedded.swap.SwapApi

Constructor: SwapApi(ws_client=None)

Python signatureKindWire methodDeclared result
async get_assets()RPCembedded.swap.getAssetsSwapAssetList
async get_assets_by_key_id_hash(key_id_hash: str)RPCembedded.swap.getAssetsByKeyIdHashSwapAssetEntry or null
async get_legacy_pillars()RPCembedded.swap.getLegacyPillarsSwapLegacyPillarList
retrieve_assets(public_key: str, signature: str)AccountBlock builderAccountBlock

TokenApi

Token discovery, issuance, minting, burning, and updates.

Import: znn.api.embedded.token.TokenApi

Constructor: TokenApi(ws_client=None)

Python signatureKindWire methodDeclared result
async get_all(page_index=0, page_size=1024)RPCembedded.token.getAllTokenList
async get_by_owner(address: znn.model.primitives.address.Address, page_index=0, page_size=1024)RPCembedded.token.getByOwnerTokenList
async get_by_owner_address(address: znn.model.primitives.address.Address, page_index=0, page_size=1024)Compatibility aliasSame as canonical method
async get_by_zts(token_standard: znn.model.primitives.token_standard.TokenStandard)RPCembedded.token.getByZtsToken or null
issue_token(token_name: str, token_symbol: str, token_domain: str, total_supply: int, max_supply: int, decimals: int, mintable: bool, burnable: bool, utility: bool)AccountBlock builderAccountBlock
mint_token(token_standard: znn.model.primitives.token_standard.TokenStandard, amount: int, receive_address: znn.model.primitives.address.Address)AccountBlock builderAccountBlock
burn_token(token_standard: znn.model.primitives.token_standard.TokenStandard, amount: int)AccountBlock builderAccountBlock
update_token(token_standard: znn.model.primitives.token_standard.TokenStandard, owner_address: znn.model.primitives.address.Address, is_mintable: bool, is_burnable: bool)AccountBlock builderAccountBlock