Search Apps Documentation Source Content File Folder Download Copy Actions Download State String Boolean Number Struct Map Slice Pointer Function Closure Reference Nil Package Type Interface Unknown

zones/v0 package

Overview

Package zones is a curated registry of gno.land networks: mainnet, the testnets, staging chains, anybody's gnodev. Each zone carries what a node or a wallet needs to join it (chain id, RPC, gnoweb, genesis) plus a growing list of endpoints: RPCs, seeds and peers, indexers, faucets, explorers.

Curation is the point. Anybody may propose a zone and register endpoints on an approved one (on a pending one, its proposer or a curator; a zone's own main RPC and gnoweb, only them); a curator approves or rejects a proposal, retires a zone that stopped running, and verifies or flags an endpoint. The latest decision on each is recorded with who made it and when, and a rejection, a retirement, a flag or an edit to an approved zone must also say why, on the zone's page. Nothing is hidden while it waits: proposals and unverified endpoints are listed, and labelled.

This realm only manages the information and answers questions about it. The read helpers (GetZone, ListZones, GetEndpoint, ListEndpoints, ListAddresses, IsCurator, Curators, IsInvited, Invited) take plain values so they work from `gnokey query vm/qeval` as well as from another realm, and turning them into a node's config.toml is a separate realm's job.

The model, its validation and its state machine are p/moul/zones. This realm owns only who may write.

Function

ProposeZone

func ProposeZone(cur realm, slug, chainID, title, description, kind, gnowebURL, rpcURL, genesisURL string)

ProposeZone files a new zone for review. Anybody may; it is listed as a proposal until a curator approves or rejects it. The review queue's caps (zones.MaxPending, zones.MaxPendingPerProposer) do not stop a curator, who also has the registry's last zones.ReservedForReviewers places, so neither a flood nor a full registry locks out the people who clear it.

kind is mainnet, testnet, devnet or local. gnowebURL and genesisURL may be empty; rpcURL may not, and is <scheme>://<host>[:<port>] with no path, which is what gnokey -remote takes.

Params

Command

# WARNING: This command is running in an INSECURE mode.
# It is strongly recommended to use a hardware device for signing
# and avoid trusting any computer connected to the internet,
# as your private keys could be exposed.

gnokey maketx call -pkgpath "gno.land/r/moul/zones/v0" -func "ProposeZone" -args $'' -args $'' -args $'' -args $'' -args $'' -args $'' -args $'' -args $'' -gas-fee 1000000ugnot -gas-wanted 1_000_000_000 -send "" -chainid "gnoland-1" -remote "https://rpc.gno.land" ADDRESSgnokey query -remote "https://rpc.gno.land" auth/accounts/ADDRESS
gnokey maketx call -pkgpath "gno.land/r/moul/zones/v0" -func "ProposeZone" -args $'' -args $'' -args $'' -args $'' -args $'' -args $'' -args $'' -args $'' -gas-fee 1000000ugnot -gas-wanted 1_000_000_000 -send "" -broadcast=false ADDRESS > call.tx
gnokey sign -tx-path call.tx -chainid "gnoland-1" -account-number ACCOUNTNUMBER -account-sequence SEQUENCENUMBER ADDRESS
gnokey broadcast -remote "https://rpc.gno.land" call.tx