Sponsored byOutsenseAI that finds your next clients
SponsorGROUOutbound, LinkedIn content and leads for B2B teamsSponsorOutsenseAI that finds your next clientsAd+Your tool hereSeen by people installing AI tools@Weekly picksThe best new tools, one email a week

nestjs-trpc

Skill by omkshirsagar2914-pixel

Teaches an AI assistant to build end-to-end type-safe tRPC APIs inside NestJS with the nestjs-trpc adapter. It is for developers who want a typed API between a Nest backend and a frontend.

  • Score 63
  • 37 stars
  • MIT
  • Updated
Works withClaude CodeClaude apps Antigravity CLI

Install nestjs-trpc

Built from the published package, never by AI.

git clone --depth 1 https://github.com/omkshirsagar2914-pixel/trycompai-crm /tmp/trycompai-crm && mkdir -p ~/.claude/skills && cp -r /tmp/trycompai-crm/.agents/skills/nestjs-trpc ~/.claude/skills/nestjs-trpc

Run in your terminal. Claude Code loads skills from ~/.claude/skills automatically.

Step-by-step: install nestjs-trpc in Claude Code

Skills can run scripts on your machine. Some need an API key: check the README.

About

This skill covers the nestjs-trpc adapter for NestJS. It explains how to define tRPC procedures as decorated classes using @Router, @Query, @Mutation and @Subscription, how to register them with TRPCModule.forRoot, and how to add injectable middlewares and context. It also covers Zod input and output schemas. Routers are written as NestJS classes, and a Rust CLI reads those decorators to generate an AppRouter type for clients. The skill separates runtime wiring from type generation, lists the setup steps and common failure points, and notes errata in the official docs. It is aimed at developers building a typed API between a Nest backend and a frontend, or migrating a NestJS GraphQL or REST API to tRPC.

Written from the project's SKILL.md and checked against it.

What it can do

  • Define proceduresWrites tRPC queries, mutations and subscriptions as decorated NestJS router classes.
  • Register the moduleSets up TRPCModule.forRoot with context, providers and the mount path.
  • Add middlewaresApplies injectable middlewares at global, router or procedure level.
  • Build contextCreates a per-request context class implementing TRPCContext.
  • Validate with ZodUses Zod input and output schemas to type and validate procedure data.
  • Generate AppRouter typeRuns the nestjs-trpc CLI to emit the AppRouter type for client code.
  • Fix known doc errorsLists v1-era examples in the official docs that break a v2 build.

What you need

  • NestJS project (v9.3.8 or later)
  • tRPC v11 (@trpc/server)
  • Zod 3.14 or later, or Zod 4
  • TypeScript with experimentalDecorators and emitDecoratorMetadata enabled
  • npm

Try asking

  • Create a tRPC user router in my NestJS app with a query and a mutation.
  • Add a protected middleware to my nestjs-trpc procedures and pass user context.
  • Set up TRPCModule.forRoot and generate the AppRouter type for my React client.

Good to know

  • Targets nestjs-trpc v2.x, verified against 2.13.0.
  • Requires tRPC v11. tRPC v10 will not work.
  • The CLI's schema flattening is built around Zod.
  • Nest HttpException is not translated into a tRPC error and surfaces as an opaque 500.

Security check

A

No download-and-run commands, hidden instructions or signs of sending keys out were found.

Checked automatically: .agents/skills/nestjs-trpc/SKILL.md. This looks for known risky patterns and is not a full audit. How grades work

Alternatives to nestjs-trpc

All alternatives →
openclaw-github-repo-commandersickn33
94

Runs a 7-stage workflow for auditing, cleaning up and reviewing GitHub repositories, plus competitor analysis. Written for developers who want a repo checked for secrets, junk files and documentation gaps.

AAA Skill 50k
gradiogradio-app
94

Teaches an AI assistant to build, debug and explain Gradio web UIs and ML demos in Python. It covers the core API, components, event listeners, layouts and the MCP server option. Aimed at Python developers who work with Gradio.

AAA Skill 44k
hig-components-menussickn33
94

Recommends menus, buttons, toolbars and disclosure controls for Apple platforms using Human Interface Guidelines conventions. Built for developers and designers making iOS, iPadOS, macOS or visionOS interfaces. Checks existing project design context before asking questions.

AAA Skill 50k
fastapi-templateswshobson
94

Creates production-ready FastAPI project structures with async patterns, dependency injection, and error handling. It is for developers starting new FastAPI applications or backend API projects.

AAA Skill 43k
appfunctionsandroid
94

Analyzes Android apps to find user workflows to expose as AppFunctions, so AI agents and system shortcuts can run them without opening the app UI. Generates Kotlin code and refines KDoc for Android developers.

AAA Skill 11k
agent-qa-authoringsickn33
94

Creates, edits, validates and runs Agent QA tests, suites and hooks through MCP or CLI. It keeps canonical IDs and schema contracts intact, for developers and QA teams using Agent QA.

AAA Skill 50k

Compare with openclaw-github-repo-commander, gradio or hig-components-menus

nestjs-trpc: common questions

Why are my nestjs-trpc procedures missing at runtime?

The source says a router that is not listed in the module providers is the most common reason procedures silently do not exist. Routers, middlewares and the context class must all be ordinary providers.

Can I use a validator other than Zod with nestjs-trpc?

The source says any Standard Schema validator works, such as Valibot or ArkType. It recommends staying on Zod because the CLI's schema flattening is built around it.

Does the official nestjs-trpc documentation match v2?

The source says the published docs mix v1 and v2 content and still contain v1-era examples, such as autoSchemaFile and @Context(). The skill lists these errata.

How do I install nestjs-trpc?

Run the command above to copy the skill into ~/.claude/skills/. Claude Code picks it up automatically.

Is nestjs-trpc free?

The code is published under the MIT licence. The service it connects to may have its own pricing.

Is nestjs-trpc safe to use?

It scores 63 of 100. Grades: maintenance C, licence A, quality C. Security check: grade A, no risky patterns found in the files checked. Review the code before you install. How grades work.

What are alternatives to nestjs-trpc?

Similar skills: openclaw-github-repo-commander, gradio, hig-components-menus, fastapi-templates.

nestjs-trpc Install

Add to stack

Loading.