Skip to main content

nest-trpc-native

Decorator-first tRPC integration for NestJS with full Nest lifecycle support

🎯

Decorator-First

Define routers, queries, mutations, and subscriptions using familiar NestJS decorators. No manual wiring needed.

🔄

Full Nest Lifecycle

Guards, interceptors, pipes, and filters work exactly as they do with HTTP controllers. Request scope included.

🔌

Adapter-Agnostic

Works with both Express and Fastify out of the box. Switch adapters without changing a single line of router code.

🛡️

Type-Safe End to End

Auto-generated AppRouter types with Zod schema inference. Full compile-time safety from server to client.

📦

Zero Dependencies

No hidden runtime dependencies. Pure bridge between NestJS and tRPC using only peer dependencies you already have.

Zod Optional

Use tRPC-style Zod schemas or Nest-style class-validator DTOs. Choose what fits your project best.