Cloud-native, microservices-based ERP system built with Rust and OpenAPI-first architecture
RERP (Rust Enterprise Resource Planning) is a next-generation, cloud-native ERP system designed from the ground up for modern enterprises. Built with Rust for performance and reliability, RERP delivers a modular microservices architecture that scales from startups to Fortune 500 companies.
Unlike traditional monolithic ERPs, RERP is architected as 71 independent microservices, each with its own OpenAPI specification, enabling rapid development, independent scaling, and seamless integration. The system follows an OpenAPI-first approach, generating type-safe services automatically from specifications using BRRTRouter.
- 🚀 Cloud-Native: Microservices architecture built for Kubernetes and cloud deployment
- ⚡ High Performance: Rust-based services delivering enterprise-grade performance
- 📐 OpenAPI-First: All services defined in OpenAPI 3.1.0, enabling rapid code generation
- 🔧 Modular: 71 independent services across 6 implementation phases
- 🔒 Type-Safe: Auto-generated handlers and types from OpenAPI specs
- 🌐 API Gateway: System-level BFF specs auto-generated from sub-services
RERP is a comprehensive Enterprise Resource Planning system that manages all aspects of business operations:
- Financial Management: Accounting, invoicing, budgeting, financial reporting
- Sales & CRM: Lead management, quotations, orders, customer relationships
- Inventory & Logistics: Stock management, warehouse operations, shipping
- Manufacturing: Production planning, BOM management, quality control
- Human Resources: Employee records, payroll, recruitment, performance management
- Project Management: Task tracking, timesheets, resource allocation
- Marketing & E-commerce: Campaign management, online stores, content management
- And More: 71 services covering every aspect of enterprise operations
mindmap
root((RERP System))
Phase 1: Core Foundation
Authentication & Authorization
IDAM
Identity Management
User Management
Session Management
RBAC
Role Management
Permission Control
Access Policies
Infrastructure
API Gateway
Request Routing
Load Balancing
Rate Limiting
Integration Platform
API Integration
Webhook Management
Data Transformation
Product Management
Catalog
Product Catalog
SKU Management
Category Management
Pricing
Dynamic Pricing
Price Rules
Discount Management
Tax
Tax Calculation
Tax Rules
Compliance
Phase 2: Business Operations
CRM
Core CRM
Lead Management
Contact Management
Opportunity Tracking
Automation
Workflow Automation
Email Automation
Task Automation
Live Chat
Chat Management
Customer Support
Real-time Communication
Sales
Sales Core
Sales Pipeline
Sales Forecasting
Sales Analytics
Quotation
Quote Generation
Quote Management
Quote Approval
Order
Order Processing
Order Fulfillment
Order Tracking
Subscription
Subscription Management
Recurring Billing
Subscription Analytics
Loyalty
Loyalty Programs
Points Management
Rewards System
Purchase
Purchase Core
Purchase Orders
PO Approval
Vendor Management
Vendor
Vendor Records
Vendor Performance
Vendor Contracts
Inventory
Inventory Core
Stock Management
Stock Movements
Stock Valuation
Warehouse
Warehouse Operations
Location Management
Picking & Packing
Logistics
Shipping Management
Carrier Integration
Delivery Tracking
Dropshipping
Dropshipping Orders
Supplier Integration
Inventory Sync
Phase 3: Financial & HR
Accounting
General Ledger
Chart of Accounts
Journal Entries
Account Reconciliation
Accounts Payable
Vendor Invoices
Payment Processing
AP Aging
Accounts Receivable
Customer Invoices
Payment Collection
AR Aging
Invoice
Invoice Generation
Invoice Management
Invoice Templates
Asset
Fixed Assets
Asset Depreciation
Asset Tracking
Budget
Budget Planning
Budget Tracking
Budget Reports
Financial Reports
P&L Reports
Balance Sheets
Cash Flow Reports
Bank Sync
Bank Reconciliation
Transaction Import
Bank Integration
EDI
EDI Processing
EDI Mapping
EDI Compliance
HR
HR Core
Employee Records
Employee Onboarding
Employee Offboarding
Payroll
Payroll Processing
Salary Management
Tax Deductions
Recruitment
Job Postings
Applicant Tracking
Interview Management
Attendance
Time Tracking
Attendance Records
Shift Management
Leave
Leave Requests
Leave Balance
Leave Policies
Appraisal
Performance Reviews
Goal Setting
Feedback Management
Skills
Skills Inventory
Skills Assessment
Training Management
Phase 4: Advanced Operations
Manufacturing
Manufacturing Core
Production Orders
Work Centers
Production Tracking
BOM
Bill of Materials
BOM Management
BOM Costing
Production Planning
Production Scheduling
Capacity Planning
Resource Allocation
Repair
Repair Orders
Repair Tracking
Warranty Management
Subcontracting
Subcontractor Management
Subcontract Orders
Quality Control
Project
Project Core
Project Management
Task Tracking
Resource Management
Timesheet
Time Tracking
Timesheet Approval
Project Billing
Phase 5: Customer-Facing
Marketing
Email
Email Campaigns
Email Templates
Email Analytics
Automation
Marketing Automation
Lead Nurturing
Campaign Management
Social Media
Social Integration
Social Publishing
Social Analytics
Website
CMS
Content Management
Page Builder
Media Library
Ecommerce
Online Store
Shopping Cart
Checkout Process
Builder
Website Builder
Theme Management
SEO Tools
POS
POS Core
Point of Sale
Offline Sales
Receipt Management
Payment Gateway
Payment Processing
Payment Methods
Payment Security
Helpdesk
Helpdesk Core
Ticket System
Ticket Routing
SLA Management
Knowledge Base
Knowledge Articles
FAQ Management
Search & Discovery
Field Service
Field Service Core
Service Scheduling
Technician Dispatch
Service History
Phase 6: Extensions
Marketplace
Marketplace Core
App Marketplace
Third-Party Apps
App Management
Integration Hub
Integration Management
Connector Library
Integration Monitoring
Analytics
BI
Business Intelligence
Data Warehousing
OLAP Cubes
Dashboards
Custom Dashboards
Widget Library
Real-time Updates
Reporting
Report Builder
Scheduled Reports
Report Distribution
Additional Services
AI
AI Core
AI Models
Machine Learning
Predictive Analytics
Document AI
Document Processing
OCR & Extraction
Document Intelligence
Automation
Workflow Automation
Process Automation
Rule Engine
Event Triggers
Appointments
Appointment Scheduling
Calendar Management
Booking System
Reminders
Approvals
Approval Workflows
Approval Chains
Approval Rules
Approval Tracking
Data
Data Cleaning
Data Quality
Data Validation
Data Enrichment
Documents
Document Management
Document Storage
Version Control
Document Sharing
ESG
ESG Compliance
Sustainability Tracking
ESG Reporting
Compliance Management
IoT
IoT Integration
Device Management
Data Collection
Real-time Monitoring
Localization
Localization Core
Multi-language Support
Currency Management
Regional Settings
Compliance
Regulatory Compliance
Tax Compliance
Legal Compliance
RERP follows a microservices architecture where each business function is an independent service:
flowchart TD
Gateway["API Gateway Layer<br/>(System-level BFF specs auto-generated)"]
Accounting["Accounting Services<br/>(9 services)"]
Sales["Sales Services<br/>(5 services)"]
HR["HR Services<br/>(7 services)"]
Common["Common Services<br/>(Auth, Infrastructure)"]
Gateway --> Accounting
Gateway --> Sales
Gateway --> HR
Accounting --> Common
Sales --> Common
HR --> Common
style Gateway fill:#e1f5ff,stroke:#01579b,stroke-width:3px
style Accounting fill:#f3e5f5,stroke:#4a148c,stroke-width:2px
style Sales fill:#e8f5e9,stroke:#1b5e20,stroke-width:2px
style HR fill:#fff3e0,stroke:#e65100,stroke-width:2px
style Common fill:#fce4ec,stroke:#880e4f,stroke-width:2px
Each service:
- Has its own OpenAPI 3.1.0 specification
- Can be developed, deployed, and scaled independently
- Follows the same patterns (generated + implementation crates)
- Integrates via well-defined APIs
Traditional ERP systems suffer from:
- Monolithic Architecture: Single codebase makes updates risky and slow
- Vendor Lock-in: Proprietary systems create dependency and high costs
- Poor Performance: Legacy codebases struggle with modern workloads
- Complex Integration: Difficult to connect with modern SaaS tools
- High Costs: Licensing fees, implementation costs, and maintenance overhead
- Slow Innovation: Large codebases resist rapid feature development
| Traditional ERP | RERP |
|---|---|
| Monolithic codebase | ✅ 71 independent microservices |
| Proprietary APIs | ✅ OpenAPI-first, open standards |
| Slow deployments | ✅ Independent service deployments |
| Vendor lock-in | ✅ Open source, self-hostable |
| Complex integrations | ✅ RESTful APIs, webhooks, event-driven |
| High licensing costs | ✅ Open source, no per-user fees |
| Legacy technology | ✅ Modern Rust, cloud-native |
- Cost Savings: No licensing fees, reduced infrastructure costs through efficient Rust services
- Flexibility: Deploy only the services you need, scale independently
- Speed: Rapid development through OpenAPI code generation
- Reliability: Rust's memory safety and performance reduce downtime
- Future-Proof: Cloud-native architecture adapts to changing needs
- Integration: API-first design enables seamless connections with modern tools
RERP uses an OpenAPI-first development approach:
- Define API: Write OpenAPI 3.1.0 specification for each service
- Generate Code: Use BRRTRouter to generate handlers, types, and routing
- Implement Logic: Add business logic in implementation crates
- Deploy: Each service runs independently
Each RERP service follows a consistent structure:
components/
├── {system}/
│ ├── {module}/ # Generated crate (from OpenAPI)
│ │ ├── Cargo.toml
│ │ ├── doc/
│ │ │ └── openapi.yaml # Service OpenAPI spec
│ │ └── src/ # Auto-generated code
│ └── {module}_impl/ # Implementation crate
│ ├── Cargo.toml
│ ├── config/
│ │ └── config.yaml
│ └── src/
│ ├── main.rs # Service entry point
│ └── controllers/ # Business logic
# 1. Define OpenAPI spec
vim openapi/accounting/general-ledger/openapi.yaml
# 2. Generate service code
cd components/accounting/general-ledger
brrtrouter-gen --spec ../../openapi/accounting/general-ledger/openapi.yaml
# 3. Implement business logic
vim ../general-ledger_impl/src/controllers/accounts.rs
# 4. Build and test
cargo build -p rerp_accounting_general_ledger_impl
cargo testSystem-level Backend for Frontend (BFF) specs are automatically generated:
# Regenerate all system BFF specs from sub-services
python3 scripts/generate_system_bff.pyThis aggregates all sub-service paths and schemas into unified system APIs, automatically kept in sync via GitHub Actions.
Current Phase: Foundation & Specification
- ✅ 71 Services Defined: Complete OpenAPI specifications with paths and schemas
- ✅ Crate Structure: 142 crates organized in Rust workspace (71 generated + 71 implementation)
- ✅ BFF Generation: Auto-generated system-level API gateway specs
- ✅ CI Automation: GitHub Actions for automatic BFF spec generation
- ⏳ Code Generation: Services ready for BRRTRouter code generation
- ⏳ Implementation: Business logic implementation in progress
RERP is organized into 6 implementation phases:
- Phase 1: Core Foundation (7 services) - Auth, infrastructure, product management
- Phase 2: Business Operations (14 services) - CRM, sales, purchase, inventory
- Phase 3: Financial & HR (16 services) - Accounting, HR management
- Phase 4: Advanced Operations (7 services) - Manufacturing, project management
- Phase 5: Customer-Facing (10 services) - Marketing, website, POS, helpdesk
- Phase 6: Extensions (5 services) - Marketplace, analytics, BI
See RERP_MUSINGS.md for detailed module breakdown and market analysis.
- Rust toolchain (stable)
- Python 3.12+ (for generation scripts)
- BRRTRouter (for code generation)
# Clone the repository
git clone https://github.com/microscaler/rerp.git
cd rerp
# View service specifications
ls openapi/*/openapi.yaml
# Check crate structure
ls components/*/
# Generate system BFF specs
python3 scripts/generate_system_bff.py# Navigate to a service
cd components/accounting/general-ledger
# Generate code from OpenAPI spec
brrtrouter-gen --spec ../../openapi/accounting/general-ledger/openapi.yaml
# Build the service
cargo buildrerp/
├── components/ # Rust workspace with all service crates
│ ├── Cargo.toml # Workspace configuration
│ ├── {system}/ # System directories
│ │ ├── {module}/ # Generated crate
│ │ └── {module}_impl/ # Implementation crate
│ └── common/ # Shared utilities
├── openapi/ # OpenAPI specifications
│ ├── {system}/ # System directories
│ │ ├── openapi.yaml # Auto-generated BFF spec
│ │ ├── README.md # System documentation
│ │ └── {module}/ # Service directories
│ │ ├── openapi.yaml # Service OpenAPI spec
│ │ └── README.md # Service documentation
├── scripts/ # Generation and automation scripts
│ ├── generate_system_bff.py
│ └── generate_complete_openapi.py
└── .github/
└── workflows/
└── generate-bff-specs.yml # CI automation
- RERP_MUSINGS.md - Detailed module breakdown, market analysis, and design rationale
- components/README.md - Crate structure and development guide
- openapi/README.md - OpenAPI specifications overview
All user-facing project documentation is located in the docs/ directory:
- docs/EXECUTIVE_SUMMARY.md - Executive summary and project overview
- docs/mermaid/ - Mermaid diagrams and visualizations
- docs/adrs/ - Architecture Decision Records (ADRs)
RERP is in active development. We welcome contributions from developers at all levels!
See CONTRIBUTING.md for:
- Getting started as a contributor
- Development workflow and guidelines
- Code standards and best practices
- Testing requirements
- Areas for contribution
- Language: Rust (for performance and safety)
- Framework: BRRTRouter (OpenAPI-first HTTP router)
- API Specification: OpenAPI 3.1.0
- Architecture: Microservices, cloud-native
- Deployment: Kubernetes-ready, containerized services
- Define 71 service specifications
- Create crate structure (142 crates)
- Generate OpenAPI specs with paths and schemas
- Set up system-level BFF generation
- Implement CI automation
- Generate code from OpenAPI specs
- Implement core services (Phase 1)
- Add comprehensive testing
- Deploy to cloud infrastructure
- Build community and ecosystem
Licensed under either of:
- Apache License, Version 2.0 (LICENSE-APACHE or http://www.apache.org/licenses/LICENSE-2.0)
- MIT license (LICENSE-MIT or http://opensource.org/licenses/MIT)
at your option.
- Issues: GitHub Issues
- Discussions: GitHub Discussions
RERP is inspired by:
- Odoo: Comprehensive modular ERP approach
- ERPNext: Open-source ERP philosophy
- BRRTRouter: OpenAPI-first development methodology
Built with ❤️ using Rust and open-source principles.