Nexus Mainframe is a modular C++20 framework for building event-driven applications on Windows and Linux. It provides a plugin-based architecture, REST/WebSocket API, MQTT integration, cron scheduling, and flexible configuration management.
- Modular plugin system — dynamically load/unload
.dll/.somodules at runtime - REST API — HTTP server on port 8080 with device, room, module, and config endpoints
- WebSocket server — real-time event streaming
- MQTT client — configurable broker connection
- Cron scheduler — cron expression-based task scheduling via croncpp
- EventBus — decoupled publish/subscribe communication between components
- IPC — TCP command server on port 9999
- MCP server — Model Context Protocol support
Requirements: C++20 compiler, CMake 3.20+, Ninja, OpenSSL (Linux/macOS)
# Debug
cmake -B build -G Ninja
cmake --build build
# Release
cmake -B build -G Ninja -DCMAKE_BUILD_TYPE=Release
cmake --build build
# With tests
cmake -B build -G Ninja -DNEXUS_BUILD_TESTS=ON
cmake --build build
ctest --test-dir build| Method | Path | Description |
|---|---|---|
| GET | /api/status |
Health check |
| GET | /api/health |
Uptime, MQTT status, loaded modules |
| GET | /api/metrics |
Memory and runtime metrics |
| GET | /api/modules |
List loaded modules |
| POST | /api/modules/:name/enable |
Load a module |
| POST | /api/modules/:name/disable |
Unload a module |
| GET | /api/devices |
List devices |
| POST | /api/devices |
Add a device |
| DELETE | /api/devices/:id |
Remove a device |
| GET | /api/rooms |
List rooms |
| GET/PATCH | /api/config |
Read or update configuration |
MIT — see LICENSE for details.
