@orpc/openapi 0.0.0-next.fd13879 → 0.0.0-next.fd6982a

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.
@@ -0,0 +1,17 @@
1
+ import { Context, Router } from '@orpc/server';
2
+ import { AwsLambdaHandler, AwsLambdaHandlerOptions } from '@orpc/server/aws-lambda';
3
+ import { S as StandardOpenAPIHandlerOptions } from '../../shared/openapi.D3j94c9n.mjs';
4
+ import '@orpc/openapi-client/standard';
5
+ import '@orpc/server/standard';
6
+
7
+ /**
8
+ * OpenAPI Handler for AWS Lambda.
9
+ *
10
+ * @see {@link https://orpc.unnoq.com/docs/openapi/openapi-handler OpenAPI Handler Docs}
11
+ * @see {@link https://orpc.unnoq.com/docs/adapters/http HTTP Adapter Docs}
12
+ */
13
+ declare class experimental_OpenAPIHandler<T extends Context> extends AwsLambdaHandler<T> {
14
+ constructor(router: Router<any, T>, options?: NoInfer<StandardOpenAPIHandlerOptions<T> & AwsLambdaHandlerOptions>);
15
+ }
16
+
17
+ export { experimental_OpenAPIHandler };
@@ -0,0 +1,17 @@
1
+ import { Context, Router } from '@orpc/server';
2
+ import { AwsLambdaHandler, AwsLambdaHandlerOptions } from '@orpc/server/aws-lambda';
3
+ import { S as StandardOpenAPIHandlerOptions } from '../../shared/openapi.D3j94c9n.js';
4
+ import '@orpc/openapi-client/standard';
5
+ import '@orpc/server/standard';
6
+
7
+ /**
8
+ * OpenAPI Handler for AWS Lambda.
9
+ *
10
+ * @see {@link https://orpc.unnoq.com/docs/openapi/openapi-handler OpenAPI Handler Docs}
11
+ * @see {@link https://orpc.unnoq.com/docs/adapters/http HTTP Adapter Docs}
12
+ */
13
+ declare class experimental_OpenAPIHandler<T extends Context> extends AwsLambdaHandler<T> {
14
+ constructor(router: Router<any, T>, options?: NoInfer<StandardOpenAPIHandlerOptions<T> & AwsLambdaHandlerOptions>);
15
+ }
16
+
17
+ export { experimental_OpenAPIHandler };
@@ -0,0 +1,18 @@
1
+ import { AwsLambdaHandler } from '@orpc/server/aws-lambda';
2
+ import '@orpc/client';
3
+ import '@orpc/contract';
4
+ import '@orpc/shared';
5
+ import { a as StandardOpenAPIHandler } from '../../shared/openapi.C_UtQ8Us.mjs';
6
+ import '@orpc/client/standard';
7
+ import '@orpc/server';
8
+ import 'rou3';
9
+ import '@orpc/openapi-client/standard';
10
+ import '@orpc/server/standard';
11
+
12
+ class experimental_OpenAPIHandler extends AwsLambdaHandler {
13
+ constructor(router, options = {}) {
14
+ super(new StandardOpenAPIHandler(router, options), options);
15
+ }
16
+ }
17
+
18
+ export { experimental_OpenAPIHandler };
@@ -1,6 +1,6 @@
1
1
  import { Context, HTTPPath, Router } from '@orpc/server';
2
2
  import { StandardHandlerInterceptorOptions, StandardHandlerPlugin, StandardHandlerOptions } from '@orpc/server/standard';
3
- import { Value } from '@orpc/shared';
3
+ import { Value, Promisable } from '@orpc/shared';
4
4
  import { OpenAPIV3_1 } from 'openapi-types';
5
5
  import { O as OpenAPIGeneratorOptions, a as OpenAPIGeneratorGenerateOptions } from '../shared/openapi.CwdCLgSU.mjs';
6
6
  import '@orpc/contract';
@@ -12,7 +12,7 @@ interface OpenAPIReferencePluginOptions<T extends Context> extends OpenAPIGenera
12
12
  * Options to pass to the OpenAPI generate.
13
13
  *
14
14
  */
15
- specGenerateOptions?: Value<OpenAPIGeneratorGenerateOptions, [StandardHandlerInterceptorOptions<T>]>;
15
+ specGenerateOptions?: Value<Promisable<OpenAPIGeneratorGenerateOptions>, [StandardHandlerInterceptorOptions<T>]>;
16
16
  /**
17
17
  * The URL path at which to serve the OpenAPI JSON.
18
18
  *
@@ -30,23 +30,23 @@ interface OpenAPIReferencePluginOptions<T extends Context> extends OpenAPIGenera
30
30
  *
31
31
  * @default 'API Reference'
32
32
  */
33
- docsTitle?: Value<string, [StandardHandlerInterceptorOptions<T>]>;
33
+ docsTitle?: Value<Promisable<string>, [StandardHandlerInterceptorOptions<T>]>;
34
34
  /**
35
35
  * Arbitrary configuration object for the UI.
36
36
  */
37
- docsConfig?: Value<Record<string, unknown>, [StandardHandlerInterceptorOptions<T>]>;
37
+ docsConfig?: Value<Promisable<Record<string, unknown>>, [StandardHandlerInterceptorOptions<T>]>;
38
38
  /**
39
39
  * HTML to inject into the <head> of the docs page.
40
40
  *
41
41
  * @default ''
42
42
  */
43
- docsHead?: Value<string, [StandardHandlerInterceptorOptions<T>]>;
43
+ docsHead?: Value<Promisable<string>, [StandardHandlerInterceptorOptions<T>]>;
44
44
  /**
45
45
  * URL of the external script bundle for the reference UI.
46
46
  *
47
47
  * @default 'https://cdn.jsdelivr.net/npm/@scalar/api-reference'
48
48
  */
49
- docsScriptUrl?: Value<string, [StandardHandlerInterceptorOptions<T>]>;
49
+ docsScriptUrl?: Value<Promisable<string>, [StandardHandlerInterceptorOptions<T>]>;
50
50
  /**
51
51
  * Override function to generate the full HTML for the docs page.
52
52
  */
@@ -1,6 +1,6 @@
1
1
  import { Context, HTTPPath, Router } from '@orpc/server';
2
2
  import { StandardHandlerInterceptorOptions, StandardHandlerPlugin, StandardHandlerOptions } from '@orpc/server/standard';
3
- import { Value } from '@orpc/shared';
3
+ import { Value, Promisable } from '@orpc/shared';
4
4
  import { OpenAPIV3_1 } from 'openapi-types';
5
5
  import { O as OpenAPIGeneratorOptions, a as OpenAPIGeneratorGenerateOptions } from '../shared/openapi.CwdCLgSU.js';
6
6
  import '@orpc/contract';
@@ -12,7 +12,7 @@ interface OpenAPIReferencePluginOptions<T extends Context> extends OpenAPIGenera
12
12
  * Options to pass to the OpenAPI generate.
13
13
  *
14
14
  */
15
- specGenerateOptions?: Value<OpenAPIGeneratorGenerateOptions, [StandardHandlerInterceptorOptions<T>]>;
15
+ specGenerateOptions?: Value<Promisable<OpenAPIGeneratorGenerateOptions>, [StandardHandlerInterceptorOptions<T>]>;
16
16
  /**
17
17
  * The URL path at which to serve the OpenAPI JSON.
18
18
  *
@@ -30,23 +30,23 @@ interface OpenAPIReferencePluginOptions<T extends Context> extends OpenAPIGenera
30
30
  *
31
31
  * @default 'API Reference'
32
32
  */
33
- docsTitle?: Value<string, [StandardHandlerInterceptorOptions<T>]>;
33
+ docsTitle?: Value<Promisable<string>, [StandardHandlerInterceptorOptions<T>]>;
34
34
  /**
35
35
  * Arbitrary configuration object for the UI.
36
36
  */
37
- docsConfig?: Value<Record<string, unknown>, [StandardHandlerInterceptorOptions<T>]>;
37
+ docsConfig?: Value<Promisable<Record<string, unknown>>, [StandardHandlerInterceptorOptions<T>]>;
38
38
  /**
39
39
  * HTML to inject into the <head> of the docs page.
40
40
  *
41
41
  * @default ''
42
42
  */
43
- docsHead?: Value<string, [StandardHandlerInterceptorOptions<T>]>;
43
+ docsHead?: Value<Promisable<string>, [StandardHandlerInterceptorOptions<T>]>;
44
44
  /**
45
45
  * URL of the external script bundle for the reference UI.
46
46
  *
47
47
  * @default 'https://cdn.jsdelivr.net/npm/@scalar/api-reference'
48
48
  */
49
- docsScriptUrl?: Value<string, [StandardHandlerInterceptorOptions<T>]>;
49
+ docsScriptUrl?: Value<Promisable<string>, [StandardHandlerInterceptorOptions<T>]>;
50
50
  /**
51
51
  * Override function to generate the full HTML for the docs page.
52
52
  */
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@orpc/openapi",
3
3
  "type": "module",
4
- "version": "0.0.0-next.fd13879",
4
+ "version": "0.0.0-next.fd6982a",
5
5
  "license": "MIT",
6
6
  "homepage": "https://orpc.unnoq.com",
7
7
  "repository": {
@@ -38,6 +38,11 @@
38
38
  "types": "./dist/adapters/node/index.d.mts",
39
39
  "import": "./dist/adapters/node/index.mjs",
40
40
  "default": "./dist/adapters/node/index.mjs"
41
+ },
42
+ "./aws-lambda": {
43
+ "types": "./dist/adapters/aws-lambda/index.d.mts",
44
+ "import": "./dist/adapters/aws-lambda/index.mjs",
45
+ "default": "./dist/adapters/aws-lambda/index.mjs"
41
46
  }
42
47
  },
43
48
  "files": [
@@ -47,15 +52,15 @@
47
52
  "json-schema-typed": "^8.0.1",
48
53
  "openapi-types": "^12.1.3",
49
54
  "rou3": "^0.6.0",
50
- "@orpc/client": "0.0.0-next.fd13879",
51
- "@orpc/openapi-client": "0.0.0-next.fd13879",
52
- "@orpc/server": "0.0.0-next.fd13879",
53
- "@orpc/contract": "0.0.0-next.fd13879",
54
- "@orpc/shared": "0.0.0-next.fd13879",
55
- "@orpc/standard-server": "0.0.0-next.fd13879"
55
+ "@orpc/client": "0.0.0-next.fd6982a",
56
+ "@orpc/openapi-client": "0.0.0-next.fd6982a",
57
+ "@orpc/server": "0.0.0-next.fd6982a",
58
+ "@orpc/standard-server": "0.0.0-next.fd6982a",
59
+ "@orpc/contract": "0.0.0-next.fd6982a",
60
+ "@orpc/shared": "0.0.0-next.fd6982a"
56
61
  },
57
62
  "devDependencies": {
58
- "zod": "3.25.0-beta.20250516T005923"
63
+ "zod": "^3.25.11"
59
64
  },
60
65
  "scripts": {
61
66
  "build": "unbuild",