@trpc/server 11.19.0 → 11.21.1-canary.20.10e2ef98f

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (141) hide show
  1. package/adapters/aws-lambda/index.d.ts +1 -0
  2. package/adapters/aws-lambda/index.js +1 -0
  3. package/adapters/express/index.d.ts +1 -0
  4. package/adapters/express/index.js +1 -0
  5. package/adapters/fastify/index.d.ts +1 -0
  6. package/adapters/fastify/index.js +1 -0
  7. package/adapters/fetch/index.d.ts +1 -0
  8. package/adapters/fetch/index.js +1 -0
  9. package/adapters/next/index.d.ts +1 -0
  10. package/adapters/next/index.js +1 -0
  11. package/adapters/next-app-dir/index.d.ts +1 -0
  12. package/adapters/next-app-dir/index.js +1 -0
  13. package/adapters/node-http/content-type/form-data/index.d.ts +1 -0
  14. package/adapters/node-http/content-type/form-data/index.js +1 -0
  15. package/adapters/node-http/content-type/json/index.d.ts +1 -0
  16. package/adapters/node-http/content-type/json/index.js +1 -0
  17. package/adapters/node-http/index.d.ts +1 -0
  18. package/adapters/node-http/index.js +1 -0
  19. package/adapters/standalone/index.d.ts +1 -0
  20. package/adapters/standalone/index.js +1 -0
  21. package/adapters/ws/index.d.ts +1 -0
  22. package/adapters/ws/index.js +1 -0
  23. package/dist/adapters/aws-lambda/index.cjs +2 -2
  24. package/dist/adapters/aws-lambda/index.d.cts +1 -1
  25. package/dist/adapters/aws-lambda/index.d.mts +1 -1
  26. package/dist/adapters/aws-lambda/index.mjs +2 -2
  27. package/dist/adapters/express.cjs +3 -3
  28. package/dist/adapters/express.d.cts +2 -2
  29. package/dist/adapters/express.d.mts +2 -2
  30. package/dist/adapters/express.mjs +3 -3
  31. package/dist/adapters/fastify/index.cjs +4 -4
  32. package/dist/adapters/fastify/index.d.cts +2 -2
  33. package/dist/adapters/fastify/index.d.mts +2 -2
  34. package/dist/adapters/fastify/index.mjs +4 -4
  35. package/dist/adapters/fetch/index.cjs +2 -2
  36. package/dist/adapters/fetch/index.d.cts +1 -1
  37. package/dist/adapters/fetch/index.d.mts +1 -1
  38. package/dist/adapters/fetch/index.mjs +2 -2
  39. package/dist/adapters/next-app-dir.cjs +7 -7
  40. package/dist/adapters/next-app-dir.d.cts +1 -1
  41. package/dist/adapters/next-app-dir.d.mts +1 -1
  42. package/dist/adapters/next-app-dir.mjs +2 -2
  43. package/dist/adapters/next.cjs +5 -5
  44. package/dist/adapters/next.d.cts +2 -2
  45. package/dist/adapters/next.d.mts +2 -2
  46. package/dist/adapters/next.mjs +4 -4
  47. package/dist/adapters/node-http/index.cjs +1 -1
  48. package/dist/adapters/node-http/index.d.cts +1 -1
  49. package/dist/adapters/node-http/index.d.mts +1 -1
  50. package/dist/adapters/node-http/index.mjs +1 -1
  51. package/dist/adapters/standalone.cjs +3 -3
  52. package/dist/adapters/standalone.d.cts +2 -2
  53. package/dist/adapters/standalone.d.mts +2 -2
  54. package/dist/adapters/standalone.mjs +3 -3
  55. package/dist/adapters/ws.cjs +1 -1
  56. package/dist/adapters/ws.d.cts +2 -2
  57. package/dist/adapters/ws.d.mts +2 -2
  58. package/dist/adapters/ws.mjs +1 -1
  59. package/dist/{tracked-BQJb0ANk.cjs → asyncGeneratorDelegate-D2tFgl_z.cjs} +167 -17
  60. package/dist/{tracked-D4jU_Hb3.mjs → asyncGeneratorDelegate-mPyp1u6d.mjs} +141 -9
  61. package/dist/asyncGeneratorDelegate-mPyp1u6d.mjs.map +1 -0
  62. package/dist/{codes-C6ZIq69A.cjs → codes-BwD4QurF.cjs} +9 -0
  63. package/dist/{codes-D5Ya6_Bi.mjs → codes-D6C_OiJy.mjs} +5 -2
  64. package/dist/codes-D6C_OiJy.mjs.map +1 -0
  65. package/dist/{getErrorShape-B0JBUs-i.mjs → getErrorShape-BziUKLM_.mjs} +52 -14
  66. package/dist/getErrorShape-BziUKLM_.mjs.map +1 -0
  67. package/dist/{getErrorShape-DeIapApr.cjs → getErrorShape-CVxLwJgN.cjs} +80 -12
  68. package/dist/http.cjs +2 -2
  69. package/dist/http.d.cts +1 -1
  70. package/dist/http.d.mts +1 -1
  71. package/dist/http.mjs +2 -2
  72. package/dist/{index-_jAhoJQ7.d.mts → index-BDZDS1SD.d.mts} +2 -2
  73. package/dist/{index-BHatz_Pu.d.cts.map → index-BDZDS1SD.d.mts.map} +1 -1
  74. package/dist/{index-BHatz_Pu.d.cts → index-BzKrDvzg.d.cts} +2 -2
  75. package/dist/{index-_jAhoJQ7.d.mts.map → index-BzKrDvzg.d.cts.map} +1 -1
  76. package/dist/index.cjs +12 -12
  77. package/dist/index.d.cts +2 -2
  78. package/dist/index.d.cts.map +1 -1
  79. package/dist/index.d.mts +2 -2
  80. package/dist/index.d.mts.map +1 -1
  81. package/dist/index.mjs +3 -3
  82. package/dist/{initTRPC-B7UdX-c3.cjs → initTRPC-DLNeKv0z.cjs} +114 -26
  83. package/dist/{initTRPC-B259os3T.mjs → initTRPC-DpOypWK_.mjs} +95 -19
  84. package/dist/initTRPC-DpOypWK_.mjs.map +1 -0
  85. package/dist/{node-http-BUlb5EdB.mjs → node-http-B_z10Yky.mjs} +5 -5
  86. package/dist/{node-http-BUlb5EdB.mjs.map → node-http-B_z10Yky.mjs.map} +1 -1
  87. package/dist/{node-http-CikCqjt6.cjs → node-http-Bti3aBT6.cjs} +9 -9
  88. package/dist/{parseTRPCMessage-MJWDg1vX.mjs → parseTRPCMessage-CSh-CVPr.mjs} +2 -2
  89. package/dist/{parseTRPCMessage-MJWDg1vX.mjs.map → parseTRPCMessage-CSh-CVPr.mjs.map} +1 -1
  90. package/dist/{parseTRPCMessage-BxAIUx49.cjs → parseTRPCMessage-RJS87G_t.cjs} +1 -1
  91. package/dist/{resolveResponse-JtMyT9TQ.mjs → resolveResponse-CrB_9MSD.mjs} +43 -179
  92. package/dist/resolveResponse-CrB_9MSD.mjs.map +1 -0
  93. package/dist/{resolveResponse-DLpzHrPG.cjs → resolveResponse-D5JAuwvU.cjs} +90 -226
  94. package/dist/rpc.cjs +2 -2
  95. package/dist/rpc.d.cts +1 -1
  96. package/dist/rpc.d.mts +1 -1
  97. package/dist/rpc.mjs +2 -2
  98. package/dist/shared.cjs +1 -1
  99. package/dist/shared.d.cts +1 -1
  100. package/dist/shared.d.mts +1 -1
  101. package/dist/shared.mjs +1 -1
  102. package/dist/{unstable-core-do-not-import-BK_OKrtM.d.mts → unstable-core-do-not-import-JE3NCpqt.d.mts} +707 -636
  103. package/dist/unstable-core-do-not-import-JE3NCpqt.d.mts.map +1 -0
  104. package/dist/{unstable-core-do-not-import-B9ZnrQAU.d.cts → unstable-core-do-not-import-Jynlfuqc.d.cts} +707 -636
  105. package/dist/unstable-core-do-not-import-Jynlfuqc.d.cts.map +1 -0
  106. package/dist/unstable-core-do-not-import.cjs +30 -23
  107. package/dist/unstable-core-do-not-import.d.cts +2 -2
  108. package/dist/unstable-core-do-not-import.d.mts +2 -2
  109. package/dist/unstable-core-do-not-import.mjs +7 -7
  110. package/dist/{ws-BMSSVFiW.cjs → ws-BgBeYgGS.cjs} +22 -22
  111. package/dist/{ws-C7ZOJJeA.mjs → ws-CNjkWAs9.mjs} +7 -7
  112. package/dist/{ws-C7ZOJJeA.mjs.map → ws-CNjkWAs9.mjs.map} +1 -1
  113. package/http/index.d.ts +1 -0
  114. package/http/index.js +1 -0
  115. package/observable/index.d.ts +1 -0
  116. package/observable/index.js +1 -0
  117. package/package.json +14 -14
  118. package/rpc/index.d.ts +1 -0
  119. package/rpc/index.js +1 -0
  120. package/shared/index.d.ts +1 -0
  121. package/shared/index.js +1 -0
  122. package/src/@trpc/server/index.ts +1 -0
  123. package/src/unstable-core-do-not-import/clientish/inference.ts +12 -0
  124. package/src/unstable-core-do-not-import/error/formatter.ts +90 -3
  125. package/src/unstable-core-do-not-import/error/getErrorShape.ts +8 -17
  126. package/src/unstable-core-do-not-import/initTRPC.ts +10 -7
  127. package/src/unstable-core-do-not-import/middleware.ts +93 -2
  128. package/src/unstable-core-do-not-import/procedure.ts +2 -0
  129. package/src/unstable-core-do-not-import/procedureBuilder.ts +79 -13
  130. package/src/unstable-core-do-not-import/rootConfig.ts +8 -0
  131. package/src/unstable-core-do-not-import/stream/jsonl.ts +41 -33
  132. package/src/unstable-core-do-not-import/utils.ts +4 -0
  133. package/unstable-core-do-not-import/index.d.ts +1 -0
  134. package/unstable-core-do-not-import/index.js +1 -0
  135. package/dist/codes-D5Ya6_Bi.mjs.map +0 -1
  136. package/dist/getErrorShape-B0JBUs-i.mjs.map +0 -1
  137. package/dist/initTRPC-B259os3T.mjs.map +0 -1
  138. package/dist/resolveResponse-JtMyT9TQ.mjs.map +0 -1
  139. package/dist/tracked-D4jU_Hb3.mjs.map +0 -1
  140. package/dist/unstable-core-do-not-import-B9ZnrQAU.d.cts.map +0 -1
  141. package/dist/unstable-core-do-not-import-BK_OKrtM.d.mts.map +0 -1
@@ -0,0 +1 @@
1
+ export * from '../../dist/adapters/aws-lambda';
@@ -0,0 +1 @@
1
+ module.exports = require('../../dist/adapters/aws-lambda');
@@ -0,0 +1 @@
1
+ export * from '../../dist/adapters/express';
@@ -0,0 +1 @@
1
+ module.exports = require('../../dist/adapters/express');
@@ -0,0 +1 @@
1
+ export * from '../../dist/adapters/fastify';
@@ -0,0 +1 @@
1
+ module.exports = require('../../dist/adapters/fastify');
@@ -0,0 +1 @@
1
+ export * from '../../dist/adapters/fetch';
@@ -0,0 +1 @@
1
+ module.exports = require('../../dist/adapters/fetch');
@@ -0,0 +1 @@
1
+ export * from '../../dist/adapters/next';
@@ -0,0 +1 @@
1
+ module.exports = require('../../dist/adapters/next');
@@ -0,0 +1 @@
1
+ export * from '../../dist/adapters/next-app-dir';
@@ -0,0 +1 @@
1
+ module.exports = require('../../dist/adapters/next-app-dir');
@@ -0,0 +1 @@
1
+ export * from '../../../../dist/adapters/node-http/content-type/form-data';
@@ -0,0 +1 @@
1
+ module.exports = require('../../../../dist/adapters/node-http/content-type/form-data');
@@ -0,0 +1 @@
1
+ export * from '../../../../dist/adapters/node-http/content-type/json';
@@ -0,0 +1 @@
1
+ module.exports = require('../../../../dist/adapters/node-http/content-type/json');
@@ -0,0 +1 @@
1
+ export * from '../../dist/adapters/node-http';
@@ -0,0 +1 @@
1
+ module.exports = require('../../dist/adapters/node-http');
@@ -0,0 +1 @@
1
+ export * from '../../dist/adapters/standalone';
@@ -0,0 +1 @@
1
+ module.exports = require('../../dist/adapters/standalone');
@@ -0,0 +1 @@
1
+ export * from '../../dist/adapters/ws';
@@ -0,0 +1 @@
1
+ module.exports = require('../../dist/adapters/ws');
@@ -1,6 +1,6 @@
1
1
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
2
- const require_getErrorShape = require("../../getErrorShape-DeIapApr.cjs");
3
- const require_resolveResponse = require("../../resolveResponse-DLpzHrPG.cjs");
2
+ const require_getErrorShape = require("../../getErrorShape-CVxLwJgN.cjs");
3
+ const require_resolveResponse = require("../../resolveResponse-D5JAuwvU.cjs");
4
4
  let node_stream = require("node:stream");
5
5
  let node_stream_promises = require("node:stream/promises");
6
6
  //#region src/vendor/cookie-es/set-cookie/split.ts
@@ -1,4 +1,4 @@
1
- import { Cn as TRPCRequestInfo, J as AnyRouter, _n as HTTPBaseHandlerOptions, ft as inferRouterContext, yt as CreateContextCallback } from "../../unstable-core-do-not-import-B9ZnrQAU.cjs";
1
+ import { $n as inferRouterContext, Dn as HTTPBaseHandlerOptions, Fn as AnyRouter, Nn as TRPCRequestInfo, or as CreateContextCallback } from "../../unstable-core-do-not-import-Jynlfuqc.cjs";
2
2
  import { APIGatewayProxyEvent, APIGatewayProxyEventV2, APIGatewayProxyResult, APIGatewayProxyStructuredResultV2, Context, StreamifyHandler } from "aws-lambda";
3
3
  //#region src/adapters/aws-lambda/getPlanner.d.ts
4
4
  type LambdaEvent = APIGatewayProxyEvent | APIGatewayProxyEventV2;
@@ -1,4 +1,4 @@
1
- import { Cn as TRPCRequestInfo, J as AnyRouter, _n as HTTPBaseHandlerOptions, ft as inferRouterContext, yt as CreateContextCallback } from "../../unstable-core-do-not-import-BK_OKrtM.mjs";
1
+ import { $n as inferRouterContext, Dn as HTTPBaseHandlerOptions, Fn as AnyRouter, Nn as TRPCRequestInfo, or as CreateContextCallback } from "../../unstable-core-do-not-import-JE3NCpqt.mjs";
2
2
  import { APIGatewayProxyEvent, APIGatewayProxyEventV2, APIGatewayProxyResult, APIGatewayProxyStructuredResultV2, Context, StreamifyHandler } from "aws-lambda";
3
3
  //#region src/adapters/aws-lambda/getPlanner.d.ts
4
4
  type LambdaEvent = APIGatewayProxyEvent | APIGatewayProxyEventV2;
@@ -1,5 +1,5 @@
1
- import { n as _objectSpread2 } from "../../getErrorShape-B0JBUs-i.mjs";
2
- import { t as resolveResponse } from "../../resolveResponse-JtMyT9TQ.mjs";
1
+ import { n as _objectSpread2 } from "../../getErrorShape-BziUKLM_.mjs";
2
+ import { t as resolveResponse } from "../../resolveResponse-CrB_9MSD.mjs";
3
3
  import { Readable } from "node:stream";
4
4
  import { pipeline } from "node:stream/promises";
5
5
  //#region src/vendor/cookie-es/set-cookie/split.ts
@@ -1,7 +1,7 @@
1
1
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
2
- const require_codes = require("../codes-C6ZIq69A.cjs");
3
- const require_getErrorShape = require("../getErrorShape-DeIapApr.cjs");
4
- const require_node_http = require("../node-http-CikCqjt6.cjs");
2
+ const require_codes = require("../codes-BwD4QurF.cjs");
3
+ const require_getErrorShape = require("../getErrorShape-CVxLwJgN.cjs");
4
+ const require_node_http = require("../node-http-Bti3aBT6.cjs");
5
5
  //#region src/adapters/express.ts
6
6
  function createExpressMiddleware(opts) {
7
7
  return (req, res) => {
@@ -1,5 +1,5 @@
1
- import { J as AnyRouter } from "../unstable-core-do-not-import-B9ZnrQAU.cjs";
2
- import { c as NodeHTTPHandlerOptions, o as NodeHTTPCreateContextFnOptions } from "../index-BHatz_Pu.cjs";
1
+ import { Fn as AnyRouter } from "../unstable-core-do-not-import-Jynlfuqc.cjs";
2
+ import { c as NodeHTTPHandlerOptions, o as NodeHTTPCreateContextFnOptions } from "../index-BzKrDvzg.cjs";
3
3
  import * as express from "express";
4
4
  //#region src/adapters/express.d.ts
5
5
  export type CreateExpressContextOptions = NodeHTTPCreateContextFnOptions<express.Request, express.Response>;
@@ -1,5 +1,5 @@
1
- import { J as AnyRouter } from "../unstable-core-do-not-import-BK_OKrtM.mjs";
2
- import { c as NodeHTTPHandlerOptions, o as NodeHTTPCreateContextFnOptions } from "../index-_jAhoJQ7.mjs";
1
+ import { Fn as AnyRouter } from "../unstable-core-do-not-import-JE3NCpqt.mjs";
2
+ import { c as NodeHTTPHandlerOptions, o as NodeHTTPCreateContextFnOptions } from "../index-BDZDS1SD.mjs";
3
3
  import * as express from "express";
4
4
  //#region src/adapters/express.d.ts
5
5
  export type CreateExpressContextOptions = NodeHTTPCreateContextFnOptions<express.Request, express.Response>;
@@ -1,6 +1,6 @@
1
- import { p as run } from "../codes-D5Ya6_Bi.mjs";
2
- import { n as _objectSpread2 } from "../getErrorShape-B0JBUs-i.mjs";
3
- import { n as nodeHTTPRequestHandler, t as internal_exceptionHandler } from "../node-http-BUlb5EdB.mjs";
1
+ import { m as run } from "../codes-D6C_OiJy.mjs";
2
+ import { n as _objectSpread2 } from "../getErrorShape-BziUKLM_.mjs";
3
+ import { n as nodeHTTPRequestHandler, t as internal_exceptionHandler } from "../node-http-B_z10Yky.mjs";
4
4
  //#region src/adapters/express.ts
5
5
  function createExpressMiddleware(opts) {
6
6
  return (req, res) => {
@@ -1,8 +1,8 @@
1
1
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
2
- const require_getErrorShape = require("../../getErrorShape-DeIapApr.cjs");
3
- const require_resolveResponse = require("../../resolveResponse-DLpzHrPG.cjs");
4
- const require_node_http = require("../../node-http-CikCqjt6.cjs");
5
- const require_ws = require("../../ws-BMSSVFiW.cjs");
2
+ const require_getErrorShape = require("../../getErrorShape-CVxLwJgN.cjs");
3
+ const require_resolveResponse = require("../../resolveResponse-D5JAuwvU.cjs");
4
+ const require_node_http = require("../../node-http-Bti3aBT6.cjs");
5
+ const require_ws = require("../../ws-BgBeYgGS.cjs");
6
6
  //#region src/adapters/fastify/fastifyRequestHandler.ts
7
7
  async function fastifyRequestHandler(opts) {
8
8
  const createContext = async (innerOpts) => {
@@ -1,5 +1,5 @@
1
- import { J as AnyRouter, _n as HTTPBaseHandlerOptions } from "../../unstable-core-do-not-import-B9ZnrQAU.cjs";
2
- import { o as NodeHTTPCreateContextFnOptions, s as NodeHTTPCreateContextOption } from "../../index-BHatz_Pu.cjs";
1
+ import { Dn as HTTPBaseHandlerOptions, Fn as AnyRouter } from "../../unstable-core-do-not-import-Jynlfuqc.cjs";
2
+ import { o as NodeHTTPCreateContextFnOptions, s as NodeHTTPCreateContextOption } from "../../index-BzKrDvzg.cjs";
3
3
  import { FastifyInstance, FastifyReply, FastifyRequest } from "fastify";
4
4
  //#region src/adapters/fastify/fastifyRequestHandler.d.ts
5
5
  export type FastifyHandlerOptions<TRouter extends AnyRouter, TRequest extends FastifyRequest, TResponse extends FastifyReply> = HTTPBaseHandlerOptions<TRouter, TRequest> & NodeHTTPCreateContextOption<TRouter, TRequest, TResponse>;
@@ -1,5 +1,5 @@
1
- import { J as AnyRouter, _n as HTTPBaseHandlerOptions } from "../../unstable-core-do-not-import-BK_OKrtM.mjs";
2
- import { o as NodeHTTPCreateContextFnOptions, s as NodeHTTPCreateContextOption } from "../../index-_jAhoJQ7.mjs";
1
+ import { Dn as HTTPBaseHandlerOptions, Fn as AnyRouter } from "../../unstable-core-do-not-import-JE3NCpqt.mjs";
2
+ import { o as NodeHTTPCreateContextFnOptions, s as NodeHTTPCreateContextOption } from "../../index-BDZDS1SD.mjs";
3
3
  import { FastifyInstance, FastifyReply, FastifyRequest } from "fastify";
4
4
  //#region src/adapters/fastify/fastifyRequestHandler.d.ts
5
5
  export type FastifyHandlerOptions<TRouter extends AnyRouter, TRequest extends FastifyRequest, TResponse extends FastifyReply> = HTTPBaseHandlerOptions<TRouter, TRequest> & NodeHTTPCreateContextOption<TRouter, TRequest, TResponse>;
@@ -1,7 +1,7 @@
1
- import { n as _objectSpread2 } from "../../getErrorShape-B0JBUs-i.mjs";
2
- import { t as resolveResponse } from "../../resolveResponse-JtMyT9TQ.mjs";
3
- import { i as incomingMessageToRequest } from "../../node-http-BUlb5EdB.mjs";
4
- import { n as getWSConnectionHandler, r as handleKeepAlive } from "../../ws-C7ZOJJeA.mjs";
1
+ import { n as _objectSpread2 } from "../../getErrorShape-BziUKLM_.mjs";
2
+ import { t as resolveResponse } from "../../resolveResponse-CrB_9MSD.mjs";
3
+ import { i as incomingMessageToRequest } from "../../node-http-B_z10Yky.mjs";
4
+ import { n as getWSConnectionHandler, r as handleKeepAlive } from "../../ws-CNjkWAs9.mjs";
5
5
  //#region src/adapters/fastify/fastifyRequestHandler.ts
6
6
  async function fastifyRequestHandler(opts) {
7
7
  const createContext = async (innerOpts) => {
@@ -1,6 +1,6 @@
1
1
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
2
- const require_getErrorShape = require("../../getErrorShape-DeIapApr.cjs");
3
- const require_resolveResponse = require("../../resolveResponse-DLpzHrPG.cjs");
2
+ const require_getErrorShape = require("../../getErrorShape-CVxLwJgN.cjs");
3
+ const require_resolveResponse = require("../../resolveResponse-D5JAuwvU.cjs");
4
4
  //#region src/adapters/fetch/fetchRequestHandler.ts
5
5
  const trimSlashes = (path) => {
6
6
  path = path.startsWith("/") ? path.slice(1) : path;
@@ -1,4 +1,4 @@
1
- import { Cn as TRPCRequestInfo, J as AnyRouter, _n as HTTPBaseHandlerOptions, ft as inferRouterContext, yt as CreateContextCallback } from "../../unstable-core-do-not-import-B9ZnrQAU.cjs";
1
+ import { $n as inferRouterContext, Dn as HTTPBaseHandlerOptions, Fn as AnyRouter, Nn as TRPCRequestInfo, or as CreateContextCallback } from "../../unstable-core-do-not-import-Jynlfuqc.cjs";
2
2
  //#region src/adapters/fetch/types.d.ts
3
3
  export type FetchCreateContextFnOptions = {
4
4
  req: Request;
@@ -1,4 +1,4 @@
1
- import { Cn as TRPCRequestInfo, J as AnyRouter, _n as HTTPBaseHandlerOptions, ft as inferRouterContext, yt as CreateContextCallback } from "../../unstable-core-do-not-import-BK_OKrtM.mjs";
1
+ import { $n as inferRouterContext, Dn as HTTPBaseHandlerOptions, Fn as AnyRouter, Nn as TRPCRequestInfo, or as CreateContextCallback } from "../../unstable-core-do-not-import-JE3NCpqt.mjs";
2
2
  //#region src/adapters/fetch/types.d.ts
3
3
  export type FetchCreateContextFnOptions = {
4
4
  req: Request;
@@ -1,5 +1,5 @@
1
- import { n as _objectSpread2 } from "../../getErrorShape-B0JBUs-i.mjs";
2
- import { t as resolveResponse } from "../../resolveResponse-JtMyT9TQ.mjs";
1
+ import { n as _objectSpread2 } from "../../getErrorShape-BziUKLM_.mjs";
2
+ import { t as resolveResponse } from "../../resolveResponse-CrB_9MSD.mjs";
3
3
  //#region src/adapters/fetch/fetchRequestHandler.ts
4
4
  const trimSlashes = (path) => {
5
5
  path = path.startsWith("/") ? path.slice(1) : path;
@@ -1,7 +1,7 @@
1
1
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
2
2
  const require_rolldown_runtime = require("../rolldown-runtime-VH7oDXx4.cjs");
3
- const require_getErrorShape = require("../getErrorShape-DeIapApr.cjs");
4
- const require_tracked = require("../tracked-BQJb0ANk.cjs");
3
+ const require_getErrorShape = require("../getErrorShape-CVxLwJgN.cjs");
4
+ const require_asyncGeneratorDelegate = require("../asyncGeneratorDelegate-D2tFgl_z.cjs");
5
5
  const require_unstable_core_do_not_import = require("../unstable-core-do-not-import.cjs");
6
6
  let next_navigation = require("next/navigation");
7
7
  next_navigation = require_rolldown_runtime.__toESM(next_navigation, 1);
@@ -9,7 +9,7 @@ next_navigation = require_rolldown_runtime.__toESM(next_navigation, 1);
9
9
  /**
10
10
  * @internal
11
11
  */
12
- var TRPCRedirectError = class extends require_tracked.TRPCError {
12
+ var TRPCRedirectError = class extends require_asyncGeneratorDelegate.TRPCError {
13
13
  constructor(url, redirectType) {
14
14
  super({
15
15
  code: "UNPROCESSABLE_CONTENT",
@@ -78,7 +78,7 @@ function nextAppDirCaller(config) {
78
78
  var _config$pathExtractor, _config$pathExtractor2;
79
79
  const path = (_config$pathExtractor = (_config$pathExtractor2 = config.pathExtractor) === null || _config$pathExtractor2 === void 0 ? void 0 : _config$pathExtractor2.call(config, { meta: opts._def.meta })) !== null && _config$pathExtractor !== void 0 ? _config$pathExtractor : "";
80
80
  const ctx = await createContext().catch((cause) => {
81
- throw new require_tracked.TRPCError({
81
+ throw new require_asyncGeneratorDelegate.TRPCError({
82
82
  code: "INTERNAL_SERVER_ERROR",
83
83
  message: "Failed to create context",
84
84
  cause
@@ -86,7 +86,7 @@ function nextAppDirCaller(config) {
86
86
  });
87
87
  const handleError = (cause) => {
88
88
  var _config$onError;
89
- const error = require_tracked.getTRPCErrorFromUnknown(cause);
89
+ const error = require_asyncGeneratorDelegate.getTRPCErrorFromUnknown(cause);
90
90
  (_config$onError = config.onError) === null || _config$onError === void 0 || _config$onError.call(config, {
91
91
  ctx,
92
92
  error,
@@ -135,7 +135,7 @@ function nextAppDirCaller(config) {
135
135
  return data;
136
136
  }).catch(handleError);
137
137
  }
138
- default: throw new require_tracked.TRPCError({
138
+ default: throw new require_asyncGeneratorDelegate.TRPCError({
139
139
  code: "NOT_IMPLEMENTED",
140
140
  message: `Not implemented for type ${opts._def.type}`
141
141
  });
@@ -149,7 +149,7 @@ function nextAppDirCaller(config) {
149
149
  * @public
150
150
  */
151
151
  const notFound = () => {
152
- throw new require_tracked.TRPCError({ code: "NOT_FOUND" });
152
+ throw new require_asyncGeneratorDelegate.TRPCError({ code: "NOT_FOUND" });
153
153
  };
154
154
  //#endregion
155
155
  exports.experimental_nextAppDirCaller = nextAppDirCaller;
@@ -1,4 +1,4 @@
1
- import { Un as CallerOverride, ii as MaybePromise, kn as ErrorHandlerOptions, li as Simplify, yt as CreateContextCallback, zr as TRPCError } from "../unstable-core-do-not-import-B9ZnrQAU.cjs";
1
+ import { $ as ErrorHandlerOptions, Xr as TRPCError, bi as Simplify, hi as MaybePromise, or as CreateContextCallback, pt as CallerOverride } from "../unstable-core-do-not-import-Jynlfuqc.cjs";
2
2
  import { RedirectType, notFound as notFound$1 } from "next/navigation";
3
3
  //#region src/adapters/next-app-dir/nextAppDirCaller.d.ts
4
4
  /**
@@ -1,4 +1,4 @@
1
- import { Un as CallerOverride, ii as MaybePromise, kn as ErrorHandlerOptions, li as Simplify, yt as CreateContextCallback, zr as TRPCError } from "../unstable-core-do-not-import-BK_OKrtM.mjs";
1
+ import { $ as ErrorHandlerOptions, Xr as TRPCError, bi as Simplify, hi as MaybePromise, or as CreateContextCallback, pt as CallerOverride } from "../unstable-core-do-not-import-JE3NCpqt.mjs";
2
2
  import { RedirectType, notFound as notFound$1 } from "next/navigation";
3
3
  //#region src/adapters/next-app-dir/nextAppDirCaller.d.ts
4
4
  /**
@@ -1,5 +1,5 @@
1
- import { r as _defineProperty } from "../getErrorShape-B0JBUs-i.mjs";
2
- import { g as getTRPCErrorFromUnknown, m as TRPCError } from "../tracked-D4jU_Hb3.mjs";
1
+ import { r as _defineProperty } from "../getErrorShape-BziUKLM_.mjs";
2
+ import { b as getTRPCErrorFromUnknown, v as TRPCError } from "../asyncGeneratorDelegate-mPyp1u6d.mjs";
3
3
  import { formDataToObject } from "../unstable-core-do-not-import.mjs";
4
4
  import * as nextNavigation from "next/navigation";
5
5
  //#region src/adapters/next-app-dir/redirect.ts
@@ -1,8 +1,8 @@
1
1
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
2
- const require_codes = require("../codes-C6ZIq69A.cjs");
3
- const require_getErrorShape = require("../getErrorShape-DeIapApr.cjs");
4
- const require_tracked = require("../tracked-BQJb0ANk.cjs");
5
- const require_node_http = require("../node-http-CikCqjt6.cjs");
2
+ const require_codes = require("../codes-BwD4QurF.cjs");
3
+ const require_getErrorShape = require("../getErrorShape-CVxLwJgN.cjs");
4
+ const require_asyncGeneratorDelegate = require("../asyncGeneratorDelegate-D2tFgl_z.cjs");
5
+ const require_node_http = require("../node-http-Bti3aBT6.cjs");
6
6
  //#region src/adapters/next.ts
7
7
  function createNextApiHandler(opts) {
8
8
  return async (req, res) => {
@@ -11,7 +11,7 @@ function createNextApiHandler(opts) {
11
11
  path = require_codes.run(() => {
12
12
  if (typeof req.query["trpc"] === "string") return req.query["trpc"];
13
13
  if (Array.isArray(req.query["trpc"])) return req.query["trpc"].join("/");
14
- throw new require_tracked.TRPCError({
14
+ throw new require_asyncGeneratorDelegate.TRPCError({
15
15
  message: "Query \"trpc\" not found - is the file named `[trpc]`.ts or `[...trpc].ts`?",
16
16
  code: "INTERNAL_SERVER_ERROR"
17
17
  });
@@ -1,5 +1,5 @@
1
- import { J as AnyRouter } from "../unstable-core-do-not-import-B9ZnrQAU.cjs";
2
- import { c as NodeHTTPHandlerOptions, o as NodeHTTPCreateContextFnOptions } from "../index-BHatz_Pu.cjs";
1
+ import { Fn as AnyRouter } from "../unstable-core-do-not-import-Jynlfuqc.cjs";
2
+ import { c as NodeHTTPHandlerOptions, o as NodeHTTPCreateContextFnOptions } from "../index-BzKrDvzg.cjs";
3
3
  import { NextApiHandler, NextApiHandler as NextApiHandler$1, NextApiRequest, NextApiRequest as NextApiRequest$1, NextApiResponse, NextApiResponse as NextApiResponse$1 } from "next";
4
4
  //#region src/adapters/next.d.ts
5
5
  export type CreateNextContextOptions = NodeHTTPCreateContextFnOptions<NextApiRequest$1, NextApiResponse$1>;
@@ -1,5 +1,5 @@
1
- import { J as AnyRouter } from "../unstable-core-do-not-import-BK_OKrtM.mjs";
2
- import { c as NodeHTTPHandlerOptions, o as NodeHTTPCreateContextFnOptions } from "../index-_jAhoJQ7.mjs";
1
+ import { Fn as AnyRouter } from "../unstable-core-do-not-import-JE3NCpqt.mjs";
2
+ import { c as NodeHTTPHandlerOptions, o as NodeHTTPCreateContextFnOptions } from "../index-BDZDS1SD.mjs";
3
3
  import { NextApiHandler, NextApiHandler as NextApiHandler$1, NextApiRequest, NextApiRequest as NextApiRequest$1, NextApiResponse, NextApiResponse as NextApiResponse$1 } from "next";
4
4
  //#region src/adapters/next.d.ts
5
5
  export type CreateNextContextOptions = NodeHTTPCreateContextFnOptions<NextApiRequest$1, NextApiResponse$1>;
@@ -1,7 +1,7 @@
1
- import { p as run } from "../codes-D5Ya6_Bi.mjs";
2
- import { n as _objectSpread2 } from "../getErrorShape-B0JBUs-i.mjs";
3
- import { m as TRPCError } from "../tracked-D4jU_Hb3.mjs";
4
- import { n as nodeHTTPRequestHandler, t as internal_exceptionHandler } from "../node-http-BUlb5EdB.mjs";
1
+ import { m as run } from "../codes-D6C_OiJy.mjs";
2
+ import { n as _objectSpread2 } from "../getErrorShape-BziUKLM_.mjs";
3
+ import { v as TRPCError } from "../asyncGeneratorDelegate-mPyp1u6d.mjs";
4
+ import { n as nodeHTTPRequestHandler, t as internal_exceptionHandler } from "../node-http-B_z10Yky.mjs";
5
5
  //#region src/adapters/next.ts
6
6
  function createNextApiHandler(opts) {
7
7
  return async (req, res) => {
@@ -1,5 +1,5 @@
1
1
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
2
- const require_node_http = require("../../node-http-CikCqjt6.cjs");
2
+ const require_node_http = require("../../node-http-Bti3aBT6.cjs");
3
3
  exports.createURL = require_node_http.createURL;
4
4
  exports.incomingMessageToRequest = require_node_http.incomingMessageToRequest;
5
5
  exports.internal_exceptionHandler = require_node_http.internal_exceptionHandler;
@@ -1,2 +1,2 @@
1
- import { a as NodeHTTPCreateContextFn, c as NodeHTTPHandlerOptions, d as NodeHTTPResponse, i as nodeHTTPRequestHandler, l as NodeHTTPRequest, n as incomingMessageToRequest, o as NodeHTTPCreateContextFnOptions, r as internal_exceptionHandler, s as NodeHTTPCreateContextOption, t as createURL, u as NodeHTTPRequestHandlerOptions } from "../../index-BHatz_Pu.cjs";
1
+ import { a as NodeHTTPCreateContextFn, c as NodeHTTPHandlerOptions, d as NodeHTTPResponse, i as nodeHTTPRequestHandler, l as NodeHTTPRequest, n as incomingMessageToRequest, o as NodeHTTPCreateContextFnOptions, r as internal_exceptionHandler, s as NodeHTTPCreateContextOption, t as createURL, u as NodeHTTPRequestHandlerOptions } from "../../index-BzKrDvzg.cjs";
2
2
  export { NodeHTTPCreateContextFn, NodeHTTPCreateContextFnOptions, NodeHTTPCreateContextOption, NodeHTTPHandlerOptions, NodeHTTPRequest, NodeHTTPRequestHandlerOptions, NodeHTTPResponse, createURL, incomingMessageToRequest, internal_exceptionHandler, nodeHTTPRequestHandler };
@@ -1,2 +1,2 @@
1
- import { a as NodeHTTPCreateContextFn, c as NodeHTTPHandlerOptions, d as NodeHTTPResponse, i as nodeHTTPRequestHandler, l as NodeHTTPRequest, n as incomingMessageToRequest, o as NodeHTTPCreateContextFnOptions, r as internal_exceptionHandler, s as NodeHTTPCreateContextOption, t as createURL, u as NodeHTTPRequestHandlerOptions } from "../../index-_jAhoJQ7.mjs";
1
+ import { a as NodeHTTPCreateContextFn, c as NodeHTTPHandlerOptions, d as NodeHTTPResponse, i as nodeHTTPRequestHandler, l as NodeHTTPRequest, n as incomingMessageToRequest, o as NodeHTTPCreateContextFnOptions, r as internal_exceptionHandler, s as NodeHTTPCreateContextOption, t as createURL, u as NodeHTTPRequestHandlerOptions } from "../../index-BDZDS1SD.mjs";
2
2
  export { NodeHTTPCreateContextFn, NodeHTTPCreateContextFnOptions, NodeHTTPCreateContextOption, NodeHTTPHandlerOptions, NodeHTTPRequest, NodeHTTPRequestHandlerOptions, NodeHTTPResponse, createURL, incomingMessageToRequest, internal_exceptionHandler, nodeHTTPRequestHandler };
@@ -1,2 +1,2 @@
1
- import { i as incomingMessageToRequest, n as nodeHTTPRequestHandler, r as createURL, t as internal_exceptionHandler } from "../../node-http-BUlb5EdB.mjs";
1
+ import { i as incomingMessageToRequest, n as nodeHTTPRequestHandler, r as createURL, t as internal_exceptionHandler } from "../../node-http-B_z10Yky.mjs";
2
2
  export { createURL, incomingMessageToRequest, internal_exceptionHandler, nodeHTTPRequestHandler };
@@ -1,8 +1,8 @@
1
1
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
2
2
  const require_rolldown_runtime = require("../rolldown-runtime-VH7oDXx4.cjs");
3
- const require_codes = require("../codes-C6ZIq69A.cjs");
4
- const require_getErrorShape = require("../getErrorShape-DeIapApr.cjs");
5
- const require_node_http = require("../node-http-CikCqjt6.cjs");
3
+ const require_codes = require("../codes-BwD4QurF.cjs");
4
+ const require_getErrorShape = require("../getErrorShape-CVxLwJgN.cjs");
5
+ const require_node_http = require("../node-http-Bti3aBT6.cjs");
6
6
  let http = require("http");
7
7
  http = require_rolldown_runtime.__toESM(http, 1);
8
8
  //#region src/adapters/standalone.ts
@@ -1,5 +1,5 @@
1
- import { J as AnyRouter } from "../unstable-core-do-not-import-B9ZnrQAU.cjs";
2
- import { c as NodeHTTPHandlerOptions, d as NodeHTTPResponse, l as NodeHTTPRequest, o as NodeHTTPCreateContextFnOptions } from "../index-BHatz_Pu.cjs";
1
+ import { Fn as AnyRouter } from "../unstable-core-do-not-import-Jynlfuqc.cjs";
2
+ import { c as NodeHTTPHandlerOptions, d as NodeHTTPResponse, l as NodeHTTPRequest, o as NodeHTTPCreateContextFnOptions } from "../index-BzKrDvzg.cjs";
3
3
  import http from "http";
4
4
  import * as http2 from "http2";
5
5
  //#region src/adapters/standalone.d.ts
@@ -1,5 +1,5 @@
1
- import { J as AnyRouter } from "../unstable-core-do-not-import-BK_OKrtM.mjs";
2
- import { c as NodeHTTPHandlerOptions, d as NodeHTTPResponse, l as NodeHTTPRequest, o as NodeHTTPCreateContextFnOptions } from "../index-_jAhoJQ7.mjs";
1
+ import { Fn as AnyRouter } from "../unstable-core-do-not-import-JE3NCpqt.mjs";
2
+ import { c as NodeHTTPHandlerOptions, d as NodeHTTPResponse, l as NodeHTTPRequest, o as NodeHTTPCreateContextFnOptions } from "../index-BDZDS1SD.mjs";
3
3
  import http from "http";
4
4
  import * as http2 from "http2";
5
5
  //#region src/adapters/standalone.d.ts
@@ -1,6 +1,6 @@
1
- import { p as run } from "../codes-D5Ya6_Bi.mjs";
2
- import { n as _objectSpread2 } from "../getErrorShape-B0JBUs-i.mjs";
3
- import { n as nodeHTTPRequestHandler, r as createURL, t as internal_exceptionHandler } from "../node-http-BUlb5EdB.mjs";
1
+ import { m as run } from "../codes-D6C_OiJy.mjs";
2
+ import { n as _objectSpread2 } from "../getErrorShape-BziUKLM_.mjs";
3
+ import { n as nodeHTTPRequestHandler, r as createURL, t as internal_exceptionHandler } from "../node-http-B_z10Yky.mjs";
4
4
  import http from "http";
5
5
  //#region src/adapters/standalone.ts
6
6
  /**
@@ -1,5 +1,5 @@
1
1
  Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
2
- const require_ws = require("../ws-BMSSVFiW.cjs");
2
+ const require_ws = require("../ws-BgBeYgGS.cjs");
3
3
  exports.applyWSSHandler = require_ws.applyWSSHandler;
4
4
  exports.getWSConnectionHandler = require_ws.getWSConnectionHandler;
5
5
  exports.handleKeepAlive = require_ws.handleKeepAlive;
@@ -1,5 +1,5 @@
1
- import { J as AnyRouter, ft as inferRouterContext, gn as BaseHandlerOptions, ii as MaybePromise, yt as CreateContextCallback } from "../unstable-core-do-not-import-B9ZnrQAU.cjs";
2
- import { o as NodeHTTPCreateContextFnOptions } from "../index-BHatz_Pu.cjs";
1
+ import { $n as inferRouterContext, En as BaseHandlerOptions, Fn as AnyRouter, hi as MaybePromise, or as CreateContextCallback } from "../unstable-core-do-not-import-Jynlfuqc.cjs";
2
+ import { o as NodeHTTPCreateContextFnOptions } from "../index-BzKrDvzg.cjs";
3
3
  import { IncomingMessage } from "http";
4
4
  import ws from "ws";
5
5
  //#region src/adapters/wsEncoder.d.ts
@@ -1,5 +1,5 @@
1
- import { J as AnyRouter, ft as inferRouterContext, gn as BaseHandlerOptions, ii as MaybePromise, yt as CreateContextCallback } from "../unstable-core-do-not-import-BK_OKrtM.mjs";
2
- import { o as NodeHTTPCreateContextFnOptions } from "../index-_jAhoJQ7.mjs";
1
+ import { $n as inferRouterContext, En as BaseHandlerOptions, Fn as AnyRouter, hi as MaybePromise, or as CreateContextCallback } from "../unstable-core-do-not-import-JE3NCpqt.mjs";
2
+ import { o as NodeHTTPCreateContextFnOptions } from "../index-BDZDS1SD.mjs";
3
3
  import { IncomingMessage } from "http";
4
4
  import ws from "ws";
5
5
  //#region src/adapters/wsEncoder.d.ts
@@ -1,2 +1,2 @@
1
- import { i as jsonEncoder, n as getWSConnectionHandler, r as handleKeepAlive, t as applyWSSHandler } from "../ws-C7ZOJJeA.mjs";
1
+ import { i as jsonEncoder, n as getWSConnectionHandler, r as handleKeepAlive, t as applyWSSHandler } from "../ws-CNjkWAs9.mjs";
2
2
  export { applyWSSHandler, getWSConnectionHandler, handleKeepAlive, jsonEncoder };