Skip to content

[#928] Switch from MCap to FDV (price x max supply) on /airdrop and /token#934

Merged
realproject7 merged 1 commit intomainfrom
task/928-fdv-switch
Apr 22, 2026
Merged

[#928] Switch from MCap to FDV (price x max supply) on /airdrop and /token#934
realproject7 merged 1 commit intomainfrom
task/928-fdv-switch

Conversation

@realproject7
Copy link
Copy Markdown
Owner

Summary

Fixes #928

Switches all MCap references to FDV (Fully Diluted Valuation = price * 1,000,000 max supply):

  • lib/contracts/constants.ts — Added PLOT_MAX_SUPPLY = 1_000_000
  • Cron (airdrop-price): Stores FDV in mcap_usd column (price * max supply, not circulating)
  • useTokenInfo: Computes fdv = price * PLOT_MAX_SUPPLY (renamed from marketCap)
  • /token page: Label changed from "Market Cap" to "FDV"
  • Status API: Response field renamed currentMcap -> currentFdv
  • CampaignHero/MilestoneTrack: StatusData interfaces updated
  • WeeklySnapshots: Label changed from "MCap" to "FDV"

No Mint Club MCap API calls used for this calculation.

Test plan

  • Verify /token page shows "FDV" label with correct value
  • Verify /airdrop components reference FDV (not MCap)
  • Verify WeeklySnapshots shows "FDV:" label
  • Verify cron endpoint computes FDV correctly (price * 1M)
  • Verify milestone tracking still works with FDV values

🤖 Generated with Claude Code

…token

- Add PLOT_MAX_SUPPLY = 1,000,000 constant
- Cron: store FDV (price * 1M) in mcap_usd column instead of MCap
- useTokenInfo: compute FDV (price * max supply) instead of MCap
- /token page: label "FDV" instead of "Market Cap"
- Status API: rename currentMcap -> currentFdv in response
- CampaignHero/MilestoneTrack: update StatusData interfaces
- WeeklySnapshots: label "FDV" instead of "MCap"

FDV = PLOT USD price * 1,000,000 (max supply). No Mint Club MCap API.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@vercel
Copy link
Copy Markdown

vercel Bot commented Apr 22, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

1 Skipped Deployment
Project Deployment Actions Updated (UTC)
plotlink Ignored Ignored Apr 22, 2026 1:47am

Request Review

Copy link
Copy Markdown
Owner Author

@realproject7 realproject7 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

re2 verdict: APPROVE

Clean MCap→FDV switch across 9 files:

  • PLOT_MAX_SUPPLY = 1_000_000 added to shared constants
  • Cron stores price × PLOT_MAX_SUPPLY (FDV) instead of price × circulating supply (MCap)
  • Status API: currentMcapcurrentFdv
  • useTokenInfo: marketCapfdv, uses shared constant
  • Token page + WeeklySnapshots: labels updated
  • Component interfaces updated

Non-blocking note: The mcap_usd DB column now stores FDV going forward, but historical rows contain MCap values. This creates a data discontinuity in WeeklySnapshots for older weeks. Consider a column rename or backfill as follow-up.

No blocking issues.

Copy link
Copy Markdown
Collaborator

@project7-interns project7-interns left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Verdict: APPROVE

Summary

The PR switches the airdrop and token flows from MCap semantics to FDV semantics using the explicit max-supply constant, updates the main UI labels to "FDV", and updates the daily snapshot cron to store the FDV-based value used by milestone tracking.

Findings

  • None.

Decision

Approving. Residual risk is limited to the still-pending CI checks (e2e, lint-and-typecheck), but I did not find a code-level blocker in the reviewed changes.

@realproject7 realproject7 merged commit 99a54e0 into main Apr 22, 2026
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[Airdrop] Switch from MCap to FDV (price × max supply) on /airdrop and /token

2 participants