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

memba_appstore_v1 package

Overview

Package memba_appstore_v1 is a curated App Store for gno.land dApps: publishers pay a flat listing fee to register an app; a curator flips it live.

MONEY PATH (the only one): RegisterApp collects a flat `registrationFee` in ugnot and forwards 100% to the treasury in the SAME call — nothing is ever custodied. The safety contract mirrors memba_token_otc_v1 + the O-13 lesson:

  1. IsUserCall() guard BEFORE reading OriginSend — an ephemeral `maketx run` realm can never attach unrecoverable coins (the guard agent_registry missed).
  2. exact-coin via unsafe.OriginSend() (the coins on THIS call, not the wallet balance) — closes the overpay-trap and the wallet-balance bypass.
  3. treasury-misconfig is fail-closed: an unset treasury panics (→ tx reverts → coins refunded), never silent custody.
  4. CEI: state is written before the banker moves funds.
  5. NewBanker(RealmSend, cur) sends the fee from the realm's own address to the treasury — no custody, no escrow (which is why no escrow is needed to be safe).

TREASURY: stored LOCALLY (admin-settable, 2-step handoff, defaults to the samcrew multisig) rather than read from memba_market_config — this keeps the realm self-contained so the whole money path is unit-tested locally. Keep it in sync with memba_market_config.GetTreasury(); a future version may read the fee spine directly (which makes the realm non-locally-testable — a deliberate later trade-off).

Function

ListLiveJSON

func ListLiveJSON(offset, limit int) string

ListLiveJSON returns a bounded JSON array of the visible (live, un-hidden) listings: skip `offset`, take up to clamped `limit`. Iteration stops as soon as the window is filled, so the scan is bounded by offset+limit regardless of catalog size.

Params

Command

gnokey query vm/qeval -remote "https://rpc.topaz.testnets.gno.land" -data "gno.land/r/samcrew/memba_appstore_v1.ListLiveJSON(,)"

Result