@classytic/arc 2.45.2 → 2.47.0
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 +1 -1
- package/dist/{EventTransport-DHb1tpu-.mjs → EventTransport-BHKy4_Bi.mjs} +5 -6
- package/dist/{EventTransport-CiicKz2Z.d.mts → EventTransport-CYEoCJGe.d.mts} +0 -2
- package/dist/{HookSystem-C1u0EUnt.mjs → HookSystem-CAIDVoKC.mjs} +3 -4
- package/dist/{QueryCache--5uAuYPW.d.mts → QueryCache-DdvrGG8Q.d.mts} +1 -3
- package/dist/{ResourceRegistry-D2jXWVN_.mjs → ResourceRegistry-23Ml6FNe.mjs} +15 -4
- package/dist/{acquire-DTkA8Lme.mjs → acquire-DoFX06fm.mjs} +2 -3
- package/dist/{actionPermissions-DRVk6m7x.mjs → actionPermissions-DXrlWHHK.mjs} +37 -42
- package/dist/audit/index.d.mts +2 -10
- package/dist/audit/index.mjs +8 -12
- package/dist/auth/audit.d.mts +0 -2
- package/dist/auth/audit.mjs +2 -3
- package/dist/auth/index.d.mts +9 -17
- package/dist/auth/index.mjs +26 -29
- package/dist/auth/redis-session.d.mts +2 -4
- package/dist/auth/redis-session.mjs +2 -3
- package/dist/{authorizationDecision-D48fUJv1.mjs → authorizationDecision-DYiubkYw.mjs} +5 -6
- package/dist/{base-CZyixEQR.d.mts → base-HXNgPQww.d.mts} +1 -7
- package/dist/{boundedMap-DkKiPifd.mjs → boundedMap-CtdzpJ3X.mjs} +2 -3
- package/dist/{buildHandler-BiZ4VATS.mjs → buildHandler-CARdmPNo.mjs} +5 -6
- package/dist/cache/index.d.mts +4 -10
- package/dist/cache/index.mjs +5 -6
- package/dist/{caching-Cj0as-P1.mjs → caching-QRiryDLs.mjs} +3 -4
- package/dist/{claimed-ChI13rUR.mjs → claimed-BLecr1j3.mjs} +2 -3
- package/dist/cleanup/index.d.mts +4 -18
- package/dist/cleanup/index.mjs +12 -20
- package/dist/cli/commands/describe.d.mts +1 -3
- package/dist/cli/commands/describe.mjs +4 -5
- package/dist/cli/commands/docs.d.mts +1 -3
- package/dist/cli/commands/docs.mjs +4 -5
- package/dist/cli/commands/doctor.d.mts +1 -3
- package/dist/cli/commands/doctor.mjs +2 -3
- package/dist/cli/commands/generate.d.mts +1 -1
- package/dist/cli/commands/generate.mjs +2 -2
- package/dist/cli/commands/init.d.mts +1 -1
- package/dist/cli/commands/init.mjs +2 -2
- package/dist/cli/commands/introspect.d.mts +1 -3
- package/dist/cli/commands/introspect.mjs +3 -4
- package/dist/cli/index.d.mts +2 -2
- package/dist/cli/index.mjs +3 -3
- package/dist/{constants-D_aiew34.mjs → constants-Cx7BcnHT.mjs} +2 -3
- package/dist/context/index.d.mts +0 -8
- package/dist/context/index.mjs +6 -7
- package/dist/core/index.d.mts +3 -3
- package/dist/core/index.mjs +8 -8
- package/dist/{core-QIZ2560Y.mjs → core-0WyMuo0f.mjs} +9 -12
- package/dist/{createActionRouter-CvH84dyx.mjs → createActionRouter-mLAGbpDV.mjs} +7 -8
- package/dist/{createAggregationRouter-DGyK2Hp6.mjs → createAggregationRouter-BEAjn3dA.mjs} +9 -10
- package/dist/{createApp-CKjZpmq9.mjs → createApp-QDP4vYWH.mjs} +49 -62
- package/dist/{createMcpServer-DSztofa9.d.mts → createMcpServer-DzXHX0SO.d.mts} +1 -3
- package/dist/{defineAggregation-BLza7Ca4.mjs → defineAggregation-CFNfvz-C.mjs} +2 -3
- package/dist/{defineResource-CEo0gDCb.mjs → defineResource-BROJmhzJ.mjs} +80 -29
- package/dist/discovery/index.d.mts +1 -3
- package/dist/discovery/index.mjs +2 -3
- package/dist/docs/index.d.mts +8 -8
- package/dist/docs/index.mjs +4 -5
- package/dist/{elevation-BW2J3tNj.d.mts → elevation-DPD0hcU-.d.mts} +0 -2
- package/dist/{elevation-BJTsSnke.mjs → elevation-DrXeEWWk.mjs} +9 -10
- package/dist/encryption/index.d.mts +1 -7
- package/dist/encryption/index.mjs +8 -13
- package/dist/{errorHandler--4rSMMvq.d.mts → errorHandler-B9r88jZV.d.mts} +8 -3
- package/dist/{errorHandler-2p4SL5zm.mjs → errorHandler-BiBXtxj4.mjs} +16 -6
- package/dist/{errors-JYc9vwqE.d.mts → errors-DTo0me1o.d.mts} +0 -2
- package/dist/{errors-grZkIA8N.mjs → errors-DnrUChAy.mjs} +2 -3
- package/dist/{eventPlugin-BtmA4-3P.d.mts → eventPlugin-BY38F6yK.d.mts} +1 -7
- package/dist/{eventPlugin-ItcYBGUs.mjs → eventPlugin-BhKLUe7H.mjs} +10 -12
- package/dist/{eventTypes-Ck6fD3ne.mjs → eventTypes-CCIRGakw.mjs} +5 -8
- package/dist/events/index.d.mts +5 -17
- package/dist/events/index.mjs +9 -9
- package/dist/events/transports/redis-stream-entry.d.mts +1 -1
- package/dist/events/transports/redis-stream-entry.mjs +5 -6
- package/dist/events/transports/redis.d.mts +2 -4
- package/dist/events/transports/redis.mjs +3 -4
- package/dist/{externalPaths-CmGOxOtD.d.mts → externalPaths-BOqdq5wr.d.mts} +0 -2
- package/dist/factory/index.d.mts +4 -14
- package/dist/factory/index.mjs +12 -18
- package/dist/{fastify-augmentation-DRlCIWE9.d.mts → fastify-augmentation-bzkWPt1f.d.mts} +4 -10
- package/dist/{fields-BRX0Krcj.mjs → fields-CYdpcV73.mjs} +2 -3
- package/dist/{fields-BBSpf8pS.d.mts → fields-JTkrtO-r.d.mts} +0 -2
- package/dist/{filter-merge-CDc7YMwX.mjs → filter-merge-6kasezRH.mjs} +2 -3
- package/dist/{generate-DCGuEbqI.d.mts → generate-C-g_KOkV.d.mts} +0 -4
- package/dist/{generate-hvg7V2g1.mjs → generate-DUkcbc4r.mjs} +7 -12
- package/dist/{headers-Cqkg4LzI.mjs → headers-KxhrKevA.mjs} +3 -4
- package/dist/{health-PVt0VjOx.mjs → health-CRJg3IIq.mjs} +2 -3
- package/dist/{health-DyeP3mTW.mjs → health-jkYNdobJ.mjs} +4 -7
- package/dist/hooks/index.d.mts +1 -1
- package/dist/hooks/index.mjs +2 -2
- package/dist/http-cache/index.d.mts +211 -0
- package/dist/http-cache/index.mjs +605 -0
- package/dist/http-cache/purgers/cloudflare.d.mts +13 -0
- package/dist/http-cache/purgers/cloudflare.mjs +46 -0
- package/dist/http-cache/purgers/fastly.d.mts +12 -0
- package/dist/http-cache/purgers/fastly.mjs +47 -0
- package/dist/http-cache/testing/index.d.mts +68 -0
- package/dist/http-cache/testing/index.mjs +168 -0
- package/dist/idempotency/index.d.mts +3 -9
- package/dist/idempotency/index.mjs +11 -14
- package/dist/idempotency/redis.d.mts +1 -1
- package/dist/idempotency/redis.mjs +3 -4
- package/dist/{index-Bxriq3so.d.mts → index-B5i9-vuP.d.mts} +4 -26
- package/dist/{index-Chgz3d0i.d.mts → index-BAXDo5eE.d.mts} +1 -7
- package/dist/{index-Beg3aNnK.d.mts → index-BxZS-8So.d.mts} +67 -25
- package/dist/{index-WH7xgvxS.d.mts → index-Cy2-QffW.d.mts} +40 -92
- package/dist/{index-uhkUA5-U.d.mts → index-D1X_C_qz.d.mts} +13 -23
- package/dist/{index-CUJvoyw3.d.mts → index-DFCCQ9AE.d.mts} +2 -24
- package/dist/index.d.mts +7 -9
- package/dist/index.mjs +12 -13
- package/dist/{init-jC3rMPzb.mjs → init-CACwpktI.mjs} +18 -35
- package/dist/{init-Cscs4lab.d.mts → init-CV2_Fw3H.d.mts} +0 -4
- package/dist/integrations/event-gateway.d.mts +3 -5
- package/dist/integrations/event-gateway.mjs +3 -4
- package/dist/integrations/index.d.mts +3 -3
- package/dist/integrations/index.mjs +1 -1
- package/dist/integrations/jobs/index.d.mts +1 -1
- package/dist/integrations/jobs/index.mjs +7 -11
- package/dist/integrations/mcp/index.d.mts +7 -39
- package/dist/integrations/mcp/index.mjs +8 -14
- package/dist/integrations/mcp/testing.d.mts +3 -5
- package/dist/integrations/mcp/testing.mjs +3 -4
- package/dist/integrations/streamline.d.mts +1 -3
- package/dist/integrations/streamline.mjs +4 -5
- package/dist/integrations/webhooks.d.mts +2 -4
- package/dist/integrations/webhooks.mjs +5 -5
- package/dist/integrations/websocket-pushref-redis.d.mts +2 -4
- package/dist/integrations/websocket-pushref-redis.mjs +2 -3
- package/dist/integrations/websocket-redis.d.mts +2 -4
- package/dist/integrations/websocket-redis.mjs +2 -3
- package/dist/integrations/websocket.d.mts +2 -2
- package/dist/integrations/websocket.mjs +13 -24
- package/dist/{interface-JJzwH4Ro.d.mts → interface-BmExzQRD.d.mts} +0 -2
- package/dist/{interface-BOk3YnTz.d.mts → interface-WR1U0K7t.d.mts} +0 -2
- package/dist/{jsonBody-ptwyzZQ-.mjs → jsonBody-CzDBkCme.mjs} +3 -4
- package/dist/{keys-C1vFuSbv.mjs → keys-Cbwf6r1B.mjs} +2 -3
- package/dist/{loadResources-CHPDyIPn.mjs → loadResources-Kr6vuljv.mjs} +4 -5
- package/dist/{loadResourcesFromEntry-BkHHTu_B.mjs → loadResourcesFromEntry-D2e0qoDR.mjs} +3 -4
- package/dist/logger/index.d.mts +1 -3
- package/dist/logger/index.mjs +2 -2
- package/dist/{logger-C5bvCiAK.mjs → logger-C110X5Yz.mjs} +3 -5
- package/dist/{mcpPlugin-C9qohJCF.mjs → mcpPlugin-4lIPr9OJ.mjs} +41 -60
- package/dist/{memory-CxiTwT0j.mjs → memory-D9qkhXiB.mjs} +4 -5
- package/dist/{metrics-Ckp2zRy-.mjs → metrics-B-qrrWfI.mjs} +4 -5
- package/dist/middleware/index.d.mts +1 -5
- package/dist/middleware/index.mjs +4 -5
- package/dist/migrations/index.d.mts +0 -2
- package/dist/migrations/index.mjs +3 -4
- package/dist/{module-CfnKuIuH.mjs → module-BD8xHgrz.mjs} +2 -3
- package/dist/{multiTenant-CAtYlW6H.d.mts → multiTenant-KZj8j1uJ.d.mts} +1 -5
- package/dist/{multipartBody-BFasGtP9.mjs → multipartBody-qU7KCn1l.mjs} +2 -3
- package/dist/observeSend-BnPtTotW.mjs +20 -0
- package/dist/{openapi-DAPxjYHX.mjs → openapi-DoVa5SVP.mjs} +18 -28
- package/dist/outbox-admin/index.d.mts +2 -4
- package/dist/outbox-admin/index.mjs +6 -7
- package/dist/{outbox-module-gZCHoE4H.d.mts → outbox-module-5Mnwcycy.d.mts} +3 -9
- package/dist/outbox-module-DyITEIop.mjs +297 -0
- package/dist/permissions/index.d.mts +4 -4
- package/dist/permissions/index.mjs +7 -7
- package/dist/{permissions-B14c3OMp.mjs → permissions-BBy4bOGi.mjs} +19 -29
- package/dist/{pipe-CQv7PsAK.mjs → pipe-BOm2o4UA.mjs} +3 -4
- package/dist/pipeline/index.d.mts +1 -9
- package/dist/pipeline/index.mjs +5 -8
- package/dist/{plan-CpnTykjb.mjs → plan-DDIGwuxr.mjs} +5 -9
- package/dist/{plugin-DXTjVg_Q.mjs → plugin-Bn4D_0XK.mjs} +156 -64
- package/dist/plugins/index.d.mts +8 -16
- package/dist/plugins/index.mjs +22 -26
- package/dist/plugins/response-cache.d.mts +2 -4
- package/dist/plugins/response-cache.mjs +10 -10
- package/dist/plugins/tracing-entry.d.mts +1 -1
- package/dist/plugins/tracing-entry.mjs +3 -4
- package/dist/{pluralize-C3VJKRGp.mjs → pluralize-ClEjcKlG.mjs} +2 -3
- package/dist/policy.types-DPqToKG1.d.mts +50 -0
- package/dist/presets/filesUpload.d.mts +4 -6
- package/dist/presets/filesUpload.mjs +6 -7
- package/dist/presets/index.d.mts +3 -19
- package/dist/presets/index.mjs +2 -2
- package/dist/presets/multiTenant.d.mts +1 -1
- package/dist/presets/multiTenant.mjs +7 -7
- package/dist/presets/search.d.mts +3 -5
- package/dist/presets/search.mjs +3 -4
- package/dist/{presets-CquqYJPy.mjs → presets-DK2jh5YR.mjs} +11 -18
- package/dist/{projection-CgfSLOSM.mjs → projection-BHH-sXyS.mjs} +3 -4
- package/dist/purger.types-2wNJK_89.mjs +24 -0
- package/dist/purger.types-DvPp4-yd.d.mts +26 -0
- package/dist/{pushref-registry-UxCkoA4C.d.mts → pushref-registry-d86QUaSq.d.mts} +0 -6
- package/dist/{queryCachePlugin-D0HUISHJ.mjs → queryCachePlugin-Ckqe98AM.mjs} +8 -10
- package/dist/{queryCachePlugin-C2lZjTxk.d.mts → queryCachePlugin-DYQUyeJ9.d.mts} +2 -4
- package/dist/{rateLimitKey-AvkBOMkl.mjs → rateLimitKey-CWAjlqcN.mjs} +2 -3
- package/dist/{realtime-CbWtVbqK.mjs → realtime-BIJi9USY.mjs} +17 -19
- package/dist/{redis-BDgv9Glw.d.mts → redis-RpDMemdm.d.mts} +2 -4
- package/dist/{redis-stream-BMk-bpQS.d.mts → redis-stream-CS1N9dwM.d.mts} +1 -3
- package/dist/{redisShapes-CQksY67q.d.mts → redisShapes-CqBXTn_s.d.mts} +0 -2
- package/dist/registry/index.d.mts +2 -12
- package/dist/registry/index.mjs +3 -3
- package/dist/{registry-BVwpAuFI.mjs → registry-y9ZA-R_J.mjs} +7 -12
- package/dist/{outbox-module-B4FAkx3A.mjs → relay-BNrC1CEP.mjs} +8 -306
- package/dist/{renewingLease-CykpeNcQ.mjs → renewingLease-CS43br5E.mjs} +2 -3
- package/dist/{replyHelpers-DA51IZio.mjs → replyHelpers-oZDzakGb.mjs} +3 -4
- package/dist/{requestContext-DIWHKDtQ.mjs → requestContext-fWb_YaV2.mjs} +2 -3
- package/dist/{requirement-Cp_fsMDL.mjs → requirement--2hWyyHi.mjs} +2 -3
- package/dist/{requirement-CbiLdQ1n.d.mts → requirement-CTRQjjQx.d.mts} +0 -2
- package/dist/{resourceRateLimit-BFuluodF.mjs → resourceRateLimit-1WbcyMZY.mjs} +3 -4
- package/dist/{resourceRateLimit-Wf6d6FL9.d.mts → resourceRateLimit-DCWglD7V.d.mts} +1 -3
- package/dist/{rolldown-runtime-D_lMdYOd.mjs → rolldown-runtime-yH2lHMo_.mjs} +2 -3
- package/dist/{routeValidator-DuLonYwr.mjs → routeValidator-BSlRIA5c.mjs} +2 -3
- package/dist/{runtimeCapabilities-CydRfm0i.mjs → runtimeCapabilities-CYCEtU1W.mjs} +2 -3
- package/dist/{schedules-B693KXxa.mjs → schedules-B5WGlYIT.mjs} +132 -9
- package/dist/{schemaConverter-DNvZWTV6.mjs → schemaConverter-DtNvts-6.mjs} +3 -4
- package/dist/{schemaIR-REV2y7Wd.mjs → schemaIR-uS_RHqa3.mjs} +3 -4
- package/dist/schemas/index.d.mts +0 -2
- package/dist/schemas/index.mjs +2 -3
- package/dist/scim/index.d.mts +0 -12
- package/dist/scim/index.mjs +10 -18
- package/dist/scope/index.d.mts +2 -6
- package/dist/scope/index.mjs +5 -5
- package/dist/{scope-Bevxy_ST.mjs → scope-BwVLSyNG.mjs} +5 -6
- package/dist/{sessionManager-qimlKV0P.d.mts → sessionManager-CdvDF04x.d.mts} +2 -4
- package/dist/{shutdown-CfrqPR7A.mjs → shutdown-BJiJN7FT.mjs} +2 -3
- package/dist/{simpleEqualityMatcher-BJwfuRKP.mjs → simpleEqualityMatcher-DGRLq-1k.mjs} +2 -3
- package/dist/{sse-CuNNWr2z.mjs → sse-B_50llZu.mjs} +8 -9
- package/dist/{sseStream-C_2ujAVY.mjs → sseStream-BjSo9Ult.mjs} +3 -4
- package/dist/{storage-Cx9Sz3Ou.d.mts → storage-odC5MNKN.d.mts} +0 -2
- package/dist/{store-helpers-C8uBGCbb.mjs → store-helpers-D-n5cwy5.mjs} +2 -3
- package/dist/{streaming-Bdq_M4d5.mjs → streaming-Dcgqa-hH.mjs} +2 -3
- package/dist/{subscriberIdentity-B-KpZkdl.mjs → subscriberIdentity-C9KhIXTF.mjs} +2 -3
- package/dist/{tenancy-C5PCvm1h.mjs → tenancy-COrhjPRZ.mjs} +3 -4
- package/dist/{tenantPreparation-dYvWrgNa.mjs → tenantPreparation-BElWHytd.mjs} +5 -6
- package/dist/testing/cleanupStoreContract.d.mts +2 -4
- package/dist/testing/cleanupStoreContract.mjs +2 -3
- package/dist/testing/index.d.mts +6 -32
- package/dist/testing/index.mjs +24 -37
- package/dist/testing/outboxStoreContract.d.mts +1 -3
- package/dist/testing/outboxStoreContract.mjs +3 -4
- package/dist/testing/requiredPorts.d.mts +2 -4
- package/dist/testing/requiredPorts.mjs +3 -4
- package/dist/testing/storageContract.d.mts +2 -4
- package/dist/testing/storageContract.mjs +2 -3
- package/dist/{timing-DCqsezX8.mjs → timing-CaxKbRk_.mjs} +3 -5
- package/dist/{tracing-Dro5eH6j.d.mts → tracing-JSFiBl5r.d.mts} +0 -2
- package/dist/{transactionContext-DrcNyjpv.mjs → transactionContext-8qKON0Nk.mjs} +2 -3
- package/dist/{typeGuards-CEl10KPy.mjs → typeGuards-DVjVSsXO.mjs} +2 -3
- package/dist/types/index.d.mts +4 -4
- package/dist/types/index.mjs +1 -1
- package/dist/types/storage.d.mts +1 -1
- package/dist/types/storage.mjs +1 -1
- package/dist/{types-ByHn9rEO.d.mts → types-0Dqlbgn8.d.mts} +0 -2
- package/dist/{types-BJ-2XqVF.d.mts → types-BeEJm-DV.d.mts} +114 -14
- package/dist/{types-DVLddu2q.d.mts → types-C0YJAiL0.d.mts} +0 -2
- package/dist/{types-D9NWjpYc.mjs → types-DZHqOuJE.mjs} +5 -6
- package/dist/{types-D3Ixsh00.d.mts → types-DeLiuaNv.d.mts} +2 -4
- package/dist/{types-Ddl9OjmE.d.mts → types-DnkIALZ8.d.mts} +0 -4
- package/dist/usage/index.d.mts +2 -10
- package/dist/usage/index.mjs +8 -12
- package/dist/{userHelpers-BHig1kHq.mjs → userHelpers-_eGj6kf0.mjs} +2 -3
- package/dist/utils/index.d.mts +5 -39
- package/dist/utils/index.mjs +12 -12
- package/dist/{utils-BG5P7_Vb.mjs → utils-Dd6MWpye.mjs} +20 -30
- package/dist/{validate-D_mdOCir.mjs → validate-BaF5wd0x.mjs} +5 -7
- package/dist/{versioning-DBGHjPh7.mjs → versioning-DyV7mwtK.mjs} +4 -5
- package/dist/{versioning-Bqm_57Qt.d.mts → versioning-S18y2-0C.d.mts} +1 -15
- package/dist/{websocket-Cs4awVyD.d.mts → websocket-BGuc-WVZ.d.mts} +1 -15
- package/dist/{workScope-DPPfM4m6.mjs → workScope-CmCBUmPR.mjs} +3 -4
- package/llms.txt +37 -30
- package/package.json +51 -22
- package/skills/arc/SKILL.md +65 -844
- package/skills/arc/references/agent-auth.md +82 -193
- package/skills/arc/references/api-reference.md +41 -245
- package/skills/arc/references/auth-api-keys.md +99 -0
- package/skills/arc/references/auth-better-auth-overlay.md +87 -0
- package/skills/arc/references/auth-better-auth.md +78 -0
- package/skills/arc/references/auth-permissions.md +100 -0
- package/skills/arc/references/auth-strategies.md +122 -0
- package/skills/arc/references/boot.md +80 -0
- package/skills/arc/references/enterprise-auth.md +65 -81
- package/skills/arc/references/events-outbox.md +90 -0
- package/skills/arc/references/events.md +75 -440
- package/skills/arc/references/integrations-jobs.md +74 -0
- package/skills/arc/references/integrations-realtime.md +84 -0
- package/skills/arc/references/integrations-webhooks.md +71 -0
- package/skills/arc/references/integrations-workflows.md +47 -0
- package/skills/arc/references/mcp-auth.md +83 -0
- package/skills/arc/references/mcp-custom-tools.md +125 -0
- package/skills/arc/references/mcp-setup.md +115 -0
- package/skills/arc/references/mcp-testing.md +63 -0
- package/skills/arc/references/multi-tenancy.md +56 -230
- package/skills/arc/references/permissions-scope.md +81 -0
- package/skills/arc/references/production-api.md +119 -0
- package/skills/arc/references/production-audit.md +101 -0
- package/skills/arc/references/production-boot.md +91 -0
- package/skills/arc/references/production-caching.md +63 -0
- package/skills/arc/references/production-distributed.md +75 -0
- package/skills/arc/references/production-idempotency.md +83 -0
- package/skills/arc/references/production-observability.md +83 -0
- package/skills/arc/references/production-realtime.md +70 -0
- package/skills/arc/references/production-reliability.md +100 -0
- package/skills/arc/references/production-shutdown.md +43 -0
- package/skills/arc/references/querying.md +76 -0
- package/skills/arc/references/resources.md +97 -0
- package/skills/arc/references/schedules.md +79 -0
- package/skills/arc/references/scim.md +61 -208
- package/skills/arc/references/tenancy-scope-install.md +82 -0
- package/skills/arc/references/testing.md +101 -144
- package/skills/arc/references/usage-cleanup-capabilities.md +45 -0
- package/skills/arc/references/validation.md +91 -0
- package/skills/arc/references/writes-hooks-errors.md +80 -0
- package/skills/arc-code-review/SKILL.md +67 -114
- package/skills/arc-code-review/references/arc-cheatsheet.md +68 -167
- package/skills/arc-code-review/references/mongokit-repositories.md +104 -0
- package/skills/arc-code-review/references/recipe-events-cache-jobs.md +112 -0
- package/skills/arc-code-review/references/recipe-resource.md +100 -0
- package/skills/arc-code-review/references/recipe-schemas-fields.md +93 -0
- package/skills/arc-code-review/references/recipe-scope-permissions.md +82 -0
- package/skills/arc-code-review/references/scaffolding.md +61 -198
- package/skills/arc-code-review/references/severity.md +49 -102
- package/skills/arc-code-review/references/smells-auth-scope.md +80 -0
- package/skills/arc-code-review/references/smells-data-events.md +66 -0
- package/skills/arc-code-review/references/smells-imports-style.md +59 -0
- package/skills/arc-code-review/references/smells-platform.md +89 -0
- package/skills/arc-code-review/references/smells-routes-schemas.md +66 -0
- package/skills/arc-module-publishing/SKILL.md +82 -208
- package/skills/arc-module-publishing/references/action-presets-and-plugins.md +87 -0
- package/skills/arc-module-publishing/references/build-and-types.md +73 -0
- package/skills/arc-module-publishing/references/module-lifecycle.md +101 -0
- package/skills/arc-module-publishing/references/package-manifest.md +34 -122
- package/skills/arc-module-publishing/references/publishing-workflow.md +44 -140
- package/skills/arc-module-publishing/references/resource-assembly.md +102 -0
- package/skills/arc-module-publishing/references/testing-packages.md +82 -0
- package/skills/arc/references/auth.md +0 -729
- package/skills/arc/references/integrations.md +0 -452
- package/skills/arc/references/mcp.md +0 -691
- package/skills/arc/references/production.md +0 -835
- package/skills/arc-code-review/references/anti-patterns.md +0 -1008
- package/skills/arc-code-review/references/migration-recipes.md +0 -649
- package/skills/arc-code-review/references/mongokit-migration.md +0 -360
- package/skills/arc-module-publishing/references/authoring-modules.md +0 -327
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
/*! @classytic/arc v2.
|
|
1
|
+
/*! @classytic/arc v2.47.0 | MIT | https://classytic.com */
|
|
2
2
|
import { AsyncLocalStorage } from "node:async_hooks";
|
|
3
|
-
|
|
3
|
+
// src/logger/scope.ts
|
|
4
4
|
/**
|
|
5
5
|
* Internal — NOT a package entry. The per-app logger scope that
|
|
6
6
|
* `@classytic/arc/logger` resolves against, plus the one hook-shaped entry
|
|
@@ -30,8 +30,7 @@ const arcLoggerScope = new AsyncLocalStorage();
|
|
|
30
30
|
function enterArcLoggerScope(options, done) {
|
|
31
31
|
arcLoggerScope.run(options, done);
|
|
32
32
|
}
|
|
33
|
-
|
|
34
|
-
//#region src/logger/index.ts
|
|
33
|
+
// src/logger/index.ts
|
|
35
34
|
let globalOptions = {};
|
|
36
35
|
/** Active options: the app's if we're inside one, else the process fallback. */
|
|
37
36
|
function resolveOptions() {
|
|
@@ -156,5 +155,4 @@ function isSuppressed() {
|
|
|
156
155
|
const env = typeof process !== "undefined" ? process.env?.ARC_SUPPRESS_WARNINGS : void 0;
|
|
157
156
|
return env === "1" || env === "true";
|
|
158
157
|
}
|
|
159
|
-
//#endregion
|
|
160
158
|
export { enterArcLoggerScope as a, runWithArcLogger as i, configureArcLogger as n, createPinoWriter as r, arcLog as t };
|
|
@@ -1,31 +1,31 @@
|
|
|
1
|
-
/*! @classytic/arc v2.
|
|
2
|
-
import { t as arcLog } from "./logger-
|
|
3
|
-
import { i as NotFoundError, p as isArcError, t as ArcError } from "./errors-
|
|
4
|
-
import {
|
|
5
|
-
import { n as requireSingleHeaderValue } from "./headers-
|
|
6
|
-
import { b as isElevated, c as getOrgId, g as getUserId, x as isMember } from "./types-
|
|
7
|
-
import { a as resolveEffectiveRoles, t as applyFieldReadPermissions } from "./fields-
|
|
8
|
-
import { o as toJsonSchema } from "./schemaConverter-
|
|
9
|
-
import { t as buildRequestScopeProjection } from "./projection-
|
|
10
|
-
import { l as resolvePipelineSteps, t as resolveActionPermission } from "./actionPermissions-
|
|
11
|
-
import { a as withoutTenantInjection, r as prepareTenantContext } from "./tenantPreparation-
|
|
12
|
-
import { r as evaluatePermissionDecision } from "./authorizationDecision-
|
|
13
|
-
import { n as declareRuntimeCapability } from "./runtimeCapabilities-
|
|
14
|
-
import { t as executePipeline } from "./pipe-
|
|
15
|
-
import { a as resourceRateLimitWindowMs, i as resolveResourceRateLimiter, t as createMemoryResourceRateLimiter } from "./resourceRateLimit-
|
|
16
|
-
import { n as evictToSize, r as touch, t as assertCapacity } from "./boundedMap-
|
|
17
|
-
import { t as pluralize } from "./pluralize-
|
|
18
|
-
import { n as createIdempotencyResult, r as operationIdentity, t as resolveIdempotencyTiming } from "./timing-
|
|
19
|
-
import { n as acquireIdempotencyKey, r as releaseIdempotencyLock } from "./acquire-
|
|
20
|
-
import { r as shouldRejectAdditionalProperties, t as normalizeSchemaIR } from "./schemaIR-
|
|
21
|
-
import { n as validateAggregations } from "./validate-
|
|
22
|
-
import { n as executeAggregation } from "./buildHandler-
|
|
1
|
+
/*! @classytic/arc v2.47.0 | MIT | https://classytic.com */
|
|
2
|
+
import { t as arcLog } from "./logger-C110X5Yz.mjs";
|
|
3
|
+
import { i as NotFoundError, p as isArcError, t as ArcError } from "./errors-DnrUChAy.mjs";
|
|
4
|
+
import { f as BaseController, n as normalizeActionsToRouterConfig, r as resolveActionTargetFence } from "./plugin-Bn4D_0XK.mjs";
|
|
5
|
+
import { n as requireSingleHeaderValue } from "./headers-KxhrKevA.mjs";
|
|
6
|
+
import { b as isElevated, c as getOrgId, g as getUserId, x as isMember } from "./types-DZHqOuJE.mjs";
|
|
7
|
+
import { a as resolveEffectiveRoles, t as applyFieldReadPermissions } from "./fields-CYdpcV73.mjs";
|
|
8
|
+
import { o as toJsonSchema } from "./schemaConverter-DtNvts-6.mjs";
|
|
9
|
+
import { t as buildRequestScopeProjection } from "./projection-BHH-sXyS.mjs";
|
|
10
|
+
import { l as resolvePipelineSteps, t as resolveActionPermission } from "./actionPermissions-DXrlWHHK.mjs";
|
|
11
|
+
import { a as withoutTenantInjection, r as prepareTenantContext } from "./tenantPreparation-BElWHytd.mjs";
|
|
12
|
+
import { r as evaluatePermissionDecision } from "./authorizationDecision-DYiubkYw.mjs";
|
|
13
|
+
import { n as declareRuntimeCapability } from "./runtimeCapabilities-CYCEtU1W.mjs";
|
|
14
|
+
import { t as executePipeline } from "./pipe-BOm2o4UA.mjs";
|
|
15
|
+
import { a as resourceRateLimitWindowMs, i as resolveResourceRateLimiter, t as createMemoryResourceRateLimiter } from "./resourceRateLimit-1WbcyMZY.mjs";
|
|
16
|
+
import { n as evictToSize, r as touch, t as assertCapacity } from "./boundedMap-CtdzpJ3X.mjs";
|
|
17
|
+
import { t as pluralize } from "./pluralize-ClEjcKlG.mjs";
|
|
18
|
+
import { n as createIdempotencyResult, r as operationIdentity, t as resolveIdempotencyTiming } from "./timing-CaxKbRk_.mjs";
|
|
19
|
+
import { n as acquireIdempotencyKey, r as releaseIdempotencyLock } from "./acquire-DoFX06fm.mjs";
|
|
20
|
+
import { r as shouldRejectAdditionalProperties, t as normalizeSchemaIR } from "./schemaIR-uS_RHqa3.mjs";
|
|
21
|
+
import { n as validateAggregations } from "./validate-BaF5wd0x.mjs";
|
|
22
|
+
import { n as executeAggregation } from "./buildHandler-CARdmPNo.mjs";
|
|
23
23
|
import { ARC_ERROR_CODES, isHttpError, toErrorContract } from "@classytic/repo-core/errors";
|
|
24
24
|
import { createHash, randomUUID } from "node:crypto";
|
|
25
25
|
import fp from "fastify-plugin";
|
|
26
26
|
import { IdempotencyError, fingerprintRequest } from "@classytic/repo-core/idempotency";
|
|
27
27
|
import { z } from "zod";
|
|
28
|
-
|
|
28
|
+
// src/integrations/mcp/createMcpServer.ts
|
|
29
29
|
/**
|
|
30
30
|
* @classytic/arc — createMcpServer()
|
|
31
31
|
*
|
|
@@ -184,8 +184,7 @@ function registerPrompt(server, prompt) {
|
|
|
184
184
|
if (prompt.argsSchema) config.argsSchema = prompt.argsSchema;
|
|
185
185
|
srv.registerPrompt(prompt.name, config, (args) => prompt.handler(args));
|
|
186
186
|
}
|
|
187
|
-
|
|
188
|
-
//#region src/integrations/mcp/buildRequestContext.ts
|
|
187
|
+
// src/integrations/mcp/buildRequestContext.ts
|
|
189
188
|
/**
|
|
190
189
|
* @classytic/arc — MCP → IRequestContext Bridge
|
|
191
190
|
*
|
|
@@ -407,8 +406,7 @@ function normalizeScopeContext(value) {
|
|
|
407
406
|
for (const [k, v] of Object.entries(value)) if (typeof v === "string") out[k] = v;
|
|
408
407
|
return Object.keys(out).length > 0 ? Object.freeze(out) : void 0;
|
|
409
408
|
}
|
|
410
|
-
|
|
411
|
-
//#region src/integrations/mcp/tool-helpers.ts
|
|
409
|
+
// src/integrations/mcp/tool-helpers.ts
|
|
412
410
|
/**
|
|
413
411
|
* Evaluate a resource's permission check in MCP context.
|
|
414
412
|
*
|
|
@@ -574,8 +572,7 @@ function createMcpController(resource) {
|
|
|
574
572
|
matchesFilter: resource.adapter?.matchesFilter
|
|
575
573
|
});
|
|
576
574
|
}
|
|
577
|
-
|
|
578
|
-
//#region src/integrations/mcp/http-parity.ts
|
|
575
|
+
// src/integrations/mcp/http-parity.ts
|
|
579
576
|
/**
|
|
580
577
|
* The gates an HTTP route applies that an MCP tool must apply too, because a tool calls the
|
|
581
578
|
* controller or action handler directly and skips the route: idempotent execution, the
|
|
@@ -704,8 +701,7 @@ async function auditToolAction(audit, args) {
|
|
|
704
701
|
}, "[arc/mcp] action audit write failed");
|
|
705
702
|
}
|
|
706
703
|
}
|
|
707
|
-
|
|
708
|
-
//#region src/integrations/mcp/invokeController.ts
|
|
704
|
+
// src/integrations/mcp/invokeController.ts
|
|
709
705
|
/**
|
|
710
706
|
* Assemble the {@link McpContextExtras} for a controller invocation from
|
|
711
707
|
* resource-scoped metadata + app-level wiring. Mirrors what
|
|
@@ -863,8 +859,7 @@ function isCallToolResult(value) {
|
|
|
863
859
|
function isControllerResponse(value) {
|
|
864
860
|
return typeof value === "object" && value !== null && "data" in value && !("content" in value);
|
|
865
861
|
}
|
|
866
|
-
|
|
867
|
-
//#region src/integrations/mcp/crud-tools.ts
|
|
862
|
+
// src/integrations/mcp/crud-tools.ts
|
|
868
863
|
const ALL_CRUD_OPS = [
|
|
869
864
|
"list",
|
|
870
865
|
"get",
|
|
@@ -961,8 +956,7 @@ function resolveCrudDescription(override, meta) {
|
|
|
961
956
|
if (typeof override === "string") return override;
|
|
962
957
|
return override(meta);
|
|
963
958
|
}
|
|
964
|
-
|
|
965
|
-
//#region src/integrations/mcp/fieldRulesToZod.ts
|
|
959
|
+
// src/integrations/mcp/fieldRulesToZod.ts
|
|
966
960
|
/**
|
|
967
961
|
* @classytic/arc — fieldRules → Zod Shape Converter
|
|
968
962
|
*
|
|
@@ -1119,8 +1113,7 @@ function buildListShape(fieldRules, options) {
|
|
|
1119
1113
|
}
|
|
1120
1114
|
return shape;
|
|
1121
1115
|
}
|
|
1122
|
-
|
|
1123
|
-
//#region src/integrations/mcp/authBridge.ts
|
|
1116
|
+
// src/integrations/mcp/authBridge.ts
|
|
1124
1117
|
/**
|
|
1125
1118
|
* @classytic/arc — MCP Auth Bridge
|
|
1126
1119
|
*
|
|
@@ -1242,8 +1235,7 @@ async function forwardResponse(reply, response) {
|
|
|
1242
1235
|
});
|
|
1243
1236
|
reply.send(await response.text());
|
|
1244
1237
|
}
|
|
1245
|
-
|
|
1246
|
-
//#region src/core/schemaIRZod.ts
|
|
1238
|
+
// src/core/schemaIRZod.ts
|
|
1247
1239
|
/**
|
|
1248
1240
|
* Schema IR → Zod adapter — the MCP-facing half of [schemaIR.ts](./schemaIR.ts).
|
|
1249
1241
|
*
|
|
@@ -1297,8 +1289,7 @@ function jsonSchemaPropToZod(schema) {
|
|
|
1297
1289
|
default: return z.string();
|
|
1298
1290
|
}
|
|
1299
1291
|
}
|
|
1300
|
-
|
|
1301
|
-
//#region src/integrations/mcp/action-tools.ts
|
|
1292
|
+
// src/integrations/mcp/action-tools.ts
|
|
1302
1293
|
/**
|
|
1303
1294
|
* Convert an action's `schema` field into a Zod shape for MCP input.
|
|
1304
1295
|
*
|
|
@@ -1432,8 +1423,7 @@ function createActionToolHandler(actionName, handler, permissions, resourceName,
|
|
|
1432
1423
|
}
|
|
1433
1424
|
};
|
|
1434
1425
|
}
|
|
1435
|
-
|
|
1436
|
-
//#region src/integrations/mcp/aggregation-tools.ts
|
|
1426
|
+
// src/integrations/mcp/aggregation-tools.ts
|
|
1437
1427
|
/**
|
|
1438
1428
|
* Build MCP tools for a resource's aggregations.
|
|
1439
1429
|
*
|
|
@@ -1556,8 +1546,7 @@ function createAggregationToolHandler(args) {
|
|
|
1556
1546
|
return toCallToolError(result.body);
|
|
1557
1547
|
};
|
|
1558
1548
|
}
|
|
1559
|
-
|
|
1560
|
-
//#region src/integrations/mcp/jsonSchemaToZod.ts
|
|
1549
|
+
// src/integrations/mcp/jsonSchemaToZod.ts
|
|
1561
1550
|
/**
|
|
1562
1551
|
* @classytic/arc — JSON Schema → Zod shape converter
|
|
1563
1552
|
*
|
|
@@ -1695,8 +1684,7 @@ function applyDescription(zodType, prop) {
|
|
|
1695
1684
|
if (typeof prop.description === "string" && prop.description.length > 0) return zodType.describe(prop.description);
|
|
1696
1685
|
return zodType;
|
|
1697
1686
|
}
|
|
1698
|
-
|
|
1699
|
-
//#region src/integrations/mcp/input-schema.ts
|
|
1687
|
+
// src/integrations/mcp/input-schema.ts
|
|
1700
1688
|
/**
|
|
1701
1689
|
* MCP tool input schema generation.
|
|
1702
1690
|
*
|
|
@@ -1833,8 +1821,7 @@ function mapJsonSchemaTypeToArcType(jsonType) {
|
|
|
1833
1821
|
default: return "string";
|
|
1834
1822
|
}
|
|
1835
1823
|
}
|
|
1836
|
-
|
|
1837
|
-
//#region src/integrations/mcp/route-input-schema.ts
|
|
1824
|
+
// src/integrations/mcp/route-input-schema.ts
|
|
1838
1825
|
/**
|
|
1839
1826
|
* Custom-route → MCP tool INPUT schema. The route's own schema is the contract:
|
|
1840
1827
|
* an input the REST route would refuse must be refused on MCP, never stripped.
|
|
@@ -1900,8 +1887,7 @@ function toolInputShape(schema) {
|
|
|
1900
1887
|
if (!isZodTypeSchema(schema)) return schema;
|
|
1901
1888
|
return schema instanceof z.ZodObject ? schema.shape : void 0;
|
|
1902
1889
|
}
|
|
1903
|
-
|
|
1904
|
-
//#region src/integrations/mcp/route-tools.ts
|
|
1890
|
+
// src/integrations/mcp/route-tools.ts
|
|
1905
1891
|
/**
|
|
1906
1892
|
* Custom-route → MCP tool generation.
|
|
1907
1893
|
*
|
|
@@ -2059,8 +2045,7 @@ function slugifyRoute(method, path) {
|
|
|
2059
2045
|
const clean = path.replace(/:[^/]+/g, "").replace(/^\/+|\/+$/g, "").replace(/\//g, "_");
|
|
2060
2046
|
return clean ? `${method.toLowerCase()}_${clean}` : method.toLowerCase();
|
|
2061
2047
|
}
|
|
2062
|
-
|
|
2063
|
-
//#region src/integrations/mcp/resourceToTools.ts
|
|
2048
|
+
// src/integrations/mcp/resourceToTools.ts
|
|
2064
2049
|
/**
|
|
2065
2050
|
* @classytic/arc — Resource → MCP Tools orchestrator.
|
|
2066
2051
|
*
|
|
@@ -2303,8 +2288,7 @@ function resourceToTools(resource, config = {}) {
|
|
|
2303
2288
|
}
|
|
2304
2289
|
return tools;
|
|
2305
2290
|
}
|
|
2306
|
-
|
|
2307
|
-
//#region src/integrations/mcp/schemaResources.ts
|
|
2291
|
+
// src/integrations/mcp/schemaResources.ts
|
|
2308
2292
|
/**
|
|
2309
2293
|
* Register MCP Resources for schema discovery.
|
|
2310
2294
|
*/
|
|
@@ -2373,8 +2357,7 @@ function getOps(r, override) {
|
|
|
2373
2357
|
if (override) ops = ops.filter((op) => override.includes(op));
|
|
2374
2358
|
return ops;
|
|
2375
2359
|
}
|
|
2376
|
-
|
|
2377
|
-
//#region src/integrations/mcp/sessionCache.ts
|
|
2360
|
+
// src/integrations/mcp/sessionCache.ts
|
|
2378
2361
|
const DEFAULT_TTL_MS = 18e5;
|
|
2379
2362
|
const DEFAULT_MAX_SESSIONS = 1e3;
|
|
2380
2363
|
var McpSessionCache = class {
|
|
@@ -2460,8 +2443,7 @@ var McpSessionCache = class {
|
|
|
2460
2443
|
} catch {}
|
|
2461
2444
|
}
|
|
2462
2445
|
};
|
|
2463
|
-
|
|
2464
|
-
//#region src/integrations/mcp/mcpPlugin.ts
|
|
2446
|
+
// src/integrations/mcp/mcpPlugin.ts
|
|
2465
2447
|
/**
|
|
2466
2448
|
* @classytic/arc — MCP Plugin (Level 1)
|
|
2467
2449
|
*
|
|
@@ -2839,5 +2821,4 @@ const mcpPlugin = fp(mcpPluginImpl, {
|
|
|
2839
2821
|
name: "arc-mcp",
|
|
2840
2822
|
fastify: "5.x"
|
|
2841
2823
|
});
|
|
2842
|
-
//#endregion
|
|
2843
2824
|
export { resolveToolCollisions as _, toolInputShape as a, resolveCrudDescription as c, permissionDeniedResult as d, toCallToolError as f, createMcpServer as g, buildRequestContext as h, isZodTypeSchema as i, invokeController as l, toCallToolSuccess as m, mcpPlugin as n, fieldRulesToZod as o, toCallToolResult as p, resourceToTools as r, defaultCrudDescription as s, filterResourcesForMcp as t, mcpHandlerAdapter as u };
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
/*! @classytic/arc v2.
|
|
2
|
-
import { t as __exportAll } from "./rolldown-runtime-
|
|
3
|
-
import { n as evictToSize } from "./boundedMap-
|
|
4
|
-
|
|
1
|
+
/*! @classytic/arc v2.47.0 | MIT | https://classytic.com */
|
|
2
|
+
import { t as __exportAll } from "./rolldown-runtime-yH2lHMo_.mjs";
|
|
3
|
+
import { n as evictToSize } from "./boundedMap-CtdzpJ3X.mjs";
|
|
4
|
+
// src/cache/memory.ts
|
|
5
5
|
var memory_exports = /* @__PURE__ */ __exportAll({ MemoryCacheStore: () => MemoryCacheStore });
|
|
6
6
|
/**
|
|
7
7
|
* In-memory LRU+TTL cache store with hard entry cap and memory budget.
|
|
@@ -183,5 +183,4 @@ function globToRegExp(pattern) {
|
|
|
183
183
|
const escaped = pattern.replace(/[.+?^${}()|[\]\\]/g, "\\$&").replace(/\*/g, ".*");
|
|
184
184
|
return new RegExp(`^${escaped}$`);
|
|
185
185
|
}
|
|
186
|
-
//#endregion
|
|
187
186
|
export { memory_exports as n, MemoryCacheStore as t };
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
/*! @classytic/arc v2.
|
|
2
|
-
import { t as __exportAll } from "./rolldown-runtime-
|
|
3
|
-
import { a as MetricHistogram, i as DURATION_BUCKETS_SECONDS, o as MetricSeries, s as renderMetricSample } from "./health-
|
|
1
|
+
/*! @classytic/arc v2.47.0 | MIT | https://classytic.com */
|
|
2
|
+
import { t as __exportAll } from "./rolldown-runtime-yH2lHMo_.mjs";
|
|
3
|
+
import { a as MetricHistogram, i as DURATION_BUCKETS_SECONDS, o as MetricSeries, s as renderMetricSample } from "./health-jkYNdobJ.mjs";
|
|
4
4
|
import fp from "fastify-plugin";
|
|
5
|
-
|
|
5
|
+
// src/plugins/metrics.ts
|
|
6
6
|
var metrics_exports = /* @__PURE__ */ __exportAll({
|
|
7
7
|
default: () => metrics_default,
|
|
8
8
|
metricsPlugin: () => metricsPlugin
|
|
@@ -188,5 +188,4 @@ var metrics_default = fp(metricsPlugin, {
|
|
|
188
188
|
name: "arc-metrics",
|
|
189
189
|
fastify: "5.x"
|
|
190
190
|
});
|
|
191
|
-
//#endregion
|
|
192
191
|
export { metrics_exports as n, metrics_default as t };
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
|
|
2
|
-
import { A as RequestWithExtras, J as MiddlewareConfig, k as MiddlewareHandler } from "../index-
|
|
2
|
+
import { A as RequestWithExtras, J as MiddlewareConfig, k as MiddlewareHandler } from "../index-Cy2-QffW.mjs";
|
|
3
3
|
import { RouteHandlerMethod } from "fastify";
|
|
4
|
-
//#region src/middleware/middleware.d.ts
|
|
5
4
|
interface NamedMiddleware {
|
|
6
5
|
/** Unique name for debugging/introspection */
|
|
7
6
|
readonly name: string;
|
|
@@ -29,8 +28,6 @@ export declare function middleware(name: string, options: MiddlewareOptions): Na
|
|
|
29
28
|
* Returns a MiddlewareConfig map keyed by operation, ready to pass to `defineResource()`.
|
|
30
29
|
*/
|
|
31
30
|
export declare function sortMiddlewares(middlewares: NamedMiddleware[]): MiddlewareConfig;
|
|
32
|
-
//#endregion
|
|
33
|
-
//#region src/middleware/multipartBody.d.ts
|
|
34
31
|
/** Parsed file from multipart form-data */
|
|
35
32
|
interface ParsedFile {
|
|
36
33
|
/** Original filename */
|
|
@@ -121,5 +118,4 @@ interface MultipartBodyOptions {
|
|
|
121
118
|
* the wrong architecture regardless of limits.
|
|
122
119
|
*/
|
|
123
120
|
export declare function multipartBody(options?: MultipartBodyOptions): RouteHandlerMethod;
|
|
124
|
-
//#endregion
|
|
125
121
|
export type { MiddlewareOptions, MultipartBodyOptions, NamedMiddleware, ParsedFile };
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
/*! @classytic/arc v2.
|
|
2
|
-
import { t as CRUD_OPERATIONS } from "../constants-
|
|
3
|
-
import { t as multipartBody } from "../multipartBody-
|
|
4
|
-
|
|
1
|
+
/*! @classytic/arc v2.47.0 | MIT | https://classytic.com */
|
|
2
|
+
import { t as CRUD_OPERATIONS } from "../constants-Cx7BcnHT.mjs";
|
|
3
|
+
import { t as multipartBody } from "../multipartBody-qU7KCn1l.mjs";
|
|
4
|
+
// src/middleware/middleware.ts
|
|
5
5
|
/**
|
|
6
6
|
* Named Middleware — Priority-based, conditional middleware execution.
|
|
7
7
|
*
|
|
@@ -67,5 +67,4 @@ function sortMiddlewares(middlewares) {
|
|
|
67
67
|
}
|
|
68
68
|
return result;
|
|
69
69
|
}
|
|
70
|
-
//#endregion
|
|
71
70
|
export { middleware, multipartBody, sortMiddlewares };
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
|
|
2
2
|
import { LockAdapter } from "@classytic/repo-core/lock";
|
|
3
|
-
//#region src/migrations/index.d.ts
|
|
4
3
|
export interface Migration {
|
|
5
4
|
/** Migration version (sequential number) */
|
|
6
5
|
version: number;
|
|
@@ -289,5 +288,4 @@ export declare class MigrationRegistry {
|
|
|
289
288
|
*/
|
|
290
289
|
clear(): void;
|
|
291
290
|
}
|
|
292
|
-
//#endregion
|
|
293
291
|
export {};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
/*! @classytic/arc v2.
|
|
2
|
-
import { t as startRenewingLease } from "../renewingLease-
|
|
1
|
+
/*! @classytic/arc v2.47.0 | MIT | https://classytic.com */
|
|
2
|
+
import { t as startRenewingLease } from "../renewingLease-CS43br5E.mjs";
|
|
3
3
|
import { createHash, randomUUID } from "node:crypto";
|
|
4
|
-
|
|
4
|
+
// src/migrations/index.ts
|
|
5
5
|
/**
|
|
6
6
|
* Schema Versioning and Migrations System
|
|
7
7
|
*
|
|
@@ -384,5 +384,4 @@ var MigrationRegistry = class {
|
|
|
384
384
|
this.migrations.clear();
|
|
385
385
|
}
|
|
386
386
|
};
|
|
387
|
-
//#endregion
|
|
388
387
|
export { MigrationRegistry, MigrationRunner, MongoMigrationStore, computeMigrationChecksum, defineMigration, withSchemaVersion };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
/*! @classytic/arc v2.
|
|
2
|
-
|
|
1
|
+
/*! @classytic/arc v2.47.0 | MIT | https://classytic.com */
|
|
2
|
+
// src/factory/module/index.ts
|
|
3
3
|
/**
|
|
4
4
|
* Identity helper for authoring a typed module — mirrors `defineResource`.
|
|
5
5
|
* Gives inference + a single obvious construction site; does no work.
|
|
@@ -74,5 +74,4 @@ Composed modules: ${composed.length ? composed.join(", ") : "(none)"}.`);
|
|
|
74
74
|
return resolved;
|
|
75
75
|
};
|
|
76
76
|
}
|
|
77
|
-
//#endregion
|
|
78
77
|
export { lazyModuleExports as a, hasModuleExports as i, getModuleExports as n, lazyRequiredModuleExports as o, getOptionalModuleExports as r, defineModule as t };
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
|
|
2
|
-
import { G as CrudRouteKey, W as PresetResult } from "./index-
|
|
3
|
-
//#region src/permissions/tenantPreparation.d.ts
|
|
2
|
+
import { G as CrudRouteKey, W as PresetResult } from "./index-Cy2-QffW.mjs";
|
|
4
3
|
type TenantFieldSpec = {
|
|
5
4
|
field: string;
|
|
6
5
|
type: "org";
|
|
@@ -11,8 +10,6 @@ type TenantFieldSpec = {
|
|
|
11
10
|
field: string;
|
|
12
11
|
contextKey: string;
|
|
13
12
|
};
|
|
14
|
-
//#endregion
|
|
15
|
-
//#region src/presets/multiTenant.d.ts
|
|
16
13
|
interface MultiTenantOptions {
|
|
17
14
|
/**
|
|
18
15
|
* Single-field form: name of the database field to filter by.
|
|
@@ -100,5 +97,4 @@ interface MultiTenantOptions {
|
|
|
100
97
|
crossTenant?: readonly Extract<CrudRouteKey, "list" | "get">[];
|
|
101
98
|
}
|
|
102
99
|
declare function multiTenantPreset(options?: MultiTenantOptions): PresetResult;
|
|
103
|
-
//#endregion
|
|
104
100
|
export { multiTenantPreset as n, TenantFieldSpec as r, MultiTenantOptions as t };
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
/*! @classytic/arc v2.
|
|
1
|
+
/*! @classytic/arc v2.47.0 | MIT | https://classytic.com */
|
|
2
2
|
import { ARC_ERROR_CODES } from "@classytic/repo-core/errors";
|
|
3
3
|
import sjson from "secure-json-parse";
|
|
4
|
-
|
|
4
|
+
// src/middleware/multipartBody.ts
|
|
5
5
|
/**
|
|
6
6
|
* Multipart Body Middleware — Opt-in multipart/form-data parsing for CRUD routes.
|
|
7
7
|
*
|
|
@@ -180,5 +180,4 @@ function tryParseValue(value) {
|
|
|
180
180
|
} catch {}
|
|
181
181
|
return value;
|
|
182
182
|
}
|
|
183
|
-
//#endregion
|
|
184
183
|
export { multipartBody as t };
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
/*! @classytic/arc v2.47.0 | MIT | https://classytic.com */
|
|
2
|
+
// src/utils/observeSend.ts
|
|
3
|
+
/** Run `fn`, reporting whether it called `reply.send` (or the reply is already sent). */
|
|
4
|
+
async function runObservingSend(reply, fn) {
|
|
5
|
+
let answered = false;
|
|
6
|
+
const send = reply.send;
|
|
7
|
+
reply.send = function trackedSend(payload) {
|
|
8
|
+
answered = true;
|
|
9
|
+
return send.call(this, payload);
|
|
10
|
+
};
|
|
11
|
+
try {
|
|
12
|
+
return {
|
|
13
|
+
result: await fn(),
|
|
14
|
+
answered: answered || reply.sent
|
|
15
|
+
};
|
|
16
|
+
} finally {
|
|
17
|
+
reply.send = send;
|
|
18
|
+
}
|
|
19
|
+
}
|
|
20
|
+
export { runObservingSend as t };
|
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
/*! @classytic/arc v2.
|
|
2
|
-
import { n as getUserRoles } from "./userHelpers-
|
|
3
|
-
import { n as convertRouteSchema } from "./schemaConverter-
|
|
4
|
-
import { t as resolveActionPermission } from "./actionPermissions-
|
|
5
|
-
import { t as pluralize } from "./pluralize-
|
|
6
|
-
import { t as buildActionBodySchema } from "./createActionRouter-
|
|
1
|
+
/*! @classytic/arc v2.47.0 | MIT | https://classytic.com */
|
|
2
|
+
import { n as getUserRoles } from "./userHelpers-_eGj6kf0.mjs";
|
|
3
|
+
import { n as convertRouteSchema } from "./schemaConverter-DtNvts-6.mjs";
|
|
4
|
+
import { t as resolveActionPermission } from "./actionPermissions-DXrlWHHK.mjs";
|
|
5
|
+
import { t as pluralize } from "./pluralize-ClEjcKlG.mjs";
|
|
6
|
+
import { t as buildActionBodySchema } from "./createActionRouter-mLAGbpDV.mjs";
|
|
7
7
|
import fp from "fastify-plugin";
|
|
8
|
-
|
|
8
|
+
// src/docs/openapi/canonical-schemas.ts
|
|
9
9
|
/**
|
|
10
10
|
* Static canonical schemas — referenced once, from
|
|
11
11
|
* `components.schemas`. Per-resource schemas (paginated `oneOf` with
|
|
@@ -227,8 +227,7 @@ function buildPaginatedListSchema(itemRef) {
|
|
|
227
227
|
]
|
|
228
228
|
};
|
|
229
229
|
}
|
|
230
|
-
|
|
231
|
-
//#region src/docs/openapi/field-permissions.ts
|
|
230
|
+
// src/docs/openapi/field-permissions.ts
|
|
232
231
|
/**
|
|
233
232
|
* Field permission descriptions — appended to schema-property
|
|
234
233
|
* `description` strings during component generation so codegen surfaces
|
|
@@ -249,8 +248,7 @@ function formatFieldPermDescription(perm) {
|
|
|
249
248
|
default: return perm.type;
|
|
250
249
|
}
|
|
251
250
|
}
|
|
252
|
-
|
|
253
|
-
//#region src/docs/openapi/components.ts
|
|
251
|
+
// src/docs/openapi/components.ts
|
|
254
252
|
/**
|
|
255
253
|
* Generate component schema definitions from pre-stored registry
|
|
256
254
|
* schemas.
|
|
@@ -346,8 +344,7 @@ function generateSchemas(resources) {
|
|
|
346
344
|
}
|
|
347
345
|
return schemas;
|
|
348
346
|
}
|
|
349
|
-
|
|
350
|
-
//#region src/docs/openapi/operations.ts
|
|
347
|
+
// src/docs/openapi/operations.ts
|
|
351
348
|
/**
|
|
352
349
|
* Standard error responses that every CRUD route ships. Per-route
|
|
353
350
|
* additions (e.g. 404 on get/update/delete, 409 on create/update) are
|
|
@@ -455,8 +452,7 @@ function describePermissionForOpenApi(check) {
|
|
|
455
452
|
if (Array.isArray(fn._orgRoles) && fn._orgRoles.length > 0) result.orgRoles = fn._orgRoles;
|
|
456
453
|
return result;
|
|
457
454
|
}
|
|
458
|
-
|
|
459
|
-
//#region src/docs/openapi/parameters.ts
|
|
455
|
+
// src/docs/openapi/parameters.ts
|
|
460
456
|
/**
|
|
461
457
|
* Default query parameters for list endpoints when the resource hasn't
|
|
462
458
|
* provided an explicit `openApiSchemas.listQuery` schema. These match
|
|
@@ -535,8 +531,7 @@ function extractPathParams(path) {
|
|
|
535
531
|
}
|
|
536
532
|
return params;
|
|
537
533
|
}
|
|
538
|
-
|
|
539
|
-
//#region src/docs/openapi/action-paths.ts
|
|
534
|
+
// src/docs/openapi/action-paths.ts
|
|
540
535
|
/**
|
|
541
536
|
* Action endpoint emitter — `POST /:resource/:id/action` and/or
|
|
542
537
|
* `POST /:resource/action`.
|
|
@@ -628,8 +623,7 @@ function emitMount(paths, resource, basePath, additionalSecurity, subsetActions,
|
|
|
628
623
|
}
|
|
629
624
|
}, anyAuthRequired, additionalSecurity);
|
|
630
625
|
}
|
|
631
|
-
|
|
632
|
-
//#region src/docs/openapi/aggregation-paths.ts
|
|
626
|
+
// src/docs/openapi/aggregation-paths.ts
|
|
633
627
|
/**
|
|
634
628
|
* Emit one OpenAPI path entry per declared aggregation.
|
|
635
629
|
*
|
|
@@ -776,8 +770,7 @@ function setNestedSchemaProp(target, path, leaf) {
|
|
|
776
770
|
if (!nested.properties) nested.properties = {};
|
|
777
771
|
setNestedSchemaProp(nested.properties, rest, leaf);
|
|
778
772
|
}
|
|
779
|
-
|
|
780
|
-
//#region src/docs/openapi/crud-paths.ts
|
|
773
|
+
// src/docs/openapi/crud-paths.ts
|
|
781
774
|
/**
|
|
782
775
|
* Append the default-CRUD paths (`GET /` list + `POST /` create on the
|
|
783
776
|
* collection path; `GET/PATCH|PUT/DELETE /:id` on the item path).
|
|
@@ -790,6 +783,7 @@ function appendCrudPaths(paths, resource, basePath, additionalSecurity) {
|
|
|
790
783
|
const collectionPath = {};
|
|
791
784
|
if (!disabledSet.has("list")) collectionPath.get = createOperation(resource, "list", "List all", {
|
|
792
785
|
parameters: resource.openApiSchemas?.listQuery ? convertSchemaToParameters(resource.openApiSchemas.listQuery) : DEFAULT_LIST_PARAMS,
|
|
786
|
+
...resource.queryContract && { "x-arc-query": resource.queryContract },
|
|
793
787
|
responses: {
|
|
794
788
|
"200": {
|
|
795
789
|
description: "List of items",
|
|
@@ -874,8 +868,7 @@ function appendCrudPaths(paths, resource, basePath, additionalSecurity) {
|
|
|
874
868
|
}, void 0, additionalSecurity);
|
|
875
869
|
if (Object.keys(itemPath).length > 0) paths[toOpenApiPath(`${basePath}/:id`)] = itemPath;
|
|
876
870
|
}
|
|
877
|
-
|
|
878
|
-
//#region src/docs/openapi/custom-paths.ts
|
|
871
|
+
// src/docs/openapi/custom-paths.ts
|
|
879
872
|
/**
|
|
880
873
|
* Append every entry in `resource.customRoutes` to the `paths` map.
|
|
881
874
|
*/
|
|
@@ -924,8 +917,7 @@ function appendCustomRoutePaths(paths, resource, basePath, additionalSecurity) {
|
|
|
924
917
|
paths[fullPath][method] = createOperation(resource, handlerName, route.summary ?? handlerName, extras, requiresAuthForRoute, additionalSecurity);
|
|
925
918
|
}
|
|
926
919
|
}
|
|
927
|
-
|
|
928
|
-
//#region src/docs/openapi/paths.ts
|
|
920
|
+
// src/docs/openapi/paths.ts
|
|
929
921
|
/**
|
|
930
922
|
* Generate the OpenAPI `paths` entries for a single resource.
|
|
931
923
|
*/
|
|
@@ -938,8 +930,7 @@ function generateResourcePaths(resource, apiPrefix = "", additionalSecurity = []
|
|
|
938
930
|
appendAggregationPaths(paths, resource, basePath, additionalSecurity);
|
|
939
931
|
return paths;
|
|
940
932
|
}
|
|
941
|
-
|
|
942
|
-
//#region src/docs/openapi/index.ts
|
|
933
|
+
// src/docs/openapi/index.ts
|
|
943
934
|
const openApiPlugin = async (fastify, opts = {}) => {
|
|
944
935
|
const { title = "Arc API", version = "1.0.0", description, serverUrl, prefix = "/_docs", apiPrefix = "", authRoles = [] } = opts;
|
|
945
936
|
const buildSpec = () => {
|
|
@@ -1041,5 +1032,4 @@ var openapi_default = fp(openApiPlugin, {
|
|
|
1041
1032
|
name: "arc-openapi",
|
|
1042
1033
|
fastify: "5.x"
|
|
1043
1034
|
});
|
|
1044
|
-
//#endregion
|
|
1045
1035
|
export { openapi_default as n, buildOpenApiSpec as t };
|
|
@@ -1,8 +1,7 @@
|
|
|
1
1
|
|
|
2
|
-
import { l as PermissionCheck } from "../base-
|
|
3
|
-
import { n as ArcModule, u as ModuleName } from "../types-
|
|
2
|
+
import { l as PermissionCheck } from "../base-HXNgPQww.mjs";
|
|
3
|
+
import { n as ArcModule, u as ModuleName } from "../types-BeEJm-DV.mjs";
|
|
4
4
|
import { OutboxStore } from "@classytic/primitives/outbox";
|
|
5
|
-
//#region src/outbox-admin/module.d.ts
|
|
6
5
|
/**
|
|
7
6
|
* A store that can answer an operator's questions.
|
|
8
7
|
*
|
|
@@ -81,5 +80,4 @@ interface OutboxAdminModuleDeps {
|
|
|
81
80
|
relayLagUnhealthyMs?: number;
|
|
82
81
|
}
|
|
83
82
|
export declare function createOutboxAdminModule(deps: OutboxAdminModuleDeps): ArcModule<void>;
|
|
84
|
-
//#endregion
|
|
85
83
|
export type { OutboxAdminModuleDeps, OutboxAdminPermissions, OutboxAdminStore };
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
/*! @classytic/arc v2.
|
|
2
|
-
import { i as NotFoundError, u as ValidationError } from "../errors-
|
|
3
|
-
import { t as defineResource } from "../defineResource-
|
|
4
|
-
import { n as getModuleExports, t as defineModule } from "../module-
|
|
5
|
-
import { r as readOutboxHealth } from "../health-
|
|
6
|
-
|
|
1
|
+
/*! @classytic/arc v2.47.0 | MIT | https://classytic.com */
|
|
2
|
+
import { i as NotFoundError, u as ValidationError } from "../errors-DnrUChAy.mjs";
|
|
3
|
+
import { t as defineResource } from "../defineResource-BROJmhzJ.mjs";
|
|
4
|
+
import { n as getModuleExports, t as defineModule } from "../module-BD8xHgrz.mjs";
|
|
5
|
+
import { r as readOutboxHealth } from "../health-CRJg3IIq.mjs";
|
|
6
|
+
// src/outbox-admin/module.ts
|
|
7
7
|
/**
|
|
8
8
|
* Strip the domain payload and the stack unless explicitly opted in.
|
|
9
9
|
*
|
|
@@ -99,5 +99,4 @@ function createOutboxAdminModule(deps) {
|
|
|
99
99
|
resources: () => [resource]
|
|
100
100
|
});
|
|
101
101
|
}
|
|
102
|
-
//#endregion
|
|
103
102
|
export { createOutboxAdminModule };
|