Getting started
10-minute path from zero to a running Arqen application.
Prerequisites
- Rust 1.96+ (edition 2024): install via rustup
- pnpm (for building docs only): install via
npm install -g pnpm - Docker (optional): needed for thingd HTTP mode and
arqen upservices
Verify your Rust installation:
bash
rustc --version # should show 1.96 or newer
cargo --versionInstall the CLI
From a repository checkout:
bash
cargo install --path crates/arqen --features cliOr run directly without installing:
bash
cargo run -p arqen --features cli --bin arqen -- --helpCreate a project
bash
arqen new hello-api
cd hello-apiThis generates:
text
hello-api/
Cargo.toml # depends on arqen 0.6 with logging + http-server
README.md
rustfmt.toml # formatting config
clippy.toml # lint config
src/
main.rs # entry point
app/mod.rs # AppModule (Module trait)Run the project
bash
cargo runExpected output:
text
Arqen v0.5.0
API: http://127.0.0.1:8888
Health: http://127.0.0.1:8888/health
Docs: http://127.0.0.1:8888/docs
Agent: http://127.0.0.1:8888/agent
Storage: memoryTest the endpoints
bash
curl http://127.0.0.1:8888/health
curl http://127.0.0.1:8888/ready
curl http://127.0.0.1:8888/agent
curl http://127.0.0.1:8888/agent/manifest
curl http://127.0.0.1:8888/docsLint and test
bash
arqen lint # check formatting + clippy
arqen test # run all testsAdd your first module
bash
arqen generate module usersThis creates src/users/mod.rs. Register it in src/app/mod.rs:
rust
mod users;
// In AppModule:
fn dependencies(&self) -> Vec<&str> {
vec!["users"]
}Add your first tool
bash
arqen generate tool get_userThis creates src/tools/get_user.rs. Register it in your module's register() method:
rust
fn register(&self, ctx: &mut ModuleContext<'_>) -> Result<(), AppError> {
crate::tools::get_user::register(ctx)?;
Ok(())
}Add your first job
bash
arqen generate job send_emailThis creates src/jobs/send_email.rs with a JobHandler stub.
Run from the workspace
If you prefer not to install the CLI:
bash
cargo run -p arqen --features cli --bin arqen -- new hello-apiNext steps
- Commands - full CLI reference
- Configuration - environment variables and config files
- Modules - module composition and lifecycle
- Typed tools - structured tool definitions
- Logging - structured logs, fields, and redaction
- Application hardening - production boundaries
- Durable jobs - background job processing
- Authentication - JWT and API key auth
- Validation - request validation
- Health - health and readiness checks
- Deployment - production deployment
- Examples - code snippets and examples