Enterprise-grade Business Management Platform built with Domain-Driven Design and Hexagonal Architecture
Skeleton is a modular business management platform designed for small and medium businesses — from retail shops and service companies to manufacturing firms. The system adapts to your business model: enable the contexts you need, disable the rest.
- Retail & Trade: orders, invoices, inventory, catalog, procurements
- Manufacturing: bills of materials, production orders, work orders, raw material tracking
- Services: contracts, documents, approvals, time tracking
- Accounting & Finance: double-entry bookkeeping, journal entries, reconciliation, full reporting
| Code | Language |
|---|---|
en |
English |
uk |
Українська |
de |
Deutsch |
Business context documentation is available in all 3 languages in docs/contexts/. The frontend (Office) supports all 3 languages with runtime switching.
The system is composed of 18 autonomous bounded contexts, each responsible for a cohesive business capability. Contexts communicate exclusively through domain events — no direct imports between contexts.
| Context | Capability | Docs |
|---|---|---|
| Identity | Authentication, RBAC, sessions, JWT | en · uk · de |
| Parties | Customers, suppliers, partners, employees, loyalty, credit limits | en · uk · de |
| Ordering | Orders, order lines, quotes, cancellation, status transitions | en · uk · de |
| Invoicing | Invoices, credit notes, payments, installment plans | en · uk · de |
| Accounting | Chart of accounts, double-entry, journal entries, periods, reconciliation | en · uk · de |
| Catalog | Products, categories, variants, pricing rules | en · uk · de |
| Inventory | Warehouses, stock, movements, lots, reservations, WMS operations | en · uk · de |
| Procurements | Purchase orders, goods receipts, supplier invoices | en · uk · de |
| Manufacturing | Bills of materials, production orders, work orders, work centers | en · uk · de |
| Contracts | Contract lifecycle, amendments, auto-renewal, payment/delivery terms | en · uk · de |
| Documents | Templates, digital signatures, approval workflows | en · uk · de |
| Messenger | Direct and group conversations, message history, full-text search | en · uk · de |
| Reports | Dashboard, revenue, accounting reports, analytics (14 reports) | en · uk · de |
| Notifications | Email, SMS, push, in-app; templates, preferences, background delivery | en · uk · de |
| Audit | Immutable cross-context action audit trail | en · uk · de |
| Tasks | Background jobs, cron schedules, retry logic, dead-letter queue | en · uk · de |
| Files | Upload, image processing, storage (local / S3-ready) | en · uk · de |
| Status | Health checks, readiness probes, system info | en · uk · de |
The Reports context provides 14 built-in reports:
| Report | Description |
|---|---|
| Dashboard | Key metrics: revenue, orders, customers, stock alerts |
| Revenue | Revenue trends by day/week/month |
| Top Customers | Customer ranking by purchase volume |
| Accounts Summary | Balances by account type |
| Low Stock Alerts | Items below reorder point |
| Aging Receivables | Overdue invoices grouped by 30/60/90+ days |
| Customer Acquisition | New customers over time |
| Order Status | Order distribution by status |
| Trial Balance | Opening/turnover/closing balances per account |
| General Ledger | Posted journal entries with cursor pagination |
| Profit & Loss | Revenue vs expenses, net profit |
| Balance Sheet | Assets, liabilities, equity snapshot |
| Cash Flow | Operating/investing/financing flows |
| Tax Report | Tax liabilities, payments, amounts due |
Detailed business-oriented documentation in docs/contexts/ (3 languages):
docs/contexts/
├── en/ # English
├── uk/ # Українська
└── de/ # Deutsch
Generate PDFs:
make context-docs # All languages
make context-docs-en # English only
make context-docs-uk # Ukrainian only
make context-docs-de # German only| Document | Description |
|---|---|
| ARCHITECTURE.md | System architecture, CQRS, hexagonal, bounded contexts |
| CONTEXT_MATURITY.md | Context maturity status (Scaffold→Hardened), sprint history |
| SETUP.md | Installation, prerequisites, environment configuration |
| DEVELOPMENT.md | Developer workflow, conventions, new context scaffolding |
| API.md | REST API reference with request/response examples |
| adr/README.md | Architecture Decision Records index (ADR-001 – ADR-026) |
| development/GETTING_STARTED.md | Quick start guide with API examples |
| deployment/DOCKER_ENVIRONMENTS.md | Docker environments (dev/staging/prod/test) |
| MAKEFILE_REFERENCE.md | All make commands quick reference |
ADR records in docs/adr/, index — docs/adr/README.md.
skeleton/
├── backend/ # Go API server
│ ├── cmd/api/ # Entry point + Wire injector
│ ├── internal/ # Bounded contexts (DDD)
│ │ ├── accounting/ # Accounts, transactions, journal entries
│ │ ├── audit/ # Audit trail
│ │ ├── catalog/ # Product catalog
│ │ ├── contracts/ # Contract lifecycle, amendments
│ │ ├── documents/ # Templates, signatures, approvals
│ │ ├── files/ # File uploads, processing
│ │ ├── identity/ # Auth, RBAC, sessions
│ │ ├── inventory/ # Stock, warehouses, movements
│ │ ├── invoicing/ # Invoices, payments, credit notes
│ │ ├── manufacturing/ # BOMs, production orders, work orders
│ │ ├── notifications/ # Email, templates, preferences
│ │ ├── ordering/ # Orders, quotes
│ │ ├── parties/ # Customers, suppliers, partners, employees
│ │ ├── procurements/ # Purchase orders, goods receipts
│ │ ├── reports/ # Dashboard, analytics, accounting reports
│ │ ├── status/ # Health checks, system info
│ │ └── tasks/ # Background jobs, schedules
│ ├── pkg/ # Shared packages
│ │ ├── eventbus/ # In-memory + Redis event bus
│ │ ├── money/ # Money value object (int64 cents)
│ │ ├── pagination/ # Cursor-based pagination
│ │ ├── apierror/ # RFC 7807 error responses
│ │ └── ...
│ ├── migrations/ # SQL migrations by context
│ └── scripts/ # Seed, migrate utilities
├── web/ # Frontend applications
│ ├── office/ # Back-office UI (Angular + PrimeNG)
│ └── commerce/ # E-commerce UI (Angular + PrimeNG)
├── docs/ # Documentation
│ ├── contexts/ # Business context docs (3 languages)
│ │ ├── en/ # English
│ │ ├── uk/ # Українська
│ │ ├── de/ # Deutsch
│ │ └── pdf/ # Generated PDFs
│ └── ...
├── docker-compose.yml # Development environment
└── Makefile # Build automation
git clone https://github.com/basilex/skeleton.git
cd skeleton
# Install dependencies
make install
# Start PostgreSQL + Redis
make db-up
# Run migrations
make db-migrate
# (Optional) Seed sample data
make db-seed
# Start backend (Terminal 1)
make backend
# Start frontend (Terminal 2)
make office- Email:
admin@skeleton.local - Password:
Admin123! - Role:
super_admin(full access*:*)
All endpoints require JWT authentication and RBAC permissions.
# Auth
POST /api/v1/auth/login
POST /api/v1/auth/register
POST /api/v1/auth/refresh
# Parties
CRUD /api/v1/customers
CRUD /api/v1/suppliers
# Ordering
CRUD /api/v1/orders
POST /api/v1/orders/:id/lines
POST /api/v1/orders/:id/cancel
# Invoicing
CRUD /api/v1/invoices
CRUD /api/v1/credit-notes
# Accounting
CRUD /api/v1/accounts
CRUD /api/v1/journal-entries
CRUD /api/v1/accounting-periods
CRUD /api/v1/reconciliations
# Catalog
CRUD /api/v1/catalog/items
CRUD /api/v1/catalog/categories
CRUD /api/v1/catalog/variants
CRUD /api/v1/catalog/pricing-rules
# Inventory
CRUD /api/v1/warehouses
CRUD /api/v1/stock
CRUD /api/v1/stock-takes
# Procurement
CRUD /api/v1/purchase-orders
CRUD /api/v1/goods-receipts
# Manufacturing
CRUD /api/v1/boms
CRUD /api/v1/production-orders
CRUD /api/v1/work-orders
# Contracts & Documents
CRUD /api/v1/contracts
CRUD /api/v1/documents
# Reports
GET /api/v1/reports/dashboard
GET /api/v1/reports/trial-balance
GET /api/v1/reports/general-ledger
GET /api/v1/reports/profit-and-loss
GET /api/v1/reports/balance-sheet
GET /api/v1/reports/cash-flow
GET /api/v1/reports/tax
Full API documentation: docs/API.md
| Decision | Approach |
|---|---|
| Architecture | Hexagonal (ports & adapters) + CQRS |
| Domain model | DDD: aggregates, value objects, domain events |
| Database | PostgreSQL 16+ with pgx/v5 driver, custom auto-migration |
| Access control | RBAC with wildcards (*:*, users:*, users:read) |
| Pagination | Cursor-based (UUID v7) |
| Money | int64 cents (never float) |
| DI | Google Wire (compile-time) |
| Event Bus | In-memory + Redis (pub/sub) |
| HTTP | Gin with middleware: auth, RBAC, rate limit, recovery |
make help # Show all commands
make dev # Docker-compose up
make backend # Wire generate + run API
make backend-build # Compile backend binary
make office # Start office dev server (port 4200)
make db-up # Start PostgreSQL + Redis
make db-migrate # Run migrations (up)
make db-seed # Seed sample data
make test # Run all backend tests
make lint # Run linters
make context-docs # Generate PDFs for all languagesFull reference: docs/MAKEFILE_REFERENCE.md
MIT License — see LICENSE.