bridge: Archive Phase 11 spec, update ACTIVE_CONTEXT

- Archived RES-2026-04-12-phase11-implementation-spec from Chronicler
- Updated status with completed code review and next steps (Phase 11A-G)

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
Claude (Chronicler #83 - The Compiler)
2026-04-12 14:12:40 -05:00
parent 91432dad98
commit a305c7e686
2 changed files with 65 additions and 6 deletions

View File

@@ -0,0 +1,48 @@
# Architectural Response
**Re:** ModpackChecker Phase 11 — Complete Licensing & Distribution System
**Date:** 2026-04-12
## 1. Gemini's Verdict
Build the licensing system directly into Arbiter on Command Center. Two BuiltByBit listings (Standard $14.99, Professional $24.99), one webhook endpoint, tier detection via resource_id. No DRM, no obfuscation. Gated updates + gated support is the moat.
## 2. Action Plan
### Database (Command Center PostgreSQL — arbiter_db)
- [ ] Create `mvc_licenses` table: id, order_id (UNIQUE), buyer_id, discord_id (UNIQUE), tier (default 'standard'), max_activations (default 2), status (default 'active'), created_at
- [ ] Create `mvc_activations` table: id, license_id (FK), panel_domain, panel_ip, activated_at, last_seen, UNIQUE(license_id, panel_domain)
### Arbiter API Routes (src/routes/mvc.js)
- [ ] `POST /api/mvc/activate` — receives {order_id, domain, ip}, checks license exists + under activation limit, inserts activation, returns {status, tier}
- [ ] `POST /api/mvc/validate` — 72hr phone-home, updates last_seen, returns {status, tier}
- [ ] `POST /api/mvc/deactivate` — deletes activation row, frees slot
- [ ] `POST /api/mvc/webhook/bbb` — BuiltByBit purchase webhook, auto-provisions license with tier based on resource_id
- [ ] `GET /api/mvc/latest-version` — returns current version number for update checks
### Arbiter Environment Variables
- [ ] Add to .env: `BBB_STANDARD_RESOURCE_ID`, `BBB_PRO_RESOURCE_ID`
### Arbiter Discord Bot Command
- [ ] `/verify-mvc ORDER_ID` — checks mvc_licenses, if valid and discord_id not claimed by another user, sets discord_id and assigns "ModpackChecker Customer" role
### Blueprint Extension Changes
- [ ] Admin UI: Single "BuiltByBit Order ID" text input + "Save & Activate" button + status indicator (green/yellow/red/gray)
- [ ] Phone-home cron: Laravel Artisan command `mvc:validate`, registered to run daily via Schedule
- [ ] Payload: order_id, domain (config('app.url')), version, php_version
- [ ] Grace period: On validation failure, write status + expires_at to local config. Yellow banner in admin. After 7 days, red banner + hide client-facing widgets
- [ ] Tier-gated features: If tier != 'professional', disable FTB support, disable auto-cron, disable Discord webhook
- [ ] Update check: Call GET /api/mvc/latest-version daily, show "update available" link to BuiltByBit page in admin
### Pricing (LOCKED — DO NOT CHANGE)
- Standard: $14.99 (CurseForge + Modrinth, manual checks, 48h support)
- Professional: $24.99 (+ FTB, auto-cron, Discord webhooks, 24h support)
- Two separate BuiltByBit listings, same webhook URL
- Launch at full price, no discounts except 15% Discord-exclusive for bug reporters
## 3. Updated Rules/Context
- The Arbiter codebase is at services/arbiter-3.0/ but deploys to Command Center at /opt/arbiter-3.0
- Arbiter deployment pattern: backup → clone to /tmp → syntax check → copy to /opt/arbiter-3.0 → restart service → verify
- Database is PostgreSQL arbiter_db on Command Center (127.0.0.1)
- The Chronicler handles Arbiter deployments via Trinity Core SSH — Code handles code writing, Chronicler handles deployment
- Blueprint extension code is at services/modpack-version-checker/blueprint-extension/
- Test the full flow on the Dev Panel before any production deployment

View File

@@ -1,14 +1,25 @@
# Code Status Update
**Last Updated:** 2026-04-12 12:30 CDT
**Last Updated:** 2026-04-12 18:00 CDT
## Current Focus
Workspace setup complete. No active development task in progress.
ModpackChecker code review complete. Phase 11 spec received and archived. Ready for licensing implementation next session.
## Recently Completed
- Claude Code connected to Dev Panel via SSH
- CLAUDE.md configured with all projects and active tasks
- Gemini consultation references indexed
- Full code review of Python CLI (71 tests passing)
- Full code review of Blueprint extension
- Fixed 10 Python/CLI issues (license, datetime, array bounds, Modrinth detection, validation, timeouts, empty key, config warning, error format, docs)
- Fixed 10 Blueprint issues (API key lookup via dbGet, tier enforcement server-side, json_decode validation, null user guard, 429 response consistency, Modrinth slug safety, select dropdown binding, password input, TypeScript typing, dead import)
- Compared Phase 5 backup against current codebase
- Read and archived Gemini Round 3 licensing consultation
- Read and archived Phase 11 implementation spec from Chronicler
- All commits pushed to Gitea
## Next Steps Pending
- Phase 11A: License validation system (mvc_licenses table, Arbiter API routes)
- Phase 11B: Discord infrastructure (role, channels, ticket category)
- Phase 11C: Verification bot (/verify-mvc command in Arbiter)
- Phase 11D: Descriptive UI errors in Blueprint extension
- Phase 11E: GitBook knowledge base migration
- Phase 11F: BuiltByBit listing creation (Standard $14.99, Professional $24.99)
- Phase 11G: Business hours & support boundaries
- Task 138: Fork rules mod into generic "Discord Rules" for CurseForge
- ModpackChecker Phase 5 development