Count
Count returns the total number of signatures. Read-only, non-crossing.
Command
gnokey query vm/qeval -remote "http://127.0.0.1:26657" -data "gno.land/r/moul/x/daily/guestbook/v0.Count()"
Result
Package guestbook is a public, on-chain guestbook realm for gno.land.
Anyone can sign the guestbook with a short message via the Sign crossing function. Every entry records the caller's address, the message, and the block height at which it was signed. Render lists all entries newest-first as a Markdown table.
Count returns the total number of signatures. Read-only, non-crossing.
gnokey query vm/qeval -remote "http://127.0.0.1:26657" -data "gno.land/r/moul/x/daily/guestbook/v0.Count()"
Render lists every entry newest-first as a Markdown table plus a total count.
gnokey query vm/qeval -remote "http://127.0.0.1:26657" -data "gno.land/r/moul/x/daily/guestbook/v0.Render()"
Sign appends a new entry to the guestbook attributed to the immediate caller.
It is a crossing function (gno 0.9 interrealm convention): callers invoke it as Sign(cross(cur), "hello"). The cur.IsCurrent() guard is the authentication primitive — without it a stale/forged realm value could spoof the author.
# 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/x/daily/guestbook/v0" -func "Sign" -args $'' -gas-fee 1000000ugnot -gas-wanted 1_000_000_000 -send "" -chainid "gnoland-1" -remote "http://127.0.0.1:26657" ADDRESSgnokey query -remote "http://127.0.0.1:26657" auth/accounts/ADDRESS
gnokey maketx call -pkgpath "gno.land/r/moul/x/daily/guestbook/v0" -func "Sign" -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 "http://127.0.0.1:26657" call.tx