Build real backends in C++. One runtime. One system. No glue.
The Vix core module is the foundation of the runtime.
It provides:
- HTTP server
- routing system
- request / response model
- async execution
- configuration system (.env)
- OpenAPI generation
- offline API documentation (Swagger UI)
Everything you need to build APIs. Nothing extra.
Most C++ backends are built with:
- multiple libraries
- inconsistent abstractions
- manual wiring
- fragile integrations
Vix core gives you a coherent backend system:
- one router
- one request model
- one runtime
- one config system
No fragmentation.
curl -fsSL https://vixcpp.com/install.sh | bash#include <vix.hpp>
int main()
{
auto exec = std::make_shared<vix::executor::RuntimeExecutor>();
vix::App app{exec};
app.get("/", [](auto&, auto& res) {
res.json({
"message", "Hello from Vix",
"framework", "Vix.cpp"
});
});
app.run(8080);
}app.get("/hello/{name}", [](vix::Request& req, vix::Response& res) {
res.json({
"message", "Hello " + req.param("name")
});
});req.param()→ path paramsreq.query()→ query stringres.json()→ JSON responseres.text()→ text responseres.file()→ static files
Handlers are async-ready:
vix::async::core::task<void> handle_request(
const Request& req,
Response& res);No blocking required. The runtime handles scheduling.
vix::config::Config cfg{".env"};
int port = cfg.getServerPort();
bool async = cfg.getLogAsync();No JSON. No parsing boilerplate.
auto spec = vix::openapi::build_from_router(router);- no annotations required
- stable operationId
- full JSON output
vix::openapi::register_openapi_and_docs(router);This adds:
- GET /openapi.json
- GET /docs
- GET /docs/index.html
- GET /docs/swagger-ui.css
- GET /docs/swagger-ui-bundle.js
All assets are embedded and served locally.
Open:
http://localhost:8080/docs
You get:
- interactive API UI
- live requests
- no internet required
Core is designed for:
- clarity over abstraction
- explicit over magic
- runtime consistency
- production readiness
No hidden layers. No implicit behavior.
- REST APIs
- microservices
- backend platforms
- internal tools
- realtime systems (with websocket module)
examples/http/
examples/websocket/
Vix core is not a framework layer. It is the runtime foundation.
Everything else builds on top of it.
Learn more about the Vix runtime in the documentation.
MIT License.