Nest Rs Mcp Macros
БесплатноНе проверенInternal — the #[mcp] and #[tools] decorator macros; re-exported by nest-rs-mcp, not a direct dependency.
Описание
Internal — the #[mcp] and #[tools] decorator macros; re-exported by nest-rs-mcp, not a direct dependency.
README
The Rust framework for modular, scalable backends.
You write the business logic; the framework carries the rest — modules, decorators and dependency injection over a native core.
~17× less memory · ~20× faster cold starts · ×2 the throughput of NestJS 12 on node:http, its fastest adapter, on a guarded route, core for core — byte-identical contract, harness in the repo.
7.0 is the foundation the next versions build on: one way to declare each concern, one contract on every edge, a boot that refuses what would fail later — and no 7.x release breaks what you build on it. What's new in 7.0 →
What it is
You write business logic; the framework carries the rest — authn, authz, row-level tenant filtering, per-field masking, transactions, discovery, and lifecycle. Those concerns are transparent to your code and verified at boot, not left to review discipline.
A full authenticated, tenant-scoped, transactional, field-masked CRUD resource
is an empty impl block:
#[controller(path = "/orgs")]
#[use_guards(AuthnGuard, AuthzGuard)]
pub struct OrgsController {
#[inject]
svc: Arc<OrgsService>,
}
#[crud(service = OrgsService)]
impl OrgsController {}
The differentiator is structural multi-tenant isolation you cannot forget:
row-level filtering, response masking, and transactions become non-optional the
moment the security modules are imported. A feature opts out by not importing
them. In NestJS, Spring, Rails, axum, or Loco, tenant filtering is discipline —
a scope you remember, a middleware you apply, a review comment. In NestRS it is
structural: the data layer applies it from the caller's ability, and an
operation with no declared access posture is refused — at compile time on
GraphQL, at boot on HTTP. MCP gets the same guarantee across the whole
protocol, not tools/call alone: scope, ability and transaction reach
prompts/get, resources/read, completion and the tasks/* trio, so a
Repo-backed prompt is row-filtered exactly like a controller.
The architecture is a modular monolith, deployed per workload — the goal Google's Service Weaver set: the development velocity of a monolith, with the scalability of microservices. Your domain lives once, in a shared crate, cut into modules whose boundaries are checked at boot; each binary — the API, the worker, the WebSocket server — is a thin composition root importing only the edges it serves, and one binary importing them all is a plain monolith. The binaries share the code and the database, hand work over through the queue, and each scales on its own signal, with no generated RPC between them. The architecture, drawn →
The numbers behind the tagline, measured 2026-11-11 on NestRS 7.0 against the
same service in NestJS 12.4 on node:http — its NodeAdapter, which NestJS
recommends and measures ahead of Express and Fastify, so the slower adapters are
not raced — idiomatic on both sides, byte-identical HTTP contract,
conformance-gated, each server pinned to one core:
| One core each | NestRS 7.0 | NestJS 12.4 · node:http | |
|---|---|---|---|
| Hello world, JSON through DI | ~201k req/s · p99 0.43 ms | ~154k req/s · p99 0.81 ms | ×1.3 |
| Guarded route (guard + interceptor) | ~183k req/s · p99 0.46 ms | ~93k req/s · p99 1.32 ms | ×2.0 |
| JSON request body | ~196k req/s · p99 0.46 ms | ~94k req/s · p99 1.31 ms | ×2.1 |
| Streamed body | ~173k req/s · p99 0.53 ms | ~44k req/s · p99 6.75 ms | ×4.0 |
| Memory idle | 6 MB | 103 MB | ×17 |
| Cold start → first 200 | ~10 ms | ~220 ms | ×22 |
On a bare hello world the gap is a third; as soon as the framework does a
framework's work — a guard, an interceptor, a request body, a stream — it is ×2
to ×4, with a tail two to thirteen times shorter. Given four cores, one NestRS
process takes them all (×1.8 to ×3.5), where Node runs one ~100 MB process per
core. Measured on a 14-core Apple-silicon host in a Linux VM, so a floor, not a
ceiling; the benchmarks page has every tier and
the protocol, the harness lives in bench/, and cd bench && just bench runs it on your own hardware.
Try it on your machine:
cargo install --locked nest-rs-cli
nestrs new hello && cd hello
nestrs run dev # → Hello World on :3000
Adding NestRS to a crate you already have is one dependency. Every
capability — http, graphql, seaorm, ws, mcp, queue, schedule, … —
is a feature of the umbrella, and a feature you leave off is code you never
compile. No decorator ever asks you to declare a second crate:
cargo add nest-rs --features http,seaorm
→ Why not axum? · Coming from NestJS · Why NestRS
What ships
Every concern below is a module you import and a Cargo feature you can leave off — a headless worker compiles no HTTP stack. Each has a reference section on nestrs.dev.
| Concern | What ships |
|---|---|
| Transports | HTTP controllers with versioning, extractors, uploads, streaming, static files · OpenAPI 3 + Swagger UI from the route table · GraphQL with dataloaders, subscriptions and federation · WebSocket gateways · MCP tools, prompts and resources · guards, pipes, interceptors and exception filters, one pipeline on every edge |
| Data | SeaORM entities, Repo, ambient transactions, pagination, migrations, seeding · S3-compatible object storage |
| Security | JWT on a shared secret, EdDSA keys or a JWK Set, OAuth 2.0 client with PKCE, token endpoint and protected resource metadata, Argon2id passwords, social login · abilities, row-level filtering, per-field masking, one policy across every transport |
| Background work | Valkey-backed queues with retries, cron schedules that run on one replica when asked, a typed in-process event bus |
| Platform | Typed config with an .env cascade · liveness/readiness/startup probes · rate limiting · OpenTelemetry logs, traces, metrics, your own reqwest client's calls included · Server-Timing |
| Tooling | The nestrs CLI — scaffold, generate a feature or an adapter, run, migrate · an in-process test harness booting the real DI graph |
What holds it up
Claims a clone of this repository lets you check:
- 77 decorators, one per integration contract, each expanding to plain Rust
you can print with
cargo expand— the index is on nestrs.dev/decorators. - 7,000+ tests across the framework workspace, with the end-to-end suites running against live Postgres, Valkey and S3 rather than mocks — the dev container brings all three up before you get a shell.
- Rules held by the toolchain — types that make the wrong code
unwritable,
clippy.toml's resolved-path lints, and behaviour tests; what none of them can hold is review's.
Stability
NestRS is stable and ready for production. No 7.x release breaks what you
build on — your code, your configuration, the names your log filters and
alerts match — and the semver policy says
exactly what that covers. Every nest-rs-* crate publishes at the same version
in lockstep, so one NestRS version names exactly one compatible resolution —
down to the third-party libraries you write in your own code (sea-orm,
async-graphql, rmcp, validator, schemars), whose majors move only with
a NestRS major.
Coming from 6.x? Upgrading from 6.x is the order that moves a 6.1 project to 7.0, and changelog/7.0.md lists every change with its reason.
Documentation
Using NestRS? Head to nestrs.dev — getting started, tutorial, why NestRS, the axum comparison, and one section per capability crate.
Contributing to the framework? This README is your entry point. For the layout and conventions, read CLAUDE.md and CONTRIBUTING.md.
Contributing
Anyone who can clone the repo can iterate on the framework — the dev container brings up Rust, Postgres and Valkey in one step.
Get the dev container running
- Install Docker and the VS Code Dev Containers extension.
- Open the repo in VS Code and accept Reopen in Container.
cd demo && nestrs run dev api— the main Publish API onhttp://localhost:3002(runnestrs run db upfirst).
The container provisions the Rust toolchain and dev tooling (just, bacon,
cargo-nextest, …), and brings up Postgres and Valkey beside it with
<PREFIX>_SEAORM__URL / <PREFIX>_REDIS__URL already pointed at them. nestrs run dev
runs under bacon — every save triggers an incremental rebuild and a restart.
The runnable apps live in their own workspace under demo/ — cd demo
first; that directory is where nestrs run, the .env cascade, and the
database/test recipes resolve.
Prefer a local toolchain? See Getting started → Scaffold and start.
Project layout
Two Cargo workspaces, split along the framework/product line.
nestrs/
├─ crates/ the framework — nest-rs (the umbrella apps install)
│ │ over one nest-rs-* compilation unit per capability
│ ├─ nest-rs-core/ IoC container, modules, DI, bootstrap
│ ├─ nest-rs-http/ REST controllers & routing
│ └─ … (members = ["crates/*"])
├─ docs/ the nestrs.dev site (Astro Starlight)
└─ demo/ the product — its own workspace, consumes the framework
├─ apps/ one runnable binary each (the Publish workspace)
│ ├─ auth/ OAuth2 / JWT token issuer
│ ├─ api/ REST + GraphQL + OpenAPI, persisted & authorized
│ ├─ assistant/ Model Context Protocol server
│ ├─ live/ real-time WebSocket gateway
│ └─ worker/ background jobs & scheduling (headless)
├─ crates/
│ ├─ features/ product features — port + adapters (users, posts, authn, …)
│ ├─ migrations/ shared-database SeaORM migrations (CLI)
│ └─ seed/ shared-database demo data (CLI)
├─ Justfile, db.just, test.just, .env*, Dockerfile
└─ (members = ["apps/*", "crates/*"])
The demo/ workspace references the framework by relative path — one
workspace dependency, nest-rs = { path = "../crates/nest-rs", features = [ …] }, exactly the shape a real app has — so it builds against the live
framework source. You cd demo and drive it as if it were the app's own
repository — see demo/README.md for running the apps, the
command table, the Publish map, and Docker.
crates/nest-rs-*/— the framework: generic, product-agnostic building blocks, reached through thenest-rsumbrella rather than named one by one.demo/apps/<name>/—main.rs+module.rslisting the edge modules the binary serves.demo/crates/features/— the product's vertical slices; apps import the edges they serve.
Adding an app means a directory under demo/apps/; a new feature means a folder
under demo/crates/features/src/; a new framework capability means a nest-rs-*
crate under crates/. The hello and blog layouts are generated on
demand by nestrs new rather than checked in, so they never drift from the
framework — see Getting started and the
tutorial.
Running the apps
Everything runnable lives in demo/ — cd demo first, then
nestrs run (no args lists every recipe). The full command table, the Publish
app map, and the Docker build are documented in
demo/README.md.
Community & contributing
NestRS is stable and actively developed — contributors shape where it goes next, and you don't have to write Rust to help.
- 💬 Ask a question, propose an idea, or just say hi in Discussions.
- 🐛 Report a bug or request a feature through issues.
- 🌱 Pick up a good first issue — CONTRIBUTING.md is the short path from idea to merged PR.
- 🗺️ See what just shipped in the changelog.
- 🔒 Found a vulnerability? Follow SECURITY.md — please don't open a public issue for it.
If NestRS is useful to you, a ⭐ helps other Rust teams find it.
License
MIT — see LICENSE.
Установка Nest Rs Mcp Macros
У этого сервера нет опубликованного пакета — он собирается из исходников. Открой репозиторий и следуй инструкции в README.
▸ github.com/YV17labs/NestRSFAQ
Nest Rs Mcp Macros MCP бесплатный?
Да, Nest Rs Mcp Macros MCP бесплатный — установка в пару кликов через Unyly без оплаты.
Нужен ли API-ключ для Nest Rs Mcp Macros?
Нет, Nest Rs Mcp Macros работает без API-ключей и переменных окружения.
Nest Rs Mcp Macros — hosted или self-hosted?
Self-hosted: сервер запускается локально на твоей машине командой из раздела установки.
Как установить Nest Rs Mcp Macros в Claude Desktop, Claude Code или Cursor?
Открой Nest Rs Mcp Macros на unyly.org, выбери вкладку своего клиента (Claude Desktop, Claude Code, Cursor) и нажми Install — конфиг сгенерируется автоматически, без правки JSON.
Похожие MCP
GitHub
PRs, issues, code search, CI status
автор: GitHubFilesystem
Secure file operations with configurable access controls.
Memory
Knowledge graph-based persistent memory system.
Template MCP Server
A CLI tool to create a new Model Context Protocol server project with TypeScript support, dual transport options, and an extensible structure
автор: mcpdotdirectServer Sequential Thinking
MCP server for sequential thinking and problem solving
автор: GitHub ActionsUnyly Deploy
Deploy sites and MCP servers to Unyly straight from your AI agent
автор: UnylyAmap Maps Mcp Server
MCP server for using the AMap Maps API
автор: duxiaohuiPayMCP
Lightweight payments layer for MCP servers: turn tools into paid endpoints with a two-line decorator. [PyPI](https://pypi.org/project/paymcp/) · [npm](https://w
автор: blustAIServer For Power BI
Enables exploring Microsoft Fabric / Power BI workspaces and semantic models, and executing ad-hoc DAX queries.
автор: Mitsubishi-FusoGpt Image 2 Mcp
RunAPI GPT Image 2 MCP server for image generation: create tasks, poll results, and check pricing across 1 model from Claude Code, Codex, Cursor, and VS Code.
автор: runapi-aiCompare Nest Rs Mcp Macros with
Не уверен что выбрать?
Найди свой стек за 60 секунд
Автор?
Embed-бейдж для README
Похожее
Все в категории development
