Skip to Content
x207x207 Docs
Smart contracts

View methods

Every read-only method of the x207-circle contract (interface 0.0.18), with parameters and what it returns.

View methods change no state and cost no gas when called over RPC. Names are copied from contracts/abi.json (interface 0.0.18). Amounts are strings holding integers; one credit is 1,000,000 units. State-changing methods are in Call methods.

List views take from_index and limit. A limit of 0, or a from_index past the end, returns an empty list.

Circle and parameters

ViewParametersReturns
interface_versionnoneThe interface version string (0.0.18).
get_circlenoneCircleConfig: circle id, token, Intents contract, owner, and current params.
get_ownernoneThe owner account id.
get_paramsnoneParams in force for the running epoch.
get_pending_paramsnoneParams stored by set_params that apply from the next epoch, or null.
get_poolnonePoolView: accounted, epoch_pools, in_flight, reserve, solver_fees, total_stake.
get_upgradenoneUpgradeView (code_hash, eta) of a pending upgrade, or null.
get_max_escrow_ttlnoneThe longest account-escrow time to live, in nanoseconds.
get_pending_gc_delaynoneThe delay before anyone may remove a never-admitted pending member.
get_locker_code_hashesnoneOfficial locker code hashes.

Members

ViewParametersReturns
memberaccount_idMemberView (status pending, active, suspended or exited, stake, limit, debt) or null.
list_membersfrom_index, limitA page of MemberView.
limitaccount_idThe member's credit limit.
headroomaccount_idmax(0, limit - outstanding_debt - reserved bundle headroom). "0" for a member that is not active.
outstanding_debtaccount_idThe member's outstanding debt in the running epoch.
is_frozenaccount_idWhether the member is frozen.
get_freezeaccount_idFreezeView (state pending or frozen, eta) or null.
is_auto_settleaccount_idWhether auto-settle from stake is on.
evm_signeraccount_idEvmSignerView (address, nonce, sponsor) for an EVM member, or null.
bond_lockedaccount_idStake currently locked as deal bonds.
solver_fee_balanceaccount_idSolver fee waiting for claim_solver_fee.
intents_balancenoneAmount booked for withdraw_intents_balance.

Epochs, obligations and clearing

ViewParametersReturns
get_epochepoch (or null for the current one)EpochView: phase (open, cutoff, clearing, commit, payment_window, finalized), deadlines and totals.
last_seqpayer, payee, epochLast accepted seq for the pair in that epoch.
obligationepoch, debtor, creditorObligationView for the pair, or null.
list_obligationsepoch, from_index, limitA page of ObligationView.
get_clearing_proposalepochThe stored best proposal summary, including the solver and cleared_total, or null.
get_proposalepoch, from_index, limitA page of the stored proposal's edges with its proposal_hash.
simulate_clearingepoch, edgesSimulationResult: valid, cleared_total, edge_count, better_than_current, reason. Checks a proposal as submit_clearing would, without storing it.
net_positionepoch, account_idPositionView (status due, paid, defaulted, claimable, claimed), or null for a net-zero member, an unknown member or an epoch that is not committed.
list_positionsepoch, from_index, limitA page of PositionView.
Epoch stateMember stateCircle statechecks without storingget_circle, get_params,get_pending_paramsget_poolmember, list_memberslimitoutstanding_debtheadroomget_epochobligation, list_obligations,last_seqget_clearing_proposal,get_proposalnet_position, list_positionssimulate_clearing

Barter and deals

ViewParametersReturns
get_intentintent_hashIntentView or null.
get_bundlebundle_idBundleView or null.
get_dealbundle_idDealView (state open or disputed) or null.

Grants, escrow and asset classes

ViewParametersReturns
get_grantgrant_idAccessGrant (status offered, active, revoked or expired) or null.
grants_ofaccount_id, role, from_index, limitA page of grants where the account has the given role.
get_escrowgrant_idThe NFT escrow of a class A grant, or null.
get_ft_escrowgrant_idThe fungible-token escrow, or null.
get_mt_escrowgrant_idThe multi-token escrow, or null.
get_account_escrowgrant_idThe account escrow (locker), or null.
get_asset_classasset_typeAssetClassEntry or null.
list_asset_classesnoneAll registered asset classes.
get_asset_contractsasset_typeOfficial token contracts of a class A asset type.

An escrow reports one of held, completing, cancelling, delivered, cancelled or stuck. Reading stuck means the asset transfer failed and the contract has no rescue method (see Security and limits).

Source

Edit on GitHub

On this page