A modern, simple studio for testing and exploring tRPC endpoints.
demo.mov
Note: This package supports tRPC@11 and zod@4. Consider contributing if you need other schema engines or new features.
npm install @trpc-studio/introspection
# or
yarn add @trpc-studio/introspectionimport { initTRPC } from '@trpc/server';
import { addIntrospectionEndpoint } from '@trpc-studio/introspection';
const t = initTRPC.create();
const router = t.router
export const appRouter = addIntrospectionEndpoint(
router({
// Your router/procedures
})
);
// You also need to enable cors for the origin https://trpc-studio.vercel.appimport { initTRPC } from '@trpc/server';
import { addIntrospectionEndpoint } from '@trpc-studio/introspection';
const t = initTRPC.create();
const router = t.router;
const mainRouter = router({
// Your router/procedures
});
export const appRouter =
process.env.NODE_ENV === 'development'
? addIntrospectionEndpoint(mainRouter)
: mainRouter;
// You also need to enable cors for the origin https://trpc-studio.vercel.app2. Visit tRPC Studio
# Install dependencies
yarn install
# Start development server
yarn devContributions are welcome! Please feel free to submit a Pull Request.
This project is licensed under the MIT License - see the LICENSE file for details.