MantisBase
View on GitHub

Coming Soon

Open-source C++ BaaS toolkit. One binary, full backend, anywhere. <12MB (4MB compressed).

Auto REST API

Autogenerated REST API endpoints based on database schema

Database Support

SQLite by default, PostgreSQL support on Linux

Built-in Auth

Basic authentication included

JS Scripting

Scripting support using JS for quick hooks

Admin Dashboard

Built-in admin dashboard for database tables management

Script Authorization

Script-based authorization for records

Quick Start

mantis --dev serve # start serving on default port 7070

Scripting

app.router().addRoute("GET", "/someapi/method/:arg", function(req, res){
    // Check if path params are available
    if(req.hasPathParam("arg")) {
        const arg = req.getPathParam("arg")
        const db_connected = app.db().connected

        // res.text(200, "Hello World")
        // res.empty(204)
        // res.send(200, "response as text", "text/plain")
        res.json(200, {path: arg, connected: db_connected})
        return
    }

    // Or send response in this format
    res.send(500, JSON.stringify({error: "Dummy Error"}), "application/json")
})