What problem does it solve?
Generates scalable, repeatable Next.js 16 API route boilerplates for gnubok with consistent authentication guards, Supabase client usage, event emission, and robust error handling.
Core Features & Use Cases
- Route Template: Standard Next.js 16 API route scaffold with per-request authentication guards, user-scoped data filters, and error signaling.
- Event Emission: Supports emitting domain events after successful operations, with ensureInitialized() invoked at module scope.
- Journal Entry Handling: Integrates non-blocking and blocking journal entry creation aligned with business logic.
- Use Case: Create endpoints for entities like invoices, customers, or vouchers using a uniform pattern.
Quick Start
Create a new Next.js 16 API route under app/api using the ERP API Route Generator template, integrating auth guards, Supabase client usage, event emission, and journal entry handling.