trpc-router

Route tRPC development tasks to targeted sub-skills for server, client, and adapters.

2|Updated Apr 11, 2026
One-click install
npx skills add https://github.com/PlazaCC/antes-da-tela --skill trpc-router
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: trpc-router
Source: https://github.com/PlazaCC/antes-da-tela/tree/main/.agents/skills/trpc-router
Command: npx skills add https://github.com/PlazaCC/antes-da-tela --skill trpc-router

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Large tRPC projects surface many decision points—server vs client setup, adapter selection, middleware composition, validation, error handling, caching, and real-time subscriptions—making it hard to know the next implementation step or best practice for a given goal. The trpc-router skill streamlines discovery by mapping a developer's intent to focused sub-skills and implementation patterns so the right guidance is delivered quickly.

Core Features & Use Cases

  • Decision-tree routing: Map high-level goals (initialize server, create client, add middleware, enable subscriptions) to specialized guidance and examples.
  • Adapter and integration guidance: Help choose and configure adapters (standalone, Express, Fastify, Edge/Lambda), client links, and SuperJSON transformers.
  • Validation, errors, and caching: Direct to patterns for Zod validators, typed errors, global formatting, and response caching strategies.
  • Use Case: Quickly determine how to wire up tRPC in a Next.js App Router with React Query, proper server context, and subscription support.

Quick Start

Use the trpc-router skill to route me to the correct sub-skill for setting up a Next.js App Router backend with React Query integration and subscription support.

Frequently Asked Questions about trpc-router

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I set up a tRPC server with Next.js App Router and React Query?

To set up a tRPC server with Next.js, you need to configure initTRPC, define procedures, and wire up the client link chain. This routing skill maps your Next.js App Router and React Query integration goals to focused implementation patterns for proper server context.

What is the best way to structure tRPC middleware and validation?

The best way to structure tRPC middleware is by composing reusable middleware functions within your procedure definitions. This skill directs you to specialized patterns for Zod validators, context injection, and middleware composition to ensure type-safe validation.

How do I add real-time subscriptions to my tRPC backend?

Adding real-time subscriptions to a tRPC backend requires configuring subscription procedures and client links. This skill routes your subscription setup goals to targeted guidance on implementing real-time features and handling the necessary context injection.

Can I use tRPC with Fastify, Express, or Edge adapters?

Yes, tRPC supports standalone, Express, Fastify, and Edge or Lambda adapters. This skill helps you choose and configure the correct adapter for your environment by mapping your platform requirements to specific adapter integration patterns.

How do I handle errors and caching in a tRPC application?

Handling errors and caching in tRPC involves implementing typed errors, global formatting, and response caching strategies. This skill routes you to focused guidance on configuring error handling patterns and optimizing response caching within your procedures.

When should I configure SuperJSON transformers in my tRPC client links?

You should configure SuperJSON transformers in your tRPC client links when you need to preserve type fidelity across the network for complex data types. This skill maps client configuration tasks to appropriate link chain and transformer setup patterns.