@geekmidas/constructs 0.0.10 → 0.0.12
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-DhUb-Vs6.cjs → AWSLambdaFunction-DMxScuaw.cjs} +3 -3
- package/dist/{AWSLambdaFunction-DhUb-Vs6.cjs.map → AWSLambdaFunction-DMxScuaw.cjs.map} +1 -1
- package/dist/{AWSLambdaFunction-D5V3YVqv.d.cts → AWSLambdaFunction-DSB2oaFG.d.mts} +5 -5
- package/dist/{AWSLambdaFunction-D_V-ZQmS.mjs → AWSLambdaFunction-cL8A169J.mjs} +3 -3
- package/dist/{AWSLambdaFunction-D_V-ZQmS.mjs.map → AWSLambdaFunction-cL8A169J.mjs.map} +1 -1
- package/dist/{AWSLambdaFunction-DvZcnL8a.d.mts → AWSLambdaFunction-t6q2o8EL.d.cts} +5 -5
- package/dist/{AWSLambdaSubscriberAdaptor-J_pSz6pu.d.cts → AWSLambdaSubscriberAdaptor-Cknp_nn1.d.cts} +2 -2
- package/dist/{AWSLambdaSubscriberAdaptor-G8y3YkWj.mjs → AWSLambdaSubscriberAdaptor-CyFh7MN8.mjs} +1 -1
- package/dist/{AWSLambdaSubscriberAdaptor-G8y3YkWj.mjs.map → AWSLambdaSubscriberAdaptor-CyFh7MN8.mjs.map} +1 -1
- package/dist/{AWSLambdaSubscriberAdaptor-D6kjKjSf.d.mts → AWSLambdaSubscriberAdaptor-DpHzp-AM.d.mts} +2 -2
- package/dist/{AWSLambdaSubscriberAdaptor-CmPZ10JF.cjs → AWSLambdaSubscriberAdaptor-Dum5bkw3.cjs} +1 -1
- package/dist/{AWSLambdaSubscriberAdaptor-CmPZ10JF.cjs.map → AWSLambdaSubscriberAdaptor-Dum5bkw3.cjs.map} +1 -1
- package/dist/{AmazonApiGatewayEndpointAdaptor-DHcUetbw.mjs → AmazonApiGatewayEndpointAdaptor-CIEhW1TQ.mjs} +47 -16
- package/dist/AmazonApiGatewayEndpointAdaptor-CIEhW1TQ.mjs.map +1 -0
- package/dist/{AmazonApiGatewayEndpointAdaptor-BnNd8tCz.d.cts → AmazonApiGatewayEndpointAdaptor-CwItKPz2.d.cts} +6 -5
- package/dist/{AmazonApiGatewayEndpointAdaptor-DHBF_5jn.cjs → AmazonApiGatewayEndpointAdaptor-H8YvtfQm.cjs} +47 -16
- package/dist/AmazonApiGatewayEndpointAdaptor-H8YvtfQm.cjs.map +1 -0
- package/dist/{AmazonApiGatewayEndpointAdaptor-B7MKo8h3.d.mts → AmazonApiGatewayEndpointAdaptor-eDQgPNLH.d.mts} +7 -6
- package/dist/{AmazonApiGatewayV1EndpointAdaptor-CmUxFoPx.cjs → AmazonApiGatewayV1EndpointAdaptor-0n71d3gq.cjs} +3 -3
- package/dist/{AmazonApiGatewayV1EndpointAdaptor-CmUxFoPx.cjs.map → AmazonApiGatewayV1EndpointAdaptor-0n71d3gq.cjs.map} +1 -1
- package/dist/{AmazonApiGatewayV1EndpointAdaptor-CsV6zyvn.mjs → AmazonApiGatewayV1EndpointAdaptor-B36zXLJ7.mjs} +3 -3
- package/dist/{AmazonApiGatewayV1EndpointAdaptor-CsV6zyvn.mjs.map → AmazonApiGatewayV1EndpointAdaptor-B36zXLJ7.mjs.map} +1 -1
- package/dist/{AmazonApiGatewayV1EndpointAdaptor-gO9OxdZl.d.mts → AmazonApiGatewayV1EndpointAdaptor-CnGVpA38.d.mts} +4 -4
- package/dist/{AmazonApiGatewayV1EndpointAdaptor-BC-a2tt3.d.cts → AmazonApiGatewayV1EndpointAdaptor-DaCvUL6y.d.cts} +3 -3
- package/dist/{AmazonApiGatewayV2EndpointAdaptor-D1uz4wNg.d.mts → AmazonApiGatewayV2EndpointAdaptor-BELz2ijs.d.mts} +4 -4
- package/dist/{AmazonApiGatewayV2EndpointAdaptor-_bFcbEa-.mjs → AmazonApiGatewayV2EndpointAdaptor-CE3wZEb8.mjs} +3 -3
- package/dist/{AmazonApiGatewayV2EndpointAdaptor-_bFcbEa-.mjs.map → AmazonApiGatewayV2EndpointAdaptor-CE3wZEb8.mjs.map} +1 -1
- package/dist/{AmazonApiGatewayV2EndpointAdaptor-zNFUPxSY.d.cts → AmazonApiGatewayV2EndpointAdaptor-DA1PH0nc.d.cts} +3 -3
- package/dist/{AmazonApiGatewayV2EndpointAdaptor-cZbaqiUi.cjs → AmazonApiGatewayV2EndpointAdaptor-DtU3Cb8F.cjs} +3 -3
- package/dist/{AmazonApiGatewayV2EndpointAdaptor-cZbaqiUi.cjs.map → AmazonApiGatewayV2EndpointAdaptor-DtU3Cb8F.cjs.map} +1 -1
- package/dist/{Authorizer-Bbk9ziuG.d.mts → Authorizer-BRCVPz_O.d.mts} +1 -1
- package/dist/{Authorizer-iXsSB600.d.cts → Authorizer-DG54w1m2.d.cts} +1 -1
- package/dist/{BaseFunctionBuilder-BmsbV0BU.cjs → BaseFunctionBuilder-B8rT07QR.cjs} +7 -2
- package/dist/BaseFunctionBuilder-B8rT07QR.cjs.map +1 -0
- package/dist/{BaseFunctionBuilder-DCUtCdVL.mjs → BaseFunctionBuilder-CT7p10K1.mjs} +7 -2
- package/dist/BaseFunctionBuilder-CT7p10K1.mjs.map +1 -0
- package/dist/{BaseFunctionBuilder-C4ZJPkIZ.d.cts → BaseFunctionBuilder-Cf0op65o.d.cts} +7 -4
- package/dist/{BaseFunctionBuilder-CxBX0arJ.d.mts → BaseFunctionBuilder-DilipY1y.d.mts} +7 -4
- package/dist/{Construct-VEI7M3fs.cjs → Construct-BYSPikVm.cjs} +28 -10
- package/dist/Construct-BYSPikVm.cjs.map +1 -0
- package/dist/{Construct-C3hsQBy4.mjs → Construct-LWeB1rSQ.mjs} +28 -10
- package/dist/Construct-LWeB1rSQ.mjs.map +1 -0
- package/dist/{Construct-ci5u8Xnu.d.cts → Construct-ZPqE0vhn.d.mts} +9 -4
- package/dist/{Construct-zhmcmIdY.d.mts → Construct-dI_rgdSp.d.cts} +9 -4
- 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-ByNYsQDH.d.mts → Cron-6lOgKqSA.d.cts} +3 -3
- package/dist/{Cron-DkPL-Fms.d.cts → Cron-BH_07atD.d.mts} +3 -3
- package/dist/{Cron-Dfgr8F9d.cjs → Cron-Bnd-2pgE.cjs} +3 -3
- package/dist/{Cron-Dfgr8F9d.cjs.map → Cron-Bnd-2pgE.cjs.map} +1 -1
- package/dist/{Cron-wP6Ob48_.mjs → Cron-DNRjf2cp.mjs} +3 -3
- package/dist/{Cron-wP6Ob48_.mjs.map → Cron-DNRjf2cp.mjs.map} +1 -1
- package/dist/{CronBuilder-BknVTWLE.d.mts → CronBuilder-5oK2AL2n.d.cts} +5 -5
- package/dist/{CronBuilder-BqTTozUi.d.cts → CronBuilder-D2b4zY4l.d.mts} +5 -5
- package/dist/{CronBuilder-C27c5oqh.mjs → CronBuilder-DdR2TuQa.mjs} +5 -5
- package/dist/{CronBuilder-C27c5oqh.mjs.map → CronBuilder-DdR2TuQa.mjs.map} +1 -1
- package/dist/{CronBuilder-W1ZqCJ7m.cjs → CronBuilder-dtw4ZyH6.cjs} +5 -5
- package/dist/{CronBuilder-W1ZqCJ7m.cjs.map → CronBuilder-dtw4ZyH6.cjs.map} +1 -1
- package/dist/{Endpoint-C98BwZjA.mjs → Endpoint-B69TqESg.mjs} +15 -8
- package/dist/Endpoint-B69TqESg.mjs.map +1 -0
- package/dist/{Endpoint-BjpQmTek.cjs → Endpoint-B9PryZES.cjs} +15 -8
- package/dist/Endpoint-B9PryZES.cjs.map +1 -0
- package/dist/{Endpoint-zHPjZ35J.d.cts → Endpoint-Cs-MsYlY.d.cts} +80 -12
- package/dist/{Endpoint-C16whGI-.d.mts → Endpoint-DuZlyjd4.d.mts} +80 -12
- package/dist/EndpointBuilder-BrB-K1jO.d.mts +86 -0
- package/dist/EndpointBuilder-C-PHInEW.d.cts +86 -0
- package/dist/{EndpointBuilder-CCUx4vep.mjs → EndpointBuilder-DnVL-EU_.mjs} +47 -5
- package/dist/EndpointBuilder-DnVL-EU_.mjs.map +1 -0
- package/dist/{EndpointBuilder-D2Zu8i9b.cjs → EndpointBuilder-DofwCnWJ.cjs} +47 -5
- package/dist/EndpointBuilder-DofwCnWJ.cjs.map +1 -0
- package/dist/{EndpointFactory-KkyIOE62.d.cts → EndpointFactory-6zNpVSYp.d.mts} +12 -11
- package/dist/{EndpointFactory-C4YhgXOc.cjs → EndpointFactory-Ba9mx9MU.cjs} +3 -3
- package/dist/{EndpointFactory-C4YhgXOc.cjs.map → EndpointFactory-Ba9mx9MU.cjs.map} +1 -1
- package/dist/{EndpointFactory-VnSAdwdv.d.mts → EndpointFactory-e5WYVR6t.d.cts} +12 -11
- package/dist/{EndpointFactory-RAb2zcw0.mjs → EndpointFactory-pPaIGFHV.mjs} +3 -3
- package/dist/{EndpointFactory-RAb2zcw0.mjs.map → EndpointFactory-pPaIGFHV.mjs.map} +1 -1
- package/dist/{Function-BbLYIKLL.d.cts → Function-6EWabl_X.d.cts} +5 -4
- package/dist/{Function-1Fh6Tdkg.cjs → Function-CO-s2pB8.cjs} +6 -6
- package/dist/Function-CO-s2pB8.cjs.map +1 -0
- package/dist/{Function-D-QEfH7k.mjs → Function-COnc-tWM.mjs} +6 -6
- package/dist/Function-COnc-tWM.mjs.map +1 -0
- package/dist/{Function-DFRZZCC-.d.mts → Function-G3JPHMaY.d.mts} +5 -4
- package/dist/{FunctionBuilder-DdGjpiFT.d.cts → FunctionBuilder-B3fpp3hA.d.cts} +13 -11
- package/dist/{FunctionBuilder-DuktGyZc.d.mts → FunctionBuilder-ByaB_LQ4.d.mts} +13 -11
- package/dist/{FunctionBuilder-Bxyr1Pf9.mjs → FunctionBuilder-CMhLQ4dt.mjs} +11 -6
- package/dist/FunctionBuilder-CMhLQ4dt.mjs.map +1 -0
- package/dist/{FunctionBuilder-DcEFYgbn.cjs → FunctionBuilder-_hMwZUof.cjs} +11 -6
- package/dist/FunctionBuilder-_hMwZUof.cjs.map +1 -0
- package/dist/{FunctionExecutionWrapper-CRYi047B.d.cts → FunctionExecutionWrapper-Ci-ookJG.d.cts} +2 -2
- package/dist/{FunctionExecutionWrapper-DaR-dSLw.d.mts → FunctionExecutionWrapper-DHFMLrOl.d.mts} +2 -2
- package/dist/{FunctionExecutionWrapper-BL6PE6Dv.mjs → FunctionExecutionWrapper-i9v5L3Av.mjs} +2 -2
- package/dist/{FunctionExecutionWrapper-BL6PE6Dv.mjs.map → FunctionExecutionWrapper-i9v5L3Av.mjs.map} +1 -1
- package/dist/{FunctionExecutionWrapper-Ee-CE8Fz.cjs → FunctionExecutionWrapper-sxJNTpuc.cjs} +2 -2
- package/dist/{FunctionExecutionWrapper-Ee-CE8Fz.cjs.map → FunctionExecutionWrapper-sxJNTpuc.cjs.map} +1 -1
- package/dist/{HonoEndpointAdaptor-CY1mXTe6.d.mts → HonoEndpointAdaptor-BElil8O5.d.mts} +9 -8
- package/dist/{HonoEndpointAdaptor-DcvZdYzx.cjs → HonoEndpointAdaptor-Cw2if5cG.cjs} +51 -20
- package/dist/HonoEndpointAdaptor-Cw2if5cG.cjs.map +1 -0
- package/dist/{HonoEndpointAdaptor-CyVPl4w2.mjs → HonoEndpointAdaptor-DAfnTFVS.mjs} +51 -20
- package/dist/HonoEndpointAdaptor-DAfnTFVS.mjs.map +1 -0
- package/dist/{HonoEndpointAdaptor-CYvrXBe-.d.cts → HonoEndpointAdaptor-DSHl8ZCY.d.cts} +8 -7
- package/dist/{Subscriber-Cy28j8MS.d.cts → Subscriber-BhzqUzs-.d.cts} +2 -2
- package/dist/{Subscriber-CTczVFsF.mjs → Subscriber-CGb8LjZa.mjs} +2 -2
- package/dist/{Subscriber-CTczVFsF.mjs.map → Subscriber-CGb8LjZa.mjs.map} +1 -1
- package/dist/{Subscriber-BL30GpWp.cjs → Subscriber-D-FPWts6.cjs} +2 -2
- package/dist/{Subscriber-BL30GpWp.cjs.map → Subscriber-D-FPWts6.cjs.map} +1 -1
- package/dist/{Subscriber-g3IWM1_d.d.mts → Subscriber-s6yfjeOc.d.mts} +2 -2
- package/dist/{SubscriberBuilder-BzK8kc2a.d.cts → SubscriberBuilder-BCVkp-ga.d.cts} +2 -2
- package/dist/{SubscriberBuilder-CekL3BoP.mjs → SubscriberBuilder-BcAspHv9.mjs} +2 -2
- package/dist/{SubscriberBuilder-CekL3BoP.mjs.map → SubscriberBuilder-BcAspHv9.mjs.map} +1 -1
- package/dist/{SubscriberBuilder-D1hojYLa.cjs → SubscriberBuilder-BfE2cL1q.cjs} +2 -2
- package/dist/{SubscriberBuilder-D1hojYLa.cjs.map → SubscriberBuilder-BfE2cL1q.cjs.map} +1 -1
- package/dist/{SubscriberBuilder-YjQ7qIpQ.d.mts → SubscriberBuilder-aCua5_wA.d.mts} +2 -2
- package/dist/{TestEndpointAdaptor-C-ahwGW6.cjs → TestEndpointAdaptor-Bn1WRFph.cjs} +47 -18
- package/dist/TestEndpointAdaptor-Bn1WRFph.cjs.map +1 -0
- package/dist/{TestEndpointAdaptor-DGWuai69.d.mts → TestEndpointAdaptor-DnlAA_rm.d.mts} +7 -6
- package/dist/{TestEndpointAdaptor-B4z9G5Ap.mjs → TestEndpointAdaptor-DubQOJk_.mjs} +47 -18
- package/dist/TestEndpointAdaptor-DubQOJk_.mjs.map +1 -0
- package/dist/{TestEndpointAdaptor-uXliWYjS.d.cts → TestEndpointAdaptor-o-xtSyQ3.d.cts} +6 -5
- package/dist/adaptors/aws.cjs +14 -13
- package/dist/adaptors/aws.d.cts +14 -14
- package/dist/adaptors/aws.d.mts +15 -15
- package/dist/adaptors/aws.mjs +14 -13
- package/dist/adaptors/hono.cjs +10 -9
- package/dist/adaptors/hono.d.cts +8 -8
- package/dist/adaptors/hono.d.mts +9 -9
- package/dist/adaptors/hono.mjs +10 -9
- package/dist/adaptors/testing.cjs +8 -7
- package/dist/adaptors/testing.d.cts +8 -8
- package/dist/adaptors/testing.d.mts +9 -9
- package/dist/adaptors/testing.mjs +8 -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 +8 -7
- package/dist/endpoints/AmazonApiGatewayEndpointAdaptor.d.cts +8 -8
- package/dist/endpoints/AmazonApiGatewayEndpointAdaptor.d.mts +9 -9
- package/dist/endpoints/AmazonApiGatewayEndpointAdaptor.mjs +8 -7
- package/dist/endpoints/AmazonApiGatewayV1EndpointAdaptor.cjs +10 -9
- package/dist/endpoints/AmazonApiGatewayV1EndpointAdaptor.d.cts +9 -9
- package/dist/endpoints/AmazonApiGatewayV1EndpointAdaptor.d.mts +10 -10
- package/dist/endpoints/AmazonApiGatewayV1EndpointAdaptor.mjs +10 -9
- package/dist/endpoints/AmazonApiGatewayV2EndpointAdaptor.cjs +10 -9
- package/dist/endpoints/AmazonApiGatewayV2EndpointAdaptor.d.cts +9 -9
- package/dist/endpoints/AmazonApiGatewayV2EndpointAdaptor.d.mts +10 -10
- package/dist/endpoints/AmazonApiGatewayV2EndpointAdaptor.mjs +10 -9
- package/dist/endpoints/Authorizer.d.cts +1 -1
- package/dist/endpoints/Authorizer.d.mts +1 -1
- package/dist/endpoints/Endpoint.cjs +6 -6
- package/dist/endpoints/Endpoint.d.cts +7 -7
- package/dist/endpoints/Endpoint.d.mts +8 -8
- package/dist/endpoints/Endpoint.mjs +6 -6
- package/dist/endpoints/EndpointBuilder.cjs +7 -7
- package/dist/endpoints/EndpointBuilder.d.cts +8 -8
- package/dist/endpoints/EndpointBuilder.d.mts +9 -9
- package/dist/endpoints/EndpointBuilder.mjs +7 -7
- package/dist/endpoints/EndpointFactory.cjs +8 -8
- package/dist/endpoints/EndpointFactory.d.cts +9 -9
- package/dist/endpoints/EndpointFactory.d.mts +10 -10
- package/dist/endpoints/EndpointFactory.mjs +8 -8
- package/dist/endpoints/HonoEndpointAdaptor.cjs +10 -9
- package/dist/endpoints/HonoEndpointAdaptor.d.cts +8 -8
- package/dist/endpoints/HonoEndpointAdaptor.d.mts +9 -9
- package/dist/endpoints/HonoEndpointAdaptor.mjs +10 -9
- package/dist/endpoints/TestEndpointAdaptor.cjs +8 -7
- package/dist/endpoints/TestEndpointAdaptor.d.cts +8 -8
- package/dist/endpoints/TestEndpointAdaptor.d.mts +9 -9
- package/dist/endpoints/TestEndpointAdaptor.mjs +8 -7
- package/dist/endpoints/audit.cjs +0 -0
- package/dist/endpoints/audit.d.cts +9 -0
- package/dist/endpoints/audit.d.mts +9 -0
- package/dist/endpoints/audit.mjs +0 -0
- package/dist/endpoints/helpers.cjs +7 -7
- package/dist/endpoints/helpers.d.cts +7 -7
- package/dist/endpoints/helpers.d.mts +8 -8
- package/dist/endpoints/helpers.mjs +7 -7
- package/dist/endpoints/index.cjs +8 -8
- package/dist/endpoints/index.cjs.map +1 -1
- package/dist/endpoints/index.d.cts +12 -12
- package/dist/endpoints/index.d.mts +13 -13
- package/dist/endpoints/index.mjs +8 -8
- package/dist/endpoints/index.mjs.map +1 -1
- package/dist/endpoints/parseHonoQuery.cjs +1 -1
- package/dist/endpoints/parseHonoQuery.mjs +1 -1
- package/dist/endpoints/parseQueryParams.cjs +1 -1
- package/dist/endpoints/parseQueryParams.mjs +1 -1
- package/dist/endpoints/processAudits.cjs +5 -0
- package/dist/endpoints/processAudits.d.cts +74 -0
- package/dist/endpoints/processAudits.d.mts +74 -0
- package/dist/endpoints/processAudits.mjs +3 -0
- 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 +4 -4
- package/dist/functions/TestFunctionAdaptor.d.cts +2 -2
- package/dist/functions/TestFunctionAdaptor.d.mts +2 -2
- package/dist/functions/TestFunctionAdaptor.mjs +4 -4
- 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-BYqZAob8.mjs +8 -0
- package/dist/{functions-DD-00sWF.mjs.map → functions-BYqZAob8.mjs.map} +1 -1
- package/dist/{functions-BtgBiuC_.cjs → functions-D03lqK-r.cjs} +2 -2
- package/dist/{functions-BtgBiuC_.cjs.map → functions-D03lqK-r.cjs.map} +1 -1
- package/dist/{helpers-QM_FSjPY.cjs → helpers-BApRyhly.cjs} +2 -2
- package/dist/{helpers-QM_FSjPY.cjs.map → helpers-BApRyhly.cjs.map} +1 -1
- package/dist/{helpers-DtPeOhUV.mjs → helpers-BPDogwac.mjs} +2 -2
- package/dist/{helpers-DtPeOhUV.mjs.map → helpers-BPDogwac.mjs.map} +1 -1
- package/dist/index-CUg_hSq-.d.cts +9 -0
- package/dist/index-D-a7e2gv.d.mts +9 -0
- package/dist/index.cjs +1 -1
- package/dist/index.d.cts +1 -1
- package/dist/index.d.mts +2 -2
- package/dist/index.mjs +1 -1
- package/dist/{parseHonoQuery-DopC24vB.cjs → parseHonoQuery-CT8Cvin-.cjs} +1 -1
- package/dist/{parseHonoQuery-DopC24vB.cjs.map → parseHonoQuery-CT8Cvin-.cjs.map} +1 -1
- package/dist/{parseHonoQuery-znDKBhdE.mjs → parseHonoQuery-CwFKw2ua.mjs} +1 -1
- package/dist/{parseHonoQuery-znDKBhdE.mjs.map → parseHonoQuery-CwFKw2ua.mjs.map} +1 -1
- package/dist/{parseQueryParams-BJaRh3OB.mjs → parseQueryParams-CHINupbZ.mjs} +1 -1
- package/dist/{parseQueryParams-BJaRh3OB.mjs.map → parseQueryParams-CHINupbZ.mjs.map} +1 -1
- package/dist/{parseQueryParams-BzPop4I1.cjs → parseQueryParams-CwvXXwkW.cjs} +1 -1
- package/dist/{parseQueryParams-BzPop4I1.cjs.map → parseQueryParams-CwvXXwkW.cjs.map} +1 -1
- package/dist/processAudits-BFokHhCO.cjs +174 -0
- package/dist/processAudits-BFokHhCO.cjs.map +1 -0
- package/dist/processAudits-DfcB-X-4.mjs +156 -0
- package/dist/processAudits-DfcB-X-4.mjs.map +1 -0
- package/dist/publisher.d.cts +1 -1
- package/dist/publisher.d.mts +1 -1
- package/dist/subscribers/AWSLambdaSubscriberAdaptor.cjs +1 -1
- package/dist/subscribers/AWSLambdaSubscriberAdaptor.d.cts +3 -3
- package/dist/subscribers/AWSLambdaSubscriberAdaptor.d.mts +3 -3
- package/dist/subscribers/AWSLambdaSubscriberAdaptor.mjs +1 -1
- 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/dist/{types-CVq20-fE.d.mts → types-DKf0juBf.d.mts} +1 -1
- package/dist/types.d.mts +1 -1
- package/package.json +14 -10
- package/src/Construct.ts +31 -5
- package/src/endpoints/AmazonApiGatewayEndpointAdaptor.ts +88 -19
- package/src/endpoints/Endpoint.ts +66 -13
- package/src/endpoints/EndpointBuilder.ts +183 -19
- package/src/endpoints/HonoEndpointAdaptor.ts +114 -33
- package/src/endpoints/TestEndpointAdaptor.ts +96 -21
- package/src/endpoints/__tests__/AmazonApiGatewayV1EndpointAdaptor.events.spec.ts +8 -0
- package/src/endpoints/__tests__/AmazonApiGatewayV1EndpointAdaptor.spec.ts +29 -0
- package/src/endpoints/__tests__/AmazonApiGatewayV2EndpointAdaptor.audits.spec.ts +626 -0
- package/src/endpoints/__tests__/AmazonApiGatewayV2EndpointAdaptor.events.spec.ts +9 -0
- package/src/endpoints/__tests__/AmazonApiGatewayV2EndpointAdaptor.kysely-audit.integration.spec.ts +718 -0
- package/src/endpoints/__tests__/Endpoint.spec.ts +19 -0
- package/src/endpoints/__tests__/EndpointBuilder.audit.spec.ts +424 -0
- package/src/endpoints/__tests__/HonoEndpointAdaptor.audit-transactions.spec.ts +685 -0
- package/src/endpoints/__tests__/HonoEndpointAdaptor.audits.spec.ts +632 -0
- package/src/endpoints/__tests__/HonoEndpointAdaptor.events.spec.ts +8 -0
- package/src/endpoints/__tests__/HonoEndpointAdaptor.kysely-audit.integration.spec.ts +678 -0
- package/src/endpoints/__tests__/HonoEndpointAdaptor.openapi.spec.ts +4 -0
- package/src/endpoints/__tests__/HonoEndpointAdaptor.spec.ts +25 -0
- package/src/endpoints/audit.ts +87 -0
- package/src/endpoints/index.ts +1 -0
- package/src/endpoints/processAudits.ts +339 -0
- package/src/functions/BaseFunctionBuilder.ts +50 -7
- package/src/functions/Function.ts +13 -9
- package/src/functions/FunctionBuilder.ts +78 -14
- package/src/functions/__tests__/FunctionBuilder.state-isolation.spec.ts +43 -2
- package/dist/AmazonApiGatewayEndpointAdaptor-DHBF_5jn.cjs.map +0 -1
- package/dist/AmazonApiGatewayEndpointAdaptor-DHcUetbw.mjs.map +0 -1
- package/dist/BaseFunctionBuilder-BmsbV0BU.cjs.map +0 -1
- package/dist/BaseFunctionBuilder-DCUtCdVL.mjs.map +0 -1
- package/dist/Construct-C3hsQBy4.mjs.map +0 -1
- package/dist/Construct-VEI7M3fs.cjs.map +0 -1
- package/dist/Endpoint-BjpQmTek.cjs.map +0 -1
- package/dist/Endpoint-C98BwZjA.mjs.map +0 -1
- package/dist/EndpointBuilder-B5l7zQU1.d.cts +0 -55
- package/dist/EndpointBuilder-BzqR0xvt.d.mts +0 -55
- package/dist/EndpointBuilder-CCUx4vep.mjs.map +0 -1
- package/dist/EndpointBuilder-D2Zu8i9b.cjs.map +0 -1
- package/dist/Function-1Fh6Tdkg.cjs.map +0 -1
- package/dist/Function-D-QEfH7k.mjs.map +0 -1
- package/dist/FunctionBuilder-Bxyr1Pf9.mjs.map +0 -1
- package/dist/FunctionBuilder-DcEFYgbn.cjs.map +0 -1
- package/dist/HonoEndpointAdaptor-CyVPl4w2.mjs.map +0 -1
- package/dist/HonoEndpointAdaptor-DcvZdYzx.cjs.map +0 -1
- package/dist/TestEndpointAdaptor-B4z9G5Ap.mjs.map +0 -1
- package/dist/TestEndpointAdaptor-C-ahwGW6.cjs.map +0 -1
- package/dist/functions-DD-00sWF.mjs +0 -8
- package/dist/index-CcmV3PKF.d.cts +0 -9
- package/dist/index-DQt3pQtF.d.mts +0 -9
|
@@ -0,0 +1,74 @@
|
|
|
1
|
+
import "../Construct-ZPqE0vhn.mjs";
|
|
2
|
+
import "../types-DKf0juBf.mjs";
|
|
3
|
+
import "../Function-G3JPHMaY.mjs";
|
|
4
|
+
import "../BaseFunctionBuilder-DilipY1y.mjs";
|
|
5
|
+
import "../FunctionBuilder-ByaB_LQ4.mjs";
|
|
6
|
+
import "../index-D-a7e2gv.mjs";
|
|
7
|
+
import { CookieFn, Endpoint, HeaderFn } from "../Endpoint-DuZlyjd4.mjs";
|
|
8
|
+
import "../Authorizer-BRCVPz_O.mjs";
|
|
9
|
+
import { Service, ServiceDiscovery } from "@geekmidas/services";
|
|
10
|
+
import { AuditStorage, AuditableAction, Auditor } from "@geekmidas/audit";
|
|
11
|
+
import { Logger } from "@geekmidas/logger";
|
|
12
|
+
import { StandardSchemaV1 } from "@standard-schema/spec";
|
|
13
|
+
import { InferStandardSchema } from "@geekmidas/schema";
|
|
14
|
+
|
|
15
|
+
//#region src/endpoints/processAudits.d.ts
|
|
16
|
+
|
|
17
|
+
/**
|
|
18
|
+
* Process declarative audit definitions after successful endpoint execution.
|
|
19
|
+
* Similar to publishConstructEvents for events.
|
|
20
|
+
*
|
|
21
|
+
* @param endpoint - The endpoint with audit configuration
|
|
22
|
+
* @param response - The handler response to generate audit payloads from
|
|
23
|
+
* @param serviceDiscovery - Service discovery for registering audit storage
|
|
24
|
+
* @param logger - Logger for debug/error messages
|
|
25
|
+
* @param ctx - Request context (session, headers, cookies, services)
|
|
26
|
+
* @param existingAuditor - Optional existing auditor instance (e.g., from handler context).
|
|
27
|
+
* If provided, uses this auditor (with its stored transaction).
|
|
28
|
+
* If not provided, creates a new auditor.
|
|
29
|
+
*/
|
|
30
|
+
declare function processEndpointAudits<TServices extends Service[] = [], TSession = unknown, TLogger extends Logger = Logger, OutSchema extends StandardSchemaV1 | undefined = undefined, TAuditStorage extends AuditStorage | undefined = undefined, TAuditStorageServiceName extends string = string, TAuditAction extends AuditableAction<string, unknown> = AuditableAction<string, unknown>>(endpoint: Endpoint<any, any, any, OutSchema, TServices, TLogger, TSession, any, any, TAuditStorage, TAuditStorageServiceName, TAuditAction>, response: InferStandardSchema<OutSchema>, serviceDiscovery: ServiceDiscovery<any, any>, logger: TLogger, ctx: {
|
|
31
|
+
session: TSession;
|
|
32
|
+
header: HeaderFn;
|
|
33
|
+
cookie: CookieFn;
|
|
34
|
+
services: Record<string, unknown>;
|
|
35
|
+
}, existingAuditor?: Auditor<TAuditAction>): Promise<void>;
|
|
36
|
+
/**
|
|
37
|
+
* Context for audit-aware handler execution.
|
|
38
|
+
*/
|
|
39
|
+
interface AuditExecutionContext<TAuditAction extends AuditableAction<string, unknown> = AuditableAction<string, unknown>> {
|
|
40
|
+
/** The auditor instance for recording audits */
|
|
41
|
+
auditor: Auditor<TAuditAction>;
|
|
42
|
+
/** The audit storage instance */
|
|
43
|
+
storage: AuditStorage;
|
|
44
|
+
}
|
|
45
|
+
/**
|
|
46
|
+
* Create audit context for handler execution.
|
|
47
|
+
* Returns the auditor and storage for use in the handler.
|
|
48
|
+
*
|
|
49
|
+
* @param endpoint - The endpoint with audit configuration
|
|
50
|
+
* @param serviceDiscovery - Service discovery for getting audit storage
|
|
51
|
+
* @param logger - Logger for debug/error messages
|
|
52
|
+
* @param ctx - Request context for actor extraction
|
|
53
|
+
* @returns Audit context with auditor and storage, or undefined if not configured
|
|
54
|
+
*/
|
|
55
|
+
declare function createAuditContext<TServices extends Service[] = [], TSession = unknown, TLogger extends Logger = Logger, TAuditStorage extends AuditStorage | undefined = undefined, TAuditStorageServiceName extends string = string, TAuditAction extends AuditableAction<string, unknown> = AuditableAction<string, unknown>>(endpoint: Endpoint<any, any, any, any, TServices, TLogger, TSession, any, any, TAuditStorage, TAuditStorageServiceName, TAuditAction>, serviceDiscovery: ServiceDiscovery<any, any>, logger: TLogger, ctx: {
|
|
56
|
+
session: TSession;
|
|
57
|
+
header: HeaderFn;
|
|
58
|
+
cookie: CookieFn;
|
|
59
|
+
services: Record<string, unknown>;
|
|
60
|
+
}): Promise<AuditExecutionContext<TAuditAction> | undefined>;
|
|
61
|
+
/**
|
|
62
|
+
* Execute a handler with automatic audit transaction support.
|
|
63
|
+
* If the audit storage has a database (via getDatabase()), wraps execution
|
|
64
|
+
* in a transaction so audits are atomic with handler's database operations.
|
|
65
|
+
*
|
|
66
|
+
* @param auditContext - The audit context from createAuditContext
|
|
67
|
+
* @param handler - The handler function to execute (receives auditor)
|
|
68
|
+
* @param onComplete - Called after handler with response, to process declarative audits
|
|
69
|
+
* @returns The handler result
|
|
70
|
+
*/
|
|
71
|
+
declare function executeWithAuditTransaction<T, TAuditAction extends AuditableAction<string, unknown> = AuditableAction<string, unknown>>(auditContext: AuditExecutionContext<TAuditAction> | undefined, handler: (auditor?: Auditor<TAuditAction>) => Promise<T>, onComplete?: (response: T, auditor: Auditor<TAuditAction>) => Promise<void>): Promise<T>;
|
|
72
|
+
//#endregion
|
|
73
|
+
export { AuditExecutionContext, createAuditContext, executeWithAuditTransaction, processEndpointAudits };
|
|
74
|
+
//# sourceMappingURL=processAudits.d.mts.map
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
require('../Construct-
|
|
1
|
+
require('../Construct-BYSPikVm.cjs');
|
|
2
2
|
require('../publisher-lFQleddL.cjs');
|
|
3
|
-
require('../Function-
|
|
4
|
-
require('../BaseFunctionBuilder-
|
|
5
|
-
require('../FunctionBuilder-
|
|
6
|
-
require('../FunctionExecutionWrapper-
|
|
7
|
-
const require_AWSLambdaFunction = require('../AWSLambdaFunction-
|
|
3
|
+
require('../Function-CO-s2pB8.cjs');
|
|
4
|
+
require('../BaseFunctionBuilder-B8rT07QR.cjs');
|
|
5
|
+
require('../FunctionBuilder-_hMwZUof.cjs');
|
|
6
|
+
require('../FunctionExecutionWrapper-sxJNTpuc.cjs');
|
|
7
|
+
const require_AWSLambdaFunction = require('../AWSLambdaFunction-DMxScuaw.cjs');
|
|
8
8
|
|
|
9
9
|
exports.AWSLambdaFunction = require_AWSLambdaFunction.AWSLambdaFunction;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import "../Construct-
|
|
2
|
-
import "../Function-
|
|
3
|
-
import "../FunctionExecutionWrapper-
|
|
4
|
-
import { AWSLambdaFunction, AWSLambdaHandler } from "../AWSLambdaFunction-
|
|
1
|
+
import "../Construct-dI_rgdSp.cjs";
|
|
2
|
+
import "../Function-6EWabl_X.cjs";
|
|
3
|
+
import "../FunctionExecutionWrapper-Ci-ookJG.cjs";
|
|
4
|
+
import { AWSLambdaFunction, AWSLambdaHandler } from "../AWSLambdaFunction-t6q2o8EL.cjs";
|
|
5
5
|
export { AWSLambdaFunction, AWSLambdaHandler };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import "../Construct-
|
|
2
|
-
import "../Function-
|
|
3
|
-
import "../FunctionExecutionWrapper-
|
|
4
|
-
import { AWSLambdaFunction, AWSLambdaHandler } from "../AWSLambdaFunction-
|
|
1
|
+
import "../Construct-ZPqE0vhn.mjs";
|
|
2
|
+
import "../Function-G3JPHMaY.mjs";
|
|
3
|
+
import "../FunctionExecutionWrapper-DHFMLrOl.mjs";
|
|
4
|
+
import { AWSLambdaFunction, AWSLambdaHandler } from "../AWSLambdaFunction-DSB2oaFG.mjs";
|
|
5
5
|
export { AWSLambdaFunction, AWSLambdaHandler };
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import "../Construct-
|
|
1
|
+
import "../Construct-LWeB1rSQ.mjs";
|
|
2
2
|
import "../publisher-Bw4770Hi.mjs";
|
|
3
|
-
import "../Function-
|
|
4
|
-
import "../BaseFunctionBuilder-
|
|
5
|
-
import "../FunctionBuilder-
|
|
6
|
-
import "../FunctionExecutionWrapper-
|
|
7
|
-
import { AWSLambdaFunction } from "../AWSLambdaFunction-
|
|
3
|
+
import "../Function-COnc-tWM.mjs";
|
|
4
|
+
import "../BaseFunctionBuilder-CT7p10K1.mjs";
|
|
5
|
+
import "../FunctionBuilder-CMhLQ4dt.mjs";
|
|
6
|
+
import "../FunctionExecutionWrapper-i9v5L3Av.mjs";
|
|
7
|
+
import { AWSLambdaFunction } from "../AWSLambdaFunction-cL8A169J.mjs";
|
|
8
8
|
|
|
9
9
|
export { AWSLambdaFunction };
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
require('../Construct-
|
|
2
|
-
const require_BaseFunctionBuilder = require('../BaseFunctionBuilder-
|
|
1
|
+
require('../Construct-BYSPikVm.cjs');
|
|
2
|
+
const require_BaseFunctionBuilder = require('../BaseFunctionBuilder-B8rT07QR.cjs');
|
|
3
3
|
|
|
4
4
|
exports.BaseFunctionBuilder = require_BaseFunctionBuilder.BaseFunctionBuilder;
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import "../Construct-
|
|
2
|
-
import { BaseFunctionBuilder } from "../BaseFunctionBuilder-
|
|
1
|
+
import "../Construct-dI_rgdSp.cjs";
|
|
2
|
+
import { BaseFunctionBuilder } from "../BaseFunctionBuilder-Cf0op65o.cjs";
|
|
3
3
|
export { BaseFunctionBuilder };
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import "../Construct-
|
|
2
|
-
import { BaseFunctionBuilder } from "../BaseFunctionBuilder-
|
|
1
|
+
import "../Construct-ZPqE0vhn.mjs";
|
|
2
|
+
import { BaseFunctionBuilder } from "../BaseFunctionBuilder-DilipY1y.mjs";
|
|
3
3
|
export { BaseFunctionBuilder };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
require('../Construct-
|
|
2
|
-
const require_Function = require('../Function-
|
|
1
|
+
require('../Construct-BYSPikVm.cjs');
|
|
2
|
+
const require_Function = require('../Function-CO-s2pB8.cjs');
|
|
3
3
|
|
|
4
4
|
exports.Function = require_Function.Function;
|
|
5
5
|
exports.FunctionFactory = require_Function.FunctionFactory;
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import "../Construct-
|
|
2
|
-
import { Function, FunctionContext, FunctionFactory, FunctionHandler } from "../Function-
|
|
1
|
+
import "../Construct-dI_rgdSp.cjs";
|
|
2
|
+
import { Function, FunctionContext, FunctionFactory, FunctionHandler } from "../Function-6EWabl_X.cjs";
|
|
3
3
|
export { Function, FunctionContext, FunctionFactory, FunctionHandler };
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
import "../Construct-
|
|
2
|
-
import { Function, FunctionContext, FunctionFactory, FunctionHandler } from "../Function-
|
|
1
|
+
import "../Construct-ZPqE0vhn.mjs";
|
|
2
|
+
import { Function, FunctionContext, FunctionFactory, FunctionHandler } from "../Function-G3JPHMaY.mjs";
|
|
3
3
|
export { Function, FunctionContext, FunctionFactory, FunctionHandler };
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
require('../Construct-
|
|
2
|
-
require('../Function-
|
|
3
|
-
require('../BaseFunctionBuilder-
|
|
4
|
-
const require_FunctionBuilder = require('../FunctionBuilder-
|
|
1
|
+
require('../Construct-BYSPikVm.cjs');
|
|
2
|
+
require('../Function-CO-s2pB8.cjs');
|
|
3
|
+
require('../BaseFunctionBuilder-B8rT07QR.cjs');
|
|
4
|
+
const require_FunctionBuilder = require('../FunctionBuilder-_hMwZUof.cjs');
|
|
5
5
|
|
|
6
6
|
exports.FunctionBuilder = require_FunctionBuilder.FunctionBuilder;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import "../Construct-
|
|
2
|
-
import "../Function-
|
|
3
|
-
import "../BaseFunctionBuilder-
|
|
4
|
-
import { FunctionBuilder } from "../FunctionBuilder-
|
|
1
|
+
import "../Construct-dI_rgdSp.cjs";
|
|
2
|
+
import "../Function-6EWabl_X.cjs";
|
|
3
|
+
import "../BaseFunctionBuilder-Cf0op65o.cjs";
|
|
4
|
+
import { FunctionBuilder } from "../FunctionBuilder-B3fpp3hA.cjs";
|
|
5
5
|
export { FunctionBuilder };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import "../Construct-
|
|
2
|
-
import "../Function-
|
|
3
|
-
import "../BaseFunctionBuilder-
|
|
4
|
-
import { FunctionBuilder } from "../FunctionBuilder-
|
|
1
|
+
import "../Construct-ZPqE0vhn.mjs";
|
|
2
|
+
import "../Function-G3JPHMaY.mjs";
|
|
3
|
+
import "../BaseFunctionBuilder-DilipY1y.mjs";
|
|
4
|
+
import { FunctionBuilder } from "../FunctionBuilder-ByaB_LQ4.mjs";
|
|
5
5
|
export { FunctionBuilder };
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import "../Construct-
|
|
2
|
-
import "../Function-
|
|
3
|
-
import "../BaseFunctionBuilder-
|
|
4
|
-
import { FunctionBuilder } from "../FunctionBuilder-
|
|
1
|
+
import "../Construct-LWeB1rSQ.mjs";
|
|
2
|
+
import "../Function-COnc-tWM.mjs";
|
|
3
|
+
import "../BaseFunctionBuilder-CT7p10K1.mjs";
|
|
4
|
+
import { FunctionBuilder } from "../FunctionBuilder-CMhLQ4dt.mjs";
|
|
5
5
|
|
|
6
6
|
export { FunctionBuilder };
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
require('../Construct-
|
|
1
|
+
require('../Construct-BYSPikVm.cjs');
|
|
2
2
|
require('../publisher-lFQleddL.cjs');
|
|
3
|
-
require('../Function-
|
|
4
|
-
require('../BaseFunctionBuilder-
|
|
5
|
-
require('../FunctionBuilder-
|
|
6
|
-
const require_FunctionExecutionWrapper = require('../FunctionExecutionWrapper-
|
|
3
|
+
require('../Function-CO-s2pB8.cjs');
|
|
4
|
+
require('../BaseFunctionBuilder-B8rT07QR.cjs');
|
|
5
|
+
require('../FunctionBuilder-_hMwZUof.cjs');
|
|
6
|
+
const require_FunctionExecutionWrapper = require('../FunctionExecutionWrapper-sxJNTpuc.cjs');
|
|
7
7
|
|
|
8
8
|
exports.FunctionExecutionWrapper = require_FunctionExecutionWrapper.FunctionExecutionWrapper;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import "../Construct-
|
|
2
|
-
import "../Function-
|
|
3
|
-
import { FunctionExecutionWrapper } from "../FunctionExecutionWrapper-
|
|
1
|
+
import "../Construct-dI_rgdSp.cjs";
|
|
2
|
+
import "../Function-6EWabl_X.cjs";
|
|
3
|
+
import { FunctionExecutionWrapper } from "../FunctionExecutionWrapper-Ci-ookJG.cjs";
|
|
4
4
|
export { FunctionExecutionWrapper };
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import "../Construct-
|
|
2
|
-
import "../Function-
|
|
3
|
-
import { FunctionExecutionWrapper } from "../FunctionExecutionWrapper-
|
|
1
|
+
import "../Construct-ZPqE0vhn.mjs";
|
|
2
|
+
import "../Function-G3JPHMaY.mjs";
|
|
3
|
+
import { FunctionExecutionWrapper } from "../FunctionExecutionWrapper-DHFMLrOl.mjs";
|
|
4
4
|
export { FunctionExecutionWrapper };
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import "../Construct-
|
|
1
|
+
import "../Construct-LWeB1rSQ.mjs";
|
|
2
2
|
import "../publisher-Bw4770Hi.mjs";
|
|
3
|
-
import "../Function-
|
|
4
|
-
import "../BaseFunctionBuilder-
|
|
5
|
-
import "../FunctionBuilder-
|
|
6
|
-
import { FunctionExecutionWrapper } from "../FunctionExecutionWrapper-
|
|
3
|
+
import "../Function-COnc-tWM.mjs";
|
|
4
|
+
import "../BaseFunctionBuilder-CT7p10K1.mjs";
|
|
5
|
+
import "../FunctionBuilder-CMhLQ4dt.mjs";
|
|
6
|
+
import { FunctionExecutionWrapper } from "../FunctionExecutionWrapper-i9v5L3Av.mjs";
|
|
7
7
|
|
|
8
8
|
export { FunctionExecutionWrapper };
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
const require_chunk = require('../chunk-CUT6urMc.cjs');
|
|
2
|
-
require('../Construct-
|
|
2
|
+
require('../Construct-BYSPikVm.cjs');
|
|
3
3
|
const require_publisher = require('../publisher-lFQleddL.cjs');
|
|
4
|
-
require('../Function-
|
|
5
|
-
require('../BaseFunctionBuilder-
|
|
6
|
-
const require_FunctionBuilder = require('../FunctionBuilder-
|
|
4
|
+
require('../Function-CO-s2pB8.cjs');
|
|
5
|
+
require('../BaseFunctionBuilder-B8rT07QR.cjs');
|
|
6
|
+
const require_FunctionBuilder = require('../FunctionBuilder-_hMwZUof.cjs');
|
|
7
7
|
const __geekmidas_services = require_chunk.__toESM(require("@geekmidas/services"));
|
|
8
8
|
const __geekmidas_envkit = require_chunk.__toESM(require("@geekmidas/envkit"));
|
|
9
9
|
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import "../Construct-
|
|
2
|
-
import { Function } from "../Function-
|
|
1
|
+
import "../Construct-dI_rgdSp.cjs";
|
|
2
|
+
import { Function } from "../Function-6EWabl_X.cjs";
|
|
3
3
|
import { EventPublisher } from "@geekmidas/events";
|
|
4
4
|
import { Logger } from "@geekmidas/logger";
|
|
5
5
|
import { Service, ServiceDiscovery, ServiceRecord } from "@geekmidas/services";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import "../Construct-
|
|
2
|
-
import { Function } from "../Function-
|
|
1
|
+
import "../Construct-ZPqE0vhn.mjs";
|
|
2
|
+
import { Function } from "../Function-G3JPHMaY.mjs";
|
|
3
3
|
import { Service, ServiceDiscovery, ServiceRecord } from "@geekmidas/services";
|
|
4
4
|
import { EventPublisher } from "@geekmidas/events";
|
|
5
5
|
import { Logger } from "@geekmidas/logger";
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import "../Construct-
|
|
1
|
+
import "../Construct-LWeB1rSQ.mjs";
|
|
2
2
|
import { publishEvents } from "../publisher-Bw4770Hi.mjs";
|
|
3
|
-
import "../Function-
|
|
4
|
-
import "../BaseFunctionBuilder-
|
|
5
|
-
import { FunctionBuilder } from "../FunctionBuilder-
|
|
3
|
+
import "../Function-COnc-tWM.mjs";
|
|
4
|
+
import "../BaseFunctionBuilder-CT7p10K1.mjs";
|
|
5
|
+
import { FunctionBuilder } from "../FunctionBuilder-CMhLQ4dt.mjs";
|
|
6
6
|
import { ServiceDiscovery } from "@geekmidas/services";
|
|
7
7
|
import { EnvironmentParser } from "@geekmidas/envkit";
|
|
8
8
|
|
package/dist/functions/index.cjs
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
require('../Construct-
|
|
2
|
-
const require_Function = require('../Function-
|
|
3
|
-
const require_BaseFunctionBuilder = require('../BaseFunctionBuilder-
|
|
4
|
-
const require_FunctionBuilder = require('../FunctionBuilder-
|
|
5
|
-
const require_functions = require('../functions-
|
|
1
|
+
require('../Construct-BYSPikVm.cjs');
|
|
2
|
+
const require_Function = require('../Function-CO-s2pB8.cjs');
|
|
3
|
+
const require_BaseFunctionBuilder = require('../BaseFunctionBuilder-B8rT07QR.cjs');
|
|
4
|
+
const require_FunctionBuilder = require('../FunctionBuilder-_hMwZUof.cjs');
|
|
5
|
+
const require_functions = require('../functions-D03lqK-r.cjs');
|
|
6
6
|
|
|
7
7
|
exports.BaseFunctionBuilder = require_BaseFunctionBuilder.BaseFunctionBuilder;
|
|
8
8
|
exports.Function = require_Function.Function;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import "../Construct-
|
|
2
|
-
import { Function, FunctionContext, FunctionHandler } from "../Function-
|
|
3
|
-
import { BaseFunctionBuilder } from "../BaseFunctionBuilder-
|
|
4
|
-
import { FunctionBuilder } from "../FunctionBuilder-
|
|
5
|
-
import { f } from "../index-
|
|
1
|
+
import "../Construct-dI_rgdSp.cjs";
|
|
2
|
+
import { Function, FunctionContext, FunctionHandler } from "../Function-6EWabl_X.cjs";
|
|
3
|
+
import { BaseFunctionBuilder } from "../BaseFunctionBuilder-Cf0op65o.cjs";
|
|
4
|
+
import { FunctionBuilder } from "../FunctionBuilder-B3fpp3hA.cjs";
|
|
5
|
+
import { f } from "../index-CUg_hSq-.cjs";
|
|
6
6
|
export { BaseFunctionBuilder, Function, FunctionBuilder, FunctionContext, FunctionHandler, f };
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import "../Construct-
|
|
2
|
-
import { Function, FunctionContext, FunctionHandler } from "../Function-
|
|
3
|
-
import { BaseFunctionBuilder } from "../BaseFunctionBuilder-
|
|
4
|
-
import { FunctionBuilder } from "../FunctionBuilder-
|
|
5
|
-
import { f } from "../index-
|
|
1
|
+
import "../Construct-ZPqE0vhn.mjs";
|
|
2
|
+
import { Function, FunctionContext, FunctionHandler } from "../Function-G3JPHMaY.mjs";
|
|
3
|
+
import { BaseFunctionBuilder } from "../BaseFunctionBuilder-DilipY1y.mjs";
|
|
4
|
+
import { FunctionBuilder } from "../FunctionBuilder-ByaB_LQ4.mjs";
|
|
5
|
+
import { f } from "../index-D-a7e2gv.mjs";
|
|
6
6
|
export { BaseFunctionBuilder, Function, FunctionBuilder, FunctionContext, FunctionHandler, f };
|
package/dist/functions/index.mjs
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import "../Construct-
|
|
2
|
-
import { Function } from "../Function-
|
|
3
|
-
import { BaseFunctionBuilder } from "../BaseFunctionBuilder-
|
|
4
|
-
import { FunctionBuilder } from "../FunctionBuilder-
|
|
5
|
-
import { f } from "../functions-
|
|
1
|
+
import "../Construct-LWeB1rSQ.mjs";
|
|
2
|
+
import { Function } from "../Function-COnc-tWM.mjs";
|
|
3
|
+
import { BaseFunctionBuilder } from "../BaseFunctionBuilder-CT7p10K1.mjs";
|
|
4
|
+
import { FunctionBuilder } from "../FunctionBuilder-CMhLQ4dt.mjs";
|
|
5
|
+
import { f } from "../functions-BYqZAob8.mjs";
|
|
6
6
|
|
|
7
7
|
export { BaseFunctionBuilder, Function, FunctionBuilder, f };
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"functions-
|
|
1
|
+
{"version":3,"file":"functions-BYqZAob8.mjs","names":[],"sources":["../src/functions/index.ts"],"sourcesContent":["export {\n Function,\n type FunctionContext,\n type FunctionHandler,\n} from './Function';\nexport { BaseFunctionBuilder } from './BaseFunctionBuilder';\nimport { FunctionBuilder } from './FunctionBuilder';\nexport { FunctionBuilder } from './FunctionBuilder';\n\nexport const f = new FunctionBuilder();\n"],"mappings":";;;AASA,MAAa,IAAI,IAAI"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
const require_FunctionBuilder = require('./FunctionBuilder-
|
|
1
|
+
const require_FunctionBuilder = require('./FunctionBuilder-_hMwZUof.cjs');
|
|
2
2
|
|
|
3
3
|
//#region src/functions/index.ts
|
|
4
4
|
const f = new require_FunctionBuilder.FunctionBuilder();
|
|
@@ -10,4 +10,4 @@ Object.defineProperty(exports, 'f', {
|
|
|
10
10
|
return f;
|
|
11
11
|
}
|
|
12
12
|
});
|
|
13
|
-
//# sourceMappingURL=functions-
|
|
13
|
+
//# sourceMappingURL=functions-D03lqK-r.cjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"functions-
|
|
1
|
+
{"version":3,"file":"functions-D03lqK-r.cjs","names":["FunctionBuilder"],"sources":["../src/functions/index.ts"],"sourcesContent":["export {\n Function,\n type FunctionContext,\n type FunctionHandler,\n} from './Function';\nexport { BaseFunctionBuilder } from './BaseFunctionBuilder';\nimport { FunctionBuilder } from './FunctionBuilder';\nexport { FunctionBuilder } from './FunctionBuilder';\n\nexport const f = new FunctionBuilder();\n"],"mappings":";;;AASA,MAAa,IAAI,IAAIA"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
const require_chunk = require('./chunk-CUT6urMc.cjs');
|
|
2
|
-
const require_Endpoint = require('./Endpoint-
|
|
2
|
+
const require_Endpoint = require('./Endpoint-B9PryZES.cjs');
|
|
3
3
|
const node_path = require_chunk.__toESM(require("node:path"));
|
|
4
4
|
const fast_glob = require_chunk.__toESM(require("fast-glob"));
|
|
5
5
|
|
|
@@ -92,4 +92,4 @@ Object.defineProperty(exports, 'getProjectRoot', {
|
|
|
92
92
|
return getProjectRoot;
|
|
93
93
|
}
|
|
94
94
|
});
|
|
95
|
-
//# sourceMappingURL=helpers-
|
|
95
|
+
//# sourceMappingURL=helpers-BApRyhly.cjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"helpers-
|
|
1
|
+
{"version":3,"file":"helpers-BApRyhly.cjs","names":["cwd: string","routes: string[]","endpoints: Endpoint<string, HttpMethod, any, any, TServices>[]"],"sources":["../src/endpoints/helpers.ts"],"sourcesContent":["import path from 'node:path';\nimport fg from 'fast-glob';\nimport { Endpoint } from './Endpoint';\n\nimport type { Service } from '@geekmidas/services';\nimport type { HttpMethod } from '../types';\n\n// Re-export utility functions\n\n/**\n * Recursively finds the project root directory by looking for lock files.\n * Traverses up the directory tree until it finds a package manager lock file.\n *\n * @param cwd - The current working directory to start searching from\n * @returns Promise resolving to the absolute path of the project root\n *\n * @example\n * ```typescript\n * const projectRoot = await getProjectRoot(process.cwd());\n * console.log(`Project root: ${projectRoot}`);\n * // Output: Project root: /Users/user/my-project\n * ```\n */\nexport async function getProjectRoot(cwd: string): Promise<string> {\n if (cwd === '/') {\n return cwd;\n }\n\n const stream = fg.stream(\n ['yarn.lock', 'pnpm-lock.yaml', 'package-lock.json', 'deno.lock'],\n { dot: true, cwd },\n );\n\n let isRoot = false;\n\n for await (const _ of stream) {\n isRoot = true;\n break;\n }\n\n if (isRoot) {\n return cwd;\n }\n\n return getProjectRoot(path.resolve(cwd, '..'));\n}\n\n/**\n * Discovers and imports all Endpoint instances from the specified route patterns.\n * Uses fast-glob to find files matching the patterns and extracts exported Endpoints.\n *\n * @template TServices - Array of service types used by the endpoints\n * @param routes - Array of glob patterns to match route files (e.g., ['src/routes/*.ts'])\n * @param cwd - The current working directory to resolve paths from\n * @returns Promise resolving to an array of Endpoint instances found in the matched files\n *\n * @example\n * ```typescript\n * // Find all endpoints in the routes directory\n * const endpoints = await getEndpointsFromRoutes(\n * ['src/routes/**\\/*.ts'],\n * process.cwd()\n * );\n *\n * // Register endpoints with your server\n * for (const endpoint of endpoints) {\n * server.register(endpoint);\n * }\n * ```\n *\n * @remarks\n * - Only exports that are valid Endpoint instances are included\n * - Files are imported dynamically, so they must be valid ES modules\n * - The function filters out non-Endpoint exports automatically\n */\nexport async function getEndpointsFromRoutes<TServices extends Service[]>(\n routes: string[],\n cwd: string,\n): Promise<Endpoint<string, HttpMethod, any, any, TServices>[]> {\n const stream = fg.stream(routes, { cwd });\n\n const endpoints: Endpoint<string, HttpMethod, any, any, TServices>[] = [];\n\n for await (const f of stream) {\n // Resolve the absolute path for the route file\n const routePath = path.resolve(cwd, f.toString());\n // Dynamically import the route module\n const route = await import(routePath);\n\n // Filter exported values to find only Endpoint instances\n const handlers = Object.values(route).filter((value) => {\n return Endpoint.isEndpoint(value);\n }) as unknown as Endpoint<string, HttpMethod, any, any, TServices>[];\n\n endpoints.push(...handlers);\n }\n\n return endpoints;\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;AAuBA,eAAsB,eAAeA,KAA8B;AACjE,KAAI,QAAQ,IACV,QAAO;CAGT,MAAM,SAAS,kBAAG,OAChB;EAAC;EAAa;EAAkB;EAAqB;CAAY,GACjE;EAAE,KAAK;EAAM;CAAK,EACnB;CAED,IAAI,SAAS;AAEb,YAAW,MAAM,KAAK,QAAQ;AAC5B,WAAS;AACT;CACD;AAED,KAAI,OACF,QAAO;AAGT,QAAO,eAAe,kBAAK,QAAQ,KAAK,KAAK,CAAC;AAC/C;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AA8BD,eAAsB,uBACpBC,QACAD,KAC8D;CAC9D,MAAM,SAAS,kBAAG,OAAO,QAAQ,EAAE,IAAK,EAAC;CAEzC,MAAME,YAAiE,CAAE;AAEzE,YAAW,MAAM,KAAK,QAAQ;EAE5B,MAAM,YAAY,kBAAK,QAAQ,KAAK,EAAE,UAAU,CAAC;EAEjD,MAAM,QAAQ,MAAM,OAAO;EAG3B,MAAM,WAAW,OAAO,OAAO,MAAM,CAAC,OAAO,CAAC,UAAU;AACtD,UAAO,0BAAS,WAAW,MAAM;EAClC,EAAC;AAEF,YAAU,KAAK,GAAG,SAAS;CAC5B;AAED,QAAO;AACR"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { Endpoint } from "./Endpoint-
|
|
1
|
+
import { Endpoint } from "./Endpoint-B69TqESg.mjs";
|
|
2
2
|
import path from "node:path";
|
|
3
3
|
import fg from "fast-glob";
|
|
4
4
|
|
|
@@ -80,4 +80,4 @@ async function getEndpointsFromRoutes(routes, cwd) {
|
|
|
80
80
|
|
|
81
81
|
//#endregion
|
|
82
82
|
export { getEndpointsFromRoutes, getProjectRoot };
|
|
83
|
-
//# sourceMappingURL=helpers-
|
|
83
|
+
//# sourceMappingURL=helpers-BPDogwac.mjs.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"helpers-
|
|
1
|
+
{"version":3,"file":"helpers-BPDogwac.mjs","names":["cwd: string","routes: string[]","endpoints: Endpoint<string, HttpMethod, any, any, TServices>[]"],"sources":["../src/endpoints/helpers.ts"],"sourcesContent":["import path from 'node:path';\nimport fg from 'fast-glob';\nimport { Endpoint } from './Endpoint';\n\nimport type { Service } from '@geekmidas/services';\nimport type { HttpMethod } from '../types';\n\n// Re-export utility functions\n\n/**\n * Recursively finds the project root directory by looking for lock files.\n * Traverses up the directory tree until it finds a package manager lock file.\n *\n * @param cwd - The current working directory to start searching from\n * @returns Promise resolving to the absolute path of the project root\n *\n * @example\n * ```typescript\n * const projectRoot = await getProjectRoot(process.cwd());\n * console.log(`Project root: ${projectRoot}`);\n * // Output: Project root: /Users/user/my-project\n * ```\n */\nexport async function getProjectRoot(cwd: string): Promise<string> {\n if (cwd === '/') {\n return cwd;\n }\n\n const stream = fg.stream(\n ['yarn.lock', 'pnpm-lock.yaml', 'package-lock.json', 'deno.lock'],\n { dot: true, cwd },\n );\n\n let isRoot = false;\n\n for await (const _ of stream) {\n isRoot = true;\n break;\n }\n\n if (isRoot) {\n return cwd;\n }\n\n return getProjectRoot(path.resolve(cwd, '..'));\n}\n\n/**\n * Discovers and imports all Endpoint instances from the specified route patterns.\n * Uses fast-glob to find files matching the patterns and extracts exported Endpoints.\n *\n * @template TServices - Array of service types used by the endpoints\n * @param routes - Array of glob patterns to match route files (e.g., ['src/routes/*.ts'])\n * @param cwd - The current working directory to resolve paths from\n * @returns Promise resolving to an array of Endpoint instances found in the matched files\n *\n * @example\n * ```typescript\n * // Find all endpoints in the routes directory\n * const endpoints = await getEndpointsFromRoutes(\n * ['src/routes/**\\/*.ts'],\n * process.cwd()\n * );\n *\n * // Register endpoints with your server\n * for (const endpoint of endpoints) {\n * server.register(endpoint);\n * }\n * ```\n *\n * @remarks\n * - Only exports that are valid Endpoint instances are included\n * - Files are imported dynamically, so they must be valid ES modules\n * - The function filters out non-Endpoint exports automatically\n */\nexport async function getEndpointsFromRoutes<TServices extends Service[]>(\n routes: string[],\n cwd: string,\n): Promise<Endpoint<string, HttpMethod, any, any, TServices>[]> {\n const stream = fg.stream(routes, { cwd });\n\n const endpoints: Endpoint<string, HttpMethod, any, any, TServices>[] = [];\n\n for await (const f of stream) {\n // Resolve the absolute path for the route file\n const routePath = path.resolve(cwd, f.toString());\n // Dynamically import the route module\n const route = await import(routePath);\n\n // Filter exported values to find only Endpoint instances\n const handlers = Object.values(route).filter((value) => {\n return Endpoint.isEndpoint(value);\n }) as unknown as Endpoint<string, HttpMethod, any, any, TServices>[];\n\n endpoints.push(...handlers);\n }\n\n return endpoints;\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;AAuBA,eAAsB,eAAeA,KAA8B;AACjE,KAAI,QAAQ,IACV,QAAO;CAGT,MAAM,SAAS,GAAG,OAChB;EAAC;EAAa;EAAkB;EAAqB;CAAY,GACjE;EAAE,KAAK;EAAM;CAAK,EACnB;CAED,IAAI,SAAS;AAEb,YAAW,MAAM,KAAK,QAAQ;AAC5B,WAAS;AACT;CACD;AAED,KAAI,OACF,QAAO;AAGT,QAAO,eAAe,KAAK,QAAQ,KAAK,KAAK,CAAC;AAC/C;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AA8BD,eAAsB,uBACpBC,QACAD,KAC8D;CAC9D,MAAM,SAAS,GAAG,OAAO,QAAQ,EAAE,IAAK,EAAC;CAEzC,MAAME,YAAiE,CAAE;AAEzE,YAAW,MAAM,KAAK,QAAQ;EAE5B,MAAM,YAAY,KAAK,QAAQ,KAAK,EAAE,UAAU,CAAC;EAEjD,MAAM,QAAQ,MAAM,OAAO;EAG3B,MAAM,WAAW,OAAO,OAAO,MAAM,CAAC,OAAO,CAAC,UAAU;AACtD,UAAO,SAAS,WAAW,MAAM;EAClC,EAAC;AAEF,YAAU,KAAK,GAAG,SAAS;CAC5B;AAED,QAAO;AACR"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { FunctionBuilder } from "./FunctionBuilder-B3fpp3hA.cjs";
|
|
2
|
+
import * as _geekmidas_logger1 from "@geekmidas/logger";
|
|
3
|
+
import * as _geekmidas_schema0 from "@geekmidas/schema";
|
|
4
|
+
|
|
5
|
+
//#region src/functions/index.d.ts
|
|
6
|
+
declare const f: FunctionBuilder<_geekmidas_schema0.ComposableStandardSchema, undefined, [], _geekmidas_logger1.Logger, undefined, string, undefined, string>;
|
|
7
|
+
//#endregion
|
|
8
|
+
export { f };
|
|
9
|
+
//# sourceMappingURL=index-CUg_hSq-.d.cts.map
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { FunctionBuilder } from "./FunctionBuilder-ByaB_LQ4.mjs";
|
|
2
|
+
import * as _geekmidas_logger6 from "@geekmidas/logger";
|
|
3
|
+
import * as _geekmidas_schema5 from "@geekmidas/schema";
|
|
4
|
+
|
|
5
|
+
//#region src/functions/index.d.ts
|
|
6
|
+
declare const f: FunctionBuilder<_geekmidas_schema5.ComposableStandardSchema, undefined, [], _geekmidas_logger6.Logger, undefined, string, undefined, string>;
|
|
7
|
+
//#endregion
|
|
8
|
+
export { f };
|
|
9
|
+
//# sourceMappingURL=index-D-a7e2gv.d.mts.map
|
package/dist/index.cjs
CHANGED
package/dist/index.d.cts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { Construct, ConstructType } from "./Construct-
|
|
1
|
+
import { Construct, ConstructType } from "./Construct-dI_rgdSp.cjs";
|
|
2
2
|
import { HttpMethod, LowerHttpMethod, RemoveUndefined } from "./types-Bp9ysFXd.cjs";
|
|
3
3
|
import { Service, ServiceRecord } from "@geekmidas/services";
|
|
4
4
|
export { Construct, ConstructType, HttpMethod, LowerHttpMethod, RemoveUndefined, Service, ServiceRecord };
|
package/dist/index.d.mts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { Construct, ConstructType } from "./Construct-
|
|
2
|
-
import { HttpMethod, LowerHttpMethod, RemoveUndefined } from "./types-
|
|
1
|
+
import { Construct, ConstructType } from "./Construct-ZPqE0vhn.mjs";
|
|
2
|
+
import { HttpMethod, LowerHttpMethod, RemoveUndefined } from "./types-DKf0juBf.mjs";
|
|
3
3
|
import { Service, ServiceRecord } from "@geekmidas/services";
|
|
4
4
|
export { Construct, ConstructType, HttpMethod, LowerHttpMethod, RemoveUndefined, Service, ServiceRecord };
|
package/dist/index.mjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"parseHonoQuery-
|
|
1
|
+
{"version":3,"file":"parseHonoQuery-CT8Cvin-.cjs","names":["c: Context","result: Record<string, any>"],"sources":["../src/endpoints/parseHonoQuery.ts"],"sourcesContent":["import type { Context } from 'hono';\n\n/**\n * Parse Hono query parameters to handle arrays and nested objects\n * Hono provides c.req.queries() for arrays, but we need to handle dot notation for objects\n */\nexport function parseHonoQuery(c: Context): Record<string, any> {\n const allParams = c.req.query();\n const result: Record<string, any> = {};\n\n // First, handle all query parameters\n for (const [key, value] of Object.entries(allParams)) {\n if (key.includes('.')) {\n // Handle dot notation for objects\n const parts = key.split('.');\n let current = result;\n\n // Navigate/create the nested structure\n for (let i = 0; i < parts.length - 1; i++) {\n const part = parts[i];\n if (\n !current[part] ||\n typeof current[part] !== 'object' ||\n Array.isArray(current[part])\n ) {\n current[part] = {};\n }\n current = current[part];\n }\n\n // Set the final value, checking for arrays in nested keys\n const lastPart = parts[parts.length - 1];\n const multipleValues = c.req.queries(key);\n if (multipleValues && multipleValues.length > 1) {\n current[lastPart] = multipleValues;\n } else {\n current[lastPart] = value;\n }\n } else {\n // For regular keys, check if there are multiple values\n const multipleValues = c.req.queries(key);\n if (multipleValues && multipleValues.length > 1) {\n result[key] = multipleValues;\n } else {\n result[key] = value;\n }\n }\n }\n\n return result;\n}\n"],"mappings":";;;;;;AAMA,SAAgB,eAAeA,GAAiC;CAC9D,MAAM,YAAY,EAAE,IAAI,OAAO;CAC/B,MAAMC,SAA8B,CAAE;AAGtC,MAAK,MAAM,CAAC,KAAK,MAAM,IAAI,OAAO,QAAQ,UAAU,CAClD,KAAI,IAAI,SAAS,IAAI,EAAE;EAErB,MAAM,QAAQ,IAAI,MAAM,IAAI;EAC5B,IAAI,UAAU;AAGd,OAAK,IAAI,IAAI,GAAG,IAAI,MAAM,SAAS,GAAG,KAAK;GACzC,MAAM,OAAO,MAAM;AACnB,QACG,QAAQ,gBACF,QAAQ,UAAU,YACzB,MAAM,QAAQ,QAAQ,MAAM,CAE5B,SAAQ,QAAQ,CAAE;AAEpB,aAAU,QAAQ;EACnB;EAGD,MAAM,WAAW,MAAM,MAAM,SAAS;EACtC,MAAM,iBAAiB,EAAE,IAAI,QAAQ,IAAI;AACzC,MAAI,kBAAkB,eAAe,SAAS,EAC5C,SAAQ,YAAY;MAEpB,SAAQ,YAAY;CAEvB,OAAM;EAEL,MAAM,iBAAiB,EAAE,IAAI,QAAQ,IAAI;AACzC,MAAI,kBAAkB,eAAe,SAAS,EAC5C,QAAO,OAAO;MAEd,QAAO,OAAO;CAEjB;AAGH,QAAO;AACR"}
|