@makaio/framework 1.0.0-dev-1781022866275 → 1.0.0-dev-1781023871421
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/.makaio-build.json +5 -0
- package/dist/account-identity-DT5NOtFi.mjs +1 -0
- package/dist/adapter-C1eI-fGV.mjs +1 -0
- package/dist/adapters/acp-client/index.d.mts +6208 -0
- package/dist/adapters/acp-client/index.mjs +3 -0
- package/dist/adapters/config/index.d.mts +429 -0
- package/dist/adapters/config/index.mjs +1 -0
- package/dist/adapters/index.d.mts +4202 -0
- package/dist/adapters/index.mjs +18 -0
- package/dist/adapters/node.d.mts +263 -0
- package/dist/adapters/node.mjs +4 -0
- package/dist/adapters/stream-session/index.d.mts +1414 -0
- package/dist/adapters/stream-session/index.mjs +1 -0
- package/dist/adapters/stream-session/testing/index.d.mts +29 -0
- package/dist/adapters/stream-session/testing/index.mjs +1 -0
- package/dist/artifact-B3npq1cy.mjs +1 -0
- package/dist/base-orchestrator-wyumsn3b.d.mts +772 -0
- package/dist/bus/index.d.mts +3994 -0
- package/dist/bus/index.mjs +1 -0
- package/dist/bus-Caz3Jpbc.mjs +1 -0
- package/dist/bus-Hb-LGzgb.mjs +2 -0
- package/dist/capability-service-CJbmhfv9.mjs +1 -0
- package/dist/chunk-DTipWd-i.mjs +1 -0
- package/dist/chunk-cpUYaJdV.mjs +1 -0
- package/dist/cleanEnvForAdapter-KkYzQa1f.mjs +1 -0
- package/dist/client-bx74gm4R.mjs +1 -0
- package/dist/clients/index.d.mts +2639 -0
- package/dist/clients/index.mjs +2 -0
- package/dist/clients-namespace-GmSJpBUV.d.mts +332 -0
- package/dist/config-namespace-CPY9YsR8.d.mts +638 -0
- package/dist/config-namespace-ncYg2ct_.mjs +1 -0
- package/dist/contracts/adapter/index.d.mts +3 -0
- package/dist/contracts/adapter/index.mjs +1 -0
- package/dist/contracts/adapter/schemas/session-lineage.d.mts +2 -0
- package/dist/contracts/adapter/schemas/session-lineage.mjs +1 -0
- package/dist/contracts/artifact/index.d.mts +2 -0
- package/dist/contracts/artifact/index.mjs +1 -0
- package/dist/contracts/client/index.d.mts +3 -0
- package/dist/contracts/client/index.mjs +1 -0
- package/dist/contracts/common/index.d.mts +2 -0
- package/dist/contracts/common/index.mjs +1 -0
- package/dist/contracts/config/index.d.mts +455 -0
- package/dist/contracts/config/index.mjs +1 -0
- package/dist/contracts/extension/index.d.mts +4 -0
- package/dist/contracts/extension/index.mjs +1 -0
- package/dist/contracts/facet/index.d.mts +2 -0
- package/dist/contracts/facet/index.mjs +1 -0
- package/dist/contracts/harness/index.d.mts +2 -0
- package/dist/contracts/harness/index.mjs +1 -0
- package/dist/contracts/host/index.d.mts +2 -0
- package/dist/contracts/host/index.mjs +1 -0
- package/dist/contracts/index.d.mts +23046 -0
- package/dist/contracts/index.mjs +1 -0
- package/dist/contracts/materialization/index.d.mts +4 -0
- package/dist/contracts/materialization/index.mjs +1 -0
- package/dist/contracts/model-registry/index.d.mts +2 -0
- package/dist/contracts/model-registry/index.mjs +1 -0
- package/dist/contracts/native-session-supervisor/index.d.mts +2 -0
- package/dist/contracts/native-session-supervisor/index.mjs +1 -0
- package/dist/contracts/platform/index.d.mts +2 -0
- package/dist/contracts/platform/index.mjs +1 -0
- package/dist/contracts/provider/index.d.mts +3 -0
- package/dist/contracts/provider/index.mjs +1 -0
- package/dist/contracts/session/index.d.mts +3 -0
- package/dist/contracts/session/index.mjs +1 -0
- package/dist/contracts/shared/index.d.mts +2 -0
- package/dist/contracts/shared/index.mjs +1 -0
- package/dist/contracts/skill/index.d.mts +2 -0
- package/dist/contracts/skill/index.mjs +1 -0
- package/dist/contracts/telemetry/index.d.mts +2 -0
- package/dist/contracts/telemetry/index.mjs +1 -0
- package/dist/contracts/timeout/index.d.mts +2 -0
- package/dist/contracts/timeout/index.mjs +1 -0
- package/dist/contracts/toast/index.d.mts +198 -0
- package/dist/contracts/toast/index.mjs +1 -0
- package/dist/contracts/variant/index.d.mts +2 -0
- package/dist/contracts/variant/index.mjs +1 -0
- package/dist/core/index.d.mts +1263 -0
- package/dist/core/index.mjs +1 -0
- package/dist/credential-ref-YWQQENEo.mjs +1 -0
- package/dist/cursor-storage-CtVJ3JzB.mjs +1 -0
- package/dist/definition-BLCdXGzh.d.mts +383 -0
- package/dist/definition-CrgHIpTK.d.mts +60 -0
- package/dist/definition-DZMXOnjX.mjs +1 -0
- package/dist/definition-pkJ6szUl.d.mts +158 -0
- package/dist/drizzle-Eq8W1EbD.mjs +1 -0
- package/dist/event-Ca2yUf5i.mjs +1 -0
- package/dist/execution-target-CRPTfZlc.mjs +1 -0
- package/dist/extension-C-4BHMRI.mjs +1 -0
- package/dist/extension-CpIUgBKI.mjs +1 -0
- package/dist/extension-namespace-cMh_mMiL.mjs +1 -0
- package/dist/facet-BuwhrThl.mjs +1 -0
- package/dist/filesystem-service-B8rhBRgB.mjs +1 -0
- package/dist/filesystem-service-p_iJVHd4.d.mts +66 -0
- package/dist/git/index.d.mts +210 -0
- package/dist/git/index.mjs +18 -0
- package/dist/globby-rtWVaFHv.mjs +41 -0
- package/dist/handlers-CkTsQLra.mjs +41 -0
- package/dist/harness-BRCMcvQN.mjs +1 -0
- package/dist/hooks/index.d.mts +423 -0
- package/dist/hooks/index.mjs +1 -0
- package/dist/host-Br9VuOyr.mjs +1 -0
- package/dist/identity-Cz2IeEtm.mjs +1 -0
- package/dist/index-472sOmsW.d.mts +218 -0
- package/dist/index-8SZkg7s6.d.mts +353 -0
- package/dist/index-B3PK4FIn.d.mts +5116 -0
- package/dist/index-B80L4YqA.d.mts +180 -0
- package/dist/index-BFg9BUpx.d.mts +355 -0
- package/dist/index-BGfWS6GE.d.mts +483 -0
- package/dist/index-BVgfS-AJ.d.mts +109 -0
- package/dist/index-B_zQC98V.d.mts +995 -0
- package/dist/index-Bh_Ne7LF.d.mts +1008 -0
- package/dist/index-Bvb2mMH6.d.mts +1730 -0
- package/dist/index-CCGVh9BF2.d.mts +749 -0
- package/dist/index-CGmcS0Ma.d.mts +412 -0
- package/dist/index-CHQ1SqT0.d.mts +117 -0
- package/dist/index-CLpjm52M.d.mts +183 -0
- package/dist/index-Caig6TeF.d.mts +6746 -0
- package/dist/index-CelJCBjk.d.mts +2992 -0
- package/dist/index-ChunCFu4.d.mts +11 -0
- package/dist/index-Cm0dUkWL.d.mts +4651 -0
- package/dist/index-CokQYGVP.d.mts +184 -0
- package/dist/index-Cs0kZXIz2.d.mts +37 -0
- package/dist/index-D5d5HeWI2.d.mts +259 -0
- package/dist/index-D90OmGmV.d.mts +389 -0
- package/dist/index-D9MwJ2Q8.d.mts +67 -0
- package/dist/index-DANINzMu.d.mts +40 -0
- package/dist/index-DBw-89vC2.d.mts +3640 -0
- package/dist/index-DGBu6bHi2.d.mts +438 -0
- package/dist/index-DKC62dY5.d.mts +146 -0
- package/dist/index-DKia0MX1.d.mts +43 -0
- package/dist/index-DMKnON5s.d.mts +28 -0
- package/dist/index-DUaw0Dw8.d.mts +14747 -0
- package/dist/index-De3kPhlN.d.mts +72 -0
- package/dist/index-L4GjJDKb.d.mts +822 -0
- package/dist/index-U-A8eyGT.d.mts +1490 -0
- package/dist/index-eemAKwsB.d.mts +362 -0
- package/dist/index-mNec7V-9.d.mts +1075 -0
- package/dist/index-soFznFCy2.d.mts +89 -0
- package/dist/index-vtXJuwrz.d.mts +40 -0
- package/dist/index-x_lVDp_J.d.mts +134 -0
- package/dist/json-value-CmhSGMLv.mjs +1 -0
- package/dist/kernel/cli/index.d.mts +143 -0
- package/dist/kernel/cli/index.mjs +1 -0
- package/dist/kernel/cli/schemas.d.mts +64 -0
- package/dist/kernel/cli/schemas.mjs +1 -0
- package/dist/kernel/extension/index.d.mts +2 -0
- package/dist/kernel/extension/index.mjs +1 -0
- package/dist/kernel/index.d.mts +296 -0
- package/dist/kernel/index.mjs +1 -0
- package/dist/kernel/namespace/index.d.mts +2 -0
- package/dist/kernel/namespace/index.mjs +1 -0
- package/dist/kernel/observability/index.d.mts +2 -0
- package/dist/kernel/observability/index.mjs +1 -0
- package/dist/kernel/providers/index.d.mts +2 -0
- package/dist/kernel/providers/index.mjs +1 -0
- package/dist/kernel/window/index.d.mts +2 -0
- package/dist/kernel/window/index.mjs +1 -0
- package/dist/materialization-CuUBu4XI.mjs +1 -0
- package/dist/model-registry-CfXytvzx.mjs +1 -0
- package/dist/model-registry-Scn_MC2d.mjs +1 -0
- package/dist/namespace-5QQqbF-B.d.mts +3133 -0
- package/dist/namespace-BM7Djng9.d.mts +189 -0
- package/dist/namespace-BoD94mrN.mjs +1 -0
- package/dist/namespace-BwzZJqTV.mjs +1 -0
- package/dist/namespace-CFLAmQfh.mjs +1 -0
- package/dist/namespace-CTm3nEvh.d.mts +51 -0
- package/dist/namespace-CaaNnKcR.d.mts +921 -0
- package/dist/namespace-CaoZ3S78.d.mts +43 -0
- package/dist/namespace-CxhsoFUP.d.mts +607 -0
- package/dist/namespace-DD8Oiqo7.d.mts +580 -0
- package/dist/namespace-DLovh2Ws.d.mts +1313 -0
- package/dist/namespace-DgqkaOVu.d.mts +768 -0
- package/dist/namespace-DkRgbZYn.mjs +1 -0
- package/dist/namespace-Dr8K0MCp.d.mts +2047 -0
- package/dist/namespace-DuXK5AYN.mjs +1 -0
- package/dist/namespace-EQniz-Aw.d.mts +142 -0
- package/dist/namespace-IV1QK__V.d.mts +159 -0
- package/dist/namespace-LViZ-EQk.mjs +1 -0
- package/dist/namespace-TyiTsLFv.d.mts +3020 -0
- package/dist/namespace-Yna5-Pws.mjs +1 -0
- package/dist/namespace-xcmbQlxh.mjs +1 -0
- package/dist/native-session-supervisor-B1TnaPUF.mjs +1 -0
- package/dist/node/bus-server/index.d.mts +178 -0
- package/dist/node/bus-server/index.mjs +1 -0
- package/dist/node/bus-server/server-lifecycle.d.mts +2 -0
- package/dist/node/bus-server/server-lifecycle.mjs +1 -0
- package/dist/node/machine-identity/index.d.mts +85 -0
- package/dist/node/machine-identity/index.mjs +3 -0
- package/dist/node/transports/index.d.mts +1945 -0
- package/dist/node/transports/index.mjs +2 -0
- package/dist/orchestrator-shared-CIDiFJMD.mjs +1 -0
- package/dist/orchestrator-shared-Dfa7FMyw.d.mts +249 -0
- package/dist/package-DKVlsMP3.mjs +1 -0
- package/dist/platform-DZ7z-wXD.mjs +1 -0
- package/dist/profile-6ynCD5k3.mjs +1 -0
- package/dist/provider-context-CK6B4X_8.mjs +1 -0
- package/dist/providers/index.d.mts +135 -0
- package/dist/providers/index.mjs +1 -0
- package/dist/providers-namespace-DSEpli4A.d.mts +583 -0
- package/dist/providers-u8i15co9.mjs +1 -0
- package/dist/schema-CoyE6mPt.mjs +1 -0
- package/dist/schema-M5YTvSAG.d.mts +949 -0
- package/dist/schema-e0wU_lcV.mjs +1 -0
- package/dist/schema-introspection-Dn1jWQs1.mjs +1 -0
- package/dist/schemas-Bd0OjRQf.d.mts +46 -0
- package/dist/schemas-C46QfKzv.d.mts +459 -0
- package/dist/schemas-CDBSjg7o.d.mts +237 -0
- package/dist/schemas-CR1Rripy.mjs +1 -0
- package/dist/schemas-CVvwIfG4.mjs +1 -0
- package/dist/schemas-CaLhkkLn.mjs +1 -0
- package/dist/schemas-ClOOT1W6.d.mts +174 -0
- package/dist/schemas-DATniTHb.d.mts +182 -0
- package/dist/schemas-DE-GNmSD.mjs +1 -0
- package/dist/schemas-DVF1A4DF.d.mts +160 -0
- package/dist/schemas-DaRSfYLf.d.mts +73 -0
- package/dist/schemas-DiYVzG6e.d.mts +315 -0
- package/dist/schemas-hSrzflwZ.mjs +1 -0
- package/dist/schemas-j7ivZ2HI.d.mts +944 -0
- package/dist/schemas-jFe1AuI-.mjs +1 -0
- package/dist/schemas-wg_6PAdV.d.mts +153 -0
- package/dist/scoped-bus-04pwo1uM.mjs +1 -0
- package/dist/server-lifecycle-FXTPW39-.mjs +1 -0
- package/dist/server-lifecycle-YoSGFGnU.d.mts +160 -0
- package/dist/service-base/index.d.mts +98 -0
- package/dist/service-base/index.mjs +1 -0
- package/dist/services/adapter-runtime/index.d.mts +4 -0
- package/dist/services/adapter-runtime/index.mjs +1 -0
- package/dist/services/adapter-runtime/namespace.d.mts +2 -0
- package/dist/services/adapter-runtime/namespace.mjs +1 -0
- package/dist/services/adapter-runtime/schemas.d.mts +2 -0
- package/dist/services/adapter-runtime/schemas.mjs +1 -0
- package/dist/services/adapter-subsystem/index.d.mts +3 -0
- package/dist/services/adapter-subsystem/index.mjs +1 -0
- package/dist/services/adapter-subsystem/namespace.d.mts +2 -0
- package/dist/services/adapter-subsystem/namespace.mjs +1 -0
- package/dist/services/agent-runtime/index.d.mts +3 -0
- package/dist/services/agent-runtime/index.mjs +1 -0
- package/dist/services/agent-runtime/namespace.d.mts +2 -0
- package/dist/services/agent-runtime/namespace.mjs +1 -0
- package/dist/services/agent-runtime/schemas.d.mts +2 -0
- package/dist/services/agent-runtime/schemas.mjs +1 -0
- package/dist/services/capability/index.d.mts +2 -0
- package/dist/services/capability/index.mjs +1 -0
- package/dist/services/cli-detection/namespace.d.mts +56 -0
- package/dist/services/cli-detection/namespace.mjs +1 -0
- package/dist/services/codebase/index.d.mts +3 -0
- package/dist/services/codebase/index.mjs +1 -0
- package/dist/services/codebase/namespace.d.mts +2 -0
- package/dist/services/codebase/namespace.mjs +1 -0
- package/dist/services/codebase/schemas.d.mts +2 -0
- package/dist/services/codebase/schemas.mjs +1 -0
- package/dist/services/compression/index.d.mts +3 -0
- package/dist/services/compression/index.mjs +1 -0
- package/dist/services/compression/namespace.d.mts +2 -0
- package/dist/services/compression/namespace.mjs +1 -0
- package/dist/services/compression/schemas.d.mts +2 -0
- package/dist/services/compression/schemas.mjs +1 -0
- package/dist/services/context-rules/index.d.mts +412 -0
- package/dist/services/context-rules/index.mjs +1 -0
- package/dist/services/credential-change/index.d.mts +17 -0
- package/dist/services/credential-change/index.mjs +1 -0
- package/dist/services/definition/index.d.mts +2 -0
- package/dist/services/definition/index.mjs +1 -0
- package/dist/services/definition/namespace.d.mts +71 -0
- package/dist/services/definition/namespace.mjs +1 -0
- package/dist/services/definition/schemas.d.mts +38 -0
- package/dist/services/definition/schemas.mjs +1 -0
- package/dist/services/dialog/namespace.d.mts +105 -0
- package/dist/services/dialog/namespace.mjs +1 -0
- package/dist/services/dialog/schemas.d.mts +109 -0
- package/dist/services/dialog/schemas.mjs +1 -0
- package/dist/services/execution-target/index.d.mts +4 -0
- package/dist/services/execution-target/index.mjs +1 -0
- package/dist/services/execution-target/namespace.d.mts +2 -0
- package/dist/services/execution-target/namespace.mjs +1 -0
- package/dist/services/execution-target/schemas.d.mts +2 -0
- package/dist/services/execution-target/schemas.mjs +1 -0
- package/dist/services/filesystem/index.d.mts +3 -0
- package/dist/services/filesystem/index.mjs +1 -0
- package/dist/services/filesystem/namespace.d.mts +432 -0
- package/dist/services/filesystem/namespace.mjs +1 -0
- package/dist/services/filesystem/schemas.d.mts +240 -0
- package/dist/services/filesystem/schemas.mjs +1 -0
- package/dist/services/git/namespace.d.mts +1163 -0
- package/dist/services/git/namespace.mjs +1 -0
- package/dist/services/git/schemas.d.mts +932 -0
- package/dist/services/git/schemas.mjs +1 -0
- package/dist/services/harness/index.d.mts +861 -0
- package/dist/services/harness/index.mjs +1 -0
- package/dist/services/harness/storage/schema.d.mts +424 -0
- package/dist/services/harness/storage/schema.mjs +1 -0
- package/dist/services/index.d.mts +6185 -0
- package/dist/services/index.mjs +1 -0
- package/dist/services/local-notification/index.d.mts +25 -0
- package/dist/services/local-notification/index.mjs +1 -0
- package/dist/services/local-notification/namespace.d.mts +73 -0
- package/dist/services/local-notification/namespace.mjs +1 -0
- package/dist/services/local-notification/schemas.d.mts +88 -0
- package/dist/services/local-notification/schemas.mjs +1 -0
- package/dist/services/log-import/browser.d.mts +3 -0
- package/dist/services/log-import/browser.mjs +1 -0
- package/dist/services/log-import/index.d.mts +274 -0
- package/dist/services/log-import/index.mjs +2 -0
- package/dist/services/log-import/log-import.d.mts +3 -0
- package/dist/services/log-import/log-import.mjs +1 -0
- package/dist/services/log-import/namespace.d.mts +327 -0
- package/dist/services/log-import/namespace.mjs +1 -0
- package/dist/services/log-import/schemas.d.mts +217 -0
- package/dist/services/log-import/schemas.mjs +1 -0
- package/dist/services/model-registry/index.d.mts +2 -0
- package/dist/services/model-registry/index.mjs +1 -0
- package/dist/services/preferences/index.d.mts +3 -0
- package/dist/services/preferences/index.mjs +1 -0
- package/dist/services/preferences/schemas.d.mts +2 -0
- package/dist/services/preferences/schemas.mjs +1 -0
- package/dist/services/preferences/storage-namespace.d.mts +3 -0
- package/dist/services/preferences/storage-namespace.mjs +1 -0
- package/dist/services/provider-context/index.d.mts +2 -0
- package/dist/services/provider-context/index.mjs +1 -0
- package/dist/services/provider-runtime/index.d.mts +136 -0
- package/dist/services/provider-runtime/index.mjs +1 -0
- package/dist/services/session/handlers/index.d.mts +2 -0
- package/dist/services/session/handlers/index.mjs +1 -0
- package/dist/services/session/index.d.mts +10 -0
- package/dist/services/session/index.mjs +1 -0
- package/dist/services/session/messages/namespace.d.mts +2 -0
- package/dist/services/session/messages/namespace.mjs +1 -0
- package/dist/services/session/orchestrator-testing/index.d.mts +2 -0
- package/dist/services/session/orchestrator-testing/index.mjs +1 -0
- package/dist/services/session/session-events/namespace.d.mts +2 -0
- package/dist/services/session/session-events/namespace.mjs +1 -0
- package/dist/services/session/storage/namespace.d.mts +2 -0
- package/dist/services/session/storage/namespace.mjs +1 -0
- package/dist/services/session/storage/schema.d.mts +2 -0
- package/dist/services/session/storage/schema.mjs +1 -0
- package/dist/services/session/testing/index.d.mts +35 -0
- package/dist/services/session/testing/index.mjs +65 -0
- package/dist/services/session/testing/orchestrator-shared.d.mts +2 -0
- package/dist/services/session/testing/orchestrator-shared.mjs +1 -0
- package/dist/services/session/turns/namespace.d.mts +2 -0
- package/dist/services/session/turns/namespace.mjs +1 -0
- package/dist/services/session-editor/index.d.mts +119 -0
- package/dist/services/session-editor/index.mjs +1 -0
- package/dist/services/settings/index.d.mts +47 -0
- package/dist/services/settings/index.mjs +1 -0
- package/dist/services/settings/namespace.d.mts +663 -0
- package/dist/services/settings/namespace.mjs +1 -0
- package/dist/services/settings/storage/clients-namespace.d.mts +2 -0
- package/dist/services/settings/storage/clients-namespace.mjs +1 -0
- package/dist/services/settings/storage/extension-configs/namespace.d.mts +184 -0
- package/dist/services/settings/storage/extension-configs/namespace.mjs +1 -0
- package/dist/services/settings/storage/index.d.mts +4 -0
- package/dist/services/settings/storage/index.mjs +1 -0
- package/dist/services/settings/storage/providers-namespace.d.mts +2 -0
- package/dist/services/settings/storage/providers-namespace.mjs +1 -0
- package/dist/services/subagent/index.d.mts +2 -0
- package/dist/services/subagent/index.mjs +1 -0
- package/dist/services/subagent-template/index.d.mts +3 -0
- package/dist/services/subagent-template/index.mjs +1 -0
- package/dist/services/subagent-template/namespace.d.mts +2 -0
- package/dist/services/subagent-template/namespace.mjs +1 -0
- package/dist/services/subagent-template/schemas.d.mts +2 -0
- package/dist/services/subagent-template/schemas.mjs +1 -0
- package/dist/services/tool-approval/index.d.mts +2 -0
- package/dist/services/tool-approval/index.mjs +1 -0
- package/dist/services/tools/index.d.mts +2 -0
- package/dist/services/tools/index.mjs +1 -0
- package/dist/services/tray-menu/index.d.mts +4 -0
- package/dist/services/tray-menu/index.mjs +1 -0
- package/dist/services/tray-menu/namespace.d.mts +2 -0
- package/dist/services/tray-menu/namespace.mjs +1 -0
- package/dist/services/tray-menu/schemas.d.mts +2 -0
- package/dist/services/tray-menu/schemas.mjs +1 -0
- package/dist/services/turn/index.d.mts +2 -0
- package/dist/services/turn/index.mjs +1 -0
- package/dist/services/turn/namespace.d.mts +2 -0
- package/dist/services/turn/namespace.mjs +1 -0
- package/dist/services/turn/schemas.d.mts +335 -0
- package/dist/services/turn/schemas.mjs +1 -0
- package/dist/session-BoldSdNZ2.mjs +134 -0
- package/dist/session-DuVOYctZ.mjs +1 -0
- package/dist/session-lineage-CRsc9g1x.d.mts +65 -0
- package/dist/shared-DpOEfD8F.mjs +1 -0
- package/dist/shared-schemas-CPShiLNp.mjs +1 -0
- package/dist/skill-CQO4mDqK.mjs +1 -0
- package/dist/storage/drizzle/client.d.mts +78 -0
- package/dist/storage/drizzle/client.mjs +1 -0
- package/dist/storage/drizzle/index.d.mts +137 -0
- package/dist/storage/drizzle/index.mjs +1 -0
- package/dist/storage/handlers/drizzle/index.d.mts +2 -0
- package/dist/storage/handlers/drizzle/index.mjs +1 -0
- package/dist/storage/handlers/index.d.mts +33 -0
- package/dist/storage/handlers/index.mjs +1 -0
- package/dist/storage/index.d.mts +192 -0
- package/dist/storage/index.mjs +1 -0
- package/dist/storage-namespace-BXkoh5Sy.d.mts +221 -0
- package/dist/storage-namespace-DWsYLAXa.mjs +1 -0
- package/dist/storage-namespace-definition-Bkx5rSto.d.mts +17 -0
- package/dist/storage-namespace-definition-CqSdsuCC.mjs +1 -0
- package/dist/style.css +3782 -0
- package/dist/telemetry-CvdLBWuk.mjs +1 -0
- package/dist/testing/drizzle-harness.d.mts +130 -0
- package/dist/testing/drizzle-harness.mjs +1 -0
- package/dist/testing/index.d.mts +106 -0
- package/dist/testing/index.mjs +1 -0
- package/dist/timeout-XsYIOKrc.mjs +1 -0
- package/dist/tool-approval-service-BvZWhYZp.mjs +1 -0
- package/dist/tools/index.d.mts +835 -0
- package/dist/tools/index.mjs +1 -0
- package/dist/tools/testing/index.d.mts +53 -0
- package/dist/tools/testing/index.mjs +1 -0
- package/dist/tools-D-luYcDw.mjs +1431 -0
- package/dist/tray-menu-service-DuXq5k22.mjs +1 -0
- package/dist/types-BCMUtBj1.d.mts +1106 -0
- package/dist/types-C2Ob9zz_.d.mts +128 -0
- package/dist/types-CCdqjeuH.d.mts +262 -0
- package/dist/types-DZHvOc_Q.d.mts +305 -0
- package/dist/types-Dy3YTcTF.d.mts +6777 -0
- package/dist/types-MfJZ67e9.d.mts +315 -0
- package/dist/types-dyP-bXXE.d.mts +31 -0
- package/dist/ui-components/index.d.mts +2342 -0
- package/dist/ui-components/index.mjs +8 -0
- package/dist/ui-config-9bDRwFZr.mjs +1 -0
- package/dist/ui-hooks/index.d.mts +1915 -0
- package/dist/ui-hooks/index.mjs +1 -0
- package/dist/ui-kernel/index.d.mts +2793 -0
- package/dist/ui-kernel/index.mjs +1 -0
- package/dist/ui-kernel/pages/namespace.d.mts +88 -0
- package/dist/ui-kernel/pages/namespace.mjs +1 -0
- package/dist/ui-kernel/pages/schemas.d.mts +2 -0
- package/dist/ui-kernel/pages/schemas.mjs +1 -0
- package/dist/ui-views/index.d.mts +487 -0
- package/dist/ui-views/index.mjs +30 -0
- package/dist/utils/health-probe.d.mts +26 -0
- package/dist/utils/health-probe.mjs +1 -0
- package/dist/utils/index.d.mts +262 -0
- package/dist/utils/index.mjs +2 -0
- package/dist/utils/keychain.d.mts +31 -0
- package/dist/utils/keychain.mjs +1 -0
- package/dist/utils/project-manifest.d.mts +130 -0
- package/dist/utils/project-manifest.mjs +1 -0
- package/dist/utils/resolve-package-root.d.mts +12 -0
- package/dist/utils/resolve-package-root.mjs +1 -0
- package/dist/utils/scope-paths.d.mts +33 -0
- package/dist/utils/scope-paths.mjs +1 -0
- package/dist/utils/workspace-packages.d.mts +59 -0
- package/dist/utils/workspace-packages.mjs +1 -0
- package/dist/utils/workspace-root.d.mts +24 -0
- package/dist/utils/workspace-root.mjs +2 -0
- package/dist/variant-CT6XBP6T.mjs +1 -0
- package/dist/version-BeT3ASEe.mjs +1 -0
- package/dist/visibility-Cb62p9bv.mjs +1 -0
- package/dist/window-registry-CBcrGTv4.d.mts +130 -0
- package/dist/window-registry-DW-dKRjQ.mjs +1 -0
- package/package.json +1 -1
|
@@ -0,0 +1,315 @@
|
|
|
1
|
+
import { z } from "zod";
|
|
2
|
+
import { IMakaioBus } from "@makaio/framework/bus";
|
|
3
|
+
import { CliManifest } from "@makaio/framework/contracts/extension";
|
|
4
|
+
|
|
5
|
+
//#region packages/kernel/src/cli/types.d.ts
|
|
6
|
+
declare module 'zod' {
|
|
7
|
+
interface GlobalMeta {
|
|
8
|
+
/** Short flag alias for CLI options (e.g. `'-p'`, `'-f'`). */
|
|
9
|
+
short?: string;
|
|
10
|
+
/** Placeholder shown in help text (e.g. `'<name>'`, `'<path>'`). */
|
|
11
|
+
placeholder?: string;
|
|
12
|
+
/** When `true`, treat this field as a positional argument instead of a named option. */
|
|
13
|
+
positional?: boolean;
|
|
14
|
+
}
|
|
15
|
+
}
|
|
16
|
+
/**
|
|
17
|
+
* Injectable output channel for CLI command handlers.
|
|
18
|
+
*
|
|
19
|
+
* Handlers write to `ctx.output` instead of `process.stdout`/`process.stderr`
|
|
20
|
+
* directly. This enables output capture for remote execution via `cli.execute`
|
|
21
|
+
* and test assertions.
|
|
22
|
+
*/
|
|
23
|
+
interface OutputWriter {
|
|
24
|
+
/** Write to standard output. */
|
|
25
|
+
write(text: string): void;
|
|
26
|
+
/** Write to standard error. */
|
|
27
|
+
error(text: string): void;
|
|
28
|
+
}
|
|
29
|
+
/**
|
|
30
|
+
* Execution context provided to CLI command handlers.
|
|
31
|
+
* @typeParam TArgs - Inferred from the command's Zod schema via `z.infer<T>`.
|
|
32
|
+
*/
|
|
33
|
+
interface CommandContext<TArgs> {
|
|
34
|
+
/** Parsed and validated command arguments/options. */
|
|
35
|
+
readonly args: TArgs;
|
|
36
|
+
/**
|
|
37
|
+
* Bus client connected to the running Makaio instance.
|
|
38
|
+
*
|
|
39
|
+
* `null` when the bus is unavailable and the command opted into offline
|
|
40
|
+
* execution via {@link CliContribution.beforeRun}. Handlers that declared
|
|
41
|
+
* themselves runnable without the bus must check for `null` before making
|
|
42
|
+
* bus calls.
|
|
43
|
+
*/
|
|
44
|
+
readonly bus: IMakaioBus | null;
|
|
45
|
+
/** Output channel for writing to stdout/stderr. */
|
|
46
|
+
readonly output: OutputWriter;
|
|
47
|
+
/**
|
|
48
|
+
* Abort signal that is triggered when local CLI execution receives SIGINT,
|
|
49
|
+
* SIGTERM, or SIGHUP.
|
|
50
|
+
*
|
|
51
|
+
* Commands must honour this signal before starting new work and during
|
|
52
|
+
* long-running operations. The local CLI translates process signals into this
|
|
53
|
+
* signal so command-owned `finally` blocks can dispose embedded runtimes
|
|
54
|
+
* before the process exits with the conventional signal exit code.
|
|
55
|
+
*
|
|
56
|
+
* Always present — contexts that cannot supply a meaningful signal must use
|
|
57
|
+
* `AbortSignal.timeout(Infinity)` or a never-aborting controller signal.
|
|
58
|
+
*/
|
|
59
|
+
readonly signal: AbortSignal;
|
|
60
|
+
/**
|
|
61
|
+
* Set the process-style exit code for the current command invocation.
|
|
62
|
+
*
|
|
63
|
+
* Local CLI execution forwards this to `process.exitCode`. Remote execution
|
|
64
|
+
* buffers it into the `cli.execute` RPC response instead of mutating the
|
|
65
|
+
* server process.
|
|
66
|
+
* @param exitCode - Command exit code to report.
|
|
67
|
+
*/
|
|
68
|
+
setExitCode(exitCode: number): void;
|
|
69
|
+
}
|
|
70
|
+
/**
|
|
71
|
+
* Context provided to {@link CliContribution.beforeRun} for pre-execution
|
|
72
|
+
* gating decisions.
|
|
73
|
+
*/
|
|
74
|
+
interface BeforeRunContext {
|
|
75
|
+
/**
|
|
76
|
+
* Name of the subcommand being invoked (e.g. `'list'`, `'statusline'`).
|
|
77
|
+
*
|
|
78
|
+
* Set to {@link INTERACTIVE_SUBCOMMAND} (`'__interactive__'`) when the bare
|
|
79
|
+
* interactive invocation is dispatched.
|
|
80
|
+
*/
|
|
81
|
+
readonly subcommandName: string;
|
|
82
|
+
/** Parsed and validated arguments for the subcommand. */
|
|
83
|
+
readonly args: Record<string, unknown>;
|
|
84
|
+
/**
|
|
85
|
+
* Bus client, or `null` when the server is unreachable.
|
|
86
|
+
*
|
|
87
|
+
* Extensions that can operate without the bus inspect this to decide
|
|
88
|
+
* whether to proceed. Extensions that need a license check can use
|
|
89
|
+
* the bus (when available) to query license state.
|
|
90
|
+
*/
|
|
91
|
+
readonly bus: IMakaioBus | null;
|
|
92
|
+
}
|
|
93
|
+
/**
|
|
94
|
+
* Result of a {@link CliContribution.beforeRun} gate check.
|
|
95
|
+
*
|
|
96
|
+
* - `{ proceed: true }` — skip the default bus-required gate and run the
|
|
97
|
+
* handler. The handler receives `bus: IMakaioBus | null`.
|
|
98
|
+
* - `{ proceed: false, message, exitCode? }` — block execution and display
|
|
99
|
+
* the message. Defaults to exit code 1.
|
|
100
|
+
*/
|
|
101
|
+
type BeforeRunResult = {
|
|
102
|
+
readonly proceed: true;
|
|
103
|
+
} | {
|
|
104
|
+
readonly proceed: false;
|
|
105
|
+
readonly message: string;
|
|
106
|
+
readonly exitCode?: number;
|
|
107
|
+
};
|
|
108
|
+
/**
|
|
109
|
+
* A single CLI subcommand with a Zod schema and strongly-typed handler.
|
|
110
|
+
*
|
|
111
|
+
* The schema defines both the data shape (for type inference) and CLI metadata
|
|
112
|
+
* (descriptions, short flags) via Zod's `.meta()` on each field.
|
|
113
|
+
* @typeParam T - A `z.ZodObject` whose shape defines the command's options/args.
|
|
114
|
+
*/
|
|
115
|
+
interface CliSubcommandDefinition<T extends z.ZodObject<z.ZodRawShape>> {
|
|
116
|
+
/** Subcommand name (e.g. `'list'`, `'switch'`). */
|
|
117
|
+
readonly name: string;
|
|
118
|
+
/** One-line description shown in help text. */
|
|
119
|
+
readonly description: string;
|
|
120
|
+
/** Zod object schema defining the command's options and arguments. */
|
|
121
|
+
readonly schema: T;
|
|
122
|
+
/** Handler invoked with the parsed, validated context. */
|
|
123
|
+
readonly handler: (ctx: CommandContext<z.infer<T>>) => Promise<void>;
|
|
124
|
+
}
|
|
125
|
+
/**
|
|
126
|
+
* Type-erased subcommand definition for collections.
|
|
127
|
+
*
|
|
128
|
+
* When collecting subcommands into arrays or registries, the per-schema generic
|
|
129
|
+
* is erased. The handler contract is preserved at runtime via the closure
|
|
130
|
+
* created by {@link defineCliSubcommand}.
|
|
131
|
+
*/
|
|
132
|
+
interface CliSubcommandEntry {
|
|
133
|
+
/** Subcommand name. */
|
|
134
|
+
readonly name: string;
|
|
135
|
+
/** One-line description. */
|
|
136
|
+
readonly description: string;
|
|
137
|
+
/** Zod object schema (type-erased for collection storage). */
|
|
138
|
+
readonly schema: z.ZodObject<z.ZodRawShape>;
|
|
139
|
+
/** Handler that receives a {@link CommandContext} with the schema's inferred type. */
|
|
140
|
+
readonly handler: (ctx: CommandContext<unknown>) => Promise<void>;
|
|
141
|
+
}
|
|
142
|
+
/**
|
|
143
|
+
* Sentinel subcommand name passed to {@link CliContribution.beforeRun} when
|
|
144
|
+
* the bare interactive invocation (`makaio <name>`) is dispatched.
|
|
145
|
+
*/
|
|
146
|
+
declare const INTERACTIVE_SUBCOMMAND: "__interactive__";
|
|
147
|
+
/**
|
|
148
|
+
* Convenience {@link BeforeRunResult} for extensions that always proceed.
|
|
149
|
+
*
|
|
150
|
+
* Use this as the return value from {@link CliContribution.beforeRun} when
|
|
151
|
+
* the extension unconditionally opts into bus-optional execution.
|
|
152
|
+
*/
|
|
153
|
+
declare const ALWAYS_PROCEED: BeforeRunResult;
|
|
154
|
+
/**
|
|
155
|
+
* Execution context provided to bare interactive CLI handlers.
|
|
156
|
+
*/
|
|
157
|
+
interface InteractiveCommandContext {
|
|
158
|
+
/**
|
|
159
|
+
* Bus client connected to the running Makaio instance.
|
|
160
|
+
*
|
|
161
|
+
* `null` when the bus is unavailable and the contribution's `beforeRun`
|
|
162
|
+
* hook opted into bus-optional execution.
|
|
163
|
+
*/
|
|
164
|
+
readonly bus: IMakaioBus | null;
|
|
165
|
+
/**
|
|
166
|
+
* Abort signal triggered when local CLI execution receives SIGINT, SIGTERM,
|
|
167
|
+
* or SIGHUP.
|
|
168
|
+
*
|
|
169
|
+
* Interactive handlers must observe this signal and tear down any TUI
|
|
170
|
+
* renderer they own, because local CLI signal handling defers immediate
|
|
171
|
+
* process termination until command-owned cleanup has run.
|
|
172
|
+
*/
|
|
173
|
+
readonly signal: AbortSignal;
|
|
174
|
+
}
|
|
175
|
+
/**
|
|
176
|
+
* Context passed to {@link CliContribution.provideBus} so the extension can
|
|
177
|
+
* inspect the incoming invocation before deciding whether to bootstrap a bus.
|
|
178
|
+
*/
|
|
179
|
+
interface ProvideBusContext {
|
|
180
|
+
/**
|
|
181
|
+
* Name of the subcommand being invoked (e.g. `'run'`, `'start'`).
|
|
182
|
+
*
|
|
183
|
+
* Set to {@link INTERACTIVE_SUBCOMMAND} (`'__interactive__'`) when the bare
|
|
184
|
+
* interactive invocation is dispatched.
|
|
185
|
+
*/
|
|
186
|
+
readonly subcommandName: string;
|
|
187
|
+
/** Parsed and validated arguments for the subcommand. */
|
|
188
|
+
readonly args: Record<string, unknown>;
|
|
189
|
+
/** Absolute path of the working directory from which the CLI was invoked. */
|
|
190
|
+
readonly cwd: string;
|
|
191
|
+
}
|
|
192
|
+
/**
|
|
193
|
+
* Handle returned by {@link CliContribution.provideBus} when the extension
|
|
194
|
+
* successfully bootstraps an embedded bus.
|
|
195
|
+
*
|
|
196
|
+
* The CLI router holds this handle for the duration of the command invocation
|
|
197
|
+
* and calls `dispose` during teardown to shut down the embedded bus cleanly.
|
|
198
|
+
*/
|
|
199
|
+
interface EmbeddedBusHandle {
|
|
200
|
+
/** The live bus instance to inject into command handlers. */
|
|
201
|
+
readonly bus: IMakaioBus;
|
|
202
|
+
/**
|
|
203
|
+
* Shut down the embedded bus and release all associated resources.
|
|
204
|
+
*
|
|
205
|
+
* Called by the CLI router after the command handler completes (or errors).
|
|
206
|
+
* Implementations must be idempotent — calling `dispose` more than once must
|
|
207
|
+
* not throw.
|
|
208
|
+
* @returns A promise that resolves when teardown is complete.
|
|
209
|
+
*/
|
|
210
|
+
dispose(): Promise<void>;
|
|
211
|
+
}
|
|
212
|
+
/**
|
|
213
|
+
* A plugin's CLI contribution, declared in its `MakaioExtension` manifest.
|
|
214
|
+
*
|
|
215
|
+
* Extends {@link CliManifest} (pure-data) with executable code: an optional
|
|
216
|
+
* interactive TUI handler and typed subcommand definitions. The CLI router
|
|
217
|
+
* uses {@link CliManifest} for discovery and help generation; this type is
|
|
218
|
+
* used when the package is loaded and ready to handle commands.
|
|
219
|
+
*
|
|
220
|
+
* The CLI router dispatches as follows:
|
|
221
|
+
* - `makaio account-manager` → {@link interactive} (if defined)
|
|
222
|
+
* - `makaio account-manager --help` → auto-generated from subcommands + schema metadata
|
|
223
|
+
* - `makaio account-manager list` → matched subcommand handler
|
|
224
|
+
*
|
|
225
|
+
* Bus resolution order (first match wins):
|
|
226
|
+
* 1. External daemon connection — if the server is reachable, its bus is used.
|
|
227
|
+
* 2. {@link provideBus} — extension embeds its own bus (standalone mode).
|
|
228
|
+
* 3. `null` bus — passed to handlers only when {@link beforeRun} opts in.
|
|
229
|
+
*
|
|
230
|
+
* {@link beforeRun} is evaluated **after** bus resolution completes so that its
|
|
231
|
+
* context always reflects the final resolved bus state.
|
|
232
|
+
*/
|
|
233
|
+
interface CliContribution extends CliManifest {
|
|
234
|
+
/**
|
|
235
|
+
* Interactive TUI launched when the command is invoked without a subcommand.
|
|
236
|
+
*
|
|
237
|
+
* When defined, bare `makaio <name>` enters this handler instead of printing
|
|
238
|
+
* help. Typically renders an Ink TUI that reuses the same bus RPC calls as
|
|
239
|
+
* the non-interactive subcommands.
|
|
240
|
+
*
|
|
241
|
+
* The bus is non-null when no {@link beforeRun} hook is defined (the default
|
|
242
|
+
* gate ensures a connected bus). When `beforeRun` opts into bus-optional
|
|
243
|
+
* execution, `bus` may be `null` — use {@link requireBus} at the top of the
|
|
244
|
+
* handler if the TUI needs bus RPC calls.
|
|
245
|
+
*/
|
|
246
|
+
readonly interactive?: (ctx: InteractiveCommandContext) => Promise<void>;
|
|
247
|
+
/** Typed subcommand definitions with Zod schemas and strongly-typed handlers. */
|
|
248
|
+
readonly subcommands: ReadonlyArray<CliSubcommandEntry>;
|
|
249
|
+
/**
|
|
250
|
+
* Pre-execution gate evaluated **after** bus resolution (including any
|
|
251
|
+
* embedded bus from {@link provideBus}) completes.
|
|
252
|
+
*
|
|
253
|
+
* When provided, this hook **replaces** the default "bus must be connected"
|
|
254
|
+
* gate. The extension inspects the context (including bus availability) and
|
|
255
|
+
* decides whether execution should proceed.
|
|
256
|
+
*
|
|
257
|
+
* Use cases:
|
|
258
|
+
* - **Bus-optional commands** — extensions that can operate without the
|
|
259
|
+
* server (e.g. `claude-code-statusline`, fire-and-forget hooks).
|
|
260
|
+
* - **License gates** — paid extensions that need to verify a subscription
|
|
261
|
+
* before allowing execution.
|
|
262
|
+
*
|
|
263
|
+
* When absent, the CLI framework applies the default behavior: require a
|
|
264
|
+
* connected bus and fail with a connection error when unavailable.
|
|
265
|
+
* @param context - Subcommand name, parsed args, and bus availability.
|
|
266
|
+
* @returns Whether to proceed or block with a message.
|
|
267
|
+
*/
|
|
268
|
+
readonly beforeRun?: (context: BeforeRunContext) => BeforeRunResult | Promise<BeforeRunResult>;
|
|
269
|
+
/**
|
|
270
|
+
* Bootstrap an embedded bus for standalone or in-process execution.
|
|
271
|
+
*
|
|
272
|
+
* When defined and {@link CliManifest.canProvideBus} is `true` in the
|
|
273
|
+
* manifest, the CLI router calls this hook **only when no external daemon
|
|
274
|
+
* connection was established**. If it returns a non-null handle the embedded
|
|
275
|
+
* bus is used for the lifetime of the command; the router calls
|
|
276
|
+
* {@link EmbeddedBusHandle.dispose} after the handler completes.
|
|
277
|
+
*
|
|
278
|
+
* Returning `null` signals that this invocation should not use an embedded
|
|
279
|
+
* bus and the handler receives `bus: null`.
|
|
280
|
+
* @param context - Subcommand name, parsed args, and working directory.
|
|
281
|
+
* @returns A live bus handle, or `null` to fall through to normal connection.
|
|
282
|
+
*/
|
|
283
|
+
readonly provideBus?: (context: ProvideBusContext) => Promise<EmbeddedBusHandle | null>;
|
|
284
|
+
}
|
|
285
|
+
/**
|
|
286
|
+
* Assert that the bus is available and narrow the type to non-null.
|
|
287
|
+
*
|
|
288
|
+
* Handlers that require the bus (i.e. extensions without a `beforeRun` hook
|
|
289
|
+
* that permits offline execution) call this at the top of their handler to
|
|
290
|
+
* get a typed non-null bus reference. Throws if the bus is unexpectedly null
|
|
291
|
+
* — which should not happen when the default bus-required gate is active.
|
|
292
|
+
*
|
|
293
|
+
* Works with both subcommand {@link CommandContext} and interactive handler
|
|
294
|
+
* contexts — any object with a `bus` property satisfies the signature.
|
|
295
|
+
* @param ctx - Context containing a potentially null bus reference.
|
|
296
|
+
* @returns The non-null bus instance.
|
|
297
|
+
*/
|
|
298
|
+
declare function requireBus(ctx: {
|
|
299
|
+
readonly bus: IMakaioBus | null;
|
|
300
|
+
}): IMakaioBus;
|
|
301
|
+
/**
|
|
302
|
+
* Define a CLI subcommand with full type inference from schema to handler.
|
|
303
|
+
*
|
|
304
|
+
* This is an identity function whose only purpose is to create a scope where
|
|
305
|
+
* TypeScript infers `T` from `schema` and flows it into `handler`. No runtime
|
|
306
|
+
* cost. Same pattern as Vite's `defineConfig()` or Vue's `defineComponent()`.
|
|
307
|
+
* @param name - Subcommand name.
|
|
308
|
+
* @param description - One-line description for help text.
|
|
309
|
+
* @param schema - Zod object schema defining options/arguments.
|
|
310
|
+
* @param handler - Async handler receiving the typed {@link CommandContext}.
|
|
311
|
+
* @returns A {@link CliSubcommandEntry} suitable for inclusion in a {@link CliContribution}.
|
|
312
|
+
*/
|
|
313
|
+
declare function defineCliSubcommand<T extends z.ZodObject<z.ZodRawShape>>(name: string, description: string, schema: T, handler: (ctx: CommandContext<z.infer<T>>) => Promise<void>): CliSubcommandEntry;
|
|
314
|
+
//#endregion
|
|
315
|
+
export { CliSubcommandDefinition as a, EmbeddedBusHandle as c, ProvideBusContext as d, defineCliSubcommand as f, CliContribution as i, INTERACTIVE_SUBCOMMAND as l, BeforeRunContext as n, CliSubcommandEntry as o, requireBus as p, BeforeRunResult as r, CommandContext as s, ALWAYS_PROCEED as t, OutputWriter as u };
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
import { LibSQLDatabase } from "drizzle-orm/libsql";
|
|
2
|
+
|
|
3
|
+
//#region storage/drizzle/src/types.d.ts
|
|
4
|
+
/**
|
|
5
|
+
* Canonical database type alias for all Makaio storage consumers.
|
|
6
|
+
*
|
|
7
|
+
* Typed as the shared async-compatible Drizzle surface, which keeps the
|
|
8
|
+
* cross-driver query contract stable while excluding libsql-only members such
|
|
9
|
+
* as `$client`, `batch()`, and `resultKind`.
|
|
10
|
+
*
|
|
11
|
+
* At runtime, the factory in `client.ts` may return a `BunSQLiteDatabase`
|
|
12
|
+
* instance (sync dialect) cast to this type. That is safe because:
|
|
13
|
+
* - All query-builder methods (`select`, `insert`, `update`, `delete`) exist
|
|
14
|
+
* on both drivers with compatible call signatures.
|
|
15
|
+
* - Awaiting Bun's synchronous return values still preserves the existing
|
|
16
|
+
* async call sites, even though it introduces the normal microtask boundary
|
|
17
|
+
* of `await`.
|
|
18
|
+
*
|
|
19
|
+
* **All consumers must import this type** instead of importing
|
|
20
|
+
* `LibSQLDatabase` directly from `drizzle-orm/libsql`. This single import
|
|
21
|
+
* seam is what makes the runtime driver swap transparent to callers.
|
|
22
|
+
*
|
|
23
|
+
* **Caveat:** Consumers must not access libsql-only members such as
|
|
24
|
+
* `db.$client` directly — use the `close()` function returned by
|
|
25
|
+
* `createDatabaseClient` instead. The factory handles driver-specific teardown
|
|
26
|
+
* internally.
|
|
27
|
+
* @typeParam TSchema - Drizzle table schema record. Defaults to an empty schema.
|
|
28
|
+
*/
|
|
29
|
+
type MakaioDatabase<TSchema extends Record<string, unknown> = Record<string, never>> = Omit<LibSQLDatabase<TSchema>, '$client' | 'batch' | 'resultKind'>;
|
|
30
|
+
//#endregion
|
|
31
|
+
export { MakaioDatabase as t };
|