@geekmidas/constructs 0.0.1
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.
- package/README.md +614 -0
- package/dist/AWSLambdaFunction-CpHFE2m6.d.mts +27 -0
- package/dist/AWSLambdaFunction-CwagvPG3.d.cts +27 -0
- package/dist/AWSLambdaFunction-DWIZYsCy.mjs +79 -0
- package/dist/AWSLambdaFunction-DWIZYsCy.mjs.map +1 -0
- package/dist/AWSLambdaFunction-qA5LqPsv.cjs +85 -0
- package/dist/AWSLambdaFunction-qA5LqPsv.cjs.map +1 -0
- package/dist/AWSLambdaSubscriberAdaptor-C1wQuucQ.d.mts +32 -0
- package/dist/AWSLambdaSubscriberAdaptor-CmPZ10JF.cjs +138 -0
- package/dist/AWSLambdaSubscriberAdaptor-CmPZ10JF.cjs.map +1 -0
- package/dist/AWSLambdaSubscriberAdaptor-G8y3YkWj.mjs +132 -0
- package/dist/AWSLambdaSubscriberAdaptor-G8y3YkWj.mjs.map +1 -0
- package/dist/AWSLambdaSubscriberAdaptor-QKVxR6qh.d.cts +32 -0
- package/dist/AmazonApiGatewayEndpointAdaptor-BoBh7vvD.d.mts +61 -0
- package/dist/AmazonApiGatewayEndpointAdaptor-Cx1oqcqh.mjs +124 -0
- package/dist/AmazonApiGatewayEndpointAdaptor-Cx1oqcqh.mjs.map +1 -0
- package/dist/AmazonApiGatewayEndpointAdaptor-DtzgQ9Vb.d.cts +61 -0
- package/dist/AmazonApiGatewayEndpointAdaptor-i74DEUbc.cjs +130 -0
- package/dist/AmazonApiGatewayEndpointAdaptor-i74DEUbc.cjs.map +1 -0
- package/dist/AmazonApiGatewayV1EndpointAdaptor-CLmBDYsl.mjs +42 -0
- package/dist/AmazonApiGatewayV1EndpointAdaptor-CLmBDYsl.mjs.map +1 -0
- package/dist/AmazonApiGatewayV1EndpointAdaptor-EhMd1YqV.d.mts +21 -0
- package/dist/AmazonApiGatewayV1EndpointAdaptor-GkMAUPL5.cjs +47 -0
- package/dist/AmazonApiGatewayV1EndpointAdaptor-GkMAUPL5.cjs.map +1 -0
- package/dist/AmazonApiGatewayV1EndpointAdaptor-Gw-j61qM.d.cts +21 -0
- package/dist/AmazonApiGatewayV2EndpointAdaptor-3RqegmJC.mjs +41 -0
- package/dist/AmazonApiGatewayV2EndpointAdaptor-3RqegmJC.mjs.map +1 -0
- package/dist/AmazonApiGatewayV2EndpointAdaptor-LUlpwmUW.d.cts +21 -0
- package/dist/AmazonApiGatewayV2EndpointAdaptor-YlFoFSS9.cjs +46 -0
- package/dist/AmazonApiGatewayV2EndpointAdaptor-YlFoFSS9.cjs.map +1 -0
- package/dist/AmazonApiGatewayV2EndpointAdaptor-zfd1gqXA.d.mts +21 -0
- package/dist/BaseFunctionBuilder-5QCHkchp.d.cts +31 -0
- package/dist/BaseFunctionBuilder-BFPVGnKi.d.mts +31 -0
- package/dist/BaseFunctionBuilder-BPE9JBbT.mjs +56 -0
- package/dist/BaseFunctionBuilder-BPE9JBbT.mjs.map +1 -0
- package/dist/BaseFunctionBuilder-DtO4Nwxm.cjs +62 -0
- package/dist/BaseFunctionBuilder-DtO4Nwxm.cjs.map +1 -0
- package/dist/Construct-BSEs6uwW.cjs +75 -0
- package/dist/Construct-BSEs6uwW.cjs.map +1 -0
- package/dist/Construct-BbKCIPQm.mjs +63 -0
- package/dist/Construct-BbKCIPQm.mjs.map +1 -0
- package/dist/Construct-Bm-PSO2V.d.cts +42 -0
- package/dist/Construct-DIguIyw4.d.mts +42 -0
- package/dist/Construct.cjs +4 -0
- package/dist/Construct.d.cts +2 -0
- package/dist/Construct.d.mts +2 -0
- package/dist/Construct.mjs +3 -0
- package/dist/Cron-Bgs6EQOb.mjs +20 -0
- package/dist/Cron-Bgs6EQOb.mjs.map +1 -0
- package/dist/Cron-DQiCj3ef.cjs +25 -0
- package/dist/Cron-DQiCj3ef.cjs.map +1 -0
- package/dist/Cron-FpAw03k6.d.mts +25 -0
- package/dist/Cron-ztnK6zgU.d.cts +25 -0
- package/dist/CronBuilder-B2clNQSP.d.mts +24 -0
- package/dist/CronBuilder-Cje9K8lZ.d.cts +24 -0
- package/dist/CronBuilder-DIBqJkh_.cjs +60 -0
- package/dist/CronBuilder-DIBqJkh_.cjs.map +1 -0
- package/dist/CronBuilder-DecAvvcn.mjs +54 -0
- package/dist/CronBuilder-DecAvvcn.mjs.map +1 -0
- package/dist/Endpoint-BaHC9y4Z.cjs +291 -0
- package/dist/Endpoint-BaHC9y4Z.cjs.map +1 -0
- package/dist/Endpoint-C7z9YJHK.d.cts +405 -0
- package/dist/Endpoint-DCn53Vd8.d.mts +405 -0
- package/dist/Endpoint-ierdM62O.mjs +279 -0
- package/dist/Endpoint-ierdM62O.mjs.map +1 -0
- package/dist/EndpointBuilder-BHFSpbPR.cjs +107 -0
- package/dist/EndpointBuilder-BHFSpbPR.cjs.map +1 -0
- package/dist/EndpointBuilder-BLUsoK3l.mjs +101 -0
- package/dist/EndpointBuilder-BLUsoK3l.mjs.map +1 -0
- package/dist/EndpointBuilder-Bfnb2oJr.d.mts +49 -0
- package/dist/EndpointBuilder-CP9RGwZH.d.cts +49 -0
- package/dist/EndpointFactory-BYdDVCNj.mjs +127 -0
- package/dist/EndpointFactory-BYdDVCNj.mjs.map +1 -0
- package/dist/EndpointFactory-CNtMXgIh.d.mts +52 -0
- package/dist/EndpointFactory-CXX4E6Gx.cjs +139 -0
- package/dist/EndpointFactory-CXX4E6Gx.cjs.map +1 -0
- package/dist/EndpointFactory-D2zgWbXZ.d.cts +52 -0
- package/dist/Function-BP58p9Mp.d.cts +59 -0
- package/dist/Function-BsBxc2wA.d.mts +59 -0
- package/dist/Function-C5mW-38v.mjs +72 -0
- package/dist/Function-C5mW-38v.mjs.map +1 -0
- package/dist/Function-CbO2NZx-.cjs +84 -0
- package/dist/Function-CbO2NZx-.cjs.map +1 -0
- package/dist/FunctionBuilder-BS1KgxA_.d.cts +24 -0
- package/dist/FunctionBuilder-C-PfPN3r.d.mts +24 -0
- package/dist/FunctionBuilder-CosgPmMl.mjs +53 -0
- package/dist/FunctionBuilder-CosgPmMl.mjs.map +1 -0
- package/dist/FunctionBuilder-DuOeWCAl.cjs +59 -0
- package/dist/FunctionBuilder-DuOeWCAl.cjs.map +1 -0
- package/dist/FunctionExecutionWrapper-Bx-Dl-2a.d.cts +24 -0
- package/dist/FunctionExecutionWrapper-CElXEjPe.cjs +42 -0
- package/dist/FunctionExecutionWrapper-CElXEjPe.cjs.map +1 -0
- package/dist/FunctionExecutionWrapper-DvglBBjE.d.mts +24 -0
- package/dist/FunctionExecutionWrapper-XGrSAAPD.mjs +36 -0
- package/dist/FunctionExecutionWrapper-XGrSAAPD.mjs.map +1 -0
- package/dist/HonoEndpointAdaptor-B0IO1zj2.d.mts +41 -0
- package/dist/HonoEndpointAdaptor-B4snrp7v.cjs +154 -0
- package/dist/HonoEndpointAdaptor-B4snrp7v.cjs.map +1 -0
- package/dist/HonoEndpointAdaptor-B6lW9Q1k.d.cts +41 -0
- package/dist/HonoEndpointAdaptor-D-M4-6Tf.mjs +148 -0
- package/dist/HonoEndpointAdaptor-D-M4-6Tf.mjs.map +1 -0
- package/dist/Subscriber-BoFm12i_.d.cts +33 -0
- package/dist/Subscriber-BwuCaC9G.mjs +28 -0
- package/dist/Subscriber-BwuCaC9G.mjs.map +1 -0
- package/dist/Subscriber-THGsj7Iy.d.mts +33 -0
- package/dist/Subscriber-iMRFG7ba.cjs +34 -0
- package/dist/Subscriber-iMRFG7ba.cjs.map +1 -0
- package/dist/SubscriberBuilder-CiPxgnKT.d.mts +26 -0
- package/dist/SubscriberBuilder-Dhz0C_t-.mjs +54 -0
- package/dist/SubscriberBuilder-Dhz0C_t-.mjs.map +1 -0
- package/dist/SubscriberBuilder-DuIgxuzc.d.cts +26 -0
- package/dist/SubscriberBuilder-wthr-FL9.cjs +60 -0
- package/dist/SubscriberBuilder-wthr-FL9.cjs.map +1 -0
- package/dist/adaptors/aws.cjs +19 -0
- package/dist/adaptors/aws.d.cts +15 -0
- package/dist/adaptors/aws.d.mts +15 -0
- package/dist/adaptors/aws.mjs +16 -0
- package/dist/adaptors/hono.cjs +12 -0
- package/dist/adaptors/hono.d.cts +9 -0
- package/dist/adaptors/hono.d.mts +9 -0
- package/dist/adaptors/hono.mjs +12 -0
- package/dist/chunk-CUT6urMc.cjs +30 -0
- package/dist/crons/Cron.cjs +8 -0
- package/dist/crons/Cron.d.cts +7 -0
- package/dist/crons/Cron.d.mts +7 -0
- package/dist/crons/Cron.mjs +8 -0
- package/dist/crons/CronBuilder.cjs +9 -0
- package/dist/crons/CronBuilder.d.cts +8 -0
- package/dist/crons/CronBuilder.d.mts +8 -0
- package/dist/crons/CronBuilder.mjs +9 -0
- package/dist/crons/index.cjs +16 -0
- package/dist/crons/index.cjs.map +1 -0
- package/dist/crons/index.d.cts +16 -0
- package/dist/crons/index.d.mts +16 -0
- package/dist/crons/index.mjs +14 -0
- package/dist/crons/index.mjs.map +1 -0
- package/dist/endpoints/AmazonApiGatewayEndpointAdaptor.cjs +10 -0
- package/dist/endpoints/AmazonApiGatewayEndpointAdaptor.d.cts +9 -0
- package/dist/endpoints/AmazonApiGatewayEndpointAdaptor.d.mts +9 -0
- package/dist/endpoints/AmazonApiGatewayEndpointAdaptor.mjs +10 -0
- package/dist/endpoints/AmazonApiGatewayV1EndpointAdaptor.cjs +12 -0
- package/dist/endpoints/AmazonApiGatewayV1EndpointAdaptor.d.cts +10 -0
- package/dist/endpoints/AmazonApiGatewayV1EndpointAdaptor.d.mts +10 -0
- package/dist/endpoints/AmazonApiGatewayV1EndpointAdaptor.mjs +12 -0
- package/dist/endpoints/AmazonApiGatewayV2EndpointAdaptor.cjs +12 -0
- package/dist/endpoints/AmazonApiGatewayV2EndpointAdaptor.d.cts +10 -0
- package/dist/endpoints/AmazonApiGatewayV2EndpointAdaptor.d.mts +10 -0
- package/dist/endpoints/AmazonApiGatewayV2EndpointAdaptor.mjs +12 -0
- package/dist/endpoints/Endpoint.cjs +9 -0
- package/dist/endpoints/Endpoint.d.cts +8 -0
- package/dist/endpoints/Endpoint.d.mts +8 -0
- package/dist/endpoints/Endpoint.mjs +8 -0
- package/dist/endpoints/EndpointBuilder.cjs +9 -0
- package/dist/endpoints/EndpointBuilder.d.cts +9 -0
- package/dist/endpoints/EndpointBuilder.d.mts +9 -0
- package/dist/endpoints/EndpointBuilder.mjs +9 -0
- package/dist/endpoints/EndpointFactory.cjs +11 -0
- package/dist/endpoints/EndpointFactory.d.cts +10 -0
- package/dist/endpoints/EndpointFactory.d.mts +10 -0
- package/dist/endpoints/EndpointFactory.mjs +10 -0
- package/dist/endpoints/HonoEndpointAdaptor.cjs +12 -0
- package/dist/endpoints/HonoEndpointAdaptor.d.cts +9 -0
- package/dist/endpoints/HonoEndpointAdaptor.d.mts +9 -0
- package/dist/endpoints/HonoEndpointAdaptor.mjs +12 -0
- package/dist/endpoints/TestEndpointAdaptor.cjs +54 -0
- package/dist/endpoints/TestEndpointAdaptor.cjs.map +1 -0
- package/dist/endpoints/TestEndpointAdaptor.d.cts +29 -0
- package/dist/endpoints/TestEndpointAdaptor.d.mts +29 -0
- package/dist/endpoints/TestEndpointAdaptor.mjs +53 -0
- package/dist/endpoints/TestEndpointAdaptor.mjs.map +1 -0
- package/dist/endpoints/helpers.cjs +10 -0
- package/dist/endpoints/helpers.d.cts +58 -0
- package/dist/endpoints/helpers.d.mts +58 -0
- package/dist/endpoints/helpers.mjs +9 -0
- package/dist/endpoints/index.cjs +16 -0
- package/dist/endpoints/index.cjs.map +1 -0
- package/dist/endpoints/index.d.cts +16 -0
- package/dist/endpoints/index.d.mts +16 -0
- package/dist/endpoints/index.mjs +15 -0
- package/dist/endpoints/index.mjs.map +1 -0
- package/dist/endpoints/parseHonoQuery.cjs +3 -0
- package/dist/endpoints/parseHonoQuery.d.cts +12 -0
- package/dist/endpoints/parseHonoQuery.d.mts +12 -0
- package/dist/endpoints/parseHonoQuery.mjs +3 -0
- package/dist/endpoints/parseQueryParams.cjs +3 -0
- package/dist/endpoints/parseQueryParams.d.cts +13 -0
- package/dist/endpoints/parseQueryParams.d.mts +13 -0
- package/dist/endpoints/parseQueryParams.mjs +3 -0
- package/dist/functions/AWSLambdaFunction.cjs +9 -0
- package/dist/functions/AWSLambdaFunction.d.cts +5 -0
- package/dist/functions/AWSLambdaFunction.d.mts +5 -0
- package/dist/functions/AWSLambdaFunction.mjs +9 -0
- package/dist/functions/BaseFunctionBuilder.cjs +4 -0
- package/dist/functions/BaseFunctionBuilder.d.cts +3 -0
- package/dist/functions/BaseFunctionBuilder.d.mts +3 -0
- package/dist/functions/BaseFunctionBuilder.mjs +4 -0
- package/dist/functions/Function.cjs +5 -0
- package/dist/functions/Function.d.cts +3 -0
- package/dist/functions/Function.d.mts +3 -0
- package/dist/functions/Function.mjs +4 -0
- package/dist/functions/FunctionBuilder.cjs +6 -0
- package/dist/functions/FunctionBuilder.d.cts +5 -0
- package/dist/functions/FunctionBuilder.d.mts +5 -0
- package/dist/functions/FunctionBuilder.mjs +6 -0
- package/dist/functions/FunctionExecutionWrapper.cjs +8 -0
- package/dist/functions/FunctionExecutionWrapper.d.cts +4 -0
- package/dist/functions/FunctionExecutionWrapper.d.mts +4 -0
- package/dist/functions/FunctionExecutionWrapper.mjs +8 -0
- package/dist/functions/TestFunctionAdaptor.cjs +38 -0
- package/dist/functions/TestFunctionAdaptor.cjs.map +1 -0
- package/dist/functions/TestFunctionAdaptor.d.cts +26 -0
- package/dist/functions/TestFunctionAdaptor.d.mts +26 -0
- package/dist/functions/TestFunctionAdaptor.mjs +37 -0
- package/dist/functions/TestFunctionAdaptor.mjs.map +1 -0
- package/dist/functions/index.cjs +10 -0
- package/dist/functions/index.d.cts +6 -0
- package/dist/functions/index.d.mts +6 -0
- package/dist/functions/index.mjs +7 -0
- package/dist/functions-DVDb5wEA.cjs +13 -0
- package/dist/functions-DVDb5wEA.cjs.map +1 -0
- package/dist/functions-mM-jcphA.mjs +8 -0
- package/dist/functions-mM-jcphA.mjs.map +1 -0
- package/dist/helpers-BeGM4pP_.cjs +95 -0
- package/dist/helpers-BeGM4pP_.cjs.map +1 -0
- package/dist/helpers-DbpO95aE.mjs +83 -0
- package/dist/helpers-DbpO95aE.mjs.map +1 -0
- package/dist/index-CuGR4L7O.d.mts +9 -0
- package/dist/index-Fg3N3EKD.d.cts +9 -0
- package/dist/index.cjs +4 -0
- package/dist/index.d.cts +4 -0
- package/dist/index.d.mts +4 -0
- package/dist/index.mjs +3 -0
- package/dist/parseHonoQuery-DopC24vB.cjs +37 -0
- package/dist/parseHonoQuery-DopC24vB.cjs.map +1 -0
- package/dist/parseHonoQuery-znDKBhdE.mjs +31 -0
- package/dist/parseHonoQuery-znDKBhdE.mjs.map +1 -0
- package/dist/parseQueryParams-BJaRh3OB.mjs +32 -0
- package/dist/parseQueryParams-BJaRh3OB.mjs.map +1 -0
- package/dist/parseQueryParams-BzPop4I1.cjs +38 -0
- package/dist/parseQueryParams-BzPop4I1.cjs.map +1 -0
- package/dist/publisher-Bw4770Hi.mjs +41 -0
- package/dist/publisher-Bw4770Hi.mjs.map +1 -0
- package/dist/publisher-lFQleddL.cjs +53 -0
- package/dist/publisher-lFQleddL.cjs.map +1 -0
- package/dist/publisher.cjs +4 -0
- package/dist/publisher.d.cts +13 -0
- package/dist/publisher.d.mts +13 -0
- package/dist/publisher.mjs +3 -0
- package/dist/subscribers/AWSLambdaSubscriberAdaptor.cjs +3 -0
- package/dist/subscribers/AWSLambdaSubscriberAdaptor.d.cts +4 -0
- package/dist/subscribers/AWSLambdaSubscriberAdaptor.d.mts +4 -0
- package/dist/subscribers/AWSLambdaSubscriberAdaptor.mjs +3 -0
- package/dist/subscribers/Subscriber.cjs +4 -0
- package/dist/subscribers/Subscriber.d.cts +3 -0
- package/dist/subscribers/Subscriber.d.mts +3 -0
- package/dist/subscribers/Subscriber.mjs +4 -0
- package/dist/subscribers/SubscriberBuilder.cjs +5 -0
- package/dist/subscribers/SubscriberBuilder.d.cts +4 -0
- package/dist/subscribers/SubscriberBuilder.d.mts +4 -0
- package/dist/subscribers/SubscriberBuilder.mjs +5 -0
- package/dist/subscribers/index.cjs +12 -0
- package/dist/subscribers/index.cjs.map +1 -0
- package/dist/subscribers/index.d.cts +10 -0
- package/dist/subscribers/index.d.mts +10 -0
- package/dist/subscribers/index.mjs +10 -0
- package/dist/subscribers/index.mjs.map +1 -0
- package/dist/types-Bp9ysFXd.d.cts +7 -0
- package/dist/types-DBKNYvsW.d.mts +7 -0
- package/dist/types.cjs +0 -0
- package/dist/types.d.cts +2 -0
- package/dist/types.d.mts +2 -0
- package/dist/types.mjs +0 -0
- package/package.json +91 -0
- package/src/Construct.ts +98 -0
- package/src/__tests__/Construct.environment.spec.ts +360 -0
- package/src/__tests__/publisher.setting.spec.ts +511 -0
- package/src/__tests__/publisher.spec.ts +454 -0
- package/src/adaptors/aws.ts +4 -0
- package/src/adaptors/hono.ts +1 -0
- package/src/crons/Cron.ts +137 -0
- package/src/crons/CronBuilder.ts +192 -0
- package/src/crons/__tests__/Cron.spec.ts +464 -0
- package/src/crons/index.ts +11 -0
- package/src/endpoints/AmazonApiGatewayEndpointAdaptor.ts +315 -0
- package/src/endpoints/AmazonApiGatewayV1EndpointAdaptor.ts +101 -0
- package/src/endpoints/AmazonApiGatewayV2EndpointAdaptor.ts +95 -0
- package/src/endpoints/Endpoint.ts +771 -0
- package/src/endpoints/EndpointBuilder.ts +308 -0
- package/src/endpoints/EndpointFactory.ts +329 -0
- package/src/endpoints/HonoEndpointAdaptor.ts +365 -0
- package/src/endpoints/TestEndpointAdaptor.ts +130 -0
- package/src/endpoints/__tests__/AmazonApiGatewayV1EndpointAdaptor.events.spec.ts +553 -0
- package/src/endpoints/__tests__/AmazonApiGatewayV1EndpointAdaptor.spec.ts +927 -0
- package/src/endpoints/__tests__/AmazonApiGatewayV2EndpointAdaptor.events.spec.ts +721 -0
- package/src/endpoints/__tests__/AmazonApiGatewayV2EndpointAdaptor.factory-publisher.spec.ts +296 -0
- package/src/endpoints/__tests__/AmazonApiGatewayV2EndpointAdaptor.spec.ts +441 -0
- package/src/endpoints/__tests__/Endpoint.spec.ts +800 -0
- package/src/endpoints/__tests__/EndpointBuilder.spec.ts +488 -0
- package/src/endpoints/__tests__/EndpointFactory.spec.ts +479 -0
- package/src/endpoints/__tests__/HonoEndpointAdaptor.events.spec.ts +569 -0
- package/src/endpoints/__tests__/HonoEndpointAdaptor.openapi.spec.ts +313 -0
- package/src/endpoints/__tests__/HonoEndpointAdaptor.spec.ts +1078 -0
- package/src/endpoints/__tests__/TestEndpointAdaptor.spec.ts +236 -0
- package/src/endpoints/__tests__/__snapshots__/HonoEndpointAdaptor.spec.ts.snap +54 -0
- package/src/endpoints/__tests__/endpoint-types.test.ts +88 -0
- package/src/endpoints/helpers.ts +99 -0
- package/src/endpoints/index.ts +5 -0
- package/src/endpoints/parseHonoQuery.ts +51 -0
- package/src/endpoints/parseQueryParams.ts +51 -0
- package/src/functions/AWSLambdaFunction.ts +222 -0
- package/src/functions/BaseFunctionBuilder.ts +110 -0
- package/src/functions/Function.ts +160 -0
- package/src/functions/FunctionBuilder.ts +182 -0
- package/src/functions/FunctionExecutionWrapper.ts +86 -0
- package/src/functions/TestFunctionAdaptor.ts +125 -0
- package/src/functions/__tests__/AWSLambdaFunctionAdaptor.spec.ts +376 -0
- package/src/functions/__tests__/Function.spec.ts +402 -0
- package/src/functions/__tests__/TestFunctionAdaptor.spec.ts +398 -0
- package/src/functions/index.ts +10 -0
- package/src/index.ts +14 -0
- package/src/publisher.ts +83 -0
- package/src/subscribers/AWSLambdaSubscriberAdaptor.ts +269 -0
- package/src/subscribers/Subscriber.ts +112 -0
- package/src/subscribers/SubscriberBuilder.ts +150 -0
- package/src/subscribers/__tests__/AWSLambdaSubscriberAdaptor.spec.ts +623 -0
- package/src/subscribers/__tests__/Subscriber.spec.ts +432 -0
- package/src/subscribers/index.ts +5 -0
- package/src/types.ts +13 -0
- package/tsdown.config.ts +3 -0
|
@@ -0,0 +1,405 @@
|
|
|
1
|
+
import { HttpMethod, LowerHttpMethod, RemoveUndefined } from "./types-Bp9ysFXd.cjs";
|
|
2
|
+
import { Function, FunctionHandler } from "./Function-BP58p9Mp.cjs";
|
|
3
|
+
import { EventPublisher, ExtractPublisherMessage, MappedEvent } from "@geekmidas/events";
|
|
4
|
+
import { Logger } from "@geekmidas/logger";
|
|
5
|
+
import { Service, ServiceRecord } from "@geekmidas/services";
|
|
6
|
+
import { StandardSchemaV1 } from "@standard-schema/spec";
|
|
7
|
+
import { OpenAPIV3_1 } from "openapi-types";
|
|
8
|
+
import { InferComposableStandardSchema, InferStandardSchema } from "@geekmidas/schema";
|
|
9
|
+
import { RateLimitConfig } from "@geekmidas/rate-limit";
|
|
10
|
+
import { ComponentCollector, OpenApiSchemaOptions } from "@geekmidas/schema/openapi";
|
|
11
|
+
|
|
12
|
+
//#region src/endpoints/Endpoint.d.ts
|
|
13
|
+
|
|
14
|
+
/**
|
|
15
|
+
* Represents an HTTP endpoint that can handle requests with type-safe input/output validation,
|
|
16
|
+
* dependency injection, session management, and authorization.
|
|
17
|
+
*
|
|
18
|
+
* @template TRoute - The route path string with parameter placeholders (e.g., '/users/:id')
|
|
19
|
+
* @template TMethod - The HTTP method (GET, POST, PUT, DELETE, PATCH)
|
|
20
|
+
* @template TInput - The input schema definition for body, query, and path parameters
|
|
21
|
+
* @template OutSchema - The output schema for response validation
|
|
22
|
+
* @template TServices - Array of service dependencies to inject
|
|
23
|
+
* @template TLogger - The logger instance type
|
|
24
|
+
* @template TSession - The session data type
|
|
25
|
+
*
|
|
26
|
+
* @extends Function - Base function construct for handler execution
|
|
27
|
+
*
|
|
28
|
+
* @example
|
|
29
|
+
* ```typescript
|
|
30
|
+
* const endpoint = new Endpoint({
|
|
31
|
+
* route: '/users/:id',
|
|
32
|
+
* method: 'GET',
|
|
33
|
+
* input: { params: userIdSchema },
|
|
34
|
+
* output: userSchema,
|
|
35
|
+
* fn: async ({ params }) => getUserById(params.id)
|
|
36
|
+
* });
|
|
37
|
+
* ```
|
|
38
|
+
*/
|
|
39
|
+
declare class Endpoint<TRoute extends string, TMethod extends HttpMethod, TInput extends EndpointSchemas = {}, OutSchema extends StandardSchemaV1 | undefined = undefined, TServices extends Service[] = [], TLogger extends Logger = Logger, TSession = unknown, TEventPublisher extends EventPublisher<any> | undefined = undefined, TEventPublisherServiceName extends string = string> extends Function<TInput, TServices, TLogger, OutSchema, FunctionHandler<TInput, TServices, TLogger, OutSchema>, TEventPublisher, TEventPublisherServiceName> {
|
|
40
|
+
operationId?: string;
|
|
41
|
+
/** The route path pattern with parameter placeholders */
|
|
42
|
+
route: TRoute;
|
|
43
|
+
/** The HTTP method for this endpoint */
|
|
44
|
+
method: TMethod;
|
|
45
|
+
/** Optional description for OpenAPI documentation */
|
|
46
|
+
description?: string;
|
|
47
|
+
/** Optional tags for OpenAPI documentation */
|
|
48
|
+
tags?: string[];
|
|
49
|
+
/** The HTTP success status code to return (default: 200) */
|
|
50
|
+
readonly status: SuccessStatus;
|
|
51
|
+
/** Function to extract session data from the request context */
|
|
52
|
+
getSession: SessionFn<TServices, TLogger, TSession>;
|
|
53
|
+
/** Function to determine if the request is authorized */
|
|
54
|
+
authorize: AuthorizeFn<TServices, TLogger, TSession>;
|
|
55
|
+
/** Optional rate limiting configuration */
|
|
56
|
+
rateLimit?: RateLimitConfig;
|
|
57
|
+
/**
|
|
58
|
+
* Builds a complete OpenAPI 3.1 schema from an array of endpoints.
|
|
59
|
+
*
|
|
60
|
+
* @param endpoints - Array of endpoint instances to document
|
|
61
|
+
* @param options - Optional configuration for OpenAPI generation
|
|
62
|
+
* @returns OpenAPI 3.1 specification object
|
|
63
|
+
*
|
|
64
|
+
* @example
|
|
65
|
+
* ```typescript
|
|
66
|
+
* const schema = await Endpoint.buildOpenApiSchema([
|
|
67
|
+
* getUserEndpoint,
|
|
68
|
+
* createUserEndpoint
|
|
69
|
+
* ], {
|
|
70
|
+
* title: 'User API',
|
|
71
|
+
* version: '1.0.0'
|
|
72
|
+
* });
|
|
73
|
+
* ```
|
|
74
|
+
*/
|
|
75
|
+
static buildOpenApiSchema(endpoints: Endpoint<any, any, any, any, any, any>[], options?: OpenApiSchemaOptions): Promise<OpenAPIV3_1.Document<{}>>;
|
|
76
|
+
/**
|
|
77
|
+
* Gets the full path including HTTP method and route.
|
|
78
|
+
* @returns Formatted string like 'GET /users/{id}'
|
|
79
|
+
*/
|
|
80
|
+
get fullPath(): `${TMethod} ${ConvertRouteParams<TRoute>}`;
|
|
81
|
+
/**
|
|
82
|
+
* Parses and validates input data for a specific input type (body, query, params).
|
|
83
|
+
*
|
|
84
|
+
* @param input - The raw input data to validate
|
|
85
|
+
* @param key - The input type key ('body', 'query', or 'params')
|
|
86
|
+
* @returns The validated input data for the specified key
|
|
87
|
+
* @throws {UnprocessableEntityError} When validation fails
|
|
88
|
+
*/
|
|
89
|
+
parseInput<K extends keyof TInput>(input: unknown, key: K): Promise<InferComposableStandardSchema<TInput[K]>>;
|
|
90
|
+
/**
|
|
91
|
+
* Parses and validates the request body against the body schema.
|
|
92
|
+
*
|
|
93
|
+
* @param body - The raw request body to validate
|
|
94
|
+
* @returns The validated body data
|
|
95
|
+
* @throws {UnprocessableEntityError} When body validation fails
|
|
96
|
+
*/
|
|
97
|
+
parseBody(body: unknown): Promise<InferStandardSchema<TInput['body']>>;
|
|
98
|
+
static isSuccessStatus(status: number): boolean;
|
|
99
|
+
/**
|
|
100
|
+
* Creates a case-insensitive header lookup function from a headers object.
|
|
101
|
+
*
|
|
102
|
+
* @param headers - Object containing header key-value pairs
|
|
103
|
+
* @returns Function to retrieve header values by case-insensitive key
|
|
104
|
+
*
|
|
105
|
+
* @example
|
|
106
|
+
* ```typescript
|
|
107
|
+
* const headerFn = Endpoint.createHeaders({ 'Content-Type': 'application/json' });
|
|
108
|
+
* headerFn('content-type'); // Returns 'application/json'
|
|
109
|
+
* ```
|
|
110
|
+
*/
|
|
111
|
+
static createHeaders(headers: Record<string, string>): HeaderFn;
|
|
112
|
+
/**
|
|
113
|
+
* Extracts and refines input data from the endpoint context.
|
|
114
|
+
*
|
|
115
|
+
* @param ctx - The endpoint execution context
|
|
116
|
+
* @returns Object containing only the input data (body, query, params)
|
|
117
|
+
* @internal
|
|
118
|
+
*/
|
|
119
|
+
refineInput(ctx: EndpointContext<TInput, TServices, TLogger, TSession>): InferComposableStandardSchema<TInput>;
|
|
120
|
+
handler: EndpointHandler<TInput, TServices, TLogger, OutSchema, TSession>;
|
|
121
|
+
/**
|
|
122
|
+
* Type guard to check if an object is an Endpoint instance.
|
|
123
|
+
*
|
|
124
|
+
* @param obj - The object to check
|
|
125
|
+
* @returns True if the object is an Endpoint
|
|
126
|
+
*/
|
|
127
|
+
static isEndpoint(obj: any): obj is Endpoint<any, any, any, any>;
|
|
128
|
+
/**
|
|
129
|
+
* Converts Express-style route params to OpenAPI format.
|
|
130
|
+
* @returns Route with ':param' converted to '{param}'
|
|
131
|
+
* @internal
|
|
132
|
+
*/
|
|
133
|
+
get _path(): ConvertRouteParams<TRoute>;
|
|
134
|
+
/**
|
|
135
|
+
* Generates OpenAPI 3.1 schema for this endpoint.
|
|
136
|
+
*
|
|
137
|
+
* @returns OpenAPI route definition with operation details
|
|
138
|
+
*/
|
|
139
|
+
toOpenApi3Route(componentCollector?: ComponentCollector): Promise<EndpointOpenApiSchema<TRoute, TMethod>>;
|
|
140
|
+
/**
|
|
141
|
+
* Creates a new Endpoint instance.
|
|
142
|
+
*
|
|
143
|
+
* @param options - Configuration options for the endpoint
|
|
144
|
+
* @param options.fn - The handler function to execute
|
|
145
|
+
* @param options.method - HTTP method
|
|
146
|
+
* @param options.route - Route path with parameter placeholders
|
|
147
|
+
* @param options.description - Optional description for documentation
|
|
148
|
+
* @param options.input - Input schemas for validation
|
|
149
|
+
* @param options.logger - Logger instance
|
|
150
|
+
* @param options.output - Output schema for response validation
|
|
151
|
+
* @param options.services - Service dependencies
|
|
152
|
+
* @param options.timeout - Execution timeout in milliseconds
|
|
153
|
+
* @param options.getSession - Session extraction function
|
|
154
|
+
* @param options.authorize - Authorization check function
|
|
155
|
+
* @param options.status - Success HTTP status code (default: 200)
|
|
156
|
+
*/
|
|
157
|
+
constructor({
|
|
158
|
+
fn,
|
|
159
|
+
method,
|
|
160
|
+
route,
|
|
161
|
+
description,
|
|
162
|
+
tags,
|
|
163
|
+
input,
|
|
164
|
+
logger,
|
|
165
|
+
output: outputSchema,
|
|
166
|
+
services,
|
|
167
|
+
timeout,
|
|
168
|
+
getSession,
|
|
169
|
+
authorize,
|
|
170
|
+
rateLimit,
|
|
171
|
+
status,
|
|
172
|
+
publisherService,
|
|
173
|
+
events
|
|
174
|
+
}: EndpointOptions<TRoute, TMethod, TInput, OutSchema, TServices, TLogger, TSession, OutSchema, TEventPublisher, TEventPublisherServiceName>);
|
|
175
|
+
}
|
|
176
|
+
/**
|
|
177
|
+
* Defines the input schema structure for an endpoint.
|
|
178
|
+
*
|
|
179
|
+
* @template TBody - Schema for request body validation
|
|
180
|
+
* @template TSearch - Schema for query string validation
|
|
181
|
+
* @template TParams - Schema for URL path parameters validation
|
|
182
|
+
*
|
|
183
|
+
* @example
|
|
184
|
+
* ```typescript
|
|
185
|
+
* type UserInput = EndpointInput<
|
|
186
|
+
* typeof createUserBodySchema,
|
|
187
|
+
* typeof userQuerySchema,
|
|
188
|
+
* typeof userParamsSchema
|
|
189
|
+
* >;
|
|
190
|
+
* ```
|
|
191
|
+
*/
|
|
192
|
+
type EndpointInput<TBody extends StandardSchemaV1 | undefined = undefined, TSearch extends StandardSchemaV1 | undefined = undefined, TParams extends StandardSchemaV1 | undefined = undefined> = RemoveUndefined<{
|
|
193
|
+
body: TBody;
|
|
194
|
+
search: TSearch;
|
|
195
|
+
params: TParams;
|
|
196
|
+
}>;
|
|
197
|
+
/**
|
|
198
|
+
* Configuration options for creating an Endpoint instance.
|
|
199
|
+
*
|
|
200
|
+
* @template TRoute - The route path string
|
|
201
|
+
* @template TMethod - The HTTP method
|
|
202
|
+
* @template TInput - Input schema definitions
|
|
203
|
+
* @template TOutput - Output schema definition
|
|
204
|
+
* @template TServices - Service dependencies array
|
|
205
|
+
* @template TLogger - Logger type
|
|
206
|
+
* @template TSession - Session data type
|
|
207
|
+
*/
|
|
208
|
+
interface EndpointOptions<TRoute extends string, TMethod extends HttpMethod, TInput extends EndpointSchemas = {}, TOutput extends StandardSchemaV1 | undefined = undefined, TServices extends Service[] = [], TLogger extends Logger = Logger, TSession = unknown, OutSchema extends StandardSchemaV1 | undefined = undefined, TEventPublisher extends EventPublisher<any> | undefined = undefined, TEventPublisherServiceName extends string = string> {
|
|
209
|
+
/** The route path with parameter placeholders */
|
|
210
|
+
route: TRoute;
|
|
211
|
+
/** The HTTP method for this endpoint */
|
|
212
|
+
method: TMethod;
|
|
213
|
+
/** The handler function that implements the endpoint logic */
|
|
214
|
+
fn: EndpointHandler<TInput, TServices, TLogger, TOutput, TSession>;
|
|
215
|
+
/** Optional authorization check function */
|
|
216
|
+
authorize: AuthorizeFn<TServices, TLogger, TSession> | undefined;
|
|
217
|
+
/** Optional description for documentation */
|
|
218
|
+
description: string | undefined;
|
|
219
|
+
/** Optional tags for OpenAPI documentation */
|
|
220
|
+
tags?: string[];
|
|
221
|
+
/** Optional execution timeout in milliseconds */
|
|
222
|
+
timeout: number | undefined;
|
|
223
|
+
/** Input validation schemas */
|
|
224
|
+
input: TInput | undefined;
|
|
225
|
+
/** Output validation schema */
|
|
226
|
+
output: TOutput | undefined;
|
|
227
|
+
/** Service dependencies to inject */
|
|
228
|
+
services: TServices;
|
|
229
|
+
/** Logger instance */
|
|
230
|
+
logger: TLogger;
|
|
231
|
+
/** Optional session extraction function */
|
|
232
|
+
getSession: SessionFn<TServices, TLogger, TSession> | undefined;
|
|
233
|
+
/** Optional rate limiting configuration */
|
|
234
|
+
rateLimit?: RateLimitConfig;
|
|
235
|
+
/** Success HTTP status code */
|
|
236
|
+
status: SuccessStatus | undefined;
|
|
237
|
+
/**
|
|
238
|
+
* Event publisher service for publishing events from this endpoint
|
|
239
|
+
*/
|
|
240
|
+
publisherService?: Service<TEventPublisherServiceName, TEventPublisher>;
|
|
241
|
+
events?: MappedEvent<TEventPublisher, OutSchema>[];
|
|
242
|
+
}
|
|
243
|
+
/**
|
|
244
|
+
* Defines the possible input schema types for an endpoint.
|
|
245
|
+
* Each property represents a different part of the HTTP request.
|
|
246
|
+
*/
|
|
247
|
+
type EndpointSchemas = Partial<{
|
|
248
|
+
/** Schema for URL path parameters (e.g., /users/:id) */
|
|
249
|
+
params: StandardSchemaV1;
|
|
250
|
+
/** Schema for query string parameters */
|
|
251
|
+
query: StandardSchemaV1;
|
|
252
|
+
/** Schema for request body (POST, PUT, PATCH) */
|
|
253
|
+
body: StandardSchemaV1;
|
|
254
|
+
}>;
|
|
255
|
+
type AuthorizeContext<TServices extends Service[] = [], TLogger extends Logger = Logger, TSession = unknown> = {
|
|
256
|
+
services: ServiceRecord<TServices>;
|
|
257
|
+
logger: TLogger;
|
|
258
|
+
header: HeaderFn;
|
|
259
|
+
session: TSession;
|
|
260
|
+
};
|
|
261
|
+
/**
|
|
262
|
+
* Function type for endpoint authorization checks.
|
|
263
|
+
*
|
|
264
|
+
* @template TServices - Available service dependencies
|
|
265
|
+
* @template TLogger - Logger type
|
|
266
|
+
* @template TSession - Session data type
|
|
267
|
+
*
|
|
268
|
+
* @param ctx - Context containing services, logger, headers, and session
|
|
269
|
+
* @returns Boolean indicating if the request is authorized
|
|
270
|
+
*
|
|
271
|
+
* @example
|
|
272
|
+
* ```typescript
|
|
273
|
+
* const authorize: AuthorizeFn = ({ session }) => {
|
|
274
|
+
* return session.userId !== undefined;
|
|
275
|
+
* };
|
|
276
|
+
* ```
|
|
277
|
+
*/
|
|
278
|
+
type AuthorizeFn<TServices extends Service[] = [], TLogger extends Logger = Logger, TSession = unknown> = (ctx: AuthorizeContext<TServices, TLogger, TSession>) => Promise<boolean> | boolean;
|
|
279
|
+
type SessionContext<TServices extends Service[] = [], TLogger extends Logger = Logger> = {
|
|
280
|
+
services: ServiceRecord<TServices>;
|
|
281
|
+
logger: TLogger;
|
|
282
|
+
header: HeaderFn;
|
|
283
|
+
};
|
|
284
|
+
/**
|
|
285
|
+
* Function type for extracting session data from a request.
|
|
286
|
+
*
|
|
287
|
+
* @template TServices - Available service dependencies
|
|
288
|
+
* @template TLogger - Logger type
|
|
289
|
+
* @template TSession - Session data type to extract
|
|
290
|
+
*
|
|
291
|
+
* @param ctx - Context containing services, logger, and headers
|
|
292
|
+
* @returns The extracted session data
|
|
293
|
+
*
|
|
294
|
+
* @example
|
|
295
|
+
* ```typescript
|
|
296
|
+
* const getSession: SessionFn<Services, Logger, UserSession> = async ({ header, services }) => {
|
|
297
|
+
* const token = header('authorization');
|
|
298
|
+
* return await services.auth.verifyToken(token);
|
|
299
|
+
* };
|
|
300
|
+
* ```
|
|
301
|
+
*/
|
|
302
|
+
type SessionFn<TServices extends Service[] = [], TLogger extends Logger = Logger, TSession = unknown> = (ctx: SessionContext<TServices, TLogger>) => Promise<TSession> | TSession;
|
|
303
|
+
/**
|
|
304
|
+
* Utility type that converts Express-style route parameters to OpenAPI format.
|
|
305
|
+
* Transforms ':param' syntax to '{param}' syntax.
|
|
306
|
+
*
|
|
307
|
+
* @template T - The route string to convert
|
|
308
|
+
*
|
|
309
|
+
* @example
|
|
310
|
+
* ```typescript
|
|
311
|
+
* type Route1 = ConvertRouteParams<'/users/:id'>; // '/users/{id}'
|
|
312
|
+
* type Route2 = ConvertRouteParams<'/users/:userId/posts/:postId'>; // '/users/{userId}/posts/{postId}'
|
|
313
|
+
* ```
|
|
314
|
+
*/
|
|
315
|
+
type ConvertRouteParams<T extends string> = T extends `${infer Start}:${infer Param}/${infer Rest}` ? `${Start}{${Param}}/${ConvertRouteParams<Rest>}` : T extends `${infer Start}:${infer Param}` ? `${Start}{${Param}}` : T;
|
|
316
|
+
/**
|
|
317
|
+
* Type representing the OpenAPI schema structure for an endpoint.
|
|
318
|
+
*
|
|
319
|
+
* @template TRoute - The route path
|
|
320
|
+
* @template TMethod - The HTTP method
|
|
321
|
+
*
|
|
322
|
+
* @example
|
|
323
|
+
* ```typescript
|
|
324
|
+
* type Schema = EndpointOpenApiSchema<'/users/:id', 'GET'>;
|
|
325
|
+
* // Results in: { '/users/{id}': { get: OperationObject, parameters?: ParameterObject[] } }
|
|
326
|
+
* ```
|
|
327
|
+
*/
|
|
328
|
+
type EndpointOpenApiSchema<TRoute extends string, TMethod extends HttpMethod> = { [key in ConvertRouteParams<TRoute>]: { [key in LowerHttpMethod<TMethod>]: OpenAPIV3_1.OperationObject<{}> } & {
|
|
329
|
+
parameters?: OpenAPIV3_1.ParameterObject[];
|
|
330
|
+
} };
|
|
331
|
+
type SingleHeaderFn = (key: string) => string | undefined;
|
|
332
|
+
type MultiHeaderFn = () => EndpointHeaders;
|
|
333
|
+
/**
|
|
334
|
+
* Type representing HTTP headers as a Map.
|
|
335
|
+
*/
|
|
336
|
+
type EndpointHeaders = Map<string, string>;
|
|
337
|
+
/**
|
|
338
|
+
* Function type for retrieving HTTP header values.
|
|
339
|
+
*
|
|
340
|
+
* @param key - The header name (case-insensitive)
|
|
341
|
+
* @returns The header value or undefined if not found
|
|
342
|
+
*/
|
|
343
|
+
type HeaderFn = SingleHeaderFn;
|
|
344
|
+
/**
|
|
345
|
+
* The execution context provided to endpoint handlers.
|
|
346
|
+
* Contains all parsed input data, services, logger, headers, and session.
|
|
347
|
+
*
|
|
348
|
+
* @template Input - The input schemas (body, query, params)
|
|
349
|
+
* @template TServices - Available service dependencies
|
|
350
|
+
* @template TLogger - Logger type
|
|
351
|
+
* @template TSession - Session data type
|
|
352
|
+
*/
|
|
353
|
+
type EndpointContext<Input extends EndpointSchemas | undefined = undefined, TServices extends Service[] = [], TLogger extends Logger = Logger, TSession = unknown> = {
|
|
354
|
+
/** Injected service instances */
|
|
355
|
+
services: ServiceRecord<TServices>;
|
|
356
|
+
/** Logger instance for this request */
|
|
357
|
+
logger: TLogger;
|
|
358
|
+
/** Function to retrieve request headers */
|
|
359
|
+
header: HeaderFn;
|
|
360
|
+
/** Session data extracted by getSession */
|
|
361
|
+
session: TSession;
|
|
362
|
+
} & InferComposableStandardSchema<Input>;
|
|
363
|
+
/**
|
|
364
|
+
* Handler function type for endpoint implementations.
|
|
365
|
+
*
|
|
366
|
+
* @template TInput - Input schemas for validation
|
|
367
|
+
* @template TServices - Available service dependencies
|
|
368
|
+
* @template TLogger - Logger type
|
|
369
|
+
* @template OutSchema - Output schema for response validation
|
|
370
|
+
* @template TSession - Session data type
|
|
371
|
+
*
|
|
372
|
+
* @param ctx - The endpoint execution context
|
|
373
|
+
* @returns The response data (validated if OutSchema is provided)
|
|
374
|
+
*
|
|
375
|
+
* @example
|
|
376
|
+
* ```typescript
|
|
377
|
+
* const handler: EndpointHandler<Input, [UserService], Logger, UserSchema> =
|
|
378
|
+
* async ({ params, services }) => {
|
|
379
|
+
* return await services.users.findById(params.id);
|
|
380
|
+
* };
|
|
381
|
+
* ```
|
|
382
|
+
*/
|
|
383
|
+
type EndpointHandler<TInput extends EndpointSchemas | undefined = undefined, TServices extends Service[] = [], TLogger extends Logger = Logger, OutSchema extends StandardSchemaV1 | undefined = undefined, TSession = unknown> = (ctx: EndpointContext<TInput, TServices, TLogger, TSession>) => OutSchema extends StandardSchemaV1 ? InferStandardSchema<OutSchema> | Promise<InferStandardSchema<OutSchema>> : any | Promise<any>;
|
|
384
|
+
/**
|
|
385
|
+
* HTTP success status codes that can be returned by endpoints.
|
|
386
|
+
*/
|
|
387
|
+
declare enum SuccessStatus {
|
|
388
|
+
/** Standard response for successful HTTP requests */
|
|
389
|
+
OK = 200,
|
|
390
|
+
/** Request has been fulfilled and resulted in a new resource being created */
|
|
391
|
+
Created = 201,
|
|
392
|
+
/** Request has been accepted for processing, but processing is not complete */
|
|
393
|
+
Accepted = 202,
|
|
394
|
+
/** Server successfully processed the request but is not returning any content */
|
|
395
|
+
NoContent = 204,
|
|
396
|
+
/** Server successfully processed the request and is not returning any content, client should reset the document view */
|
|
397
|
+
ResetContent = 205,
|
|
398
|
+
/** Server is delivering only part of the resource due to a range header */
|
|
399
|
+
PartialContent = 206,
|
|
400
|
+
}
|
|
401
|
+
type EndpointOutput<T> = T extends Endpoint<any, any, any, infer OutSchema, any, any, any, any> ? InferStandardSchema<OutSchema> : never;
|
|
402
|
+
type EndpointEvent<T> = T extends Endpoint<any, any, any, any, any, any, any, infer TEventPublisher> ? ExtractPublisherMessage<TEventPublisher> : never;
|
|
403
|
+
//#endregion
|
|
404
|
+
export { AuthorizeContext, AuthorizeFn, ConvertRouteParams, Endpoint, EndpointContext, EndpointEvent, EndpointHandler, EndpointHeaders, EndpointInput, EndpointOpenApiSchema, EndpointOptions, EndpointOutput, EndpointSchemas, HeaderFn, MultiHeaderFn, SessionContext, SessionFn, SingleHeaderFn, SuccessStatus };
|
|
405
|
+
//# sourceMappingURL=Endpoint-C7z9YJHK.d.cts.map
|