Skip to content Search Apps Documentation Source Content Run Reset Eval Playground File Folder Download Copy Actions State String Boolean Number Struct Map Slice Pointer Function Closure Reference Nil Package Type Interface Unknown

doc.gno

1.09 Kb · 22 lines
 1// Package dca is the GnoSwap DCA (dollar-cost averaging) order realm.
 2//
 3// Users escrow inputToken and sell amountPerExecution of it for outputToken
 4// every interval, executionCount times, at a chosen slot of the interval
 5// (e.g. 09:00 UTC daily). Orders of the same pair, interval, and slot
 6// form a group that keepers execute in one pool swap per round, on the
 7// pair's best whitelisted pool, without the router. Each round's swap output
 8// accrues to the orders and is paid by Claim, or by keepers through
 9// ClaimGroupOrders; each payout deducts the execution fee at the rate the
10// order snapshotted when it was created.
11//
12// This package is the permanent entry point. It owns the escrow address, the
13// KV store shared by every version, and the upgrade switch; the business
14// logic lives in a registered implementation (impl/v0).
15//
16// Files:
17//   - proxy.gno: state-changing entry points
18//   - getter.gno: read-only queries
19//   - store.gno: KV store and store keys
20//   - state.gno: realm state and the active implementation
21//   - upgrade.gno: implementation registration and upgrades
22package dca