Changelog
August 4, 2026
🚀 Features
- rpc: Restrict RPC handlers to POST, PUT, PATCH and DELETE by default - by @dinwwwh in https://github.com/middleapi/orpc/issues/1778 (59952)
🐞 Bug Fixes
- nest: Apply method-level decorators to router-contract
@Implementroutes - by @dinwwwh in https://github.com/middleapi/orpc/issues/1776 (a0afe)
View changes on GitHub
August 3, 2026
🚀 Features
- Re-export renamed v1 APIs as deprecated aliases - by @dinwwwh in https://github.com/middleapi/orpc/issues/1758 (74807)
- contract:
- Error factory - by @dinwwwh in https://github.com/middleapi/orpc/issues/1760 (4dc08)
- Validate data in error factory constructor - by @dinwwwh in https://github.com/middleapi/orpc/issues/1765 (24021)
- effect:
- Add catchORPCError, catchORPCErrorCode and catchORPCErrorCodes utils - by @dinwwwh in https://github.com/middleapi/orpc/issues/1766 (d9d03)
- hibernation:
- Hibernation APIs - by @dinwwwh in https://github.com/middleapi/orpc/issues/1763 (db548)
- rpc, openapi:
- AWS Lambda and Fastify adapters - by @dinwwwh in https://github.com/middleapi/orpc/issues/1767 (504ff)
- server:
- Describe batch binary responses with a dedicated content type - by @dinwwwh in https://github.com/middleapi/orpc/issues/1761 (f53ba)
🐞 Bug Fixes
- Keep nested clients and utils referentially stable - by @dinwwwh in https://github.com/middleapi/orpc/issues/1757 (46bd0)
- client: Match subclasses in ORPCError cross-context instanceof check - by @dinwwwh in https://github.com/middleapi/orpc/issues/1762 (4b865)
🏎 Performance
- client: Remove redundant default instanceof fallback in ORPCError - by @dinwwwh in https://github.com/middleapi/orpc/issues/1764 (72597)
View changes on GitHub
July 30, 2026
🚀 Features
- zod,valibot,arktype: Add option to cache generated JSON schemas - by @dinwwwh in https://github.com/middleapi/orpc/issues/1753 (21251)
🐞 Bug Fixes
- server: Make callable extension type augmentation work in published builds - by @keithf123r in https://github.com/middleapi/orpc/issues/1755 (10e1e)
View changes on GitHub
July 29, 2026
🚀 Features
- Upgrade standardserver to 0.6.0 - by @dinwwwh in https://github.com/middleapi/orpc/issues/1748 (85215)
🐞 Bug Fixes
- openapi:
- Serialize headers in detailed input/output structures - by @dinwwwh and @KingSora in https://github.com/middleapi/orpc/issues/1743 (5b554)
- Only treat actual array values as multi-value headers when serializing - by @dinwwwh in https://github.com/middleapi/orpc/issues/1745 (37e88)
- pino,evlog:
- Only treat thrown ORPCError as business error - by @dinwwwh in https://github.com/middleapi/orpc/issues/1746 (b589b)
- rpc,openapi:
- Concurrent lazy router resolution, and faster route matching - by @dinwwwh in https://github.com/middleapi/orpc/issues/1736 (cfe89)
- shared:
- Prevent prototype injection in set util - by @dinwwwh in https://github.com/middleapi/orpc/issues/1744 (48b9a)
🏎 Performance
- rpc,openapi: Speed up RPC and OpenAPI serializers - by @dinwwwh in https://github.com/middleapi/orpc/issues/1731 (53280)
View changes on GitHub
July 26, 2026
🚨 Breaking Changes
- openapi: Replace shouldHoistDef with customComponentName option in generator - by @dinwwwh in https://github.com/middleapi/orpc/issues/1728 (69418)
🐞 Bug Fixes
- json-schema: Safer value coercion and smarter union matching - by @dinwwwh in https://github.com/middleapi/orpc/issues/1729 (91471)
View changes on GitHub
July 25, 2026
🚀 Features
- openapi: Modularize generator and hoist error schemas into components - by @dinwwwh in https://github.com/middleapi/orpc/issues/1721 (deb9e)
- pinia-colada: Define base options and interceptors via contract meta - by @dinwwwh in https://github.com/middleapi/orpc/issues/1718 (cfe18)
- swr: SWR integration - by @dinwwwh in https://github.com/middleapi/orpc/issues/1723 (d4388)
- tanstack-query: Define base options and interceptors via contract meta - by @dinwwwh in https://github.com/middleapi/orpc/issues/1705 (6c2c3)
View changes on GitHub
July 24, 2026
🚨 Breaking Changes
- json-schema,openapi: Make JsonSchemaConverter sync - by @dinwwwh in https://github.com/middleapi/orpc/issues/1716 (fb2b8)
- publisher,bun,cloudflare: Rename replay option to resume - by @dinwwwh in https://github.com/middleapi/orpc/issues/1711 (be82b)
🚀 Features
- ai-sdk:
- AI SDK integration - by @dinwwwh in https://github.com/middleapi/orpc/issues/1707 (428ad)
- client:
- Timeout link plugin - by @dinwwwh in https://github.com/middleapi/orpc/issues/1697 (eee68)
- contract:
- Replace contract caller with contract client factory - by @dinwwwh in https://github.com/middleapi/orpc/issues/1699 (c2bee)
- pinia-colada:
- Pinia Colada integration - by @dinwwwh in https://github.com/middleapi/orpc/issues/1686 (e12f7)
- Contract utils factory - by @dinwwwh in https://github.com/middleapi/orpc/issues/1700 (b4556)
- server:
- Disable validation - by @dinwwwh in https://github.com/middleapi/orpc/issues/1678 (14ead)
- tanstack-query:
prefixoption to avoid key conflicts - by @dinwwwh in https://github.com/middleapi/orpc/issues/1692 (7106a)
- trpc:
- TRPC integration - by @dinwwwh in https://github.com/middleapi/orpc/issues/1683 (b8447)
- zod:
- Support JSON schema registries - by @dinwwwh in https://github.com/middleapi/orpc/issues/1695 (3826b)
- Shallow merge JSON schema registries & dedicated converter integration docs - by @dinwwwh in https://github.com/middleapi/orpc/issues/1696 (b36da)
🐞 Bug Fixes
- server: Re-export missing
InitialInputSchemaandInitialOutputSchematypes - by @dinwwwh in https://github.com/middleapi/orpc/issues/1682 (0a0a8)
View changes on GitHub
July 16, 2026
🚀 Features
- Upgrade standardserver to 0.5.0 - in https://github.com/middleapi/orpc/issues/1673 (be200)
View changes on GitHub
July 14, 2026
🚀 Features
- Upgrade standardserver to 0.4.2 - by @dinwwwh in https://github.com/middleapi/orpc/issues/1667 (8a051)
- client, server: Add keep-alive for streaming batch responses - by @dinwwwh in https://github.com/middleapi/orpc/issues/1657 (5e286)
- nest: Allow context as async fn(ExecutionContext) - by @Wadiou in https://github.com/middleapi/orpc/issues/1666 (d5472)
- zod: Support defs at root level in json schema converter - by @KingSora in https://github.com/middleapi/orpc/issues/1649 (f7e65)
🐞 Bug Fixes
- next: Use built-in unstable_rethrow for better compatibility - by @dinwwwh in https://github.com/middleapi/orpc/issues/1668 (9eea7)
- server: Stop copying request Vary into CORS responses - by @dinwwwh in https://github.com/middleapi/orpc/issues/1662 (dd515)
View changes on GitHub
July 10, 2026
🚨 Breaking Changes
- client, server: Add response compression plugin, replace body compression plugin - by @dinwwwh in https://github.com/middleapi/orpc/issues/1653 (af359)
- server: Replace BodyLimitHandlerPlugin with RequestLimitHandlerPlugin - by @dinwwwh in https://github.com/middleapi/orpc/issues/1647 (49b63)
🚀 Features
- client: Enable fetch duplex mode automatically for streaming requests - by @dinwwwh in https://github.com/middleapi/orpc/issues/1644 (d19bd)
- client, server: Request compression plugin - by @dinwwwh in https://github.com/middleapi/orpc/issues/1643 (c64cd)
🐞 Bug Fixes
- OpenAPISerializerOptions should not extend OpenAPISerializerSerializeOptions - by @KingSora in https://github.com/middleapi/orpc/issues/1650 (377f5)
View changes on GitHub
July 6, 2026
🚀 Features
- Rename event iterator functions to async iterator object for clarity - by @dinwwwh in https://github.com/middleapi/orpc/issues/1627 (2ebfc)
- OnAsyncIteratorObjectError, onReadableStreamError - by @dinwwwh in https://github.com/middleapi/orpc/issues/1629 (5d50e)
View changes on GitHub
July 3, 2026
🚀 Features
- feat(ratelimit, publisher, cloudflare): ratelimit and publisher adapters for cloudflare (#1618) (35f2ca2) by @dinwwwh
🐞 Bug Fixes
- fix(client, server): preserve message ordering for blob messages in peer adapters (#1621) (897a751 ) by @dinwwwh
View changes on GitHub
July 1, 2026
🚀 Features
- nest: Rename toStandardLazyRequest to toNestStandardLazyRequest with additional params - by @dinwwwh in https://github.com/middleapi/orpc/issues/1611 (ccf6c)
🐞 Bug Fixes
- openapi: Make scalar and swagger peer dependencies optional - by @dinwwwh (cec51)
View changes on GitHub
June 30, 2026
🐞 Bug Fixes
- server: Standardize WebSocket adapter naming across the codebase and fix bun websocket compatible - by @dinwwwh (ae7f5)
View changes on GitHub
June 30, 2026
🐞 Bug Fixes
- nest: Avoid confusion between Fetch Response and Express Response types - by @dinwwwh (a202f)
View changes on GitHub
June 30, 2026
🚀 Features
- ratelimit, publisher, bun: Bun’s redis ratelimit and publisher adapters - by @dinwwwh (2f356)
View changes on GitHub
June 27, 2026
June 27, 2026
🚀 Features
- server: Websocket adapter now support bun websocket - by @dinwwwh (7b743)
View changes on GitHub
June 25, 2026
🚀 Features
- effect: Update integration to Effect V4 - by @LarsLrn in https://github.com/middleapi/orpc/issues/1603 (7e282)
🐞 Bug Fixes
- effect: Update context keys from
~effecttoeffectto avoid suggesting internal APIs - by @dinwwwh (b4ad0)
View changes on GitHub
June 25, 2026
🚀 Features
- openapi: PopulateRouterContractOpenAPIPaths util - by @dinwwwh (acf5c)
- server: Rethrow plugin - by @dinwwwh (b045f)
View changes on GitHub
June 24, 2026
🐞 Bug Fixes
- Reexport client & standard types - by @dinwwwh (cfc09)
- client, contract, server: Reexport PromiseWithError - by @dinwwwh (79756)
View changes on GitHub
June 24, 2026
🚀 Features
- client, server, shared: Signal support for streamToEventIterator and streamToAsyncIteratorClass - by @dinwwwh (90726)
- openapi: Update rou3 to 0.8.1 - by @dinwwwh (587c2)
View changes on GitHub
June 24, 2026
🚀 Features
- V2 - by @dinwwwh and @github-actions[bot] in https://github.com/middleapi/orpc/issues/1593 (ddf22)
View changes on GitHub
August 7, 2026
🐞 Bug Fixes
- openapi: Preserve event iterator return type in JsonifiedClient - by @dinwwwh in https://github.com/middleapi/orpc/issues/1798 (17551)
View changes on GitHub
August 4, 2026
🐞 Bug Fixes
- nest: Run method-level guards on routes synthesized by router-contract
@Implement- by @dinwwwh in https://github.com/middleapi/orpc/issues/1775 (2b81d)
View changes on GitHub
July 29, 2026
🐞 Bug Fixes
- standard-server: Make event iterator encoder/decoder SSE spec compliant - by @dinwwwh in https://github.com/middleapi/orpc/issues/1742 (b26a0)
View changes on GitHub
July 27, 2026
🐞 Bug Fixes
- rpc,openapi: Prevent lazy router races under concurrent requests - by @dinwwwh in https://github.com/middleapi/orpc/issues/1734 (ec6d8)
- standard-server: Settle sendStandardResponse when client disconnects before sending - by @dinwwwh in https://github.com/middleapi/orpc/issues/1738 (a0d7d)
View changes on GitHub
July 25, 2026
🐞 Bug Fixes
- zod: Prevent prototype injection in smart coercion - by @dinwwwh in https://github.com/middleapi/orpc/issues/1727 (26314) GHSA-gcgf-fh7c-8gf2
View changes on GitHub
July 25, 2026
🐞 Bug Fixes
- json-schema: Prevent prototype injection when coercing objects - by @dinwwwh in https://github.com/middleapi/orpc/issues/1726 (8a352) GHSA-4h5r-cv8j-4456
View changes on GitHub
July 12, 2026
🐞 Bug Fixes
- server: Stop copying request Vary into CORS responses - by @dinwwwh (daabd)
View changes on GitHub
July 6, 2026
🐞 Bug Fixes
- server: Avoid crashing server when using ws adapter by logging error - by @dinwwwh (931dc)
View changes on GitHub
June 12, 2026
🐞 Bug Fixes
- client: Reject calls when websocket is not open instead of sending into a closed socket - by @strblr in https://github.com/middleapi/orpc/issues/1581 (47dbd)
View changes on GitHub
June 5, 2026
🐞 Bug Fixes
- client: Move global ORPCError constructors registration to static block for better bundler compatibility - by @dinwwwh in https://github.com/middleapi/orpc/issues/1574 (21703)
[!TIP] If you find oRPC valuable and would like to support its development, you can do so here.
View changes on GitHub
May 28, 2026
🐞 Bug Fixes
- tanstack-query: Narrow live options defaults type - by @lyzno1 in https://github.com/middleapi/orpc/issues/1568 (36cf3)
View changes on GitHub
May 12, 2026
🐞 Bug Fixes
- server: Routing skips callable/actionable procedures - by @dinwwwh in https://github.com/middleapi/orpc/issues/1551 (7605f)
View changes on GitHub
May 6, 2026
🐞 Bug Fixes
- Mark orpc packages as sideEffect-free for cross-pkg tree-shaking - by @voidborne-d in https://github.com/middleapi/orpc/issues/1540 (683f2)
View changes on GitHub
May 4, 2026
🚀 Features
- nest: Add Hono framework support - by @Mnigos in https://github.com/middleapi/orpc/issues/1299 (90a4d)
View changes on GitHub
April 22, 2026
🚀 Features
- server,openapi: Support ReadableStream
as handler return value - by @ghdoergeloh in https://github.com/middleapi/orpc/issues/1535 (b6b87)
View changes on GitHub
April 9, 2026
🚀 Features
- server,contract: Guard against primitive values in router tree traversal - by @jameskranz in https://github.com/middleapi/orpc/issues/1522 (99d5d)
View changes on GitHub
March 26, 2026
🚀 Features
- client: Reexport getEventMeta, withEventMeta - by @dinwwwh in https://github.com/middleapi/orpc/issues/1508 (77e42)
View changes on GitHub
March 26, 2026
🐞 Bug Fixes
- Serialize undefined array elements as null - by @treehill05 in https://github.com/middleapi/orpc/issues/1505 (89acf)
View changes on GitHub
March 25, 2026
🐞 Bug Fixes
- standard-server: Invalid content-disposition with non-ASCII filenames - by @dinwwwh in https://github.com/middleapi/orpc/issues/1500 (67219)
View changes on GitHub
March 24, 2026
🐞 Bug Fixes
- node-adapter: Handle utf-8 characters split across stream chunks - by @zxhyc131 in https://github.com/middleapi/orpc/issues/1496 (6bc47)
View changes on GitHub
March 20, 2026
🐞 Bug Fixes
- openapi: Stored XSS in OpenAPI Reference Plugin via unescaped JSON.stringify (https://github.com/middleapi/orpc/security/advisories/GHSA-7f6v-3gx7-27q8)
View changes on GitHub
March 18, 2026
🐞 Bug Fixes
- zod: Improve json schema compatibility by add
typefield and fix native enum - by @Sigmabrogz in https://github.com/middleapi/orpc/issues/1478 (3816d)
View changes on GitHub
March 13, 2026
🐞 Bug Fixes
- server: Prevent duplicate request id attack on peer adapter - by @dinwwwh in https://github.com/middleapi/orpc/issues/1474 (5ebcc)
View changes on GitHub
[!TIP] If you find oRPC valuable and would like to support its development, you can do so here.
March 2, 2026
🐞 Bug Fixes
- client, server: Prototype Pollution via
StandardRPCJsonSerializerDeserialization (https://github.com/middleapi/orpc/security/advisories/GHSA-m272-9rp6-32mc)
View changes on GitHub
February 11, 2026
🐞 Bug Fixes
- trpc: Add missing batchIndex for trpc^11.10 procedure calls - by @dinwwwh in https://github.com/middleapi/orpc/issues/1420 (ae486)
View changes on GitHub
[!TIP] If you find oRPC valuable and would like to support its development, you can do so here.
January 13, 2026
🐞 Bug Fixes
- Decoding chunks in http event stream - by @dinwwwh in https://github.com/middleapi/orpc/issues/1356 (da9af)
View changes on GitHub
December 29, 2025
🐞 Bug Fixes
- zod: Enhance schema conversion logic for zod4 preprocess - by @dinwwwh in https://github.com/middleapi/orpc/issues/1318 (fc2dc)
View changes on GitHub
[!TIP] If you find oRPC valuable and would like to support its development, you can do so here.
December 26, 2025
🚀 Features
- nest, contract: Prefer import populateContractRouterPaths from
@orpc/contract- by @dinwwwh in https://github.com/middleapi/orpc/issues/1312 (544b9)
View changes on GitHub
December 18, 2025
Smart Coercion now stable docs
Automatically converts input values to match schema types without manually defining coercion logic.
import { OpenAPIHandler } from '@orpc/openapi/fetch'
import { SmartCoercionPlugin } from '@orpc/json-schema'
const handler = new OpenAPIHandler(router, {
plugins: [
new SmartCoercionPlugin({
schemaConverters: [
new ZodToJsonSchemaConverter(),
// Add other schema converters as needed
],
})
]
})
Rethrow handler plugin docs
The RethrowHandlerPlugin allows you to catch and rethrow specific errors that occur during request handling. This is particularly useful when your framework has its own error handling mechanism (e.g., global exception filters in NestJS, error middleware in Express) and you want certain errors to be processed by that mechanism instead of being handled by the oRPC error handling flow.
import {
experimental_RethrowHandlerPlugin as RethrowHandlerPlugin,
} from '@orpc/server/plugins'
const handler = new RPCHandler(router, {
plugins: [
new RethrowHandlerPlugin({
// Decide which errors should be rethrown.
filter: (error) => {
// Example: Rethrow all non-ORPCError errors
// This allows unhandled exceptions to bubble up to your framework
return !(error instanceof ORPCError)
},
}),
],
})
.$input now available in contract builder docs
Unlike .input, the .$input method lets you redefine the input schema after its initial configuration. This is useful when you need to enforce a void input when no .input is specified.
const base = os.$input(z.void())
const base = os.$input<Schema<void, unknown>>()
🚀 Features
- json-schema: Stable SmartCoercionPlugin - by @dinwwwh in https://github.com/middleapi/orpc/issues/1285 (f01f7)
- server: Rethrow handler plugin - by @dinwwwh in https://github.com/middleapi/orpc/issues/1286 (b2d00)
🐞 Bug Fixes
- contract: Missing
.$inputbuilder method - by @dinwwwh in https://github.com/middleapi/orpc/issues/1304 (b81d4)
View changes on GitHub
December 12, 2025
🐞 Bug Fixes
- standard-server: Change SHORTABLE_ORIGIN from orpc:// to http:// for Android WebView compatibility - by @Copilot in https://github.com/middleapi/orpc/issues/1295 (d1259)
View changes on GitHub
December 2, 2025
🐞 Bug Fixes
- standard-server: Filter out undefined headers for node:http adapters compatibility - by @dinwwwh in https://github.com/middleapi/orpc/issues/1269 (c994d)
View changes on GitHub
December 1, 2025
🚀 Features
- publisher: Change cloudflare durable object cleanup - by @dinwwwh in https://github.com/middleapi/orpc/issues/1266 (7844b)
View changes on GitHub
November 30, 2025
Tanstack Query Default Options docs
You can configure default options for all query/mutation utilities using experimental_defaults. These options are spread merged with user-provided options, allowing you to set defaults while still enabling customization on a per-call basis.
const orpc = createTanstackQueryUtils(client, {
experimental_defaults: {
planet: {
find: {
queryOptions: {
staleTime: 60 * 1000, // 1 minute
retry: 3,
},
},
list: {
infiniteOptions: {
staleTime: 30 * 1000,
},
},
create: {
mutationOptions: {
onSuccess: (output, input, _, ctx) => {
ctx.client.invalidateQueries({ queryKey: orpc.planet.key() })
},
},
},
},
},
})
// These will automatically use the default options
const query = useQuery(orpc.planet.find.queryOptions({ input: { id: 123 } }))
const mutation = useMutation(orpc.planet.create.mutationOptions())
// User-provided options override defaults
const customQuery = useQuery(orpc.planet.find.queryOptions({
input: { id: 123 },
staleTime: 0, // overrides the default
}))
Cloudflare Durable Object Publisher Adapter docs
Building real-time features on Cloudflare Workers has never been easier, thanks to our publisher helpers:
import { DurablePublisher, PublisherDurableObject } from '@orpc/experimental-publisher-durable-object'
export class PublisherDO extends PublisherDurableObject {
constructor(ctx: DurableObjectState, env: Env) {
super(ctx, env, {
resume: {
retentionSeconds: 60 * 2, // Retain events for 2 minutes to support resume
},
})
}
}
export default {
async fetch(request, env) {
const publisher = new DurablePublisher<{
'something-updated': {
id: string
}
}>(env.PUBLISHER_DO, {
prefix: 'publisher1', // avoid conflict with other keys
customJsonSerializers: [] // optional custom serializers
})
},
}
[!NOTE] Full example at Cloudflare Worker Playground
NestJS Integration Upgraded docs
NestJS Integration now supports oRPC plugins, custom error responses, custom send-response behavior, and global context type-safe.
declare module '@orpc/nest' {
/**
* Extend oRPC global context to make it type-safe inside your handlers/middlewares
*/
interface ORPCGlobalContext {
request: Request
}
}
@Module({
imports: [
ORPCModule.forRootAsync({ // or use .forRoot for static config
useFactory: (request: Request) => ({
interceptors: [
onError((error) => {
console.error(error)
}),
],
context: { request }, // oRPC context, accessible from middlewares, etc.
eventIteratorKeepAliveInterval: 5000, // 5 seconds
customJsonSerializers: [],
plugins: [
new SmartCoercionPlugin({
schemaConverters: [
new ZodToJsonSchemaConverter(),
],
}),
], // almost oRPC plugins are compatible
}),
inject: [REQUEST],
}),
],
controllers: [AuthController, PlanetController, ReferenceController, OtherController],
providers: [PlanetService, ReferenceService],
})
🚀 Features
- nest: Custom send response, global context, plugins, custom error response - by @dinwwwh in https://github.com/middleapi/orpc/issues/1256 (56695)
- publisher: Cloudflare durable object adapter - by @dinwwwh in https://github.com/middleapi/orpc/issues/1253 (e565e)
- tanstack-query: Default query/mutation options - by @dinwwwh in https://github.com/middleapi/orpc/issues/1260 (1fe44)
🐞 Bug Fixes
- Clone util should clone symbol properties of object - by @Copilot in https://github.com/middleapi/orpc/issues/1258 (b4897)
[!TIP] If you find oRPC valuable and would like to support its development, you can do so here.
View changes on GitHub
November 17, 2025
Cloudflare Worker Ratelimit Adapter docs
Adapter for Cloudflare Workers Ratelimit.
import { CloudflareRatelimiter } from '@orpc/experimental-ratelimit/cloudflare-ratelimit'
export default {
async fetch(request, env) {
const limiter = new CloudflareRatelimiter(env.MY_RATE_LIMITER)
return new Response(`Hello World!`)
}
}
🚀 Features
- ratelimit: Cloudflare Worker Ratelimit Adapter - by @dinwwwh in https://github.com/middleapi/orpc/issues/1212 (194c9)
View changes on GitHub
November 12, 2025
🚀 Features
- standard-server: Send initial comment in event stream to flush response headers immediately - by @dinwwwh in https://github.com/middleapi/orpc/issues/1204 (91ac3)
🐞 Bug Fixes
- tanstack-query: Set stream query to success immediately after stream resolves - by @dinwwwh in https://github.com/middleapi/orpc/issues/1202 (bbe55)
View changes on GitHub
[!TIP] If you find oRPC valuable and would like to support its development, you can do so here.
November 10, 2025
🚀 Features
- pino:
[!TIP] If you find oRPC valuable and would like to support its development, you can do so here.
View changes on GitHub
November 9, 2025
Pino Logging Integration docs
Easy add structured logging, request tracking, and error monitoring to your oRPC powered by Pino
const logger = pino()
const handler = new RPCHandler(router, {
plugins: [
new LoggingHandlerPlugin({
logger, // Custom logger instance
generateId: ({ request }) => crypto.randomUUID(), // Custom ID generator
logRequestResponse: true, // Log request start/end (disabled by default)
logRequestAbort: true, // Log when requests are aborted (disabled by default)
}),
],
})
Ratelimit Helpers docs
The Rate Limit package provides flexible rate limiting for oRPC with multiple storage backend support. It includes adapters for in-memory, Redis, and Upstash, along with middleware and plugin helpers for seamless integration.
Ratelimiter
const ratelimiter = new MemoryRatelimiter({
maxRequests: 10,
window: 60000,
})
Manually usage
const result = await limiter.limit('user:123')
if (!result.success) {
throw new ORPCError('TOO_MANY_REQUESTS', {
data: {
limit: result.limit,
remaining: result.remaining,
reset: result.reset,
},
})
}
Built-in middleware
const loginProcedure = os
.$context<{ ratelimiter: Ratelimiter }>()
.input(z.object({ email: z.email() }))
.use(
createRatelimitMiddleware({
limiter: ({ context }) => context.ratelimiter,
key: ({ context }, input) => `login:${input.email}`,
}),
)
.handler(({ input }) => {
return { success: true }
})
const result = await call(
loginProcedure,
{ email: 'user@example.com' },
{ context: { ratelimiter } }
)
Response Header Plugin
import { RatelimitHandlerPlugin } from '@orpc/experimental-ratelimit'
const handler = new RPCHandler(router, {
plugins: [
new RatelimitHandlerPlugin(),
],
})
Retry After Plugin docs
The Retry After Plugin automatically retries requests based on server Retry-After headers. This is particularly useful for handling rate limiting and temporary server unavailability.
import { RetryAfterPlugin } from '@orpc/client/plugins'
const link = new RPCLink({
url: 'http://localhost:3000/rpc',
plugins: [
new RetryAfterPlugin({
condition: (response, options) => {
// Override condition to determine if a request should be retried
return response.status === 429 || response.status === 503
},
maxAttempts: 5, // Maximum retry attempts
timeout: 5 * 60 * 1000, // Maximum time to spend retrying (ms)
}),
],
})
Expand support union/interaction in openapi generator
Now you can use union/interaction for define params, query, headers, …
const procedure = os
.route({ path: '/{type}' })
.input(z.discriminatedUnion('type', [
z.object({
type: z.literal("a"),
foo: z.number().int().positive(),
}),
z.object({
type: z.literal("b"),
foo: z.number().int().negative(),
}),
]))
🚀 Features
- client: Retry After Plugin - by @dinwwwh in https://github.com/middleapi/orpc/issues/1190 (0ab5a)
- openapi: Expand support for unions/intersection of objects when generating OpenAPI specs - by @dinwwwh in https://github.com/middleapi/orpc/issues/1178 (6424b)
- pino: Logging Plugin - by @dinwwwh in https://github.com/middleapi/orpc/issues/1191 (4b03c)
- server: Ratelimit helpers & plugins - by @dinwwwh in https://github.com/middleapi/orpc/issues/1183 (33122)
[!TIP] If you find oRPC valuable and would like to support its development, you can do so here.
View changes on GitHub
November 5, 2025
🚀 Features
- ai-sdk: Disable validation at oRPC level in createTool to avoid double validation - by @dinwwwh in https://github.com/middleapi/orpc/issues/1166 (3bec7)
View changes on GitHub
November 2, 2025
AI SDK implementTool & createTool helpers
Implement/Convert a procedure/contract -> AI SDK Tool
const getWeatherTool = implementTool(getWeatherContract, {
execute: async ({ location }) => ({
location,
temperature: 72 + Math.floor(Math.random() * 21) - 10,
}),
})
const getWeatherTool = createTool(getWeatherProcedure, {
context: {}, // provide initial context if needed
})
🚀 Features
- ai-sdk: CreateTool, implementTool helpers - by @dinwwwh in https://github.com/middleapi/orpc/issues/1151 (d92c7)
🐞 Bug Fixes
- zod: Union and intersection schema conversion - by @dinwwwh in https://github.com/middleapi/orpc/issues/1157 (b1b99)
View changes on GitHub
October 26, 2025
OpenAPI - custom error format docs
By default, OpenAPIHandler, OpenAPIGenerator, and OpenAPILink share the same error response format. You can customize one, some, or all of them based on your requirements.
const handler = new OpenAPIHandler(router, {
customErrorResponseBodyEncoder(error) {
return error.toJSON()
},
})
Native Fastify adapter docs
Previously, oRPC in Fastify used the Node adapter, which didn’t integrate well with Fastify’s ecosystem (e.g., cookies, helpers, middleware). This native adapter supports Fastify’s request/reply APIs directly, enabling full access to Fastify features within oRPC.
import Fastify from 'fastify'
import { RPCHandler } from '@orpc/server/fastify'
import { onError } from '@orpc/server'
const handler = new RPCHandler(router, {
interceptors: [
onError((error) => {
console.error(error)
})
]
})
const fastify = Fastify()
fastify.addContentTypeParser('*', (request, payload, done) => {
// Fully utilize oRPC feature by allowing any content type
// And let oRPC parse the body manually by passing `undefined`
done(null, undefined)
})
fastify.all('/rpc/*', async (req, reply) => {
const { matched } = await handler.handle(req, reply, {
prefix: '/rpc',
context: {} // Provide initial context if needed
})
if (!matched) {
reply.status(404).send('Not found')
}
})
fastify.listen({ port: 3000 }).then(() => console.log('Server running on http://localhost:3000'))
🚀 Features
- openapi: Support custom error response format - by @dinwwwh in https://github.com/middleapi/orpc/issues/1137 (66a82)
- server: Native Fastify adapter - by @dinwwwh in https://github.com/middleapi/orpc/issues/1127 (fe89a)
[!TIP] If you find oRPC valuable and would like to support its development, you can do so here.
View changes on GitHub
October 24, 2025
Message port transfer docs
By default, oRPC serializes request/response messages to string/binary data before sending over message port. If needed, you can define the transfer option to utilize full power of MessagePort: postMessage() method, such as transferring ownership of objects to the other side or support unserializable objects like OffscreenCanvas.
const handler = new RPCHandler(router, {
experimental_transfer: (message, port) => {
const transfer = deepFindTransferableObjects(message) // implement your own logic
return transfer.length ? transfer : null // only enable when needed
}
})
🚀 Features
- client, server: Message port transfer - by @dinwwwh in https://github.com/middleapi/orpc/issues/1113 (66429)
[!TIP] If you find oRPC valuable and would like to support its development, you can do so here.
View changes on GitHub
October 20, 2025
Publisher helper docs
The Publisher is a helper that enables you to listen to and publish events to subscribers. Combined with the Event Iterator, it allows you to build streaming responses, real-time updates, and server-sent events with minimal requirements.
const publisher = new MemoryPublisher<{
'something-updated': {
id: string
}
}>()
const live = os
.handler(async function* ({ input, signal, lastEventId }) {
const iterator = publisher.subscribe('something-updated', { signal, lastEventId })
for await (const payload of iterator) {
// Handle payload here or yield directly to client
yield payload
}
})
const publish = os
.input(z.object({ id: z.string() }))
.handler(async ({ input }) => {
await publisher.publish('something-updated', { id: input.id })
})
Available Adapters
| Name | Resume Support | Description |
|---|---|---|
MemoryPublisher |
✅ | A simple in-memory publisher |
IORedisPublisher |
✅ | Adapter for ioredis |
UpstashRedisPublisher |
✅ | Adapter for Upstash Redis |
eventIteratorToUnproxiedDataStream util
Prefer using eventIteratorToUnproxiedDataStream over eventIteratorToStream when integrating oRPC with the AI SDK. The AI SDK uses structuredClone internally, which doesn’t support proxied data. Since oRPC may proxy events to attach metadata, you should unproxy them before passing to the AI SDK.
const { messages, sendMessage, status } = useChat({
transport: {
async sendMessages(options) {
return eventIteratorToUnproxiedDataStream(await client.chat({
chatId: options.chatId,
messages: options.messages,
}, { signal: options.abortSignal }))
},
reconnectToStream(options) {
throw new Error('Unsupported')
},
},
})
🚀 Features
- client, server: Add eventIteratorToUnproxiedDataStream util - by @dinwwwh in https://github.com/middleapi/orpc/issues/1110 (e91d2)
- publisher: Memory, ioredis, upstash redis publishers - by @dinwwwh and Joonseo Lee in https://github.com/middleapi/orpc/issues/1094 (22ef1)
🏎 Performance
- durable-iterator: Improve resume events cleanup logic - by @dinwwwh in https://github.com/middleapi/orpc/issues/1102 (425e0)
[!TIP] If you find oRPC valuable and would like to support its development, you can do so here.
View changes on GitHub
October 14, 2025
🚀 Features
- client: Infer utilities - by @dinwwwh in https://github.com/middleapi/orpc/issues/1096 (9581b)
[!TIP] If you find oRPC valuable and would like to support its development, you can do so here.
View changes on GitHub
October 4, 2025
[!TIP] If you find oRPC valuable and would like to support its development, you can do so here.
Bump dependencies
View changes on GitHub
September 29, 2025
[!TIP] If you find oRPC valuable and would like to support its development, you can do so here.
🚀 Features
- server: Extend .actionable error handling for tanstack router compatibility - by @dinwwwh in https://github.com/middleapi/orpc/issues/1045 (f677f)
- standard-server: Support parsed body in node adapter - by @dinwwwh in https://github.com/middleapi/orpc/issues/1001 (4748d)
🐞 Bug Fixes
- server: Avoid opaque path in URL for better compatibility - by @dinwwwh in https://github.com/middleapi/orpc/issues/1046 (fc143)
- standard-server: Handle node:http malformed url - by @dinwwwh in https://github.com/middleapi/orpc/issues/1041 (907c0)
View changes on GitHub
September 26, 2025
[!TIP] If you find oRPC valuable and would like to support its development, you can do so here.
🚀 Features
- durable-iterator:
- Add refreshTokenDelayInSeconds option to DurableIteratorLinkPlugin - by @dinwwwh in https://github.com/middleapi/orpc/issues/1026 (01f0b)
- X-orpc-durable-iterator header - by @dinwwwh in https://github.com/middleapi/orpc/issues/1032 (a136b)
View changes on GitHub
September 23, 2025
Durable Iterator docs
Durable Iterator is a complete rewrite of the old Durable Event Iterator. It builds on Event Iterator by offloading streaming to a dedicated service that delivers durable event streams with automatic reconnections and event recovery.
[!NOTE] While not limited to Cloudflare Durable Objects, it’s currently the only supported implementation.
Durable Object
import { DurableIteratorObject } from '@orpc/experimental-durable-iterator/durable-object'
export class ChatRoom extends DurableIteratorObject<{ message: string }> {
constructor(ctx: DurableObjectState, env: Env) {
super(ctx, env, {
signingKey: 'secret-key', // Replace with your actual signing key
interceptors: [
onError(e => console.error(e)), // log error thrown from rpc calls
],
onSubscribed: (websocket, lastEventId) => {
console.log(`WebSocket Ready id=${websocket['~orpc'].deserializeId()}`)
}
})
}
someMethod() {
// publishEvent method inherited from DurableIteratorObject
this.publishEvent({ message: 'Hello, world!' })
}
}
Server Side
import { DurableEventIterator } from '@orpc/experimental-durable-iterator'
export const router = {
onMessage: base.handler(({ context }) => {
return new DurableEventIterator<ChatRoom>('some-room', {
tags: ['tag1', 'tag2'],
signingKey: 'secret-key', // Replace with your actual signing key
})
}),
sendMessage: base
.input(z.object({ message: z.string() }))
.handler(async ({ context, input }) => {
const id = context.env.CHAT_ROOM.idFromName('some-room')
const stub = context.env.CHAT_ROOM.get(id)
await stub.publishEvent(input)
}),
}
Client Side
const iterator = await client.onMessage()
for await (const { message } of iterator) {
console.log('Received message:', message)
}
await client.sendMessage({ message: 'Hello, world!' })
experimental_streamedOptions is removed in old tanstack query
If you depend on this, please try NEW Tanstack Query Interagration
[!TIP] If you find oRPC valuable and would like to support its development, you can do so here.
🚀 Features
- durable-iterator:
- Rewrite + enchance - by @dinwwwh in https://github.com/middleapi/orpc/issues/965 (c5401)
- Rewrite + enhance (part 2) - by @dinwwwh (03cef)
- tanstack-query:
- Update to 5.89 with
streamOptionsupdate - by @dinwwwh in https://github.com/middleapi/orpc/issues/1019 (b83dc)
- Update to 5.89 with
View changes on GitHub
September 15, 2025
Request Validation Plugin docs
The Request Validation Plugin ensures that only valid requests are sent to your server. This is especially valuable for applications that depend on server-side validation.
You can simplify your frontend by removing heavy form validation libraries and relying on oRPC’s validation errors instead, since input validation runs directly in the browser and is highly performant.
export function ContactForm() {
const [error, setError] = useState()
const handleSubmit = async (form: FormData) => {
try {
const output = await client.someProcedure(parseFormData(form))
console.log(output)
}
catch (error) {
setError(error)
}
}
return (
<form action={handleSubmit}>
<input name="user[name]" type="text" />
<span>{getIssueMessage(error, 'user[name]')}</span>
<input name="user[emails][]" type="email" />
<span>{getIssueMessage(error, 'user[emails][]')}</span>
<button type="submit">Submit</button>
</form>
)
}
[!NOTE] If you find oRPC valuable and would like to support its development, you can do so here.
🚀 Features
- contract: Request Validation Plugin - by @dinwwwh in https://github.com/middleapi/orpc/issues/1000 (e4b0d)
🐞 Bug Fixes
- contract: Cannot be named without a reference AsyncIteratorClass - by @dinwwwh (c68ce)
View changes on GitHub
September 11, 2025
consumeEventIterator utility docs
oRPC provides a utility function consumeEventIterator to consume an event iterator with lifecycle callbacks.
import { consumeEventIterator } from '@orpc/client'
const cancel = consumeEventIterator(client.streaming(), {
onEvent: (event) => {
console.log(event.message)
},
onError: (error) => {
console.error(error)
},
onSuccess: (value) => {
console.log(value)
},
onFinish: (state) => {
console.log(state)
},
})
setTimeout(async () => {
// Stop the stream after 1 second
await cancel()
}, 1000)
optimize withEventMeta to avoid unnecessary proxies event iterator data
This prevents structuredClone from failing on proxy event iterator data, which the AI SDKdepends on.
const { messages, sendMessage, status } = useChat({
transport: {
async sendMessages(options) {
return eventIteratorToStream(await client.chat({
chatId: options.chatId,
messages: options.messages,
}, { signal: options.abortSignal }))
},
reconnectToStream(options) {
throw new Error('Unsupported')
},
},
})
[!NOTE] If you find oRPC valuable and would like to support its development, you can do so here.
🚀 Features
- client: ConsumeEventIterator utility - by @dinwwwh in https://github.com/middleapi/orpc/issues/976 (965aa)
🐞 Bug Fixes
- standard-server:
- Throw error for waiting operation if event iterator cancelled - by @dinwwwh in https://github.com/middleapi/orpc/issues/974 (06aad)
- Optimize withEventMeta to avoid unnecessary proxies event iterator data - by @dinwwwh in https://github.com/middleapi/orpc/issues/979 (cedbd)
View changes on GitHub
September 8, 2025
🚀 Features
- client: Support ORPCError instanceof checks across different dependency graph - by @dinwwwh in https://github.com/middleapi/orpc/issues/972 (85c0f)
- contract: Improve
eventIteratorschema output type - by @dinwwwh in https://github.com/middleapi/orpc/issues/970 (c79fd)
View changes on GitHub
September 1, 2025
Response Validation Plugin docs
The Response Validation Plugin validates server responses against your contract schema, ensuring that data returned from your server matches the expected types defined in your contract.
import { RPCLink } from '@orpc/client/fetch'
import { ResponseValidationPlugin } from '@orpc/contract/plugins'
const link = new RPCLink({
url: 'http://localhost:3000/rpc',
plugins: [
new ResponseValidationPlugin(contract),
],
})
const client: ContractRouterClient<typeof contract> = createORPCClient(link)
[!TIP] Beyond response validation, this plugin also serves special purposes such as Expanding Type Support for OpenAPI Link.
Support fetch headers in link header option
import { RPCLink } from '@orpc/client/fetch'
const link = new RPCLink({
url: `${typeof window !== 'undefined' ? window.location.origin : 'http://localhost:3000'}/rpc`,
headers: async () => {
if (typeof window !== 'undefined') {
return {}
}
const { headers } = await import('next/headers')
- return Object.fromEntries(await headers())
+ return await headers()
},
})
🚀 Features
- client:
- Support fetch headers in link options - by @dinwwwh in https://github.com/middleapi/orpc/issues/946 (216e5)
- contract:
- Add failed data to ValidationError for debugging - by @dinwwwh in https://github.com/middleapi/orpc/issues/949 (f437d)
- Response Validation Plugin - by @dinwwwh in https://github.com/middleapi/orpc/issues/953 (5a170)
- openapi:
- Form-data helpers - by @dinwwwh in https://github.com/middleapi/orpc/issues/951 (4b3a4)
View changes on GitHub
August 25, 2025
🐞 Bug Fixes
- Make signal in EventPublisherSubscribeIteratorOptions
AbortSignal | undefined- by @boredland in https://github.com/middleapi/orpc/issues/928 (117b5) - server: Compression Plugin (fetch) response invalid status - by @dinwwwh in https://github.com/middleapi/orpc/issues/929 (117b5)
View changes on GitHub
August 23, 2025
🐞 Bug Fixes
- client: DedupeRequestsPlugin not working well with Event Iterator - by @dinwwwh in https://github.com/middleapi/orpc/issues/921 (b38be)
- openapi: Spec generator in case commonSchemas + GET + compact + no params - by @dinwwwh in https://github.com/middleapi/orpc/issues/920 (d7c47)
View changes on GitHub
August 22, 2025
🚀 Features
- client: Adapter interceptor - by @dinwwwh in https://github.com/middleapi/orpc/issues/899 (b5e32)
- nest: Add async configuration support for ORPCModule - by @dinwwwh in https://github.com/middleapi/orpc/issues/916 (1e104)
- openapi: Add Swagger UI support to OpenAPI Reference Plugin - by @Copilot in https://github.com/middleapi/orpc/issues/904 (4f28b)
View changes on GitHub
August 20, 2025
React SWR Integration docs
import useSWR from 'swr'
const { data, error, isLoading } = useSWR(
orpc.planet.find.key({ input: { id: 123 } }),
orpc.planet.find.fetcher(),
)
🚀 Features
- react-swr: React SWR Integration - by @dinwwwh in https://github.com/middleapi/orpc/issues/891 (ff7ad)
🐞 Bug Fixes
- client: Prevent unintended procedure calls when awaiting client - by @dinwwwh in https://github.com/middleapi/orpc/issues/887 (54654)
- server: Apply error validation to event iterator - by @dinwwwh in https://github.com/middleapi/orpc/issues/893 (03fed)
View changes on GitHub
August 14, 2025
🚀 Features
- server:
- Compression Plugin - by @dinwwwh in https://github.com/middleapi/orpc/issues/869 (85cf3) and https://github.com/middleapi/orpc/issues/880 (b7780)
🐞 Bug Fixes
- server:
- Restore original request.emit method in Node Body Limit Plugin - by @dinwwwh in https://github.com/middleapi/orpc/issues/863 (584cf)
- tanstack-query:
- ExactOptionalPropertyTypes - by @dinwwwh in https://github.com/middleapi/orpc/issues/878 (d53d8)
View changes on GitHub
August 11, 2025
First-class OpenTelemetry Support docs
import { NodeSDK } from '@opentelemetry/sdk-node'
import { ORPCInstrumentation } from '@orpc/otel'
const sdk = new NodeSDK({
instrumentations: [
new ORPCInstrumentation(),
],
})
sdk.start()
🚀 Features
- otel:
- OpenTelemetry Integration - by @dinwwwh in https://github.com/middleapi/orpc/issues/806 (7b151)
- server:
- Allow RPC calls without data - by @dinwwwh in https://github.com/middleapi/orpc/issues/853 (890a8)
- Stable hibernation apis - by @dinwwwh in https://github.com/middleapi/orpc/issues/854 (a3206)
- trpc:
- Stable tRPC to oRPC router - by @dinwwwh in https://github.com/middleapi/orpc/issues/808 (842d6)
View changes on GitHub
August 8, 2025
🐞 Bug Fixes
- openapi: Tsconfig erasableSyntaxOnly option not working - by @dinwwwh in https://github.com/middleapi/orpc/issues/845 (18a97)
View changes on GitHub
August 7, 2025
🐞 Bug Fixes
- tanstack-query: Default enabled option not working - by @dinwwwh in https://github.com/middleapi/orpc/issues/840 (9257f)
View changes on GitHub
August 3, 2025
🚀 Features
- server: Delete cookie helper - by @dinwwwh in https://github.com/middleapi/orpc/issues/820 (cf959)
View changes on GitHub
August 2, 2025
🚀 Features
- openapi: Override operationId and spec callback for extending operations - by @dinwwwh in https://github.com/middleapi/orpc/issues/818 (98403)
🐞 Bug Fixes
- client, server: Missing reexport AsyncIteratorClass - by @dinwwwh (8646d)
View changes on GitHub
August 1, 2025
🐞 Bug Fixes
- openapi: Support strict object schema for dynamic params - by @dinwwwh in https://github.com/middleapi/orpc/issues/814 (90a7c)
View changes on GitHub
July 31, 2025
🐞 Bug Fixes
- json-schema: Enhance array to map coercion to handle unique keys - by @dinwwwh in https://github.com/middleapi/orpc/issues/811 (42e16)
View changes on GitHub
July 26, 2025
🚀 Features
- client:
- Add headers support to WebSocket and MessagePort adapters - by @dinwwwh (27467)
- server:
- Request Headers Plugin - by @dinwwwh in https://github.com/middleapi/orpc/issues/804 (caeb6)
- Helpers - by @dinwwwh in https://github.com/middleapi/orpc/issues/805 (01ede)
View changes on GitHub
July 18, 2025
🚀 Features
- zod: Support zod v4 and v3 ZodSmartCoercionPlugin use in parallel - by @dinwwwh (93ea2)
View changes on GitHub
July 18, 2025
🚀 Features
- zod: Support zod v4 and v3 SchemaConverter use in parallel - by @dinwwwh in https://github.com/middleapi/orpc/issues/790 (84ea6)
View changes on GitHub
July 16, 2025
AI SDK Integration docs
AI SDK is a free open-source library for building AI-powered products. You can seamlessly integrate it with oRPC without any extra overhead.
const { messages, sendMessage, status } = useChat({
transport: {
async sendMessages(options) {
return eventIteratorToStream(await client.chat({
chatId: options.chatId,
messages: options.messages,
}, { signal: options.abortSignal }))
},
},
})
🚀 Features
- Stream converter utils + AI SDK examples - by @dinwwwh in https://github.com/middleapi/orpc/issues/775 (e7882)
- server, openapi: Add filter option to handlers - by @dinwwwh in https://github.com/middleapi/orpc/issues/770 (3f73b)
- zod: Support zod meta
titlein generated JSON schema - by @zhelezkov in https://github.com/middleapi/orpc/issues/774 (c8607)
View changes on GitHub
July 15, 2025
ORPCMeta update for tRPC docs
const example = t.procedure
- .meta({ path: '/hello', summary: 'Hello procedure' })
+ .meta({ route: { path: '/hello', summary: 'Hello procedure' } })
.input(z.object({ name: z.string() }))
.query(({ input }) => {
return `Hello, ${input.name}!`
})
🚀 Features
- trpc: Restructure ORPCMeta + accessible lazy router - by @dinwwwh in https://github.com/middleapi/orpc/issues/758 (5049f)
🐞 Bug Fixes
- client: Missing export
createSafeClient- by @dinwwwh (cf4ae)
View changes on GitHub
July 14, 2025
Safe Client docs
If you often use safe for error handling, createSafeClient can simplify your code by automatically wrapping all procedure calls with safe. It works with both server-side and client-side clients.
import { createSafeClient } from '@orpc/client'
const safeClient = createSafeClient(client)
const [error, data] = await safeClient.doSomething({ id: '123' })
Smart Coercion Plugin docs
Automatically converts input values to match schema types without manually defining coercion logic. This plugin can support almost any standard schema.
import { OpenAPIHandler } from '@orpc/openapi/fetch'
import {
experimental_SmartCoercionPlugin as SmartCoercionPlugin
} from '@orpc/json-schema'
const handler = new OpenAPIHandler(router, {
plugins: [
new SmartCoercionPlugin({
schemaConverters: [
new ZodToJsonSchemaConverter(), // <-- if you use Zod
new ValibotToJsonSchemaConverter(), // <-- if you use Valibot
new ArkTypeToJsonSchemaConverter(), // <-- if you use ArkType
],
})
]
})
Promote stable
aws lambda, websocket, message port, zod 4 converter now stable
🚀 Features
- client:
- Safe client - by @Copilot in https://github.com/middleapi/orpc/issues/751 (25279)
- json-schema:
- Smart coercion plugin for any standard schema - by @dinwwwh in https://github.com/middleapi/orpc/issues/748 (e5e26)
- standard-server-aws-lambda:
- Promote to stable - by @dinwwwh in https://github.com/middleapi/orpc/issues/762 (c84c8)
- standard-server-peer:
- Promote to stable - by @dinwwwh in https://github.com/middleapi/orpc/issues/766 (4f419)
- zod:
- Better support zod@4.x.x - by @dinwwwh in https://github.com/middleapi/orpc/issues/760 (53096)
- Promote zod4 converter to stable - by @dinwwwh in https://github.com/middleapi/orpc/issues/763 (9cd4e)
- Promote zod4 registries to stable - by @dinwwwh (1207d)
🐞 Bug Fixes
- server: Add missing export for utils in standard adapter - by @dinwwwh (29120)
- trpc: Add missing exports - by @dinwwwh (c465e)
View changes on GitHub
July 11, 2025
No significant changes
View changes on GitHub
July 11, 2025
🐞 Bug Fixes
- server: Add missing export for utils in standard adapter - by @dinwwwh (29120)
- trpc: Add missing exports - by @dinwwwh (03fca)
View changes on GitHub
July 5, 2025
🚀 Features
- openapi: Add array index limit to bracket notation for security - by @dinwwwh in https://github.com/middleapi/orpc/issues/731 (865fe)
View changes on GitHub
July 5, 2025
🚀 Features
- react:
useOptimisticServerActionHook - by @dinwwwh in https://github.com/middleapi/orpc/issues/724 (12f07)
View changes on GitHub
July 3, 2025
Live Query Options docs
Use .liveOptions to configure live queries for Event Iterator. Unlike .streamedOptions which accumulates chunks, live queries replace the entire result with each new chunk received
const query = useQuery(orpc.live.experimental_liveOptions({
input: { id: 123 }, // Specify input if needed
context: { cache: true }, // Provide client context if needed
// additional options...
}))
🚀 Features
- tanstack-query: Live query options - by @dinwwwh in https://github.com/middleapi/orpc/issues/721 (25156)
View changes on GitHub
July 2, 2025
🚀 Features
- trpc: Support event iterator for toORPCRouter - by @dinwwwh in https://github.com/middleapi/orpc/issues/716 (dda04)
View changes on GitHub
July 2, 2025
🐞 Bug Fixes
- contract: EventIterator should cleanup on validation failure - by @dinwwwh in https://github.com/middleapi/orpc/issues/715 (40088)
View changes on GitHub
July 2, 2025
🚀 Features
- nest: Module configuration - by @dinwwwh in https://github.com/middleapi/orpc/issues/710 (3d8a8)