api-router
Prerequisite: This skill requires a schema0 template project. Before using, ensure
CLAUDE.mdexists in the project root and read it for project rules and conventions.
API Router Generator
Create ORPC routers with CRUD handlers. AI creates files following this pattern.
File Location
Create at: packages/api/src/routers/{entity}.ts
Dependencies
flowchart TD
A[schema-gen] --> B[api-router]
Prerequisite: Run schema-gen skill first to create the database schema. The schema file in packages/db/src/schema/{entity}.ts MUST already export insert{Entity}Schema and update{Entity}Schema (generated by drizzle-zod) before creating the router.
More from schema0/ai-agent-plugins
manage-secrets
Add and manage application secrets and environment variables. Use when adding API keys, credentials, or updating env.ts.
2schema-gen
Generates database table schema with Drizzle ORM (project)
2rls-setup
Set up database tables with Row-Level Security policies, configure authenticated connections, and implement secure user-scoped data access patterns (Do not apply this skill unless specifically asked by user) (project)
2workflow-builder
>-
2handle-views
Generates route components - List Route and Detail Route (project)
2ai-integration
Generate AI-powered features using AI SDK with oRPC. Use when building chat apps, AI endpoints, or integrating LLMs.
2