Cosmic Bull

Rendered from pearl/r/subscriptions/DISCOVERY.md at commit 6a510c665a53 in the project repository. The committed file is the source of truth; this page is a rendering of it.

Discovery record — subscriptions

Objective: a reusable Gno application in which providers create subscription plans, users subscribe and pay per billing period, the realm tracks subscription state and billing periods, supports cancellation, and prevents unauthorized, duplicate, and out-of-window payments — with obligations explicit on chain and deterministic renewal / expiration / cancellation rules.

Search performed 2026-09-22, per docs/DISCOVERY_AND_REUSE.md. Four legs.

1. Own catalog

HitClassification
p/…/feeledgerREUSABLE PRIMITIVE — composed. Provider balances, protocol-fee pot, hard cap, checked arithmetic, conservation surface.
p/…/coinioREUSABLE PRIMITIVE — composed. Receipt-guarded receive, payout, reserve-protected sweep.
p/…/duebookRELATED — studied, not composed. Its consume-then-act window (DueAt/expiry/Claim) inspired the renewal-window shape, but composing it was rejected on structure: duebook models one-shot obligations as individually allocated Deferrals with ids and a global open-entry cap (MaxOpenLimit); a subscription is a rolling obligation on one identity. Modeling N billing periods as N deferrals allocates storage per period forever, and a shared open-entry cap couples unrelated subscribers' liveness. A single monotonic paidThrough int64 gives the same replay-impossibility (a paid period cannot be paid again because the window arithmetic has moved) at O(1) state per subscription.
service_marketRELATED — per-order escrow marketplace; its snapshot/consent/fee idioms are reused as patterns, not as code.

2. On-chain (pearl-1, enumerated live)

vm/qpaths over gno.land/r/ returned 466 realms. Name-matched hits:

HitWhat it isClassification
r/g16m0r7…/subscriptionA subscription state-machine simulation: plain-int "balance"/"revenue" fields, no banker, no coins, no OriginSend; authorization trusts a caller-supplied caller string; height advances via a caller-supplied Tick. Read in full via $download.RELATED — evidence of the niche, not reusable: it moves no value and verifies no identity.
r/gov/dao/v3/memberstoreGovernance membership tiers, no payment/billing.NOT RELEVANT

gno.land/p/demo/ on pearl holds only blog/nestedpkg/svg/grc20 — no subscription package. gno.land/p/jaekwon/ is empty on pearl.

3. Upstream examples (pinned GNOROOT, chain-matched)

HitClassification
examples/quarantined/gno.land/p/demo/subscription (recurring + lifetime)RELATED — the principal design study. Single-plan-per-instance /p/ library; payment PULLED via a p/jaekwon/allowancesender cap-token; wall-clock time.Now(). Three structural gaps against this objective, quoted from source: (1) no cancellation exists — no function ends a subscription; (2) no renewal windowSubscribe returns ErrAlreadySub while active, so a subscriber cannot renew before lapse: continuous service requires letting it expire first; (3) one plan per instance — no provider catalog, no per-plan state. It is also quarantined (outside the kept set) and its allowancesender dependency does not exist on pearl, so it could not be imported there even if chosen.

4. Public ecosystem

gh search repos "gno subscription" → zero results. Code search for RecurringSubscription in Go → unrelated payment SDKs (seerbit, spurtcms). Limits: default branches of public repos only; GitLab/Codeberg not searched.

Verdict

No relevant existing implementation was found in the searched sources for a multi-provider, push-payment, windowed-renewal subscription realm with cancellation. Strategy: compose (feeledger + coinio + avl + sanitize) under one new realm; the only genuinely new logic is the plan/subscription state machine and the deterministic window arithmetic — which is the objective itself.