You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Introduces a per-workspace skip-registration mechanism for tool names,
distinct from `permissions.deny` (which keeps the tool registered and
blocks invocation). Tools listed in `disabledTools` are not registered
at all and never appear in `/tools`, `getAllTools()`, or function-call
discovery — both built-ins and MCP-discovered tools flow through
`ToolRegistry.registerTool` / `registerFactory`, so gating there covers
every registration path.
- `ConfigParameters.disabledTools?: string[]` (frozen into a `ReadonlySet`
at Config construction; queried via `Config.getDisabledTools()`)
- `ToolRegistry.registerTool` and `ToolRegistry.registerFactory` skip
when the tool name is in the disabled set, with a debug log line
- New `settings.tools.disabled: string[]` (UNION merge across scopes),
wired from `loadCliConfig` into ConfigParameters
- Tests pin the contract: skip at register, lazy factory skip, and the
"next refresh" semantic (already-registered tools are unaffected by a
subsequent toggle — the disabled set is consulted at register time,
not at lookup time)
Foundation for the `POST /workspace/tools/:name/enable` route in a
follow-up commit; the bridge will write the settings file directly,
and the next ACP child spawn will pick up the change.
🤖 Generated with [Qwen Code](https://github.com/QwenLM/qwen-code)
Copy file name to clipboardExpand all lines: packages/cli/src/config/settingsSchema.ts
+11Lines changed: 11 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -1571,6 +1571,17 @@ const SETTINGS_SCHEMA = {
1571
1571
showInDialog: false,
1572
1572
mergeStrategy: MergeStrategy.UNION,
1573
1573
},
1574
+
disabled: {
1575
+
type: 'array',
1576
+
label: 'Disabled Tools',
1577
+
category: 'Tools',
1578
+
requiresRestart: true,
1579
+
default: undefinedasstring[]|undefined,
1580
+
description:
1581
+
'Tool names hidden from the registry. Differs from permissions.deny: disabled tools are not registered at all, so they never appear in /tools and cannot be discovered by the model. Managed by the daemon mutation route POST /workspace/tools/:name/enable.',
0 commit comments