Search Apps Documentation Source Content File Folder Download Copy Actions Download

init package

Overview

Package init provides basic user registration.

Functions

Bootstrap

func Bootstrap(_ realm)

Bootstrap registers this package as a controller in r/sys/users.

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/sys/users/init" -func "Bootstrap" -gas-fee 1000000ugnot -gas-wanted 1_000_000_000 -send "" -broadcast -chainid "gnoland1" -remote "http://rpc.betanet.testnets.gno.land" ADDRESSgnokey query -remote "http://rpc.betanet.testnets.gno.land" auth/accounts/ADDRESS
gnokey maketx call -pkgpath "gno.land/r/sys/users/init" -func "Bootstrap" -gas-fee 1000000ugnot -gas-wanted 1_000_000_000 -send "" ADDRESS > call.tx
gnokey sign -tx-path call.tx -chainid "gnoland1" -account-number ACCOUNTNUMBER -account-sequence SEQUENCENUMBER ADDRESS
gnokey broadcast -remote "http://rpc.betanet.testnets.gno.land" call.tx
  

RegisterUser

func RegisterUser(_ realm, name string, addr address)

RegisterUser registers a new user in r/sys/users.

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/sys/users/init" -func "RegisterUser" -args $'' -args $'' -gas-fee 1000000ugnot -gas-wanted 1_000_000_000 -send "" -broadcast -chainid "gnoland1" -remote "http://rpc.betanet.testnets.gno.land" ADDRESSgnokey query -remote "http://rpc.betanet.testnets.gno.land" auth/accounts/ADDRESS
gnokey maketx call -pkgpath "gno.land/r/sys/users/init" -func "RegisterUser" -args $'' -args $'' -gas-fee 1000000ugnot -gas-wanted 1_000_000_000 -send "" ADDRESS > call.tx
gnokey sign -tx-path call.tx -chainid "gnoland1" -account-number ACCOUNTNUMBER -account-sequence SEQUENCENUMBER ADDRESS
gnokey broadcast -remote "http://rpc.betanet.testnets.gno.land" call.tx