tRPC Procedures API

tRPC procedures exposed as REST endpoints

Work with this as data

Every API here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for apis

7 MCP tools reach this
  • find_apisBrowse and filter every API in the catalog.
  • get_api_artifactsOne API's artifacts, grouped by type.
  • get_openapiThe primary OpenAPI for this API.
  • find_similar_apisAPIs that look like this one.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools

Call it yourself

curl for this page
This API
curl "https://apis.io/api/v1/apis/trpc-procedures-api"
All apis
curl "https://apis.io/api/v1/apis?limit=25"

Discovery needs no key. Ratings and market analysis are Pro.

Get an API key

Free tier, no email required.

A second provider on the same verified email joins the account you already have.

OpenAPI Specification

trpc-procedures-api-openapi.yml Raw ↑
openapi: 3.0.3
info:
  title: tRPC OpenAPI Example Procedures API
  description: 'This is a representative OpenAPI specification demonstrating how tRPC procedures are exposed as REST endpoints using the trpc-openapi adapter. tRPC itself is a TypeScript framework for building end-to-end typesafe APIs. When combined with trpc-openapi (or trpc-to-openapi), tRPC procedures are mapped to standard HTTP REST endpoints with full OpenAPI documentation.

    This spec represents the standard HTTP API surface exposed by a tRPC server using the fetch or standalone adapter, following tRPC''s HTTP protocol conventions.'
  version: 11.0.0
  contact:
    name: tRPC
    url: https://trpc.io
  license:
    name: MIT
    url: https://github.com/trpc/trpc/blob/main/LICENSE
servers:
- url: https://your-server.example.com/api/trpc
  description: tRPC server endpoint
security:
- BearerAuth: []
tags:
- name: Procedures
  description: tRPC procedures exposed as REST endpoints
paths:
  /health:
    get:
      summary: Health Check
      description: Returns the health status of the tRPC server. This is a standard unauthenticated endpoint for monitoring and load balancer health checks.
      operationId: healthCheck
      tags:
      - Procedures
      security: []
      responses:
        '200':
          description: Server is healthy
          content:
            application/json:
              schema:
                type: object
                properties:
                  ok:
                    type: boolean
                    example: true
  /batch:
    post:
      summary: Batch Procedures
      description: Execute multiple tRPC procedures in a single HTTP request. tRPC clients automatically batch requests made concurrently using httpBatchLink.
      operationId: batchProcedures
      tags:
      - Procedures
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              description: A map of procedure call index to the procedure input. Keys are numeric indices (0, 1, 2...) for each procedure.
              additionalProperties:
                type: object
                properties:
                  json:
                    description: Procedure input serialized as JSON
      responses:
        '207':
          description: Multi-status batch response
          content:
            application/json:
              schema:
                type: array
                items:
                  oneOf:
                  - $ref: '#/components/schemas/TRPCSuccessResult'
                  - $ref: '#/components/schemas/TRPCErrorResult'
        '400':
          $ref: '#/components/responses/BadRequest'
  /{procedure}:
    get:
      summary: Query Procedure
      description: Invoke a tRPC query procedure. Queries are read-only operations and map to HTTP GET requests. Input is passed via the `input` query parameter as a JSON-encoded string.
      operationId: queryProcedure
      tags:
      - Procedures
      parameters:
      - name: procedure
        in: path
        required: true
        description: The procedure path (e.g., `userRouter.getUser`, `post.list`). Nested routers use dot notation.
        schema:
          type: string
      - name: input
        in: query
        description: JSON-encoded procedure input
        schema:
          type: string
      - name: batch
        in: query
        description: Enables batching mode for this single request
        schema:
          type: string
          enum:
          - '1'
      responses:
        '200':
          description: Procedure result
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/TRPCSuccessResult'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '404':
          $ref: '#/components/responses/NotFound'
    post:
      summary: Mutation Procedure
      description: Invoke a tRPC mutation procedure. Mutations cause side effects and map to HTTP POST requests. Input is passed in the request body.
      operationId: mutationProcedure
      tags:
      - Procedures
      parameters:
      - name: procedure
        in: path
        required: true
        description: The mutation procedure path
        schema:
          type: string
      requestBody:
        required: false
        content:
          application/json:
            schema:
              type: object
              properties:
                json:
                  description: Procedure input
      responses:
        '200':
          description: Procedure result
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/TRPCSuccessResult'
        '400':
          $ref: '#/components/responses/BadRequest'
        '401':
          $ref: '#/components/responses/Unauthorized'
components:
  responses:
    Unauthorized:
      description: Unauthorized - protected procedure requires authentication
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/TRPCErrorResult'
    BadRequest:
      description: Bad request - invalid input or procedure not found
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/TRPCErrorResult'
    NotFound:
      description: Procedure not found
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/TRPCErrorResult'
  schemas:
    TRPCSuccessResult:
      type: object
      description: A successful tRPC procedure result
      properties:
        result:
          type: object
          properties:
            data:
              description: The procedure output, serialized as JSON
              type: object
              properties:
                json:
                  description: The actual return value from the procedure
    TRPCErrorResult:
      type: object
      description: A tRPC procedure error result
      properties:
        error:
          type: object
          properties:
            json:
              type: object
              properties:
                message:
                  type: string
                  description: Human-readable error message
                code:
                  type: integer
                  description: tRPC error code
                data:
                  type: object
                  properties:
                    code:
                      type: string
                      description: tRPC error type (e.g., NOT_FOUND, UNAUTHORIZED)
                    httpStatus:
                      type: integer
                    stack:
                      type: string
                      description: Stack trace (development only)
                    path:
                      type: string
                      description: The procedure path that errored
  securitySchemes:
    BearerAuth:
      type: http
      scheme: bearer
      description: Bearer token for protected procedures