NestJS-like API framework for Rust built on Axum and Tower.
nestrs gives you a familiar module/controller/provider mental model with Rust performance and explicit typing.
- Module-oriented architecture (
module,controller,injectablemacros) - HTTP route macros (
get,post,put,patch,delete,options,head,all) - DI + application context
- DTO validation pipeline and class-validator-style ergonomics
- Cross-cutting pipeline: guards, pipes, interceptors, exception filters, strategies
- Production controls: backpressure, metrics, request tracing, security runbooks
- Performance hardening workflows: benchmark gating (HTTP, DI, validated JSON), history tracking, dashboard artifacts; scheduled libFuzzer smoke runs
- Maintainer / code owner: @Joshyahweh
- Current workspace version:
0.3.8(fromVERSIONand workspace package settings) - Release notes template:
.github/release-template.md - Changelog:
CHANGELOG.md - Contribution guide:
CONTRIBUTING.md - Release process:
RELEASE.md - Code of conduct:
CODE_OF_CONDUCT.md - Security disclosure policy:
SECURITY.md - Licenses:
LICENSE-MITandLICENSE-APACHE
- Rust edition:
2021(workspace-level) - MSRV:
1.88(tested in CI as1.88.0) - CI matrix: MSRV +
stable+beta - Contributor note: keep new crates on
edition.workspace = trueandrust-version.workspace = trueunless there is a documented exception
nestrs/- main framework crate (public runtime API)nestrs-core/- runtime primitives (context, traits, metadata, strategy)nestrs-macros/- proc macros and helper attributesnestrs-cli/- scaffold/generate CLI (crates.io package name:nestrs-scaffold, binary:nestrs)nestrs-prisma/- Prisma integration cratenestrs-microservices/- transport/client/event primitivesnestrs-openapi/,nestrs-graphql/,nestrs-ws/- parity extension crateswebsite/- landing page + docs hub (light/dark theme)
cargo check --workspace
cargo test --workspacecargo run -p hello-appIf the example package name differs in your local setup, run:
cargo run --manifest-path examples/hello-app/Cargo.tomlpython3 -m http.server 4173Then open:
http://localhost:4173/website/(landing page)http://localhost:4173/website/docs.html(documentation hub)
website/docs.html- docs portal entrypoint- NestJS → nestrs — mdBook:
docs/src/nestjs-migration.md; website hub:website/docs/migration/nestjs-to-nestrs.md - Security defaults & ordering — mdBook:
docs/src/secure-defaults.md,docs/src/http-pipeline-order.md CHANGELOG.md- release historySTABILITY.md- semver, public vs#[doc(hidden)]API,test-hooks/ global registries
PRODUCTION_RUNBOOK.md- deployment/operations runbookSECURITY.md- security guidance and controlsMICROSERVICES.md- microservices/event-driven patterns
benchmarks/BASELINE.md- how to run, compare, and track benchmarksbenchmarks/relative_thresholds.json- active relative regression gate confignestrs/fuzz/andnestrs-microservices/fuzz/-cargo-fuzztargets (seePRODUCTION_RUNBOOK.md)
BENCHMARK_STORAGE_PLAYBOOK.md- long-term storage layout and restore workflowBENCHMARK_STORAGE_SECRETS_CHECKLIST.md- provider setup checklist (OIDC/least privilege).github/workflows/benchmark-storage-sync.yml- manual-dispatch storage sync template
# benchmark gates
python3 scripts/load/check_benchmark_thresholds.py
python3 scripts/load/check_benchmark_relative_regression.py
# benchmark reports and recommendation artifacts
python3 scripts/load/export_benchmark_report.py
python3 scripts/load/maintain_benchmark_history.py
python3 scripts/load/build_benchmark_dashboard.py
python3 scripts/load/recommend_relative_thresholds.py
python3 scripts/load/evaluate_threshold_reassessment.py.github/workflows/security.yml- security checks.github/workflows/ci.yml- PR/push checks on MSRV + stable + beta, plus fmt/clippy/docs/audit.github/workflows/performance.yml- performance benches, gating, reporting, optional publishing.github/workflows/fuzz.yml- weekly libFuzzer smoke (wire JSON, auth header, URI/JSON).github/workflows/benchmark-storage-sync.yml- storage sync template for S3/GCS/Azure.github/workflows/release-version-check.yml- enforcesVERSIONand latestCHANGELOG.mdrelease heading stay in sync.github/workflows/publish-crates.yml- tag-driven crates.io publish after preflight; usesCARGO_REGISTRY_TOKEN(optional OIDC/trusted publishing can replace this)
.github/ISSUE_TEMPLATE/bug_report.yml.github/ISSUE_TEMPLATE/feature_request.yml.github/ISSUE_TEMPLATE/config.yml.github/pull_request_template.md
The tracked roadmap implementation is complete. Ongoing work is maintenance mode: periodic benchmark history accumulation and threshold re-evaluation when data changes.