Badges and Perks
Status: Phase 1 shipped (before 2026-07-20 — predates this repo's shallow history): admin-defined badges, award / revoke from the admin console, the user's Badges page (/account/badges — feature up to 12, one primary), the profile Badges section, the primary badge on comments and hover cards, and the award reveal. Phases 2–5 (criteria-driven awarders, progress visualizations, perks) are planned; nothing awards automatically yet.
Overview
Badges are publicly visible markers earned through behavior on Echo of Dreams — engagement with a creator's work, contribution to shared content, time on the platform, or paid support. They serve three roles at once:
- Recognition — fans, contributors, and supporters get a small public reward for showing up.
- Signal — comments and profiles carry visibly different weight depending on who's behind them. A founding fan's review reads differently than a passing visitor's.
- Foundation — once badges exist as a primitive, perks (early access, fan-only content, comment highlighting, leaderboards) hang off them naturally.
The key constraint: eligibility is earned, not bought. Subscribers get a subscriber badge, but the bulk of the badge surface is driven by genuine engagement and contribution — not by clicking follow once or paying once.
This doc catalogs the badges and perks worth building, the progress visualizations that drive them, and a phased rollout that doesn't try to ship everything at once.
Why
Today, the only public signal of fandom or contribution is the follow relationship and the comment author's display name. Follows are essentially free. Comments are flat. Creators can't tell at a glance who their actual audience is, contributors get no public credit for approved proposals, subscribers blend in with everyone else, and there's no rhythm-driving mechanic that rewards returning to the platform.
Badges fix all of that with one rendering pipeline:
- Creators see who shows up.
- Fans get a small public identity tied to creators they love.
- Contributors get visible credit for approved work.
- Subscribers get the recognition they paid for, without paywalling identity itself.
- The platform gets a rhythm/streak loop that rewards engagement without pay-to-win.
Perks layered on top turn that recognition into actual benefits — but the badges have to come first.
Badge Catalog
Badges are grouped by what earns them. Each group shares a rendering pattern and lifecycle, so building one in a group makes the rest cheap.
Engagement-earned (per creator / per project)
These are the "fan" family. Each is scoped to a specific creator or project, so a user can hold many of them. All require an active follow as a baseline.
- Fan badge — the flagship. Earned by following + having substantive conversation history with content from the creator/project, sustained over time. Lapses if the user unfollows or goes inactive past a grace period. Display on profile and on comments tied to that creator's/project's content. Visual is creator-customizable within taste/safety limits.
- Founding fan — earned in the first N days of a creator/project going public. Permanent, doesn't lapse. Scarce by design — the value comes from being un-re-earnable later.
- Streak badge — chatted with the creator's content on N distinct days in a row. Rewards rhythm, not volume. Visible flame icon with streak count. Resets on a missed day; small grace allowance configurable.
- Deep diver — finished a long-form mode or package (hit a "completion" signal: last greeting reached, ending lorebook entry triggered, or manual mark-complete by the user). Per-package, like Steam achievements. Showcased individually.
- Lorekeeper — triggered or read N% of a lorebook's entries across conversations with that lorebook attached. Rewards exploring the worldbuilding instead of chatting a single character.
- Beta tester — used a creator's content while it was still in draft / early-access state. Permanent, can't be re-earned once the content goes public.
Contribution-earned (per creator / per project)
These give visible credit to users with can_contribute who don't have can_manage, plugging into the existing proposal system.
- Contributor badge — had N approved proposals on a creator's or project's content. Already-built proposal system makes this nearly free to compute.
- Translator — contributed translations once multilingual ships. Per language; a user can hold "Translator (DE)" and "Translator (FR)" independently.
- Bug spotter — filed a report that led to a content fix. Manually awarded by the creator or admin; not auto-derived.
Platform-wide
Not tied to a specific creator. Worn on the user's profile and (configurably) on every comment.
- Early adopter — account created before a published cutoff date. Permanent. Different visual tier per "wave" (closed beta, public beta, v1 launch).
- Subscriber tier badge — Pro today, future tiers as they're added. Visible on profile and comments. Disappears if the subscription lapses (no zombie status).
- Echo patron — purchased Echoes N times or above some lifetime threshold. Soft monetization signal without paywalling identity.
- Verified creator — for creators with published work and a clean moderation history. A trust signal, not a popularity one. Manually granted, manually revocable.
- Top contributor — rotating monthly leaderboard for proposals / comments / translations across the platform. Holds for the month earned, then visible as "Top Contributor — March 2026" permanently.
Community / moderation
- Trusted reporter — high signal-to-noise ratio on submitted moderation reports. Could stay internal-only or be a public badge — TBD.
- Community helper — manually awarded for ticket help, Discord support, or other recognized community work.
Admin-defined custom badges
Beyond the criteria-driven catalog above, admins can define and award arbitrary custom badges from the admin console. This is the escape hatch for everything the rule-based system can't predict — event commemoratives ("EoD Anniversary 2026"), one-off recognition ("Helped during the April outage"), partner / collaboration markers, contest winners, internal team flair, anything bespoke.
Definition (admin console):
- Identity — key (machine-readable), display name, short description / tooltip text.
- Icon — uploaded image URL (small square; SVG or PNG with transparency). The same image-upload pipeline used by gallery / banners.
- Custom colors — at minimum a primary color (background / accent) and a foreground color for label legibility. Optional border color for outlined variants. All hex, validated against the same injection guards used by profile customization.
- Visibility — public (worn on profile + comments) vs internal-only (admin-visible labels for moderation context, never rendered to other users).
- Stacking rules — whether multiple users can hold this badge, whether it counts as one of the user's "showcase" slots automatically, whether it's permanent or revocable.
- Lifecycle defaults — permanent by default; admin can set a
valid_untildate for time-bound commemoratives.
Award flow:
- Single award — admin opens a user's admin profile, picks a defined badge, optional note (shown to the user on the milestone notification), submits. Audited.
- Bulk award — admin selects a defined badge plus a user list (CSV / multi-select / saved query) and awards in one transaction. Same audit row per user. Useful for event commemoratives.
- Revoke — same path in reverse. Auditable, reason required.
Permissions:
- Define / edit / delete badge definitions — gated on
AdminArea.publicationsat Admin level. Badges are platform-curated public artifacts (the same conceptual bucket as announcements, banners, featured items, named pages), so they reuse the existing publications role rather than spinning up a new area before there's evidence the granularity matters. If award-vs-define ever needs to split (so moderators can hand out badges without inventing new ones), introduce a permission level distinction within the area before splitting the area itself. - Award / revoke — same area, lower level (Manage). A moderator with
publications: managecan award/revoke from defined badges; onlypublications: admincan create/edit/delete definitions.
Icon constraints:
- Either an SVG (preferred — scales cleanly to comment-row sizes) or a PNG with transparency.
- Hard cap on raster dimensions (≤512×512) so admins don't upload 4K images that get scaled in the browser on every comment render. Validated server-side at upload time.
- URLs accepted in addition to uploads, gated by the same scheme/host hardening
ProfilePageService.ValidateAndNormalizealready applies to profile customization.
Storage shape (sketch):
badge_definitions— definition rows for every badge type, manual or automated. Columns:key,display_name,description,icon_url,colors(JSONB: primary / foreground / border),visibility(public / internal-only),criteria_visibility(visible/hint/hidden),expiration_cadence(null/monthly/ custom interval),max_tier(1 for untiered; >1 for tiered ladders), per-tier criteria +echo_rewardJSONB,lifecycle_defaults,created_by_admin_id, soft-delete flag.user_badge_awards—(user_id, badge_id, tier)plus award metadata:awarded_by_admin_id(null for automated awards),awarded_at, optionalreason, optionalvalid_until(set automatically for cadence-bound badges),revoked_at/revoked_by_admin_id/revoked_reason. Tier defaults to 1 so untiered badges read cleanly.user_featured_badges— the user's chosen showcase selection: a small ordered list of(badge_id, tier)pairs, with one row flagged as the primary featured badge that ships with the standard user payload. Powers the hover-card / username-call surface decision.- The same
user_badge_awardstable is the natural home for all manually-awarded badges (Bug spotter, Verified creator, Community helper) — they're justbadge_definitionsrows seeded by the platform. Criteria-driven awarders write to it the same way admins do.
Why this is worth shipping early:
The criteria-driven badges (Fan, Streak, Deep diver, …) all need their own threshold logic, eligibility re-evaluation, and progress visualizations. Admin-defined badges need none of that — they're the rendering pipeline plus an admin form. Building them first proves out the badge data model, the rendering surfaces (profile, comments, hover card, showcase section), and the award notification flow without waiting on the criteria-evaluation engine. Then the criteria-driven badges layer on as automated awarders that write to the same tables.
Perks
Badges are the primitive. Perks are what makes earning them mean something beyond the visual.
- Comment highlighting — fan-badged comments on a creator's content get a subtle accent or sort priority.
- Early access — fans see new releases from a creator N hours/days before they go fully public.
- Fan-only chat scripts / greetings — creators can mark certain greetings or scripts as fan-only, the way some content is subscriber-only.
- Fan leaderboard slot — top N fans by engagement displayed on the creator's profile. Opt-in for both creator and fan.
- Custom flair — fans can pick from creator-defined flair text shown next to their badge ("Pack member", "Crew", whatever the creator names). Creator defines the vocabulary; fan picks from the list.
- Creator reply weight — when the creator replies to a fan's comment, the fan gets a heavier notification (toast + persistent + optional email).
Perks should be opt-in per creator — not every creator wants to gate content behind fandom. The creator's profile customization gains a "Fan perks" panel where they toggle which perks are active.
Progress Visualizations
Most badges are multi-criteria (follow + N conversations + N days), so a single progress bar doesn't fit by default. The patterns that work:
- Multi-step checklist — "Follow ✓ · 3/5 substantive conversations · 2/7 active days". Shows exactly what's missing. Default for fan-badge-style milestones. Builds on the existing form-field patterns; each row is a small icon + label + progress fragment.
- Single progress bar — only when there's one numeric criterion (streak length, package completion %, proposals approved). Reuse the existing
ProgressBarshared component. - Circular ring — for "X/Y" achievements where the visual needs to be compact (showcase grid, profile widget). Same data as the bar, smaller footprint.
- Locked card with reveal — for hidden/surprise badges (Founding fan, Beta tester) — show a silhouette plus a vague hint ("earned by being here early"), but don't expose exact criteria. Becomes a fully revealed card once earned.
- Streak calendar — GitHub-contributions-style heatmap for streak / active-days badges. High visual reward, drives return visits, doubles as a profile section.
- Tier ladder — for stacked badges (Bronze / Silver / Gold fan, if we add tiers). Show all tiers with the current position highlighted and progress to the next one.
Where progress visualizations live
- Dedicated "Badges" tab on the user's own profile — full grid, all badges with progress, locked plus earned. Self-only by default; user can publish.
- Compact "your progress" widget on creator/project profile — visible only to the logged-in viewer, shows progress toward that creator's badges. Disappears when fully earned (replaced by the badge itself).
- Milestone notification — toast plus persistent notification on crossing the threshold, with the visualization animating from in-progress → earned. This is the dopamine hit; don't ship badges without it.
- Showcase section on profile dashboards — user picks 3–6 badges to feature publicly via a new section type on the profile customization editor.
Display Surfaces
A badge needs to render consistently in several places, so the rendering should go through a single component family from day one.
- Profile — badge row(s) on the user's profile page. Configurable visibility (show all / show featured only / hide). Hover/tooltip explains what the badge represents and (optionally) when it was earned.
- Comments — inline next to the user's display name. Default: only badges scoped to the content being commented on (a fan badge for creator X shows on comments on X's content). User setting can flip this to "show globally."
- Showcase section — opt-in profile section type, similar to entity-list sections but rendering a curated grid of earned badges.
- Hover card / username payload — the standard user object (chat, comments, profile cards) carries the user's single primary featured badge only. The full badge collection loads on demand via a dedicated batch endpoint (
GET /api/users/:id/badges) when the user opens a profile, expands the badges drawer, or hovers a card past a short delay — same pattern as a followers list, paginated if needed.
Visual style is creator-customizable within constraints (color, icon, short label), enforced by the same kind of validator the profile customization uses (no NSFW imagery, no platform-UI impersonation, no misleading labels). Platform-wide badges have fixed visuals.
Lifecycle
The same lifecycle applies to most badges, with permanent badges skipping the lapse stages.
- Earn — when the user crosses the milestone, the badge becomes available. Notification surfaces it; the user chooses to display immediately or later.
- Maintain — eligibility is re-evaluated on a schedule. Active badges stay active.
- Lapse — if the user falls below criteria (unfollow, inactivity, expired subscription) past a grace period, the badge is hidden. Re-engaging restores it.
- Cyclical expiration — badges with an
expiration_cadence(default monthly for hidden-criteria "Top Fan"-style badges) expire at the end of each cycle. Re-evaluation runs against the (possibly hidden) criteria; users in the qualifying cohort keep / re-earn the badge, others lose it until the next cycle. Distinct from lapse: lapse is "you stopped meeting the bar"; expiration is "the slot reopens for everyone." - Revoke — creators (for creator-scoped badges) or admins (for ToS violations) can revoke a badge from a specific user. Auditable; should be rare.
- Permanent badges (Founding fan, Beta tester, Early adopter, monthly Top Contributor labels) skip lapse — they're tied to a moment in time.
Phased Rollout
Don't ship all of this at once. Ship the primitives first, layer the rest on.
Phase 1 — Primitives + admin-defined badges
- Badge data model —
custom_badgesdefinition table +user_badge_awardsaward/revoke table. Same storage backs every later badge type, automated or manual. - Admin console — define / edit / delete badge definitions (icon URL, custom colors, visibility, lifecycle); award / revoke per-user; bulk-award by user list. Audited end-to-end.
- Rendering surfaces — profile badge row, comment-author badge, hover card, showcase section type on profile dashboards. Built once, reused by all later phases.
- Milestone notification with animated reveal — required for the admin-award path to feel rewarding, not bureaucratic.
This phase ships the entire pipeline without any criteria-evaluation engine. Everything from Phase 2 onward is "add an automated awarder that writes to user_badge_awards."
Phase 2 — Criteria-driven primitives
- Fan badge + Founding fan + Subscriber tier badges. Covers the three core motivations (engagement, scarcity, monetization) on top of the rendering pipeline from Phase 1.
- Multi-step checklist as the default progress UI; circular ring for compact spots.
- Profile "Badges" tab + creator-profile progress widget.
Phase 3 — Engagement loops
- Streak badge + streak calendar visualization.
- Deep diver + Lorekeeper (per-package and per-lorebook achievements).
- Comment highlighting perk for fan-badged comments.
Phase 4 — Contribution surface
- Contributor badge (auto from approved proposals).
- Beta tester badge (auto from access during draft state).
- Verified creator + Top contributor monthly rotation.
Phase 5 — Perks economy
- Early access, fan-only greetings/scripts, fan leaderboard slot, custom flair.
- Creator's "Fan perks" panel on profile customization.
- Translator badge (depends on multilingual shipping).
Decisions
These are settled — the implementation must keep room for each one even if it doesn't ship in Phase 1.
- Tiered fan badges — yes, leave the door open. Tiers (Bronze / Silver / Gold or named equivalents) read naturally as a progress-reward ladder, the same shape as Echoes daily-task rewards. The data model treats every fan badge as
(badge_key, tier)from day one; Phase 2 ships with a single tier and the ladder lights up later without a migration. The renderer accepts a tier parameter and falls back to "untiered" cleanly. - Echoes interaction — option stays open. The default is purely social (no Echo reward) to avoid grinding incentives, but the badge data model carries an optional
echo_rewardfield on tier crossings so specific badges (likely streak / tier-up milestones) can grant Echoes when it makes sense. Wiring uses the existingecho_transactionsledger + per-badge idempotency keys; nothing new structurally. Off by default per badge. - Project vs creator badges — user picks which to show. Users earn both independently. Display is governed by the user's showcase selection (the same featured-badges list used elsewhere). On comments scoped to a creator's content, the renderer prefers a relevant featured badge if the user has one; otherwise falls back to the user's globally-featured badge. No automatic supersession — the user is in control.
- Anti-gaming — hidden goals + expiration. Some badges (especially the highest tier of a fan ladder, à la Facebook's "Top Fan") have hidden criteria: the user can see the badge exists, but the exact thresholds aren't surfaced, only progress hints. The catalog flags these per-badge with a
criteriaVisibilityfield (visible|hint|hidden). Hidden-criteria badges typically also have expiration — they're not one-shot trophies but recurring slots (monthly is the default cadence, configurable per badge). Each expiration cycle re-evaluates against the (still-hidden) criteria; users who fall out of the top cohort lose the badge and can re-earn it next cycle. The rendering pipeline already handles lapse, so this is mostly a configuration shape on the badge definition. - Badge marketplace / global directory — future expansion, not in v1. Explicitly out of scope for the rollout below. Keep it on the roadmap as a follow-up feature: leaderboards, sort-by-fan-count creator discovery, hall-of-fame views. The data model doesn't need anything special for it —
user_badge_awardsis already the right shape — so no implementation cost is paid now to keep the option alive. - Hover-card / username-call depth — one badge in the regular user payload, the rest on demand. The standard user object (returned alongside comments, profile cards, chat author lookups) carries only the user's chosen "featured" badge — one row, cheap, fits in the existing cache. The full badge collection is fetched on demand as a single batch call when the user opens a profile or expands the badges drawer (same pattern as a followers list — load once, paginate if needed). No fan-out of N badge lookups per page render.
Dependencies
- Creator follows —
user_followsalready exists (follower → creator). Foundational for creator-scoped fan badges. - Project follows — planned, not yet built. Required before project-scoped fan badges can ship. Likely either a sibling
user_project_followstable or a generalization ofuser_followsto a polymorphic(target_type, target_id)shape. The project profile header (see Profile Customization) will also surface the follow action once this lands. - Conversation attribution — needs to reliably link a conversation back to the creator/project that owns the entities used. Most of this exists; verify coverage for packages and project-scoped content before relying on it for fan badges.
- Subscription state — already exists; tier badges read directly from
user_subscriptions. - Proposal system — already exists; Contributor badge is a count query.
- Profile customization — see Profile Customization. Showcase section type and creator's "Fan perks" panel hang off the existing profile editor.
- Notifications — earning, lapsing, and revoking are notification events; ride on the existing notification infrastructure plus the planned Notification Enhancements.
- Comments — shipped. Badge rendering hooks into the comment author component; comment highlighting is a Phase 3 perk built on top.
- Daily tasks / Echoes — see Daily Tasks and Echoes. If we ever wire badge rewards to Echoes, the ledger and idempotency primitives are already there.