Backend Modules Specification Directory
Welcome to the Backend Modules section of the MetaPilot documentation. Every backend Django application is documented using a uniform 15-Point Module Specification Template.
Core Modules Index
- users Module: Custom User model, 4-tier roles (), managers, setup views, and CLI scripts.
UserRole - tenants Module: Tenants, Agencies, , Fernet AES-256 encryption,
TenantConfig, andTenantMiddleware.AuditLog - campaigns Module: WhatsApp broadcast marketing campaigns, recipient targeting, and campaign states.
- templates Module: WhatsApp HSM message templates, placeholders, and approval statuses.
- messaging Module: Customer conversations, inbound/outbound messages, and media handling.
- inbox Module: Realtime agent inbox, Django Channels WebSockets, consumers, and event groups.
- chatbot Module: Platform AI assistant, WhatsApp AI auto-responders, and OpenRouter integration.
- scheduler Module: Celery task runner, Cron schedules, and Token Bucket rate limiter.
- notifications Module: System alerts, unread counter badges, and notification triggers.
Standardized 15-Point Specification Structure
Every module document strictly includes:
- Purpose & Overview
- Responsibilities
- Directory Structure
- Models & Database Schemas
- Services & Business Logic
- Serializers & Data Transfer Objects
- Views & API Endpoints
- Permissions & Role Rules
- Signals & Event Listeners
- Background Tasks & Celery Jobs
- Data Flow & External Dependencies
- Business Rules & Validations
- Sequence Diagram (Mermaid)
- Known Limitations & Technical Debt
- Future Improvements