dodo-mcp 1.0.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/LICENSE +21 -0
- package/README.md +425 -0
- package/dist/auth/adapter.js +43 -0
- package/dist/auth/adapter.js.map +1 -0
- package/dist/auth/clientDeletion.js +45 -0
- package/dist/auth/clientDeletion.js.map +1 -0
- package/dist/auth/clients.js +55 -0
- package/dist/auth/clients.js.map +1 -0
- package/dist/auth/constants.js +10 -0
- package/dist/auth/constants.js.map +1 -0
- package/dist/auth/interactions.js +184 -0
- package/dist/auth/interactions.js.map +1 -0
- package/dist/auth/keys.js +56 -0
- package/dist/auth/keys.js.map +1 -0
- package/dist/auth/provider.js +131 -0
- package/dist/auth/provider.js.map +1 -0
- package/dist/auth/verifier.js +74 -0
- package/dist/auth/verifier.js.map +1 -0
- package/dist/cli/kill.js +124 -0
- package/dist/cli/kill.js.map +1 -0
- package/dist/cli/main.js +1393 -0
- package/dist/cli/main.js.map +1 -0
- package/dist/cli/menu.js +127 -0
- package/dist/cli/menu.js.map +1 -0
- package/dist/cli/terminal.js +30 -0
- package/dist/cli/terminal.js.map +1 -0
- package/dist/config/globalConfig.js +144 -0
- package/dist/config/globalConfig.js.map +1 -0
- package/dist/config/limits.js +42 -0
- package/dist/config/limits.js.map +1 -0
- package/dist/config/paths.js +94 -0
- package/dist/config/paths.js.map +1 -0
- package/dist/config/projectConfig.js +63 -0
- package/dist/config/projectConfig.js.map +1 -0
- package/dist/config/stateImport.js +306 -0
- package/dist/config/stateImport.js.map +1 -0
- package/dist/config/tunnelConfig.js +23 -0
- package/dist/config/tunnelConfig.js.map +1 -0
- package/dist/errors.js +82 -0
- package/dist/errors.js.map +1 -0
- package/dist/evaluation/contracts.js +86 -0
- package/dist/evaluation/contracts.js.map +1 -0
- package/dist/evaluation/dodoBench.js +69 -0
- package/dist/evaluation/dodoBench.js.map +1 -0
- package/dist/index.js +26 -0
- package/dist/index.js.map +1 -0
- package/dist/ipc/authentication.js +117 -0
- package/dist/ipc/authentication.js.map +1 -0
- package/dist/ipc/client.js +86 -0
- package/dist/ipc/client.js.map +1 -0
- package/dist/ipc/installationClient.js +83 -0
- package/dist/ipc/installationClient.js.map +1 -0
- package/dist/ipc/ownerControl.js +46 -0
- package/dist/ipc/ownerControl.js.map +1 -0
- package/dist/ipc/protocol.js +2 -0
- package/dist/ipc/protocol.js.map +1 -0
- package/dist/ipc/server.js +108 -0
- package/dist/ipc/server.js.map +1 -0
- package/dist/platform/execResolve.js +64 -0
- package/dist/platform/execResolve.js.map +1 -0
- package/dist/platform/fileIdentity.js +26 -0
- package/dist/platform/fileIdentity.js.map +1 -0
- package/dist/platform/fsRetry.js +22 -0
- package/dist/platform/fsRetry.js.map +1 -0
- package/dist/platform/pathPolicy.js +29 -0
- package/dist/platform/pathPolicy.js.map +1 -0
- package/dist/platform/privateFs.js +116 -0
- package/dist/platform/privateFs.js.map +1 -0
- package/dist/platform/processTree.js +31 -0
- package/dist/platform/processTree.js.map +1 -0
- package/dist/platform/shell.js +74 -0
- package/dist/platform/shell.js.map +1 -0
- package/dist/platform/speech.js +94 -0
- package/dist/platform/speech.js.map +1 -0
- package/dist/platform/system.js +28 -0
- package/dist/platform/system.js.map +1 -0
- package/dist/platform/windowsSandbox.js +129 -0
- package/dist/platform/windowsSandbox.js.map +1 -0
- package/dist/projects/federation.js +312 -0
- package/dist/projects/federation.js.map +1 -0
- package/dist/projects/registry.js +291 -0
- package/dist/projects/registry.js.map +1 -0
- package/dist/security/accessMode.js +19 -0
- package/dist/security/accessMode.js.map +1 -0
- package/dist/security/approvals.js +56 -0
- package/dist/security/approvals.js.map +1 -0
- package/dist/security/env.js +57 -0
- package/dist/security/env.js.map +1 -0
- package/dist/security/mutationQueue.js +78 -0
- package/dist/security/mutationQueue.js.map +1 -0
- package/dist/security/policy.js +22 -0
- package/dist/security/policy.js.map +1 -0
- package/dist/security/projectAuthority.js +22 -0
- package/dist/security/projectAuthority.js.map +1 -0
- package/dist/security/redact.js +30 -0
- package/dist/security/redact.js.map +1 -0
- package/dist/server/aiAdmin.js +201 -0
- package/dist/server/aiAdmin.js.map +1 -0
- package/dist/server/appServer.js +461 -0
- package/dist/server/appServer.js.map +1 -0
- package/dist/server/bootstrap.js +185 -0
- package/dist/server/bootstrap.js.map +1 -0
- package/dist/server/configUi/app.css +347 -0
- package/dist/server/configUi/app.js +958 -0
- package/dist/server/configUi/index.html +379 -0
- package/dist/server/configUi/ui/alerts.js +92 -0
- package/dist/server/configUi/ui/dom.js +19 -0
- package/dist/server/configUi/ui/tooltips.js +115 -0
- package/dist/server/configUi/vendor/VERSION.txt +1 -0
- package/dist/server/configUi/vendor/sweetalert2.min.css +1 -0
- package/dist/server/configUi/vendor/sweetalert2.min.js +5 -0
- package/dist/server/configUi/workbench.css +62 -0
- package/dist/server/configUi/workbench.js +394 -0
- package/dist/server/installationRuntime.js +155 -0
- package/dist/server/installationRuntime.js.map +1 -0
- package/dist/server/instructions.js +17 -0
- package/dist/server/instructions.js.map +1 -0
- package/dist/server/ipcDispatch.js +225 -0
- package/dist/server/ipcDispatch.js.map +1 -0
- package/dist/server/localConfig.js +561 -0
- package/dist/server/localConfig.js.map +1 -0
- package/dist/server/optionalServices.js +30 -0
- package/dist/server/optionalServices.js.map +1 -0
- package/dist/server/projectLease.js +46 -0
- package/dist/server/projectLease.js.map +1 -0
- package/dist/server/stdioServer.js +75 -0
- package/dist/server/stdioServer.js.map +1 -0
- package/dist/server/version.js +13 -0
- package/dist/server/version.js.map +1 -0
- package/dist/server/workspaceHost.js +194 -0
- package/dist/server/workspaceHost.js.map +1 -0
- package/dist/services/agent/agentService.js +598 -0
- package/dist/services/agent/agentService.js.map +1 -0
- package/dist/services/agent/contracts.js +102 -0
- package/dist/services/agent/contracts.js.map +1 -0
- package/dist/services/ai/adapters.js +287 -0
- package/dist/services/ai/adapters.js.map +1 -0
- package/dist/services/ai/contracts.js +39 -0
- package/dist/services/ai/contracts.js.map +1 -0
- package/dist/services/ai/credentials.js +77 -0
- package/dist/services/ai/credentials.js.map +1 -0
- package/dist/services/ai/network.js +113 -0
- package/dist/services/ai/network.js.map +1 -0
- package/dist/services/ai/settings.js +178 -0
- package/dist/services/ai/settings.js.map +1 -0
- package/dist/services/ai/subagents.js +468 -0
- package/dist/services/ai/subagents.js.map +1 -0
- package/dist/services/assistance/analysis.js +352 -0
- package/dist/services/assistance/analysis.js.map +1 -0
- package/dist/services/assistance/contracts.js +54 -0
- package/dist/services/assistance/contracts.js.map +1 -0
- package/dist/services/assistance/verification.js +274 -0
- package/dist/services/assistance/verification.js.map +1 -0
- package/dist/services/brain/brainParser.js +97 -0
- package/dist/services/brain/brainParser.js.map +1 -0
- package/dist/services/brain/brainService.js +733 -0
- package/dist/services/brain/brainService.js.map +1 -0
- package/dist/services/brain/brainWorker.js +212 -0
- package/dist/services/brain/brainWorker.js.map +1 -0
- package/dist/services/brain/contracts.js +154 -0
- package/dist/services/brain/contracts.js.map +1 -0
- package/dist/services/brain/protocol.js +2 -0
- package/dist/services/brain/protocol.js.map +1 -0
- package/dist/services/changes/applier.js +544 -0
- package/dist/services/changes/applier.js.map +1 -0
- package/dist/services/changes/contentBudget.js +11 -0
- package/dist/services/changes/contentBudget.js.map +1 -0
- package/dist/services/changes/planner.js +284 -0
- package/dist/services/changes/planner.js.map +1 -0
- package/dist/services/changes/types.js +3 -0
- package/dist/services/changes/types.js.map +1 -0
- package/dist/services/context/contextEngine.js +746 -0
- package/dist/services/context/contextEngine.js.map +1 -0
- package/dist/services/context/contracts.js +88 -0
- package/dist/services/context/contracts.js.map +1 -0
- package/dist/services/desktop/desktopPolicy.js +76 -0
- package/dist/services/desktop/desktopPolicy.js.map +1 -0
- package/dist/services/desktop/desktopService.js +130 -0
- package/dist/services/desktop/desktopService.js.map +1 -0
- package/dist/services/desktop/nativeBackend.js +174 -0
- package/dist/services/desktop/nativeBackend.js.map +1 -0
- package/dist/services/desktop/protocol.js +32 -0
- package/dist/services/desktop/protocol.js.map +1 -0
- package/dist/services/files/readService.js +136 -0
- package/dist/services/files/readService.js.map +1 -0
- package/dist/services/git/gitService.js +369 -0
- package/dist/services/git/gitService.js.map +1 -0
- package/dist/services/intelligence/intelService.js +136 -0
- package/dist/services/intelligence/intelService.js.map +1 -0
- package/dist/services/intelligence/protocol.js +2 -0
- package/dist/services/intelligence/protocol.js.map +1 -0
- package/dist/services/intelligence/tsWorker.js +419 -0
- package/dist/services/intelligence/tsWorker.js.map +1 -0
- package/dist/services/jobs/commandInput.js +34 -0
- package/dist/services/jobs/commandInput.js.map +1 -0
- package/dist/services/jobs/jobManager.js +398 -0
- package/dist/services/jobs/jobManager.js.map +1 -0
- package/dist/services/jobs/sandbox.js +156 -0
- package/dist/services/jobs/sandbox.js.map +1 -0
- package/dist/services/jobs/sandboxWiring.js +37 -0
- package/dist/services/jobs/sandboxWiring.js.map +1 -0
- package/dist/services/jobs/spool.js +112 -0
- package/dist/services/jobs/spool.js.map +1 -0
- package/dist/services/jobs/windowsSandboxChild.js +24 -0
- package/dist/services/jobs/windowsSandboxChild.js.map +1 -0
- package/dist/services/jobs/windowsSandboxWorker.js +155 -0
- package/dist/services/jobs/windowsSandboxWorker.js.map +1 -0
- package/dist/services/lsp/documentUri.js +16 -0
- package/dist/services/lsp/documentUri.js.map +1 -0
- package/dist/services/lsp/jsonrpc.js +382 -0
- package/dist/services/lsp/jsonrpc.js.map +1 -0
- package/dist/services/lsp/lspService.js +1051 -0
- package/dist/services/lsp/lspService.js.map +1 -0
- package/dist/services/memory/contracts.js +94 -0
- package/dist/services/memory/contracts.js.map +1 -0
- package/dist/services/memory/memoryService.js +683 -0
- package/dist/services/memory/memoryService.js.map +1 -0
- package/dist/services/multimodal/browserService.js +407 -0
- package/dist/services/multimodal/browserService.js.map +1 -0
- package/dist/services/multimodal/byteRange.js +31 -0
- package/dist/services/multimodal/byteRange.js.map +1 -0
- package/dist/services/multimodal/contracts.js +59 -0
- package/dist/services/multimodal/contracts.js.map +1 -0
- package/dist/services/multimodal/gameService.js +95 -0
- package/dist/services/multimodal/gameService.js.map +1 -0
- package/dist/services/multimodal/images.js +107 -0
- package/dist/services/multimodal/images.js.map +1 -0
- package/dist/services/multimodal/mediaService.js +279 -0
- package/dist/services/multimodal/mediaService.js.map +1 -0
- package/dist/services/multimodal/mediaWorker.js +143 -0
- package/dist/services/multimodal/mediaWorker.js.map +1 -0
- package/dist/services/multimodal/multimodalService.js +51 -0
- package/dist/services/multimodal/multimodalService.js.map +1 -0
- package/dist/services/multimodal/network.js +69 -0
- package/dist/services/multimodal/network.js.map +1 -0
- package/dist/services/multimodal/operations.js +40 -0
- package/dist/services/multimodal/operations.js.map +1 -0
- package/dist/services/multimodal/storage.js +160 -0
- package/dist/services/multimodal/storage.js.map +1 -0
- package/dist/services/multimodal/workflowService.js +179 -0
- package/dist/services/multimodal/workflowService.js.map +1 -0
- package/dist/services/overview.js +284 -0
- package/dist/services/overview.js.map +1 -0
- package/dist/services/resources/casStore.js +304 -0
- package/dist/services/resources/casStore.js.map +1 -0
- package/dist/services/resources/contracts.js +75 -0
- package/dist/services/resources/contracts.js.map +1 -0
- package/dist/services/resources/mime.js +77 -0
- package/dist/services/resources/mime.js.map +1 -0
- package/dist/services/resources/providerRegistry.js +22 -0
- package/dist/services/resources/providerRegistry.js.map +1 -0
- package/dist/services/resources/providers.js +120 -0
- package/dist/services/resources/providers.js.map +1 -0
- package/dist/services/resources/resourceService.js +282 -0
- package/dist/services/resources/resourceService.js.map +1 -0
- package/dist/services/runtime/contracts.js +65 -0
- package/dist/services/runtime/contracts.js.map +1 -0
- package/dist/services/runtime/runtimeService.js +364 -0
- package/dist/services/runtime/runtimeService.js.map +1 -0
- package/dist/services/schedules/scheduleService.js +198 -0
- package/dist/services/schedules/scheduleService.js.map +1 -0
- package/dist/services/search/searchService.js +434 -0
- package/dist/services/search/searchService.js.map +1 -0
- package/dist/services/search/searchWorker.js +58 -0
- package/dist/services/search/searchWorker.js.map +1 -0
- package/dist/setup/componentProbes.js +259 -0
- package/dist/setup/componentProbes.js.map +1 -0
- package/dist/setup/download.js +139 -0
- package/dist/setup/download.js.map +1 -0
- package/dist/setup/managedTools.js +118 -0
- package/dist/setup/managedTools.js.map +1 -0
- package/dist/setup/sandboxProbe.js +172 -0
- package/dist/setup/sandboxProbe.js.map +1 -0
- package/dist/setup/setup.js +522 -0
- package/dist/setup/setup.js.map +1 -0
- package/dist/setup/windowsChromiumAcl.js +56 -0
- package/dist/setup/windowsChromiumAcl.js.map +1 -0
- package/dist/setup/windowsSandboxInstall.js +94 -0
- package/dist/setup/windowsSandboxInstall.js.map +1 -0
- package/dist/setup/windowsSpeechInstall.js +86 -0
- package/dist/setup/windowsSpeechInstall.js.map +1 -0
- package/dist/store/db.js +711 -0
- package/dist/store/db.js.map +1 -0
- package/dist/store/scopeEncoding.js +15 -0
- package/dist/store/scopeEncoding.js.map +1 -0
- package/dist/store/store.js +467 -0
- package/dist/store/store.js.map +1 -0
- package/dist/tools/agentRuntimeTools.js +216 -0
- package/dist/tools/agentRuntimeTools.js.map +1 -0
- package/dist/tools/agentTools.js +317 -0
- package/dist/tools/agentTools.js.map +1 -0
- package/dist/tools/assistanceTools.js +126 -0
- package/dist/tools/assistanceTools.js.map +1 -0
- package/dist/tools/brainTools.js +130 -0
- package/dist/tools/brainTools.js.map +1 -0
- package/dist/tools/catalog.js +30 -0
- package/dist/tools/catalog.js.map +1 -0
- package/dist/tools/changeTools.js +188 -0
- package/dist/tools/changeTools.js.map +1 -0
- package/dist/tools/context.js +243 -0
- package/dist/tools/context.js.map +1 -0
- package/dist/tools/contextTools.js +57 -0
- package/dist/tools/contextTools.js.map +1 -0
- package/dist/tools/coreCatalog.js +82 -0
- package/dist/tools/coreCatalog.js.map +1 -0
- package/dist/tools/desktopTools.js +41 -0
- package/dist/tools/desktopTools.js.map +1 -0
- package/dist/tools/directTools.js +273 -0
- package/dist/tools/directTools.js.map +1 -0
- package/dist/tools/envelope.js +71 -0
- package/dist/tools/envelope.js.map +1 -0
- package/dist/tools/extraTools.js +298 -0
- package/dist/tools/extraTools.js.map +1 -0
- package/dist/tools/gitTools.js +93 -0
- package/dist/tools/gitTools.js.map +1 -0
- package/dist/tools/jobTools.js +454 -0
- package/dist/tools/jobTools.js.map +1 -0
- package/dist/tools/memoryTools.js +102 -0
- package/dist/tools/memoryTools.js.map +1 -0
- package/dist/tools/metaTools.js +153 -0
- package/dist/tools/metaTools.js.map +1 -0
- package/dist/tools/multimodalTools.js +262 -0
- package/dist/tools/multimodalTools.js.map +1 -0
- package/dist/tools/projectTools.js +261 -0
- package/dist/tools/projectTools.js.map +1 -0
- package/dist/tools/resourceTools.js +81 -0
- package/dist/tools/resourceTools.js.map +1 -0
- package/dist/tools/runtimeTools.js +137 -0
- package/dist/tools/runtimeTools.js.map +1 -0
- package/dist/tools/scheduleTools.js +10 -0
- package/dist/tools/scheduleTools.js.map +1 -0
- package/dist/tools/semanticTools.js +141 -0
- package/dist/tools/semanticTools.js.map +1 -0
- package/dist/tools/subagentTools.js +32 -0
- package/dist/tools/subagentTools.js.map +1 -0
- package/dist/tools/surface.js +644 -0
- package/dist/tools/surface.js.map +1 -0
- package/dist/tunnel/control.js +113 -0
- package/dist/tunnel/control.js.map +1 -0
- package/dist/tunnel/credentials.js +392 -0
- package/dist/tunnel/credentials.js.map +1 -0
- package/dist/tunnel/log.js +84 -0
- package/dist/tunnel/log.js.map +1 -0
- package/dist/tunnel/runtime.js +55 -0
- package/dist/tunnel/runtime.js.map +1 -0
- package/dist/tunnel/supervisor.js +280 -0
- package/dist/tunnel/supervisor.js.map +1 -0
- package/dist/util/bytes.js +53 -0
- package/dist/util/bytes.js.map +1 -0
- package/dist/util/hash.js +53 -0
- package/dist/util/hash.js.map +1 -0
- package/dist/workspace/fs.js +305 -0
- package/dist/workspace/fs.js.map +1 -0
- package/dist/workspace/identity.js +17 -0
- package/dist/workspace/identity.js.map +1 -0
- package/dist/workspace/ignores.js +173 -0
- package/dist/workspace/ignores.js.map +1 -0
- package/dist/workspace/root.js +59 -0
- package/dist/workspace/root.js.map +1 -0
- package/docs/AGENT_RUNTIME.md +154 -0
- package/docs/AI_PROVIDERS.md +110 -0
- package/docs/ARCHITECTURE.md +331 -0
- package/docs/ASSISTANCE.md +31 -0
- package/docs/AUTH.md +59 -0
- package/docs/BRAIN.md +92 -0
- package/docs/COMPATIBILITY.md +92 -0
- package/docs/CONFIRMATION.md +13 -0
- package/docs/CONTEXT.md +87 -0
- package/docs/DESKTOP.md +35 -0
- package/docs/EVALUATION.md +86 -0
- package/docs/LARGE_INPUTS.md +21 -0
- package/docs/LSP.md +21 -0
- package/docs/MANUAL_ACCEPTANCE.md +283 -0
- package/docs/MEMORY.md +128 -0
- package/docs/MULTIMODAL.md +32 -0
- package/docs/PROJECTS.md +146 -0
- package/docs/RELEASE_1.0.0.md +111 -0
- package/docs/RELEASE_NOTES.md +92 -0
- package/docs/RESOURCES.md +83 -0
- package/docs/RUNTIME.md +125 -0
- package/docs/SCHEDULES.md +23 -0
- package/docs/SECURITY.md +250 -0
- package/docs/TEST_REPORT.md +312 -0
- package/docs/TUNNEL.md +86 -0
- package/docs/WEB_CLIENTS.md +43 -0
- package/docs/WINDOWS.md +79 -0
- package/docs/adr/001-one-process-one-workspace.md +22 -0
- package/docs/adr/002-external-tunnel.md +19 -0
- package/docs/adr/003-sdk-v2-legacy-stateless.md +20 -0
- package/docs/adr/004-embedded-oauth-provider.md +19 -0
- package/docs/adr/005-static-client-baseline.md +19 -0
- package/docs/adr/006-guarded-fs-explicit-exec.md +16 -0
- package/docs/adr/007-preview-hash-journal.md +18 -0
- package/docs/adr/008-ts-js-semantics-first.md +17 -0
- package/docs/adr/009-jobs-polling.md +18 -0
- package/docs/adr/010-sqlite-better-sqlite3.md +18 -0
- package/docs/adr/011-env-example-secure-default.md +19 -0
- package/docs/adr/012-workspace-scope-grant.md +24 -0
- package/docs/adr/013-loopback-proxy-trust.md +18 -0
- package/docs/adr/014-direct-coding-tier.md +48 -0
- package/docs/adr/015-coding-agent-parity.md +56 -0
- package/docs/adr/016-oidc-openid-consent.md +15 -0
- package/docs/adr/017-installation-identity-local-config.md +44 -0
- package/docs/adr/018-access-scope-encoding.md +11 -0
- package/docs/adr/019-runtime-workspace-switch.md +59 -0
- package/docs/adr/020-desktop-access.md +50 -0
- package/docs/adr/021-persistent-desktop-consent.md +39 -0
- package/docs/adr/022-owner-kill-preserves-login.md +30 -0
- package/docs/adr/023-large-coding-inputs.md +49 -0
- package/docs/adr/024-usage-rounds-and-schedules.md +72 -0
- package/docs/adr/025-owner-chat-whitelist.md +53 -0
- package/docs/adr/026-remove-conversation-confirmation.md +35 -0
- package/docs/adr/027-workspace-client-list.md +20 -0
- package/docs/adr/028-owner-client-deletion.md +25 -0
- package/docs/adr/029-compact-tool-surface.md +121 -0
- package/docs/adr/030-windows-native-candidate.md +71 -0
- package/docs/adr/031-owner-selected-tunnel-supervision.md +13 -0
- package/docs/adr/032-owner-project-registry.md +43 -0
- package/docs/adr/033-read-only-project-federation.md +61 -0
- package/docs/adr/034-universal-resource-cas.md +60 -0
- package/docs/adr/035-project-brain-incremental-index.md +51 -0
- package/docs/adr/036-context-engine-evidence.md +53 -0
- package/docs/adr/037-owner-reviewed-memory.md +46 -0
- package/docs/adr/038-runtime-intelligence.md +46 -0
- package/docs/adr/039-advanced-agent-runtime.md +57 -0
- package/docs/adr/040-dodobench-release-gate.md +43 -0
- package/docs/adr/041-local-macos-docker-linux-gates.md +32 -0
- package/docs/adr/042-project-directory-generation-identity.md +36 -0
- package/docs/adr/043-trusted-self-hosted-platform-gates.md +38 -0
- package/docs/adr/044-global-launcher-and-cli-menu.md +43 -0
- package/docs/adr/045-ai-providers-multiproject.md +56 -0
- package/docs/adr/046-personal-access-mode.md +32 -0
- package/docs/adr/README.md +64 -0
- package/examples/.dodo.json.example +20 -0
- package/examples/cloudflared.yml +23 -0
- package/examples/reverse-proxy-fixture.mjs +37 -0
- package/native/desktop-linux.py +387 -0
- package/native/desktop-windows.cs +180 -0
- package/native/desktop.swift +212 -0
- package/package.json +145 -0
- package/schemas/global-config.schema.json +497 -0
- package/schemas/project-config.schema.json +75 -0
- package/schemas/tools.compact.json +3236 -0
- package/schemas/tools.hybrid.json +8194 -0
- package/schemas/tools.json +34518 -0
- package/scripts/guard-publish.mjs +12 -0
- package/scripts/setup-multimodal.mjs +70 -0
package/docs/TUNNEL.md
ADDED
|
@@ -0,0 +1,86 @@
|
|
|
1
|
+
# DODO MCP — Tunnel Guide
|
|
2
|
+
|
|
3
|
+
DODO เปิด MCP และ OAuth บน local loopback ผู้ใช้เป็นผู้สร้าง Cloudflare remotely-managed Tunnel, public hostname และ DNS เอง DODO supervise เฉพาะ process `cloudflared` ที่เริ่มในรอบปัจจุบันและไม่ติดตั้งเป็น system service
|
|
4
|
+
|
|
5
|
+
## Local endpoints
|
|
6
|
+
|
|
7
|
+
- MCP + OAuth: `http://127.0.0.1:21730`
|
|
8
|
+
- MCP endpoint: `http://127.0.0.1:21730/mcp`
|
|
9
|
+
- Local Config: `http://127.0.0.1:21731`
|
|
10
|
+
- managed readiness/metrics: `http://127.0.0.1:21732` โดยค่าเริ่มต้น
|
|
11
|
+
|
|
12
|
+
Tunnel ต้อง route health, discovery, OAuth และ MCP ทุก path ไปยัง listener `21730` เดียวกัน ห้าม route Local Config `21731`, metrics `21732`, private IPC หรือ debug endpoint ออก public
|
|
13
|
+
|
|
14
|
+
## Public origin
|
|
15
|
+
|
|
16
|
+
```bash
|
|
17
|
+
dodo init --public-url https://mcp.example.com
|
|
18
|
+
dodo start --root /path/to/project
|
|
19
|
+
```
|
|
20
|
+
|
|
21
|
+
## เปิดพร้อม DODO ด้วย token ชั่วคราว
|
|
22
|
+
|
|
23
|
+
```bash
|
|
24
|
+
dodo setup --check --components cloudflared
|
|
25
|
+
dodo init --public-url https://mcp.example.com
|
|
26
|
+
dodo start --root /path/to/project
|
|
27
|
+
# Cloudflare Tunnel token (temporary; Enter = local only):
|
|
28
|
+
```
|
|
29
|
+
|
|
30
|
+
`dodo setup --yes` ใช้ component `all` เป็นค่าเริ่มต้นและรวม `cloudflared` บน macOS
|
|
31
|
+
หรือเลือกจากเมนู `dodo --cli` ข้อ “ติดตั้ง/ตรวจ dependencies ทั้งหมด” ได้
|
|
32
|
+
|
|
33
|
+
กรอก Tunnel token ที่ Cloudflare ออกให้สำหรับ remotely-managed Tunnel Token จะอยู่
|
|
34
|
+
เฉพาะใน DODO process และ environment ของ child `cloudflared` ระหว่างรอบ เมื่อ DODO
|
|
35
|
+
หยุด child จะหยุดตาม กด Enter โดยไม่กรอกหรือใช้คำสั่งต่อไปนี้เพื่อเปิด local MCP เท่านั้น:
|
|
36
|
+
|
|
37
|
+
```bash
|
|
38
|
+
dodo start --no-tunnel
|
|
39
|
+
```
|
|
40
|
+
|
|
41
|
+
หน้า Local Config มีช่อง **Temporary Tunnel token** สำหรับเริ่ม tunnel ใน process ที่
|
|
42
|
+
เปิดอยู่ได้ทันที และมีปุ่มหยุดเฉพาะ child ที่ process นี้เป็นเจ้าของ ช่องถูกล้างหลังส่ง
|
|
43
|
+
Backend ตอบ `tokenStored:false` และไม่เขียนค่าลง config หรือ credential store
|
|
44
|
+
|
|
45
|
+
คำสั่งตรวจสถานะที่ไม่มี secret:
|
|
46
|
+
|
|
47
|
+
```bash
|
|
48
|
+
dodo tunnel status
|
|
49
|
+
dodo tunnel doctor
|
|
50
|
+
dodo tunnel logs --lines 100
|
|
51
|
+
dodo tunnel stop
|
|
52
|
+
```
|
|
53
|
+
|
|
54
|
+
`status` ใช้ authenticated owner IPC และไม่อ่าน credential ส่วน `doctor` เป็นคำสั่งตรวจแบบ explicit: ตรวจ executable, credential availability, local `/healthz`, managed `/ready` และ public `/healthz` แยกกัน Public health ที่ผ่านไม่ได้แปลว่า AI client เชื่อมต่ออยู่
|
|
55
|
+
|
|
56
|
+
## ขอบเขตของ token
|
|
57
|
+
|
|
58
|
+
DODO ไม่รับ token เป็น CLI argument และไม่ใส่ token ใน `cloudflared` argv เส้นทาง
|
|
59
|
+
มาตรฐานไม่ใช้ macOS Keychain, Windows Credential Manager, Linux Secret Service,
|
|
60
|
+
token file หรือ shell environment Token จาก terminal และ Local Config ถูกส่งผ่าน
|
|
61
|
+
environment ของ child ที่สร้างเองเท่านั้น Tunnel diagnostics ถูกจำกัดขนาดและ redact
|
|
62
|
+
ก่อนเขียนลง private state MCP jobs จะไม่ได้รับ `TUNNEL_TOKEN` หรือ
|
|
63
|
+
`TUNNEL_TOKEN_FILE` แม้ owner จะใส่ชื่อไว้ใน environment allowlist
|
|
64
|
+
|
|
65
|
+
คำสั่ง `dodo tunnel configure/start` และ credential reference รุ่นเดิมยังคงอยู่เพื่อ
|
|
66
|
+
advanced/headless compatibility แต่ไม่ถูกเรียกโดย `dodo start`, `dodo --cli` หรือ
|
|
67
|
+
Local Config และต้องเกิดจากคำสั่ง owner โดยตรง
|
|
68
|
+
|
|
69
|
+
runtime ใช้ bounded restart หลัง `cloudflared` จบ retry ของตัวเอง และ `stop` ส่งสัญญาณเฉพาะ live child handle ที่ supervisor เป็นผู้สร้าง ไม่มีการ kill saved PID หรือ process ชื่อเหมือนกัน
|
|
70
|
+
|
|
71
|
+
## Client setup
|
|
72
|
+
|
|
73
|
+
1. ใช้ `https://mcp.example.com/mcp` ใน MCP client
|
|
74
|
+
2. เลือก OAuth
|
|
75
|
+
3. คัดลอก exact callback จาก client
|
|
76
|
+
4. ลงทะเบียนด้วย `dodo auth add-client --redirect-uri ...`
|
|
77
|
+
5. ทำ browser authorization และ approve interaction จาก terminal
|
|
78
|
+
6. scan tools และตรวจ surface ที่ client รายงาน
|
|
79
|
+
|
|
80
|
+
## หลายโปรเจกต์
|
|
81
|
+
|
|
82
|
+
หนึ่ง DODO process มี active workspace เดียว ถ้าต้องการทำงานพร้อมกันหลายโปรเจกต์ ให้เปิดหลาย DODO processes ด้วย port, public origin และ config directory ที่แยกกัน แต่ละ managed tunnel ต้องใช้ metrics port ที่ไม่ซ้ำ ระบบจะไม่ให้ process หนึ่ง takeover root ที่อีก process กำลัง serve
|
|
83
|
+
|
|
84
|
+
## Security
|
|
85
|
+
|
|
86
|
+
ห้ามปิด OAuth, ใช้ Tunnel token แทน MCP OAuth, ส่ง token ใน URL หรือเปิด CORS กว้าง Tunnel provider ไม่ได้แทน owner consent ของ DODO และ DODO ไม่เรียก Cloudflare API, ไม่จัดการ DNS, ไม่สร้าง/ลบ Tunnel และไม่เปิด firewall
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
# DODO MCP — Web Clients
|
|
2
|
+
|
|
3
|
+
## Connection checklist
|
|
4
|
+
|
|
5
|
+
1. รัน DODO และตั้ง public HTTPS origin
|
|
6
|
+
2. ตรวจว่า URL ลงท้ายด้วย `/mcp`
|
|
7
|
+
3. เพิ่ม static OAuth client ด้วย exact callback URL
|
|
8
|
+
4. เลือก OAuth ใน web client
|
|
9
|
+
5. ทำ authorization ใน browser
|
|
10
|
+
6. approve interaction ผ่าน `dodo auth pending` และ `dodo auth approve ID`
|
|
11
|
+
7. scan tools
|
|
12
|
+
8. เรียก `project_overview` และตรวจ `toolSurface`
|
|
13
|
+
|
|
14
|
+
## Compact behavior
|
|
15
|
+
|
|
16
|
+
HTTP default เป็น Compact surface 19 tools ประกอบด้วย overview, `dodo_discover` และ gateways client จะค้น operation ที่ต้องการจาก discover แล้วเรียก gateway พร้อม top-level workspace context
|
|
17
|
+
|
|
18
|
+
Compact ไม่ลด security และไม่ได้รวมสิทธิ์หลาย operation เป็น approval เดียว target operation ยังคงมี scope, ACL, trust, approval, hash และ path policy ของตัวเอง
|
|
19
|
+
|
|
20
|
+
## Client cache
|
|
21
|
+
|
|
22
|
+
client บางตัว cache tool catalog หลังสร้าง connection หาก schema หรือ surface เปลี่ยน ให้ refresh ตาม client หรือ recreate connection เมื่อ refresh ไม่ได้ล้าง catalog เดิม
|
|
23
|
+
|
|
24
|
+
## Manual evidence
|
|
25
|
+
|
|
26
|
+
บันทึกจำนวน tools ที่ client แสดงจริง, response ของ overview, write/edit read-back และ error cases แยกจาก automated test อย่ารายงานว่า web client ผ่านจาก server log เพียงอย่างเดียว
|
|
27
|
+
|
|
28
|
+
## Delegate งานด้วย AI profile ของเจ้าของ
|
|
29
|
+
|
|
30
|
+
ค่าเริ่มต้นซ่อน Sub-agent operations จาก MCP เพื่อให้ catalog งานทั่วไปกระชับขึ้น ก่อน
|
|
31
|
+
delegate จาก ChatGPT/remote MCP ให้เจ้าของเปิด **Settings → Sub-agent tools ใน MCP**
|
|
32
|
+
แล้ว restart DODO และ rescan/recreate connection หน้าเว็บ Chat & Tasks ใช้ได้แม้สวิตช์ปิด
|
|
33
|
+
|
|
34
|
+
เมื่อเปิดแล้ว ChatGPT/remote MCP ใช้ `project_overview(targetProjectId)`
|
|
35
|
+
เพื่อรับ context และ `ai.profiles` เฉพาะที่อนุญาต แล้ว `dodo_discover` หา
|
|
36
|
+
`subagent_spawn` ผ่าน `dodo_assist_change` ตรวจผลด้วย `subagent_result` ผ่าน
|
|
37
|
+
`dodo_assist_read` รูปแบบ top-level target/context เหมือน read/write tools
|
|
38
|
+
ไม่ใส่ key ในแชตหรือ tool args; เจ้าของตั้งผ่าน private Local Config เท่านั้น
|
|
39
|
+
|
|
40
|
+
การมี MCP OAuth scopes ไม่ได้อนุญาต provider egress โดยอัตโนมัติ ต้องมี target ACL,
|
|
41
|
+
profile/client allowlist และ trust/approval เดิม งานหลาย projects สร้างหนึ่ง run ต่อ
|
|
42
|
+
project; ผลลัพธ์คืน run ID/receipts ไม่มี internal reasoning และ retry ด้วย key เดิม
|
|
43
|
+
ไม่สร้างงานซ้ำ โปรด rescan/recreate connector หากยังไม่เห็น schema ใหม่
|
package/docs/WINDOWS.md
ADDED
|
@@ -0,0 +1,79 @@
|
|
|
1
|
+
# DODO Windows Candidate — Deferred
|
|
2
|
+
|
|
3
|
+
DODO MCP 1.0.0 ยังไม่ประกาศ native Windows support โค้ดและ tests สำหรับ Windows
|
|
4
|
+
บางส่วนมีอยู่เป็น candidate สำหรับ phase สุดท้าย แต่ยังไม่มีหลักฐานจาก Windows 11 จริง
|
|
5
|
+
และ Linux Docker ไม่สามารถใช้แทนหลักฐาน Windows ได้
|
|
6
|
+
|
|
7
|
+
## ตรวจเครื่อง
|
|
8
|
+
|
|
9
|
+
```powershell
|
|
10
|
+
dodo setup --check
|
|
11
|
+
dodo doctor
|
|
12
|
+
```
|
|
13
|
+
|
|
14
|
+
คำสั่งตรวจจะรายงานสถานะ Git, ripgrep, LSP, media, speech, browser, desktop และ command sandbox แยกกัน ไม่เปิด permission หรือดาวน์โหลด model เอง
|
|
15
|
+
|
|
16
|
+
## การทำงานหลัก
|
|
17
|
+
|
|
18
|
+
- MCP HTTP ใช้ OAuth และ bind local loopback ก่อน owner จะนำไปวางหลัง HTTPS tunnel
|
|
19
|
+
- STDIO ใช้ full tool surface เป็นค่าเริ่มต้น
|
|
20
|
+
- Local Config ใช้ owner authentication และ named-pipe/loopback transport ตาม platform
|
|
21
|
+
- workspace path ต้องเป็น absolute path และผ่าน canonicalization, ACL และ secret/path guards
|
|
22
|
+
- jobs ใช้ Windows process tree และ environment allowlist
|
|
23
|
+
- file changes ใช้ expected hash, journal, atomic replace และ rollback
|
|
24
|
+
|
|
25
|
+
## Optional backends
|
|
26
|
+
|
|
27
|
+
Desktop, speech, browser และ command sandbox ต้องผ่าน probe และ owner permission หาก backend ไม่พร้อมระบบตอบ `NOT_SUPPORTED` ตามจริง
|
|
28
|
+
|
|
29
|
+
## งานที่ต้องผ่านก่อนประกาศรองรับ
|
|
30
|
+
|
|
31
|
+
การแก้ candidate สำหรับ native CI:
|
|
32
|
+
|
|
33
|
+
- directory identity ใช้ bigint เมื่ออ่าน NTFS; ค่าที่เกิน JavaScript safe integer
|
|
34
|
+
เก็บเป็น `u64:<decimal>` ใน JSON/SQLite เพื่อไม่ให้ file ID คนละค่าถูกปัดรวมกัน
|
|
35
|
+
ค่า integer เดิมยังอ่านได้ และการตรวจ replaced root/ACL/trust ยังคงมีผล
|
|
36
|
+
- resource buffer เปิด staging file ด้วย writable handle ก่อน fsync ตามข้อกำหนด Windows
|
|
37
|
+
- LSP เทียบ URI ที่ normalize drive letter และ percent encoding แล้ว โดยไม่เปลี่ยน case ของชื่อไฟล์
|
|
38
|
+
- private fixture ตรวจ Windows ACL; fault injection แบบ filesystem error ตรวจ rollback
|
|
39
|
+
ได้ทุก platform เพิ่มจาก POSIX chmod test และจำกัด Windows file workers ที่สองตัว
|
|
40
|
+
- `dodo kill` ตรวจและหยุด authenticated IPC endpoints ทีละรายการบน Windows
|
|
41
|
+
เพื่อไม่ให้ synchronous PowerShell ACL probes ขวางการรับ IPC response ของอีก
|
|
42
|
+
endpoint โดยยังตรวจ identity/epoch และรอ shutdown จริง ไม่ใช้ PID จาก state เพื่อส่ง signal
|
|
43
|
+
- หาก endpoint ถูกปิดระหว่างตรวจ IPC identity จะตรวจยืนยันว่า descriptor และ
|
|
44
|
+
locator หายไปจริง ก่อนรายงานว่าไม่มี endpoint; ข้อมูลเสียหรือ ACL ที่ไม่ปลอดภัย
|
|
45
|
+
ของ endpoint ที่ยังอยู่ยังเป็น error ตามเดิม
|
|
46
|
+
|
|
47
|
+
ระบบจะประกาศ native support ได้เมื่อผ่าน named-pipe identity, NTFS
|
|
48
|
+
reparse/ADS/8.3 guards, ACL enforcement, PATHEXT resolution, shell strategy,
|
|
49
|
+
process cancellation, read-only/antivirus file behavior, Windows argv limits,
|
|
50
|
+
Chromium environment, LSP, full automated suite และ packaging บน Windows จริง
|
|
51
|
+
|
|
52
|
+
## Manual acceptance
|
|
53
|
+
|
|
54
|
+
ต้องทดสอบบน Windows 11 จริง: OAuth/HTTP, STDIO, workspace isolation, ACL, file
|
|
55
|
+
conflict, rollback, jobs, setup และ package installation ผลปัจจุบันคือ
|
|
56
|
+
`MANUAL_NOT_RUN` Dedicated `windows-ci 02` self-hosted runner ใช้เก็บ automated native
|
|
57
|
+
candidate evidence บน Node 22/24 แต่ไม่เปลี่ยน manual status เอง Workflow เลือก
|
|
58
|
+
label `windows-ci 02` โดยเฉพาะ และเลิกใช้ runner 01 แล้ว
|
|
59
|
+
|
|
60
|
+
Workflow เตรียม Portable Git for Windows ใน temp ของ job หากไม่มี Git ใน PATH
|
|
61
|
+
โดยตรึง official release และตรวจ SHA-256 ก่อนแตกไฟล์ เพื่อให้ checkout ได้ `.git`
|
|
62
|
+
และตรวจ source revision จริง PowerShell ของ job ใช้ `RemoteSigned` แบบ process scope
|
|
63
|
+
สำหรับสคริปต์ที่ runner สร้าง ไม่แก้ execution policy ถาวรของเครื่อง และยังบังคับ
|
|
64
|
+
enabled Administrator token สำหรับชุดตรวจ ACL
|
|
65
|
+
|
|
66
|
+
## เริ่ม self-hosted runner บนเครื่องที่พบปัญหา locale
|
|
67
|
+
|
|
68
|
+
หาก runner ล้มก่อน step แรกด้วย `PowerShellPreAmpersandEscape` ให้หยุด runner แล้ว
|
|
69
|
+
รันใน PowerShell ที่โฟลเดอร์ runner เดิม:
|
|
70
|
+
|
|
71
|
+
```powershell
|
|
72
|
+
$env:DOTNET_SYSTEM_GLOBALIZATION_INVARIANT = "1"
|
|
73
|
+
$env:DOTNET_SYSTEM_GLOBALIZATION_PREDEFINEDCULTURESONLY = "false"
|
|
74
|
+
.\run.cmd
|
|
75
|
+
```
|
|
76
|
+
|
|
77
|
+
ค่ามีผลเฉพาะหน้าต่างนี้; เมื่อเปิดใหม่ต้องตั้งอีกครั้ง Workflow คืน globalization
|
|
78
|
+
ตามปกติให้ขั้นทดสอบ เพื่อไม่ใช้ workaround ของ runner มาบังปัญหา locale ใน DODO
|
|
79
|
+
อาการและ workaround อ้างอิง [actions/runner#4686](https://github.com/actions/runner/issues/4686)
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
# ADR-001 — One process = one CWD workspace = one endpoint profile
|
|
2
|
+
|
|
3
|
+
**Status:** superseded in part by ADR-019 and ADR-044. The one-active-workspace
|
|
4
|
+
invariant remains; CWD startup and restart-only switching do not.
|
|
5
|
+
|
|
6
|
+
**Decision.** A DODO process serves exactly one workspace root — the realpath of
|
|
7
|
+
`process.cwd()` captured at the CLI entrypoint — and one public issuer/profile.
|
|
8
|
+
There is no remote tool to change root or lower policy. `workspaceId` is
|
|
9
|
+
server-minted (derived from a per-install secret + canonical root) and every
|
|
10
|
+
tool except `project_overview` must present a matching `workspaceId` +
|
|
11
|
+
`workspaceEpoch`.
|
|
12
|
+
|
|
13
|
+
**Trade-off.** Switching projects means restarting and re-consenting. In return,
|
|
14
|
+
scope confusion is impossible and a stolen token cannot be pointed at another
|
|
15
|
+
folder on the same host.
|
|
16
|
+
|
|
17
|
+
**Evidence / validation.** Root-switch grant isolation and workspace-context
|
|
18
|
+
enforcement are covered by `security/auth.test.ts` (AUTH-07/AUTH-18) and
|
|
19
|
+
`integration/m0` (WORKSPACE_MISMATCH / STALE_WORKSPACE). CWD-not-install-dir is
|
|
20
|
+
covered by `integration/cli.test.ts` (CLI-03). See
|
|
21
|
+
[src/workspace/root.ts](../../src/workspace/root.ts),
|
|
22
|
+
[src/workspace/identity.ts](../../src/workspace/identity.ts).
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
# ADR-002 — User-managed external named tunnel
|
|
2
|
+
|
|
3
|
+
**Status:** superseded in part by ADR-031; external mode remains supported
|
|
4
|
+
|
|
5
|
+
**Decision.** DODO binds `127.0.0.1:21730` and nothing else. The user runs their
|
|
6
|
+
own Cloudflare named tunnel (or equivalent) and owns DNS/firewall. This remains
|
|
7
|
+
the `external` mode. ADR-031 adds an explicit local-owner option to supervise
|
|
8
|
+
only `cloudflared`; DODO still never creates/deletes tunnels, manages DNS or
|
|
9
|
+
opens ports.
|
|
10
|
+
|
|
11
|
+
**Trade-off.** The user does more setup and holds the tunnel credentials. In
|
|
12
|
+
return DODO holds no cloud secrets and has no relay/SaaS to trust.
|
|
13
|
+
|
|
14
|
+
**Evidence / validation.** A named tunnel + stable hostname is the recommended
|
|
15
|
+
baseline because Quick Tunnels do not support SSE and lack hostname persistence
|
|
16
|
+
for OAuth callbacks (spec §2.4/§17, source [S11]). A local reverse-proxy fixture
|
|
17
|
+
([examples/reverse-proxy-fixture.mjs](../../examples/reverse-proxy-fixture.mjs))
|
|
18
|
+
reproduces the full-path forwarding for automated OAuth testing; real-tunnel
|
|
19
|
+
end-to-end is a manual gate (MAN-02). See [docs/TUNNEL.md](../TUNNEL.md).
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
# ADR-003 — Official MCP SDK v2 + legacy stateless fallback
|
|
2
|
+
|
|
3
|
+
**Status:** accepted (implemented)
|
|
4
|
+
|
|
5
|
+
**Decision.** Use the official MCP TypeScript SDK **v2** split packages
|
|
6
|
+
(`@modelcontextprotocol/{server,express,node}` `2.0.0`, verified on the npm
|
|
7
|
+
registry) and serve with `createMcpHandler(factory, { legacy: 'stateless' })`,
|
|
8
|
+
which handles the modern 2026-07-28 per-request path and a stateless fallback
|
|
9
|
+
for 2025-era clients on one endpoint. We do not hand-roll JSON-RPC, session
|
|
10
|
+
handling, or era classification, and do not mix v1 imports.
|
|
11
|
+
|
|
12
|
+
**Trade-off.** No support for the old sessionful GET-stream transport. The exact
|
|
13
|
+
protocol revision a given ChatGPT build negotiates was not captured; both
|
|
14
|
+
generations are tested locally instead.
|
|
15
|
+
|
|
16
|
+
**Evidence / validation.** `integration/m0-transport-oauth.test.ts` connects a
|
|
17
|
+
real SDK v2 `Client` (modern) AND drives a raw 2025 `initialize`+`tools/call`
|
|
18
|
+
(legacy stateless), both listing 33 tools; `GET`/`DELETE` return `405`. Versions
|
|
19
|
+
recorded in [COMPATIBILITY.md](../COMPATIBILITY.md). See
|
|
20
|
+
[src/server/appServer.ts](../../src/server/appServer.ts).
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
# ADR-004 — Embedded `oidc-provider` authorization server
|
|
2
|
+
|
|
3
|
+
**Status:** accepted (implemented)
|
|
4
|
+
|
|
5
|
+
**Decision.** Co-host a maintained OAuth 2.1 / OIDC authorization server
|
|
6
|
+
(`oidc-provider` `9.12.2`) with the MCP resource server on one public origin. We
|
|
7
|
+
do not implement OAuth crypto, PKCE, token formats, or refresh rotation
|
|
8
|
+
ourselves. Issuer = configured public origin; resource = issuer + `/mcp`. Tokens
|
|
9
|
+
are ES256 JWTs bound to the workspace.
|
|
10
|
+
|
|
11
|
+
**Trade-off.** Local owner-consent UX must be built, and the provider is a large
|
|
12
|
+
dependency. In return there is no central SaaS and the protocol details are
|
|
13
|
+
handled by an audited library.
|
|
14
|
+
|
|
15
|
+
**Evidence / validation.** Full authorization-code + PKCE(S256) flow issues a
|
|
16
|
+
usable, workspace-bound token in `integration/m0` and `security/auth.test.ts`
|
|
17
|
+
(revocation, audience, PKCE failure, refresh). See
|
|
18
|
+
[src/auth/provider.ts](../../src/auth/provider.ts),
|
|
19
|
+
[src/auth/verifier.ts](../../src/auth/verifier.ts), [docs/AUTH.md](../AUTH.md).
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
# ADR-005 — Static client registration baseline; DCR off, CIMD deferred
|
|
2
|
+
|
|
3
|
+
**Status:** accepted (implemented)
|
|
4
|
+
|
|
5
|
+
**Decision.** The v1 baseline is static OAuth client preregistration by the local
|
|
6
|
+
owner (`dodo auth add-client --redirect-uri <exact>`), copying the exact
|
|
7
|
+
callback the client UI shows. Wildcard redirect URIs are rejected. Dynamic
|
|
8
|
+
Client Registration (DCR) is **off** by default (deprecated in favor of CIMD in
|
|
9
|
+
the current spec). CIMD is **deferred** because the feature was experimental in
|
|
10
|
+
the `oidc-provider` version examined; enabling it requires allowlisted metadata
|
|
11
|
+
origins, SSRF/redirect/private-IP protection, and pinned deps first.
|
|
12
|
+
|
|
13
|
+
**Trade-off.** The owner registers a client once. In return there is no
|
|
14
|
+
anonymous public registration surface.
|
|
15
|
+
|
|
16
|
+
**Evidence / validation.** Redirect-URI exact-match, wildcard rejection, and
|
|
17
|
+
secret-shown-once are covered by `integration/cli.test.ts` and
|
|
18
|
+
`security/auth.test.ts` (AUTH-10, AUTH-12). Real ChatGPT registration mode is a
|
|
19
|
+
manual gate (MAN-03). See [src/auth/clients.ts](../../src/auth/clients.ts).
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
# ADR-006 — Guarded file tools + explicit native execution (no OS sandbox)
|
|
2
|
+
|
|
3
|
+
**Status:** accepted (implemented)
|
|
4
|
+
|
|
5
|
+
**Decision.** File tools are confined by one shared `WorkspaceFS` path policy;
|
|
6
|
+
execution is explicit and gated by trust mode + per-action approval. We do
|
|
7
|
+
**not** claim an OS sandbox. Programs run with the user's real OS privileges;
|
|
8
|
+
`shell:false` reduces wrapper injection only, not confinement.
|
|
9
|
+
|
|
10
|
+
**Trade-off.** `trusted` mode is genuinely powerful and dangerous; the boundary
|
|
11
|
+
is "I trust this code with my account", not isolation. Documented prominently.
|
|
12
|
+
|
|
13
|
+
**Evidence / validation.** Path traversal/symlink/hardlink/secret denial via
|
|
14
|
+
tools in `security/pathTraversal.test.ts`; the non-sandbox limit is stated in
|
|
15
|
+
[SECURITY.md](../SECURITY.md). See [src/workspace/fs.ts](../../src/workspace/fs.ts),
|
|
16
|
+
[src/security/policy.ts](../../src/security/policy.ts).
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
# ADR-007 — Preview / hash / idempotency / journal for changes
|
|
2
|
+
|
|
3
|
+
**Status:** accepted (implemented)
|
|
4
|
+
|
|
5
|
+
**Decision.** File changes flow through: read (raw-byte SHA-256) → immutable
|
|
6
|
+
preview plan → approval → apply (expected-hash recheck + durable journal +
|
|
7
|
+
per-file backups + atomic temp/fsync/rename) → audit → optional rollback. Retry
|
|
8
|
+
is idempotent via durable keys. Multi-file apply is explicitly **not** one
|
|
9
|
+
filesystem transaction; unrecoverable partial failures surface
|
|
10
|
+
`PARTIAL_RECOVERY_REQUIRED`. No automatic `git reset/clean/stash`.
|
|
11
|
+
|
|
12
|
+
**Trade-off.** Much more code than `writeFile`, in exchange for not destroying
|
|
13
|
+
the owner's work and surviving crashes with an honest recovery story.
|
|
14
|
+
|
|
15
|
+
**Evidence / validation.** `integration/changes.test.ts` (14 cases: immutability,
|
|
16
|
+
AMBIGUOUS_EDIT, FILE_CHANGED, idempotency replay/conflict, rollback conflict
|
|
17
|
+
refusal, dirty-tree preservation, concurrency). See
|
|
18
|
+
[src/services/changes/applier.ts](../../src/services/changes/applier.ts).
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
# ADR-008 — TypeScript/JavaScript semantics first, in a guarded worker
|
|
2
|
+
|
|
3
|
+
**Status:** accepted (implemented)
|
|
4
|
+
|
|
5
|
+
**Decision.** `symbols` / `references` / `preview_rename` use the bundled
|
|
6
|
+
TypeScript Language Service running in a worker thread with a custom
|
|
7
|
+
`LanguageServiceHost` that routes every file access through the same
|
|
8
|
+
`WorkspaceFS` policy (plus a read-only allowlist for TypeScript's own lib dir).
|
|
9
|
+
Other languages return `UNSUPPORTED_LANGUAGE` — grep is never labeled semantic.
|
|
10
|
+
tsconfig is parsed as data; repo TS plugins are never loaded.
|
|
11
|
+
|
|
12
|
+
**Trade-off.** Only TS/JS get true semantics in v1. Honest capability reporting
|
|
13
|
+
over pretend coverage.
|
|
14
|
+
|
|
15
|
+
**Evidence / validation.** `integration/semantics.test.ts` (shadowing/import/
|
|
16
|
+
re-export references, homonym-safe rename, Python → UNSUPPORTED_LANGUAGE). See
|
|
17
|
+
[src/services/intelligence/tsWorker.ts](../../src/services/intelligence/tsWorker.ts).
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
# ADR-009 — Jobs + polling as the execution baseline
|
|
2
|
+
|
|
3
|
+
**Status:** accepted (implemented)
|
|
4
|
+
|
|
5
|
+
**Decision.** Long work returns a `jobId` immediately; clients poll
|
|
6
|
+
`job_status` / `job_output`. Jobs live in a service layer, not in any MCP
|
|
7
|
+
session, so a dropped HTTP connection never kills a job and a reconnect can
|
|
8
|
+
resume reading. Output is a bounded segmented on-disk spool. Cancellation
|
|
9
|
+
signals only the owned process group; jobs from a previous boot become
|
|
10
|
+
`interrupted_on_restart` and are never auto-rerun.
|
|
11
|
+
|
|
12
|
+
**Trade-off.** No reliance on long-lived streaming or experimental task
|
|
13
|
+
transports; the client must poll.
|
|
14
|
+
|
|
15
|
+
**Evidence / validation.** `integration/jobs.test.ts` (prompt jobId, output after
|
|
16
|
+
reconnect, stdin pipe, cancel, no-shell argv, idempotent single job, concurrency
|
|
17
|
+
limit, PATH safety). Spool rollover in `unit/spoolAndConfig.test.ts`. See
|
|
18
|
+
[src/services/jobs/jobManager.ts](../../src/services/jobs/jobManager.ts).
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
# ADR-010 — `better-sqlite3` durable store, chosen in M0
|
|
2
|
+
|
|
3
|
+
**Status:** accepted (implemented)
|
|
4
|
+
|
|
5
|
+
**Decision.** Durable state uses `better-sqlite3` `13.0.3` in WAL mode. It
|
|
6
|
+
installed from a **prebuilt** binary on macOS arm64 with no compiler required
|
|
7
|
+
(verified in M0; `dodo doctor` reports `sqlite-native`). Migrations run under
|
|
8
|
+
`BEGIN IMMEDIATE`, and read-only CLI paths open the DB read-only so `dodo status`
|
|
9
|
+
never races the server's startup migration. We did not choose `node:sqlite`
|
|
10
|
+
because its API status warranted caution on the target Node.
|
|
11
|
+
|
|
12
|
+
**Trade-off.** A native dependency (prebuilt-binary reliance). If no prebuilt
|
|
13
|
+
exists for a target, install fails loudly — no silent in-memory fallback.
|
|
14
|
+
|
|
15
|
+
**Evidence / validation.** Concurrent open safety is covered by
|
|
16
|
+
`integration/cli.test.ts` (status while start boots). Native load is checked by
|
|
17
|
+
`dodo doctor` and `packaging/pack.test.ts`. See
|
|
18
|
+
[src/store/db.ts](../../src/store/db.ts).
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
# ADR-011 — `.env.example` denied by default (secure default)
|
|
2
|
+
|
|
3
|
+
**Status:** accepted (implemented)
|
|
4
|
+
|
|
5
|
+
**Context.** Spec §10.2 flags `.env.example` ambiguously: the `.env*` hard deny
|
|
6
|
+
covers it, yet the text says it should not be excluded "by guessing".
|
|
7
|
+
|
|
8
|
+
**Decision.** Apply the pack's conflict rule — "when specs conflict, choose the
|
|
9
|
+
path that does not reduce security" — and keep `.env.example` under the `.env*`
|
|
10
|
+
secret deny **by default**. An owner who wants it readable can allow it via
|
|
11
|
+
explicit local policy in future (not exposed as a repo-config toggle, since repo
|
|
12
|
+
config cannot widen access).
|
|
13
|
+
|
|
14
|
+
**Trade-off.** A genuinely-template `.env.example` is unreadable by default,
|
|
15
|
+
which is mildly inconvenient but never leaks a misused one.
|
|
16
|
+
|
|
17
|
+
**Evidence / validation.** `unit/ignores.test.ts` asserts the secure default and
|
|
18
|
+
documents the rationale. See
|
|
19
|
+
[src/workspace/ignores.ts](../../src/workspace/ignores.ts).
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
# ADR-012 — Grants at both OIDC and resource scope; first-party auto-consent
|
|
2
|
+
|
|
3
|
+
**Status:** accepted (implemented)
|
|
4
|
+
|
|
5
|
+
**Context.** During M0 the authorization flow returned `access_denied`
|
|
6
|
+
("no scope granted"). Root cause: `dodo:*` are RFC 8707 resource-indicator
|
|
7
|
+
scopes, and the just-created grant was not being reused as the consent grant
|
|
8
|
+
because it was not yet linked to the browser session.
|
|
9
|
+
|
|
10
|
+
**Decision.** (1) Advertise `dodo:*` both as global OIDC scopes (so the
|
|
11
|
+
authorization request's `scope` param is accepted) and as resource-server scopes
|
|
12
|
+
(so the access token audience is the `/mcp` resource); grant at both levels.
|
|
13
|
+
(2) Implement `loadExistingGrant` to reuse the DODO grant the owner approved for
|
|
14
|
+
this client + this workspace — the standard first-party trusted-client pattern —
|
|
15
|
+
so the owner consents once over local IPC and the browser does not re-prompt. A
|
|
16
|
+
grant bound to a different workspace is filtered out (no cross-workspace reuse).
|
|
17
|
+
|
|
18
|
+
**Trade-off.** Slightly more grant plumbing; in return single-owner consent is
|
|
19
|
+
one approval, and audience binding is still enforced by the verifier.
|
|
20
|
+
|
|
21
|
+
**Evidence / validation.** `integration/m0` issues a working token; AUTH-07
|
|
22
|
+
cross-workspace isolation holds in `security/auth.test.ts`. See
|
|
23
|
+
[src/auth/provider.ts](../../src/auth/provider.ts),
|
|
24
|
+
[src/auth/interactions.ts](../../src/auth/interactions.ts).
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
# ADR-013 — `trust proxy = loopback`; issuer from explicit config only
|
|
2
|
+
|
|
3
|
+
**Status:** accepted (implemented)
|
|
4
|
+
|
|
5
|
+
**Decision.** Express `trust proxy` is set to `'loopback'` (not `true`). The only
|
|
6
|
+
hop in front of DODO is the owner's tunnel daemon on loopback, so its
|
|
7
|
+
`X-Forwarded-Proto` is trusted for HTTPS/secure-cookie handling — but the OAuth
|
|
8
|
+
issuer and resource URLs are **always** the explicit configured `publicUrl`,
|
|
9
|
+
never derived from `Host` or `X-Forwarded-Host`. Host and Origin are allowlisted
|
|
10
|
+
before the provider sees a request; `Origin: null` is denied.
|
|
11
|
+
|
|
12
|
+
**Trade-off.** The owner must configure `publicUrl` correctly; DODO will not
|
|
13
|
+
guess it from headers (which would be spoofable).
|
|
14
|
+
|
|
15
|
+
**Evidence / validation.** `security/auth.test.ts` (AUTH-14: evil Host 403,
|
|
16
|
+
`Origin: null` 403, spoofed forwarded headers do not change issuer; AUTH-13:
|
|
17
|
+
loopback traffic still needs a token). See
|
|
18
|
+
[src/server/appServer.ts](../../src/server/appServer.ts).
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
# ADR-014 — Direct coding-agent tool tier (v1.1)
|
|
2
|
+
|
|
3
|
+
**Status:** accepted (implemented)
|
|
4
|
+
|
|
5
|
+
**Context.** v1 shipped the 24-tool review workflow (preview → approve → apply;
|
|
6
|
+
argv-only exec + job polling). The owner's actual use is an MCP client that
|
|
7
|
+
confirms **every** tool call itself (ChatGPT developer mode), and wants the AI
|
|
8
|
+
to work like a local coding agent — run tests, install packages, edit and search
|
|
9
|
+
in one step — "as capable as AI coding tools".
|
|
10
|
+
|
|
11
|
+
**Decision.** Add a direct tier of 9 tools on top of the SAME policy and
|
|
12
|
+
journal, taking the catalog to 33:
|
|
13
|
+
|
|
14
|
+
- `write_file`, `edit_file`, `delete_path`, `move_path`, `make_directory` — one
|
|
15
|
+
call each, implemented by building a single-op plan through the existing
|
|
16
|
+
`Planner` and applying it through the journaled `Applier`, so every direct
|
|
17
|
+
write stays hash-verified, backed up, visible in `change_history` and
|
|
18
|
+
reversible with `rollback_changes`.
|
|
19
|
+
- `glob_files` — pattern search over the policy-filtered walk (`picomatch`).
|
|
20
|
+
- `run_command` — a shell command **string** executed as `bash -c` (fixed
|
|
21
|
+
system binary), which waits up to `waitMs` and returns exit code + bounded
|
|
22
|
+
stdout/stderr inline; a still-running command hands back its `jobId`. This is
|
|
23
|
+
the same capability a trusted caller already had via
|
|
24
|
+
`exec_command(program:'sh', args:['-c', …])`, exposed ergonomically and gated
|
|
25
|
+
by the identical exec policy — it adds convenience, not authority. DODO itself
|
|
26
|
+
still spawns with `shell:false` (argv), so the only shell parsing is the one
|
|
27
|
+
the caller explicitly asked for.
|
|
28
|
+
- `git_log` (read tier) and `git_commit` (exec tier: hooks run and the user's
|
|
29
|
+
git identity is needed). `all: true` stages only paths from the scoped,
|
|
30
|
+
secret-filtered status — never `git add -A .`.
|
|
31
|
+
|
|
32
|
+
Trust-mode semantics are unchanged; `trusted` is now documented as the
|
|
33
|
+
recommended mode when the client confirms each call.
|
|
34
|
+
|
|
35
|
+
**Trade-off.** Fewer DODO-side checkpoints in `trusted` mode — by the owner's
|
|
36
|
+
explicit choice, since the client dialog is the gate. The safety floor that does
|
|
37
|
+
not depend on mode (path policy, secret deny, hash verification, journal,
|
|
38
|
+
reversibility, no token/secret in child env) is untouched.
|
|
39
|
+
|
|
40
|
+
**Evidence / validation.** `tests/integration/directTools.test.ts` (13 cases:
|
|
41
|
+
the fix-the-bug loop with `run_command npm test` → `edit_file` → green,
|
|
42
|
+
AMBIGUOUS_EDIT/FILE_CHANGED refusals, create/move/delete round-trip with
|
|
43
|
+
rollback, policy + secret denial through direct tools, running-job handoff and
|
|
44
|
+
cancel, a real local `npm install`, inspect-mode approval gating, `git_commit`
|
|
45
|
+
that never stages `.env`). Catalog/schema counts updated to 33 in m0/compat/pack
|
|
46
|
+
suites. See [src/tools/directTools.ts](../../src/tools/directTools.ts),
|
|
47
|
+
[src/tools/jobTools.ts](../../src/tools/jobTools.ts),
|
|
48
|
+
[src/services/git/gitService.ts](../../src/services/git/gitService.ts).
|
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
# ADR-015 — Coding-agent parity (v1.2): parallel commands, sandbox, patch, LSP, stdio
|
|
2
|
+
|
|
3
|
+
**Status:** accepted (implemented)
|
|
4
|
+
|
|
5
|
+
**Context.** After v1.1 the owner asked for DODO to match the tool set of
|
|
6
|
+
Claude Code / Codex CLI / Kiro / OpenCode "in one package", including running
|
|
7
|
+
several commands at once so the AI works faster. The MCP client confirms every
|
|
8
|
+
call, so DODO's own approvals stay for `inspect`/`edit` but must not add
|
|
9
|
+
friction in `trusted` mode.
|
|
10
|
+
|
|
11
|
+
**Decision.** Add, on the same policy + journal:
|
|
12
|
+
|
|
13
|
+
- **Parallel & background execution** — `run_commands` (up to 8 commands at
|
|
14
|
+
once, one result each), `run_command background:true`, `job_wait`.
|
|
15
|
+
- **OS sandbox for commands** (Codex-style) — `run_command{sandbox:true}` /
|
|
16
|
+
global `commandSandbox: off|prefer|require`: macOS `sandbox-exec` seatbelt
|
|
17
|
+
profile or Linux `bwrap`, restricting **writes** to the workspace + declared
|
|
18
|
+
caches and optionally denying network. Availability is detected; `require`
|
|
19
|
+
fails closed. It confines what the command may *write*, not what it may read.
|
|
20
|
+
- **`apply_patch`** — unified-diff application with `fuzzFactor: 0` (no fuzzy
|
|
21
|
+
matching); a non-applying hunk fails the whole call.
|
|
22
|
+
- **`replace_in_files`** — bulk literal replace, dry-run by default.
|
|
23
|
+
- **Grep parity** — `search_code` gains context lines, `fileGlob`, output modes
|
|
24
|
+
`files`/`count`, and a time-capped worker-thread regex fallback when ripgrep
|
|
25
|
+
is absent (the worker is terminated on timeout).
|
|
26
|
+
- **`read_image`**, `read_files{numbered}`, `glob_files{sortBy:'mtime'}`.
|
|
27
|
+
- **Agent memory** — `todo_write`/`todo_read` (per-workspace, outside the repo),
|
|
28
|
+
`read_instructions` (AGENTS.md / CLAUDE.md / .cursor/rules / .kiro/steering…
|
|
29
|
+
as untrusted conventions), `environment_info`.
|
|
30
|
+
- **`fetch_url`** — opt-in (`allowWebFetch`), https-only, SSRF-guarded
|
|
31
|
+
(private/loopback/link-local refused, re-checked on every redirect hop),
|
|
32
|
+
gated like a command.
|
|
33
|
+
- **LSP adapter** — owner-registered language servers (`dodo lsp add`) behind
|
|
34
|
+
the same semantic tools; see docs/LSP.md.
|
|
35
|
+
- **stdio transport** — `dodo stdio` for local clients (Claude Code, Cursor,
|
|
36
|
+
Codex CLI, Claude Desktop): no tunnel, no OAuth; the local client process is
|
|
37
|
+
the principal. Trust modes, approvals and path policy are unchanged.
|
|
38
|
+
- **Ecosystem task discovery** — Makefile, pyproject/pytest, Cargo, Go,
|
|
39
|
+
composer, Gradle, Maven recipes in `project_overview`.
|
|
40
|
+
- `dodo audit` to review what the AI did.
|
|
41
|
+
|
|
42
|
+
**Trade-offs.** More surface (43 tools). The sandbox is best-effort OS
|
|
43
|
+
isolation of writes/network for the command process tree — not a security
|
|
44
|
+
boundary against a hostile same-user process; `sandbox-exec` is deprecated by
|
|
45
|
+
Apple but functional. `fetch_url` is network egress from the owner's machine
|
|
46
|
+
and stays off by default.
|
|
47
|
+
|
|
48
|
+
**Evidence / validation.** `tests/integration/agentTools.test.ts` (parallel
|
|
49
|
+
results, background + job_wait, macOS sandbox write denial, search modes +
|
|
50
|
+
regex worker, multi-file apply_patch + CONFLICT on stale hunks, bulk replace
|
|
51
|
+
dry-run/apply, image block, numbered reads, instructions, todos, env info,
|
|
52
|
+
Makefile recipes, fetch_url disabled/SSRF refusals),
|
|
53
|
+
`tests/integration/stdio.test.ts` (real `@modelcontextprotocol/client` stdio
|
|
54
|
+
transport against `dodo stdio`), `tests/unit/sandbox.test.ts` (seatbelt profile
|
|
55
|
+
+ real enforcement on macOS), `tests/integration/lsp.test.ts` (pyright over
|
|
56
|
+
stdio JSON-RPC), `tests/integration/faultInjection.test.ts` (CHG-08/09).
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
# 016 — Preserve requested OpenID consent
|
|
2
|
+
|
|
3
|
+
The ChatGPT authorization request observed on 2026-09-09 includes `openid`
|
|
4
|
+
alongside DODO resource scopes. The interaction adapter filtered this out of
|
|
5
|
+
its grant, so oidc-provider 9.12.2 resumed into another consent interaction
|
|
6
|
+
instead of returning an authorization code.
|
|
7
|
+
|
|
8
|
+
Grant `openid` at the OIDC level only when the authorization request includes
|
|
9
|
+
it. Keep resource scopes and workspace grants restricted to DODO permissions.
|
|
10
|
+
Local approval, PKCE, session binding and static registration remain required.
|
|
11
|
+
|
|
12
|
+
Evidence: AUTH-22 reproduced the redirect to a second interaction before the
|
|
13
|
+
fix; after the fix, one approval reaches the callback, exchanges the code and
|
|
14
|
+
successfully calls authenticated MCP tools/list. All 20 auth tests passed.
|
|
15
|
+
Live ChatGPT/tunnel reconnection remains a manual verification.
|