BASE

oRPC

oRPC

Backend / API library · Free

TypeScript tools for end-to-end APIs with OpenAPI and RPC: they connect procedure contracts, validation, and a typed client.

Also known as: unnoq/orpc; orpc; typesafe-apis

Resource illustration: oRPC

Open resource ↗

What you can use for free

Code and local use under MIT.

Paid features and costs

Computing resources, self-hosting, and external services are paid for separately if used.

Access and limitations

Code and local use under MIT. Computing resources, self-hosting, and external services are paid for separately if used.

Use cases

  • Align a typed API between client and server
  • Connect a handler and typed client, then test an RPC or OpenAPI scenario

Example workflow

A possible workflow; this is not a report of hands-on testing.

Align a typed API between client and server.

Before you start

  • A data contract or HTTP workflow.
  • A project with a supported runtime.

Steps

  1. Define the procedure contract, input schema, and result.
  2. Connect a handler and typed client, then test an RPC or OpenAPI scenario.
  3. Add error handling and an integration check of the result.

Check your result

  • Invalid and missing data are handled predictably.
  • Types and the actual response agree; errors are not hidden.

Choosing oRPC

Align a typed API between client and server

Choose this when

  • Align a typed API between client and server
  • Connect a handler and typed client, then test an RPC or OpenAPI scenario

Things to consider

  • Costs and limits of free use: Computing resources, self-hosting, and external services are paid for separately if used.
  • Terms of use: MIT for the code; dependencies have separate licenses.
  • Middleware must call next to continue the chain. With multiple input schemas, ordinary objects merge only two levels deep; output schemas are processed sequentially rather than merged.

Frequently asked questions

What can you use for free in oRPC?

Code and local use under MIT.

What additional costs might arise with oRPC?

Computing resources, self-hosting, and external services are paid for separately if used.

What terms of use matter for oRPC?

MIT for the code; dependencies have separate licenses.

How do you get started with oRPC?

Define the procedure contract, input schema, and result. Connect a handler and typed client, then test an RPC or OpenAPI scenario. Add error handling and an integration check of the result.

How does oRPC combine data validation with a procedure handler?

The procedure builder defines input/output schemas, context, metadata, typed errors, and middleware; the handler implements logic. Zod, Valibot, ArkType, and other Standard Schema libraries support validation. API contracts, server/client, and OpenAPI adaptation are separate packages, so contracts can be implemented and used independently.

License

MIT for the code; dependencies have separate licenses.

MIT — permissive license

You can use, modify, distribute, and sell the code, including in a closed-source commercial product. When sharing copies or substantial portions of the code, retain the license text and copyright notice. You do not need to open-source your entire project; the author provides no warranties.

License terms

Technologies and topics

  • oRPC
  • API
  • Development

Sources

Other resources