@geekmidas/constructs 0.0.7 → 0.0.10
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/dist/{AWSLambdaFunction-CANc3Qo2.d.mts → AWSLambdaFunction-D5V3YVqv.d.cts} +5 -5
- package/dist/{AWSLambdaFunction-DWIZYsCy.mjs → AWSLambdaFunction-D_V-ZQmS.mjs} +3 -3
- package/dist/{AWSLambdaFunction-DWIZYsCy.mjs.map → AWSLambdaFunction-D_V-ZQmS.mjs.map} +1 -1
- package/dist/{AWSLambdaFunction-qA5LqPsv.cjs → AWSLambdaFunction-DhUb-Vs6.cjs} +3 -3
- package/dist/{AWSLambdaFunction-qA5LqPsv.cjs.map → AWSLambdaFunction-DhUb-Vs6.cjs.map} +1 -1
- package/dist/{AWSLambdaFunction-CwagvPG3.d.cts → AWSLambdaFunction-DvZcnL8a.d.mts} +5 -5
- package/dist/{AWSLambdaSubscriberAdaptor-QKVxR6qh.d.cts → AWSLambdaSubscriberAdaptor-D6kjKjSf.d.mts} +4 -4
- package/dist/{AWSLambdaSubscriberAdaptor-C6JYIZxn.d.mts → AWSLambdaSubscriberAdaptor-J_pSz6pu.d.cts} +4 -4
- package/dist/{AmazonApiGatewayEndpointAdaptor-BrB3RfbI.d.mts → AmazonApiGatewayEndpointAdaptor-B7MKo8h3.d.mts} +3 -3
- package/dist/{AmazonApiGatewayEndpointAdaptor-BFhJ2Rpz.d.cts → AmazonApiGatewayEndpointAdaptor-BnNd8tCz.d.cts} +2 -2
- package/dist/{AmazonApiGatewayEndpointAdaptor-B8mozTcG.cjs → AmazonApiGatewayEndpointAdaptor-DHBF_5jn.cjs} +2 -2
- package/dist/{AmazonApiGatewayEndpointAdaptor-B8mozTcG.cjs.map → AmazonApiGatewayEndpointAdaptor-DHBF_5jn.cjs.map} +1 -1
- package/dist/{AmazonApiGatewayEndpointAdaptor-Bmz6Cy1e.mjs → AmazonApiGatewayEndpointAdaptor-DHcUetbw.mjs} +2 -2
- package/dist/{AmazonApiGatewayEndpointAdaptor-Bmz6Cy1e.mjs.map → AmazonApiGatewayEndpointAdaptor-DHcUetbw.mjs.map} +1 -1
- package/dist/{AmazonApiGatewayV1EndpointAdaptor-Bd-o8ese.d.cts → AmazonApiGatewayV1EndpointAdaptor-BC-a2tt3.d.cts} +3 -3
- package/dist/{AmazonApiGatewayV1EndpointAdaptor-D4eZ-fx5.cjs → AmazonApiGatewayV1EndpointAdaptor-CmUxFoPx.cjs} +2 -2
- package/dist/{AmazonApiGatewayV1EndpointAdaptor-D4eZ-fx5.cjs.map → AmazonApiGatewayV1EndpointAdaptor-CmUxFoPx.cjs.map} +1 -1
- package/dist/{AmazonApiGatewayV1EndpointAdaptor-24g3dLn5.mjs → AmazonApiGatewayV1EndpointAdaptor-CsV6zyvn.mjs} +2 -2
- package/dist/{AmazonApiGatewayV1EndpointAdaptor-24g3dLn5.mjs.map → AmazonApiGatewayV1EndpointAdaptor-CsV6zyvn.mjs.map} +1 -1
- package/dist/{AmazonApiGatewayV1EndpointAdaptor-BtNXt0-4.d.mts → AmazonApiGatewayV1EndpointAdaptor-gO9OxdZl.d.mts} +4 -4
- package/dist/{AmazonApiGatewayV2EndpointAdaptor-DAJdtgek.d.mts → AmazonApiGatewayV2EndpointAdaptor-D1uz4wNg.d.mts} +4 -4
- package/dist/{AmazonApiGatewayV2EndpointAdaptor-Cc40RThv.mjs → AmazonApiGatewayV2EndpointAdaptor-_bFcbEa-.mjs} +2 -2
- package/dist/{AmazonApiGatewayV2EndpointAdaptor-Cc40RThv.mjs.map → AmazonApiGatewayV2EndpointAdaptor-_bFcbEa-.mjs.map} +1 -1
- package/dist/{AmazonApiGatewayV2EndpointAdaptor-J6tACl-N.cjs → AmazonApiGatewayV2EndpointAdaptor-cZbaqiUi.cjs} +2 -2
- package/dist/{AmazonApiGatewayV2EndpointAdaptor-J6tACl-N.cjs.map → AmazonApiGatewayV2EndpointAdaptor-cZbaqiUi.cjs.map} +1 -1
- package/dist/{AmazonApiGatewayV2EndpointAdaptor-DX-Uci5w.d.cts → AmazonApiGatewayV2EndpointAdaptor-zNFUPxSY.d.cts} +3 -3
- package/dist/Authorizer-Bbk9ziuG.d.mts +29 -0
- package/dist/Authorizer-iXsSB600.d.cts +29 -0
- package/dist/{BaseFunctionBuilder-DtO4Nwxm.cjs → BaseFunctionBuilder-BmsbV0BU.cjs} +2 -2
- package/dist/{BaseFunctionBuilder-DtO4Nwxm.cjs.map → BaseFunctionBuilder-BmsbV0BU.cjs.map} +1 -1
- package/dist/{BaseFunctionBuilder-5QCHkchp.d.cts → BaseFunctionBuilder-C4ZJPkIZ.d.cts} +2 -2
- package/dist/{BaseFunctionBuilder-Dda7AiID.d.mts → BaseFunctionBuilder-CxBX0arJ.d.mts} +2 -2
- package/dist/{BaseFunctionBuilder-BPE9JBbT.mjs → BaseFunctionBuilder-DCUtCdVL.mjs} +2 -2
- package/dist/{BaseFunctionBuilder-BPE9JBbT.mjs.map → BaseFunctionBuilder-DCUtCdVL.mjs.map} +1 -1
- package/dist/{Construct-BbKCIPQm.mjs → Construct-C3hsQBy4.mjs} +10 -13
- package/dist/Construct-C3hsQBy4.mjs.map +1 -0
- package/dist/{Construct-BSEs6uwW.cjs → Construct-VEI7M3fs.cjs} +10 -13
- package/dist/Construct-VEI7M3fs.cjs.map +1 -0
- package/dist/{Construct-Bm-PSO2V.d.cts → Construct-ci5u8Xnu.d.cts} +4 -2
- package/dist/{Construct-DdyYENBD.d.mts → Construct-zhmcmIdY.d.mts} +4 -2
- package/dist/Construct.cjs +1 -1
- package/dist/Construct.d.cts +1 -1
- package/dist/Construct.d.mts +1 -1
- package/dist/Construct.mjs +1 -1
- package/dist/{Cron-BxMXmn4t.d.cts → Cron-ByNYsQDH.d.mts} +4 -4
- package/dist/{Cron-CmZ6esMM.cjs → Cron-Dfgr8F9d.cjs} +5 -5
- package/dist/Cron-Dfgr8F9d.cjs.map +1 -0
- package/dist/{Cron-NDBlJhb3.d.mts → Cron-DkPL-Fms.d.cts} +4 -4
- package/dist/{Cron-D6hnZLk7.mjs → Cron-wP6Ob48_.mjs} +5 -5
- package/dist/Cron-wP6Ob48_.mjs.map +1 -0
- package/dist/{CronBuilder-C6K5AbIO.d.cts → CronBuilder-BknVTWLE.d.mts} +6 -5
- package/dist/{CronBuilder-s5x8V8hH.d.mts → CronBuilder-BqTTozUi.d.cts} +6 -5
- package/dist/{CronBuilder-Dfv5JguE.mjs → CronBuilder-C27c5oqh.mjs} +10 -5
- package/dist/CronBuilder-C27c5oqh.mjs.map +1 -0
- package/dist/{CronBuilder-Di7QK8Rt.cjs → CronBuilder-W1ZqCJ7m.cjs} +10 -5
- package/dist/CronBuilder-W1ZqCJ7m.cjs.map +1 -0
- package/dist/{Endpoint-COGAflGh.cjs → Endpoint-BjpQmTek.cjs} +21 -12
- package/dist/Endpoint-BjpQmTek.cjs.map +1 -0
- package/dist/{Endpoint-C7jPJzAH.d.mts → Endpoint-C16whGI-.d.mts} +45 -13
- package/dist/{Endpoint-DLLZvqoh.mjs → Endpoint-C98BwZjA.mjs} +21 -12
- package/dist/Endpoint-C98BwZjA.mjs.map +1 -0
- package/dist/{Endpoint-XUMNAXYy.d.cts → Endpoint-zHPjZ35J.d.cts} +45 -13
- package/dist/{EndpointBuilder-t6fVEKBH.d.cts → EndpointBuilder-B5l7zQU1.d.cts} +18 -12
- package/dist/{EndpointBuilder-CFtWQhcv.d.mts → EndpointBuilder-BzqR0xvt.d.mts} +18 -12
- package/dist/{EndpointBuilder-oXO_ka1-.mjs → EndpointBuilder-CCUx4vep.mjs} +28 -5
- package/dist/EndpointBuilder-CCUx4vep.mjs.map +1 -0
- package/dist/{EndpointBuilder-FJktpPOu.cjs → EndpointBuilder-D2Zu8i9b.cjs} +28 -5
- package/dist/EndpointBuilder-D2Zu8i9b.cjs.map +1 -0
- package/dist/{EndpointFactory-Kk1tpifs.cjs → EndpointFactory-C4YhgXOc.cjs} +41 -10
- package/dist/EndpointFactory-C4YhgXOc.cjs.map +1 -0
- package/dist/{EndpointFactory-DBRGrXAy.d.mts → EndpointFactory-KkyIOE62.d.cts} +29 -21
- package/dist/{EndpointFactory-eG8bDhOh.mjs → EndpointFactory-RAb2zcw0.mjs} +41 -10
- package/dist/EndpointFactory-RAb2zcw0.mjs.map +1 -0
- package/dist/{EndpointFactory-DInjHvFR.d.cts → EndpointFactory-VnSAdwdv.d.mts} +29 -21
- package/dist/{Function-CbO2NZx-.cjs → Function-1Fh6Tdkg.cjs} +4 -5
- package/dist/Function-1Fh6Tdkg.cjs.map +1 -0
- package/dist/{Function-BP58p9Mp.d.cts → Function-BbLYIKLL.d.cts} +3 -4
- package/dist/{Function-C5mW-38v.mjs → Function-D-QEfH7k.mjs} +4 -5
- package/dist/Function-D-QEfH7k.mjs.map +1 -0
- package/dist/{Function-C98H68DW.d.mts → Function-DFRZZCC-.d.mts} +3 -4
- package/dist/{FunctionBuilder-CosgPmMl.mjs → FunctionBuilder-Bxyr1Pf9.mjs} +11 -5
- package/dist/FunctionBuilder-Bxyr1Pf9.mjs.map +1 -0
- package/dist/{FunctionBuilder-DuOeWCAl.cjs → FunctionBuilder-DcEFYgbn.cjs} +11 -5
- package/dist/FunctionBuilder-DcEFYgbn.cjs.map +1 -0
- package/dist/{FunctionBuilder-BS1KgxA_.d.cts → FunctionBuilder-DdGjpiFT.d.cts} +6 -4
- package/dist/{FunctionBuilder-DBwR7jg7.d.mts → FunctionBuilder-DuktGyZc.d.mts} +6 -4
- package/dist/{FunctionExecutionWrapper-XGrSAAPD.mjs → FunctionExecutionWrapper-BL6PE6Dv.mjs} +2 -2
- package/dist/{FunctionExecutionWrapper-XGrSAAPD.mjs.map → FunctionExecutionWrapper-BL6PE6Dv.mjs.map} +1 -1
- package/dist/{FunctionExecutionWrapper-B0V7V8YS.d.mts → FunctionExecutionWrapper-CRYi047B.d.cts} +4 -4
- package/dist/{FunctionExecutionWrapper-Bx-Dl-2a.d.cts → FunctionExecutionWrapper-DaR-dSLw.d.mts} +4 -4
- package/dist/{FunctionExecutionWrapper-CElXEjPe.cjs → FunctionExecutionWrapper-Ee-CE8Fz.cjs} +2 -2
- package/dist/{FunctionExecutionWrapper-CElXEjPe.cjs.map → FunctionExecutionWrapper-Ee-CE8Fz.cjs.map} +1 -1
- package/dist/{HonoEndpointAdaptor-BrbM9vxd.d.cts → HonoEndpointAdaptor-CY1mXTe6.d.mts} +7 -6
- package/dist/{HonoEndpointAdaptor-CxcYKdzT.d.mts → HonoEndpointAdaptor-CYvrXBe-.d.cts} +9 -8
- package/dist/{HonoEndpointAdaptor-BlT1rWHV.mjs → HonoEndpointAdaptor-CyVPl4w2.mjs} +33 -16
- package/dist/HonoEndpointAdaptor-CyVPl4w2.mjs.map +1 -0
- package/dist/{HonoEndpointAdaptor-Ds433Q8w.cjs → HonoEndpointAdaptor-DcvZdYzx.cjs} +20 -3
- package/dist/HonoEndpointAdaptor-DcvZdYzx.cjs.map +1 -0
- package/dist/{Subscriber-CSt7EOlT.cjs → Subscriber-BL30GpWp.cjs} +2 -2
- package/dist/{Subscriber-CSt7EOlT.cjs.map → Subscriber-BL30GpWp.cjs.map} +1 -1
- package/dist/{Subscriber-DkCDcTUL.mjs → Subscriber-CTczVFsF.mjs} +2 -2
- package/dist/{Subscriber-DkCDcTUL.mjs.map → Subscriber-CTczVFsF.mjs.map} +1 -1
- package/dist/{Subscriber-BoFm12i_.d.cts → Subscriber-Cy28j8MS.d.cts} +2 -2
- package/dist/{Subscriber-BxH6n8zQ.d.mts → Subscriber-g3IWM1_d.d.mts} +2 -2
- package/dist/{SubscriberBuilder-BpSDPzBz.d.mts → SubscriberBuilder-BzK8kc2a.d.cts} +3 -3
- package/dist/{SubscriberBuilder-Bn9Hyi28.mjs → SubscriberBuilder-CekL3BoP.mjs} +2 -2
- package/dist/{SubscriberBuilder-Bn9Hyi28.mjs.map → SubscriberBuilder-CekL3BoP.mjs.map} +1 -1
- package/dist/{SubscriberBuilder-RsiOmnwq.cjs → SubscriberBuilder-D1hojYLa.cjs} +2 -2
- package/dist/{SubscriberBuilder-RsiOmnwq.cjs.map → SubscriberBuilder-D1hojYLa.cjs.map} +1 -1
- package/dist/{SubscriberBuilder-DgljKtYu.d.cts → SubscriberBuilder-YjQ7qIpQ.d.mts} +3 -3
- package/dist/{TestEndpointAdaptor-Ct4I-gDo.mjs → TestEndpointAdaptor-B4z9G5Ap.mjs} +3 -3
- package/dist/{TestEndpointAdaptor-Ct4I-gDo.mjs.map → TestEndpointAdaptor-B4z9G5Ap.mjs.map} +1 -1
- package/dist/{TestEndpointAdaptor-FJUob2W_.cjs → TestEndpointAdaptor-C-ahwGW6.cjs} +3 -3
- package/dist/{TestEndpointAdaptor-FJUob2W_.cjs.map → TestEndpointAdaptor-C-ahwGW6.cjs.map} +1 -1
- package/dist/{TestEndpointAdaptor-vboVyJ0w.d.mts → TestEndpointAdaptor-DGWuai69.d.mts} +2 -2
- package/dist/{TestEndpointAdaptor-wwEaVHAt.d.cts → TestEndpointAdaptor-uXliWYjS.d.cts} +2 -2
- package/dist/adaptors/aws.cjs +11 -11
- package/dist/adaptors/aws.d.cts +14 -13
- package/dist/adaptors/aws.d.mts +14 -13
- package/dist/adaptors/aws.mjs +11 -11
- package/dist/adaptors/hono.cjs +8 -8
- package/dist/adaptors/hono.d.cts +8 -7
- package/dist/adaptors/hono.d.mts +8 -7
- package/dist/adaptors/hono.mjs +8 -8
- package/dist/adaptors/testing.cjs +7 -7
- package/dist/adaptors/testing.d.cts +8 -7
- package/dist/adaptors/testing.d.mts +8 -7
- package/dist/adaptors/testing.mjs +7 -7
- package/dist/crons/Cron.cjs +6 -6
- package/dist/crons/Cron.d.cts +6 -6
- package/dist/crons/Cron.d.mts +6 -6
- package/dist/crons/Cron.mjs +6 -6
- package/dist/crons/CronBuilder.cjs +7 -7
- package/dist/crons/CronBuilder.d.cts +7 -7
- package/dist/crons/CronBuilder.d.mts +7 -7
- package/dist/crons/CronBuilder.mjs +7 -7
- package/dist/crons/index.cjs +7 -7
- package/dist/crons/index.d.cts +11 -11
- package/dist/crons/index.d.mts +11 -11
- package/dist/crons/index.mjs +7 -7
- package/dist/endpoints/AmazonApiGatewayEndpointAdaptor.cjs +7 -7
- package/dist/endpoints/AmazonApiGatewayEndpointAdaptor.d.cts +8 -7
- package/dist/endpoints/AmazonApiGatewayEndpointAdaptor.d.mts +8 -7
- package/dist/endpoints/AmazonApiGatewayEndpointAdaptor.mjs +7 -7
- package/dist/endpoints/AmazonApiGatewayV1EndpointAdaptor.cjs +8 -8
- package/dist/endpoints/AmazonApiGatewayV1EndpointAdaptor.d.cts +9 -8
- package/dist/endpoints/AmazonApiGatewayV1EndpointAdaptor.d.mts +9 -8
- package/dist/endpoints/AmazonApiGatewayV1EndpointAdaptor.mjs +8 -8
- package/dist/endpoints/AmazonApiGatewayV2EndpointAdaptor.cjs +8 -8
- package/dist/endpoints/AmazonApiGatewayV2EndpointAdaptor.d.cts +9 -8
- package/dist/endpoints/AmazonApiGatewayV2EndpointAdaptor.d.mts +9 -8
- package/dist/endpoints/AmazonApiGatewayV2EndpointAdaptor.mjs +8 -8
- package/dist/endpoints/Authorizer.cjs +15 -0
- package/dist/endpoints/Authorizer.cjs.map +1 -0
- package/dist/endpoints/Authorizer.d.cts +2 -0
- package/dist/endpoints/Authorizer.d.mts +2 -0
- package/dist/endpoints/Authorizer.mjs +14 -0
- package/dist/endpoints/Authorizer.mjs.map +1 -0
- package/dist/endpoints/Endpoint.cjs +6 -6
- package/dist/endpoints/Endpoint.d.cts +7 -6
- package/dist/endpoints/Endpoint.d.mts +7 -6
- package/dist/endpoints/Endpoint.mjs +6 -6
- package/dist/endpoints/EndpointBuilder.cjs +7 -7
- package/dist/endpoints/EndpointBuilder.d.cts +8 -7
- package/dist/endpoints/EndpointBuilder.d.mts +8 -7
- package/dist/endpoints/EndpointBuilder.mjs +7 -7
- package/dist/endpoints/EndpointFactory.cjs +8 -8
- package/dist/endpoints/EndpointFactory.d.cts +9 -8
- package/dist/endpoints/EndpointFactory.d.mts +9 -8
- package/dist/endpoints/EndpointFactory.mjs +8 -8
- package/dist/endpoints/HonoEndpointAdaptor.cjs +8 -8
- package/dist/endpoints/HonoEndpointAdaptor.d.cts +8 -7
- package/dist/endpoints/HonoEndpointAdaptor.d.mts +8 -7
- package/dist/endpoints/HonoEndpointAdaptor.mjs +8 -8
- package/dist/endpoints/TestEndpointAdaptor.cjs +7 -7
- package/dist/endpoints/TestEndpointAdaptor.d.cts +8 -7
- package/dist/endpoints/TestEndpointAdaptor.d.mts +8 -7
- package/dist/endpoints/TestEndpointAdaptor.mjs +7 -7
- package/dist/endpoints/helpers.cjs +7 -7
- package/dist/endpoints/helpers.d.cts +7 -6
- package/dist/endpoints/helpers.d.mts +7 -6
- package/dist/endpoints/helpers.mjs +7 -7
- package/dist/endpoints/index.cjs +8 -8
- package/dist/endpoints/index.d.cts +11 -10
- package/dist/endpoints/index.d.mts +11 -10
- package/dist/endpoints/index.mjs +8 -8
- package/dist/functions/AWSLambdaFunction.cjs +6 -6
- package/dist/functions/AWSLambdaFunction.d.cts +4 -4
- package/dist/functions/AWSLambdaFunction.d.mts +4 -4
- package/dist/functions/AWSLambdaFunction.mjs +6 -6
- package/dist/functions/BaseFunctionBuilder.cjs +2 -2
- package/dist/functions/BaseFunctionBuilder.d.cts +2 -2
- package/dist/functions/BaseFunctionBuilder.d.mts +2 -2
- package/dist/functions/BaseFunctionBuilder.mjs +2 -2
- package/dist/functions/Function.cjs +2 -2
- package/dist/functions/Function.d.cts +2 -2
- package/dist/functions/Function.d.mts +2 -2
- package/dist/functions/Function.mjs +2 -2
- package/dist/functions/FunctionBuilder.cjs +4 -4
- package/dist/functions/FunctionBuilder.d.cts +4 -4
- package/dist/functions/FunctionBuilder.d.mts +4 -4
- package/dist/functions/FunctionBuilder.mjs +4 -4
- package/dist/functions/FunctionExecutionWrapper.cjs +5 -5
- package/dist/functions/FunctionExecutionWrapper.d.cts +3 -3
- package/dist/functions/FunctionExecutionWrapper.d.mts +3 -3
- package/dist/functions/FunctionExecutionWrapper.mjs +5 -5
- package/dist/functions/TestFunctionAdaptor.cjs +5 -5
- package/dist/functions/TestFunctionAdaptor.d.cts +2 -2
- package/dist/functions/TestFunctionAdaptor.d.mts +2 -2
- package/dist/functions/TestFunctionAdaptor.mjs +5 -5
- package/dist/functions/index.cjs +5 -5
- package/dist/functions/index.d.cts +5 -5
- package/dist/functions/index.d.mts +5 -5
- package/dist/functions/index.mjs +5 -5
- package/dist/{functions-DVDb5wEA.cjs → functions-BtgBiuC_.cjs} +2 -2
- package/dist/{functions-DVDb5wEA.cjs.map → functions-BtgBiuC_.cjs.map} +1 -1
- package/dist/functions-DD-00sWF.mjs +8 -0
- package/dist/{functions-mM-jcphA.mjs.map → functions-DD-00sWF.mjs.map} +1 -1
- package/dist/{helpers-CM0U-4Vk.mjs → helpers-DtPeOhUV.mjs} +2 -2
- package/dist/{helpers-CM0U-4Vk.mjs.map → helpers-DtPeOhUV.mjs.map} +1 -1
- package/dist/{helpers-go4jiRvV.cjs → helpers-QM_FSjPY.cjs} +2 -2
- package/dist/{helpers-go4jiRvV.cjs.map → helpers-QM_FSjPY.cjs.map} +1 -1
- package/dist/index-CcmV3PKF.d.cts +9 -0
- package/dist/index-DQt3pQtF.d.mts +9 -0
- package/dist/index.cjs +1 -1
- package/dist/index.d.cts +1 -1
- package/dist/index.d.mts +1 -1
- package/dist/index.mjs +1 -1
- package/dist/publisher.d.cts +1 -1
- package/dist/publisher.d.mts +1 -1
- package/dist/subscribers/AWSLambdaSubscriberAdaptor.d.cts +3 -3
- package/dist/subscribers/AWSLambdaSubscriberAdaptor.d.mts +3 -3
- package/dist/subscribers/Subscriber.cjs +2 -2
- package/dist/subscribers/Subscriber.d.cts +2 -2
- package/dist/subscribers/Subscriber.d.mts +2 -2
- package/dist/subscribers/Subscriber.mjs +2 -2
- package/dist/subscribers/SubscriberBuilder.cjs +3 -3
- package/dist/subscribers/SubscriberBuilder.d.cts +3 -3
- package/dist/subscribers/SubscriberBuilder.d.mts +3 -3
- package/dist/subscribers/SubscriberBuilder.mjs +3 -3
- package/dist/subscribers/index.cjs +3 -3
- package/dist/subscribers/index.d.cts +5 -5
- package/dist/subscribers/index.d.mts +5 -5
- package/dist/subscribers/index.mjs +3 -3
- package/package.json +6 -6
- package/src/Construct.ts +11 -24
- package/src/crons/Cron.ts +2 -0
- package/src/crons/CronBuilder.ts +8 -0
- package/src/crons/__tests__/CronBuilder.state-isolation.spec.ts +227 -0
- package/src/endpoints/Authorizer.ts +34 -0
- package/src/endpoints/Endpoint.ts +67 -14
- package/src/endpoints/EndpointBuilder.ts +79 -12
- package/src/endpoints/EndpointFactory.ts +106 -27
- package/src/endpoints/HonoEndpointAdaptor.ts +29 -0
- package/src/endpoints/__tests__/Endpoint.cookies.spec.ts +85 -0
- package/src/endpoints/__tests__/Endpoint.headers.spec.ts +187 -0
- package/src/endpoints/__tests__/Endpoint.manifest.spec.ts +176 -0
- package/src/endpoints/__tests__/EndpointFactory.authorizers.spec.ts +259 -0
- package/src/endpoints/__tests__/EndpointFactory.reference-audit.spec.ts +190 -0
- package/src/endpoints/__tests__/EndpointFactory.state-isolation.spec.ts +155 -0
- package/src/functions/Function.ts +12 -2
- package/src/functions/FunctionBuilder.ts +9 -0
- package/src/functions/__tests__/FunctionBuilder.state-isolation.spec.ts +160 -0
- package/dist/Construct-BSEs6uwW.cjs.map +0 -1
- package/dist/Construct-BbKCIPQm.mjs.map +0 -1
- package/dist/Cron-CmZ6esMM.cjs.map +0 -1
- package/dist/Cron-D6hnZLk7.mjs.map +0 -1
- package/dist/CronBuilder-Dfv5JguE.mjs.map +0 -1
- package/dist/CronBuilder-Di7QK8Rt.cjs.map +0 -1
- package/dist/Endpoint-COGAflGh.cjs.map +0 -1
- package/dist/Endpoint-DLLZvqoh.mjs.map +0 -1
- package/dist/EndpointBuilder-FJktpPOu.cjs.map +0 -1
- package/dist/EndpointBuilder-oXO_ka1-.mjs.map +0 -1
- package/dist/EndpointFactory-Kk1tpifs.cjs.map +0 -1
- package/dist/EndpointFactory-eG8bDhOh.mjs.map +0 -1
- package/dist/Function-C5mW-38v.mjs.map +0 -1
- package/dist/Function-CbO2NZx-.cjs.map +0 -1
- package/dist/FunctionBuilder-CosgPmMl.mjs.map +0 -1
- package/dist/FunctionBuilder-DuOeWCAl.cjs.map +0 -1
- package/dist/HonoEndpointAdaptor-BlT1rWHV.mjs.map +0 -1
- package/dist/HonoEndpointAdaptor-Ds433Q8w.cjs.map +0 -1
- package/dist/functions-mM-jcphA.mjs +0 -8
- package/dist/index-BGr5gFrX.d.cts +0 -9
- package/dist/index-YM4W9XUq.d.mts +0 -9
|
@@ -5,6 +5,7 @@ import set from 'lodash.set';
|
|
|
5
5
|
import type { OpenAPIV3_1 } from 'openapi-types';
|
|
6
6
|
|
|
7
7
|
import type { Service, ServiceRecord } from '@geekmidas/services';
|
|
8
|
+
import type { Authorizer } from './Authorizer';
|
|
8
9
|
import { ConstructType } from '../Construct';
|
|
9
10
|
import { Function, type FunctionHandler } from '../functions';
|
|
10
11
|
|
|
@@ -93,6 +94,8 @@ export class Endpoint<
|
|
|
93
94
|
public authorize: AuthorizeFn<TServices, TLogger, TSession> = () => true;
|
|
94
95
|
/** Optional rate limiting configuration */
|
|
95
96
|
public rateLimit?: RateLimitConfig;
|
|
97
|
+
/** Optional authorizer for this endpoint */
|
|
98
|
+
public authorizer?: Authorizer;
|
|
96
99
|
/** The endpoint handler function */
|
|
97
100
|
private endpointFn!: EndpointHandler<
|
|
98
101
|
TInput,
|
|
@@ -174,12 +177,13 @@ export class Endpoint<
|
|
|
174
177
|
* Creates a case-insensitive header lookup function from a headers object.
|
|
175
178
|
*
|
|
176
179
|
* @param headers - Object containing header key-value pairs
|
|
177
|
-
* @returns Function to retrieve header values by case-insensitive key
|
|
180
|
+
* @returns Function to retrieve header values by case-insensitive key, or all headers
|
|
178
181
|
*
|
|
179
182
|
* @example
|
|
180
183
|
* ```typescript
|
|
181
184
|
* const headerFn = Endpoint.createHeaders({ 'Content-Type': 'application/json' });
|
|
182
185
|
* headerFn('content-type'); // Returns 'application/json'
|
|
186
|
+
* headerFn(); // Returns { 'content-type': 'application/json' }
|
|
183
187
|
* ```
|
|
184
188
|
*/
|
|
185
189
|
static createHeaders(headers: Record<string, string>): HeaderFn {
|
|
@@ -189,22 +193,30 @@ export class Endpoint<
|
|
|
189
193
|
headerMap.set(key, v);
|
|
190
194
|
}
|
|
191
195
|
|
|
192
|
-
|
|
196
|
+
function get(): Record<string, string>;
|
|
197
|
+
function get(key: string): string | undefined;
|
|
198
|
+
function get(key?: string): string | undefined | Record<string, string> {
|
|
199
|
+
if (key === undefined) {
|
|
200
|
+
// Return all headers as plain object
|
|
201
|
+
return Object.fromEntries(headerMap.entries());
|
|
202
|
+
}
|
|
193
203
|
return headerMap.get(key.toLowerCase());
|
|
194
|
-
}
|
|
204
|
+
}
|
|
205
|
+
|
|
206
|
+
return get;
|
|
195
207
|
}
|
|
196
208
|
|
|
197
209
|
/**
|
|
198
210
|
* Parses cookie string and creates a cookie lookup function.
|
|
199
211
|
*
|
|
200
212
|
* @param cookieHeader - The Cookie header value
|
|
201
|
-
* @returns Function to retrieve cookie values by name
|
|
213
|
+
* @returns Function to retrieve cookie values by name, or all cookies
|
|
202
214
|
*
|
|
203
215
|
* @example
|
|
204
216
|
* ```typescript
|
|
205
217
|
* const cookieFn = Endpoint.createCookies('session=abc123; theme=dark');
|
|
206
218
|
* cookieFn('session'); // Returns 'abc123'
|
|
207
|
-
* cookieFn(
|
|
219
|
+
* cookieFn(); // Returns { session: 'abc123', theme: 'dark' }
|
|
208
220
|
* ```
|
|
209
221
|
*/
|
|
210
222
|
static createCookies(cookieHeader: string | undefined): CookieFn {
|
|
@@ -222,9 +234,17 @@ export class Endpoint<
|
|
|
222
234
|
}
|
|
223
235
|
}
|
|
224
236
|
|
|
225
|
-
|
|
237
|
+
function get(): Record<string, string>;
|
|
238
|
+
function get(name: string): string | undefined;
|
|
239
|
+
function get(name?: string): string | undefined | Record<string, string> {
|
|
240
|
+
if (name === undefined) {
|
|
241
|
+
// Return all cookies as plain object
|
|
242
|
+
return Object.fromEntries(cookieMap.entries());
|
|
243
|
+
}
|
|
226
244
|
return cookieMap.get(name);
|
|
227
|
-
}
|
|
245
|
+
}
|
|
246
|
+
|
|
247
|
+
return get;
|
|
228
248
|
}
|
|
229
249
|
|
|
230
250
|
/**
|
|
@@ -499,6 +519,7 @@ export class Endpoint<
|
|
|
499
519
|
* @param options.getSession - Session extraction function
|
|
500
520
|
* @param options.authorize - Authorization check function
|
|
501
521
|
* @param options.status - Success HTTP status code (default: 200)
|
|
522
|
+
* @param options.authorizer - Optional authorizer configuration
|
|
502
523
|
*/
|
|
503
524
|
constructor({
|
|
504
525
|
fn,
|
|
@@ -511,12 +532,14 @@ export class Endpoint<
|
|
|
511
532
|
output: outputSchema,
|
|
512
533
|
services,
|
|
513
534
|
timeout,
|
|
535
|
+
memorySize,
|
|
514
536
|
getSession,
|
|
515
537
|
authorize,
|
|
516
538
|
rateLimit,
|
|
517
539
|
status = SuccessStatus.OK,
|
|
518
540
|
publisherService,
|
|
519
541
|
events,
|
|
542
|
+
authorizer,
|
|
520
543
|
}: EndpointOptions<
|
|
521
544
|
TRoute,
|
|
522
545
|
TMethod,
|
|
@@ -539,6 +562,7 @@ export class Endpoint<
|
|
|
539
562
|
logger,
|
|
540
563
|
publisherService,
|
|
541
564
|
events,
|
|
565
|
+
memorySize,
|
|
542
566
|
);
|
|
543
567
|
|
|
544
568
|
this.route = route;
|
|
@@ -559,6 +583,10 @@ export class Endpoint<
|
|
|
559
583
|
if (rateLimit) {
|
|
560
584
|
this.rateLimit = rateLimit;
|
|
561
585
|
}
|
|
586
|
+
|
|
587
|
+
if (authorizer) {
|
|
588
|
+
this.authorizer = authorizer;
|
|
589
|
+
}
|
|
562
590
|
}
|
|
563
591
|
}
|
|
564
592
|
|
|
@@ -625,6 +653,8 @@ export interface EndpointOptions<
|
|
|
625
653
|
tags?: string[];
|
|
626
654
|
/** Optional execution timeout in milliseconds */
|
|
627
655
|
timeout: number | undefined;
|
|
656
|
+
/** Optional memory size in MB for serverless deployments */
|
|
657
|
+
memorySize: number | undefined;
|
|
628
658
|
/** Input validation schemas */
|
|
629
659
|
input: TInput | undefined;
|
|
630
660
|
/** Output validation schema */
|
|
@@ -645,6 +675,8 @@ export interface EndpointOptions<
|
|
|
645
675
|
publisherService?: Service<TEventPublisherServiceName, TEventPublisher>;
|
|
646
676
|
|
|
647
677
|
events?: MappedEvent<TEventPublisher, OutSchema>[];
|
|
678
|
+
/** Optional authorizer configuration */
|
|
679
|
+
authorizer?: Authorizer;
|
|
648
680
|
}
|
|
649
681
|
|
|
650
682
|
/**
|
|
@@ -780,24 +812,45 @@ export type EndpointHeaders = Map<string, string>;
|
|
|
780
812
|
|
|
781
813
|
/**
|
|
782
814
|
* Function type for retrieving HTTP header values.
|
|
815
|
+
* Supports two calling patterns:
|
|
816
|
+
* - `header(key)` - Get a single header value (case-insensitive)
|
|
817
|
+
* - `header()` - Get all headers as a plain object
|
|
783
818
|
*
|
|
784
|
-
* @
|
|
785
|
-
*
|
|
819
|
+
* @example
|
|
820
|
+
* ```typescript
|
|
821
|
+
* // Get single header
|
|
822
|
+
* const contentType = header('content-type');
|
|
823
|
+
*
|
|
824
|
+
* // Get all headers
|
|
825
|
+
* const allHeaders = header();
|
|
826
|
+
* // { 'content-type': 'application/json', 'host': 'example.com', ... }
|
|
827
|
+
* ```
|
|
786
828
|
*/
|
|
787
|
-
export
|
|
829
|
+
export interface HeaderFn {
|
|
830
|
+
(): Record<string, string>;
|
|
831
|
+
(key: string): string | undefined;
|
|
832
|
+
}
|
|
788
833
|
|
|
789
834
|
/**
|
|
790
835
|
* Function type for retrieving cookie values.
|
|
791
|
-
*
|
|
792
|
-
*
|
|
793
|
-
*
|
|
836
|
+
* Supports two calling patterns:
|
|
837
|
+
* - `cookie(name)` - Get a single cookie value
|
|
838
|
+
* - `cookie()` - Get all cookies as a plain object
|
|
794
839
|
*
|
|
795
840
|
* @example
|
|
796
841
|
* ```typescript
|
|
842
|
+
* // Get single cookie
|
|
797
843
|
* const sessionId = cookie('session');
|
|
844
|
+
*
|
|
845
|
+
* // Get all cookies
|
|
846
|
+
* const allCookies = cookie();
|
|
847
|
+
* // { session: 'abc123', theme: 'dark', ... }
|
|
798
848
|
* ```
|
|
799
849
|
*/
|
|
800
|
-
export
|
|
850
|
+
export interface CookieFn {
|
|
851
|
+
(): Record<string, string>;
|
|
852
|
+
(name: string): string | undefined;
|
|
853
|
+
}
|
|
801
854
|
|
|
802
855
|
/**
|
|
803
856
|
* Cookie options matching standard Set-Cookie attributes
|
|
@@ -3,6 +3,7 @@ import type { RateLimitConfig } from '@geekmidas/rate-limit';
|
|
|
3
3
|
import type { Service } from '@geekmidas/services';
|
|
4
4
|
import type { StandardSchemaV1 } from '@standard-schema/spec';
|
|
5
5
|
import uniqBy from 'lodash.uniqby';
|
|
6
|
+
import type { Authorizer } from './Authorizer';
|
|
6
7
|
import { ConstructType } from '../Construct';
|
|
7
8
|
import { BaseFunctionBuilder } from '../functions';
|
|
8
9
|
import { Endpoint, type EndpointSchemas } from './Endpoint';
|
|
@@ -26,6 +27,7 @@ export class EndpointBuilder<
|
|
|
26
27
|
TSession = unknown,
|
|
27
28
|
TEventPublisher extends EventPublisher<any> | undefined = undefined,
|
|
28
29
|
TEventPublisherServiceName extends string = string,
|
|
30
|
+
TAuthorizers extends readonly string[] = readonly string[],
|
|
29
31
|
> extends BaseFunctionBuilder<
|
|
30
32
|
TInput,
|
|
31
33
|
OutSchema,
|
|
@@ -38,9 +40,12 @@ export class EndpointBuilder<
|
|
|
38
40
|
protected _description?: string;
|
|
39
41
|
protected _status?: SuccessStatus;
|
|
40
42
|
protected _tags?: string[];
|
|
43
|
+
protected _memorySize?: number;
|
|
41
44
|
_getSession: SessionFn<TServices, TLogger, TSession> = () => ({}) as TSession;
|
|
42
45
|
_authorize: AuthorizeFn<TServices, TLogger, TSession> = () => true;
|
|
43
46
|
_rateLimit?: RateLimitConfig;
|
|
47
|
+
_availableAuthorizers: Authorizer[] = [];
|
|
48
|
+
_authorizerName?: TAuthorizers[number];
|
|
44
49
|
|
|
45
50
|
constructor(
|
|
46
51
|
readonly route: TRoute,
|
|
@@ -78,6 +83,11 @@ export class EndpointBuilder<
|
|
|
78
83
|
return this;
|
|
79
84
|
}
|
|
80
85
|
|
|
86
|
+
memorySize(memorySize: number): this {
|
|
87
|
+
this._memorySize = memorySize;
|
|
88
|
+
return this;
|
|
89
|
+
}
|
|
90
|
+
|
|
81
91
|
publisher<T extends EventPublisher<any>, TName extends string>(
|
|
82
92
|
publisher: Service<TName, T>,
|
|
83
93
|
): EndpointBuilder<
|
|
@@ -89,7 +99,8 @@ export class EndpointBuilder<
|
|
|
89
99
|
OutSchema,
|
|
90
100
|
TSession,
|
|
91
101
|
T,
|
|
92
|
-
TName
|
|
102
|
+
TName,
|
|
103
|
+
TAuthorizers
|
|
93
104
|
> {
|
|
94
105
|
this._publisher = publisher as unknown as Service<
|
|
95
106
|
TEventPublisherServiceName,
|
|
@@ -105,7 +116,8 @@ export class EndpointBuilder<
|
|
|
105
116
|
OutSchema,
|
|
106
117
|
TSession,
|
|
107
118
|
T,
|
|
108
|
-
TName
|
|
119
|
+
TName,
|
|
120
|
+
TAuthorizers
|
|
109
121
|
>;
|
|
110
122
|
}
|
|
111
123
|
|
|
@@ -119,7 +131,9 @@ export class EndpointBuilder<
|
|
|
119
131
|
TLogger,
|
|
120
132
|
OutSchema,
|
|
121
133
|
TSession,
|
|
122
|
-
TEventPublisher
|
|
134
|
+
TEventPublisher,
|
|
135
|
+
TEventPublisherServiceName,
|
|
136
|
+
TAuthorizers
|
|
123
137
|
> {
|
|
124
138
|
this.schemas.body = schema as unknown as T;
|
|
125
139
|
// @ts-ignore
|
|
@@ -136,7 +150,9 @@ export class EndpointBuilder<
|
|
|
136
150
|
TLogger,
|
|
137
151
|
OutSchema,
|
|
138
152
|
TSession,
|
|
139
|
-
TEventPublisher
|
|
153
|
+
TEventPublisher,
|
|
154
|
+
TEventPublisherServiceName,
|
|
155
|
+
TAuthorizers
|
|
140
156
|
> {
|
|
141
157
|
this.schemas.query = schema as unknown as T;
|
|
142
158
|
// @ts-ignore
|
|
@@ -153,7 +169,9 @@ export class EndpointBuilder<
|
|
|
153
169
|
TLogger,
|
|
154
170
|
OutSchema,
|
|
155
171
|
TSession,
|
|
156
|
-
TEventPublisher
|
|
172
|
+
TEventPublisher,
|
|
173
|
+
TEventPublisherServiceName,
|
|
174
|
+
TAuthorizers
|
|
157
175
|
> {
|
|
158
176
|
return this.search(schema);
|
|
159
177
|
}
|
|
@@ -168,7 +186,9 @@ export class EndpointBuilder<
|
|
|
168
186
|
TLogger,
|
|
169
187
|
OutSchema,
|
|
170
188
|
TSession,
|
|
171
|
-
TEventPublisher
|
|
189
|
+
TEventPublisher,
|
|
190
|
+
TEventPublisherServiceName,
|
|
191
|
+
TAuthorizers
|
|
172
192
|
> {
|
|
173
193
|
this.schemas.params = schema as unknown as T;
|
|
174
194
|
// @ts-ignore
|
|
@@ -180,6 +200,40 @@ export class EndpointBuilder<
|
|
|
180
200
|
return this;
|
|
181
201
|
}
|
|
182
202
|
|
|
203
|
+
authorizer(
|
|
204
|
+
name: TAuthorizers[number] | 'none',
|
|
205
|
+
): EndpointBuilder<
|
|
206
|
+
TRoute,
|
|
207
|
+
TMethod,
|
|
208
|
+
TInput,
|
|
209
|
+
TServices,
|
|
210
|
+
TLogger,
|
|
211
|
+
OutSchema,
|
|
212
|
+
TSession,
|
|
213
|
+
TEventPublisher,
|
|
214
|
+
TEventPublisherServiceName,
|
|
215
|
+
TAuthorizers
|
|
216
|
+
> {
|
|
217
|
+
// Special case: 'none' explicitly marks endpoint as having no authorizer
|
|
218
|
+
if (name === 'none') {
|
|
219
|
+
this._authorizerName = undefined;
|
|
220
|
+
return this;
|
|
221
|
+
}
|
|
222
|
+
|
|
223
|
+
// Validate that the authorizer exists in available authorizers
|
|
224
|
+
const authorizerExists = this._availableAuthorizers.some(
|
|
225
|
+
(a) => a.name === name,
|
|
226
|
+
);
|
|
227
|
+
if (!authorizerExists && this._availableAuthorizers.length > 0) {
|
|
228
|
+
const available = this._availableAuthorizers.map((a) => a.name).join(', ');
|
|
229
|
+
throw new Error(
|
|
230
|
+
`Authorizer "${name as string}" not found in available authorizers: ${available}`,
|
|
231
|
+
);
|
|
232
|
+
}
|
|
233
|
+
this._authorizerName = name;
|
|
234
|
+
return this;
|
|
235
|
+
}
|
|
236
|
+
|
|
183
237
|
services<T extends Service[]>(
|
|
184
238
|
services: T,
|
|
185
239
|
): EndpointBuilder<
|
|
@@ -191,7 +245,8 @@ export class EndpointBuilder<
|
|
|
191
245
|
OutSchema,
|
|
192
246
|
TSession,
|
|
193
247
|
TEventPublisher,
|
|
194
|
-
TEventPublisherServiceName
|
|
248
|
+
TEventPublisherServiceName,
|
|
249
|
+
TAuthorizers
|
|
195
250
|
> {
|
|
196
251
|
this._services = uniqBy(
|
|
197
252
|
[...this._services, ...services],
|
|
@@ -207,7 +262,8 @@ export class EndpointBuilder<
|
|
|
207
262
|
OutSchema,
|
|
208
263
|
TSession,
|
|
209
264
|
TEventPublisher,
|
|
210
|
-
TEventPublisherServiceName
|
|
265
|
+
TEventPublisherServiceName,
|
|
266
|
+
TAuthorizers
|
|
211
267
|
>;
|
|
212
268
|
}
|
|
213
269
|
|
|
@@ -222,7 +278,8 @@ export class EndpointBuilder<
|
|
|
222
278
|
OutSchema,
|
|
223
279
|
TSession,
|
|
224
280
|
TEventPublisher,
|
|
225
|
-
TEventPublisherServiceName
|
|
281
|
+
TEventPublisherServiceName,
|
|
282
|
+
TAuthorizers
|
|
226
283
|
> {
|
|
227
284
|
this._logger = logger as unknown as TLogger;
|
|
228
285
|
|
|
@@ -235,7 +292,8 @@ export class EndpointBuilder<
|
|
|
235
292
|
OutSchema,
|
|
236
293
|
TSession,
|
|
237
294
|
TEventPublisher,
|
|
238
|
-
TEventPublisherServiceName
|
|
295
|
+
TEventPublisherServiceName,
|
|
296
|
+
TAuthorizers
|
|
239
297
|
>;
|
|
240
298
|
}
|
|
241
299
|
|
|
@@ -250,7 +308,8 @@ export class EndpointBuilder<
|
|
|
250
308
|
T,
|
|
251
309
|
TSession,
|
|
252
310
|
TEventPublisher,
|
|
253
|
-
TEventPublisherServiceName
|
|
311
|
+
TEventPublisherServiceName,
|
|
312
|
+
TAuthorizers
|
|
254
313
|
> {
|
|
255
314
|
this.outputSchema = schema as unknown as OutSchema;
|
|
256
315
|
|
|
@@ -263,7 +322,8 @@ export class EndpointBuilder<
|
|
|
263
322
|
T,
|
|
264
323
|
TSession,
|
|
265
324
|
TEventPublisher,
|
|
266
|
-
TEventPublisherServiceName
|
|
325
|
+
TEventPublisherServiceName,
|
|
326
|
+
TAuthorizers
|
|
267
327
|
>;
|
|
268
328
|
}
|
|
269
329
|
|
|
@@ -286,6 +346,11 @@ export class EndpointBuilder<
|
|
|
286
346
|
TSession,
|
|
287
347
|
TEventPublisher
|
|
288
348
|
> {
|
|
349
|
+
// Find authorizer metadata if name is set
|
|
350
|
+
const authorizer = this._authorizerName
|
|
351
|
+
? this._availableAuthorizers.find((a) => a.name === this._authorizerName)
|
|
352
|
+
: undefined;
|
|
353
|
+
|
|
289
354
|
return new Endpoint({
|
|
290
355
|
fn,
|
|
291
356
|
method: this.method,
|
|
@@ -297,12 +362,14 @@ export class EndpointBuilder<
|
|
|
297
362
|
services: this._services,
|
|
298
363
|
logger: this._logger,
|
|
299
364
|
timeout: this._timeout,
|
|
365
|
+
memorySize: this._memorySize,
|
|
300
366
|
authorize: this._authorize,
|
|
301
367
|
status: this._status,
|
|
302
368
|
getSession: this._getSession,
|
|
303
369
|
rateLimit: this._rateLimit,
|
|
304
370
|
publisherService: this._publisher,
|
|
305
371
|
events: this._events,
|
|
372
|
+
authorizer,
|
|
306
373
|
});
|
|
307
374
|
}
|
|
308
375
|
}
|