slave-framework 0.1.1

Runtime for slave apps (a Laravel-inspired Rust framework for MCP-first apps): server lifecycle, config, logging, Turso database and migrations, password hashing and bearer tokens
docs.rs failed to build slave-framework-0.1.1
Please check the build logs for more information.
See Builds for ideas on how to fix a failed build, or Metadata for how to configure docs.rs builds.
If you believe this is docs.rs' fault, open an issue.
Visit the last successful build: slave-framework-0.6.0

slave-framework

The runtime behind applications created with slave, a Laravel-inspired Rust framework for MCP-first apps. You normally get it through slave new rather than adding it by hand.

Module Provides
server serve(router, host, port): an Axum server with graceful shutdown on Ctrl+C / SIGTERM
env .env loading and typed settings (var_or, parse_or)
logging tracing setup driven by RUST_LOG
database (feature database) Local Turso connections
migration (feature database) Migrations with batches, status and rollback, plus the console used by slave migrate
auth (feature auth) Argon2id password hashing (with timing-safe checks for unknown accounts) and random bearer tokens stored as SHA-256 hashes

Both features are on by default. Web apps in a slave workspace depend on it with default-features = false and use only server, env and logging.

#[tokio::main]
async fn main() -> slave_framework::Result<()> {
    slave_framework::env::load_dotenv()?;
    slave_framework::logging::init()?;
    let router = axum::Router::new();
    slave_framework::server::serve(router, "127.0.0.1", 3000).await
}

See the slave README for the full framework. License: MIT.