B7.5.1 · dive 1 of 3 · module B7.5
Three currencies.
Keys are paid, bought with Telegram Stars and spent in paid rooms; clips are free and carry no value; diamonds are prizes, won from a game’s bank and convertible to keys at ten to one.
The idea
codemojex · three currenciesThe reference economy runs on three currencies, each with a different meaning. Keys are the paid currency: a player buys them with Telegram Stars and spends them to enter paid rooms. Clips are the free currency, earned and spent in free rooms, carrying no cash value. Diamonds are the prize currency, won from a game’s bank and convertible to keys at a fixed rate of ten to one.
Keeping the currencies distinct is what keeps the economy legible. A free player never touches anything of value, so a free room cannot be a back door to cash; a paid player’s stake and a winner’s prize are different tokens with a defined exchange between them. The boundary between play money and real value is drawn once, at the points where stars become keys and diamonds become keys.
Real money enters through commerce, not through the game. A purchase of keys is an order paid in stars, recorded on its own payment ledger and confirmed by an idempotent webhook, and only a confirmed purchase credits the wallet. The game itself moves keys, clips, and diamonds; it never sees a card or a star directly, which keeps the payment path on one side of a clean line.
The doors
the sibling coursesEchoMQ — the protocol, in depth
The bus B3 narrates, taught rung by rung: the keyspace, the Lua inventory, and the 3.0 Stream Tier — XADD, XREADGROUP, XACK — with conformance on Valkey.
Redis Patterns Applied
The substrate patterns under the bus: sorted sets, atomic Lua moves, locks, and streams — the judgement layer.
/echo-persistenceEcho Persistence — the durable floor
Beneath the volatile tiers: the Graft page engine built twice, the commit-LSN loop, and the stream archive on Tigris. Where Part I says state lives somewhere, this says where it lives durably.
References
sources · relatedSources
- Helland — Life Beyond Distributed Transactions (CIDR 2007)a wallet and a bank as durable entities, the ledger as the record of truth
- King — Announcing Snowflake (2010)the branded id that keys a wallet, a ledger entry, and a game’s bank
- Kreps — The Log: real-time data’s unifying abstractionthe ledger as an append-only log whose entries the balance is derived from
Related
- BCS — the course homethe law, the id anatomy, the chapter map
- Echo Persistencethe durable floor beneath the bus