feat: Implement Phase 4 module licensing backend
All checks were successful
Test Asgard Runner / test (push) Successful in 2s
All checks were successful
Test Asgard Runner / test (push) Successful in 2s
Build complete module activation and license-module binding system with marketplace catalog, purchase tracking, and installation status monitoring. Database schema (migration 009): - modules table — Registry with pricing, features, plugin URLs - module_purchases — License-module ownership with transaction logging - module_installations — Deployment status tracking - Seed data: Loot Manager module ($9.99) Backend implementation: - Domain models with rust_decimal pricing support - 11 data access functions (catalog, ownership, purchases, installation) - 5 REST endpoints with JWT auth and license scoping - Multi-tenant enforcement via license_id from claims Purchase flow stub: - Immediate purchase recording without payment gateway - PayPal integration deferred to XO's direct implementation - Transaction ID and amount fields ready for real gateway Module installation: - Integration with ModuleInstaller service - NATS-based deployment to companion agent - Real-time status tracking via polling endpoint All queries compile-time verified. Zero cross-tenant exposure. Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
This commit is contained in:
@@ -131,6 +131,7 @@ async fn main() -> anyhow::Result<()> {
|
||||
.nest("/api/analytics", api::analytics::router())
|
||||
.nest("/api/plugin", api::plugin::router())
|
||||
.nest("/api/settings", api::settings::router())
|
||||
.nest("/api/modules", api::modules::router())
|
||||
.layer(cors)
|
||||
.layer(TraceLayer::new_for_http())
|
||||
.with_state(state);
|
||||
|
||||
Reference in New Issue
Block a user