-
-
Notifications
You must be signed in to change notification settings - Fork 80.7k
Feature: configPatch in plugin manifest — automatic config setup on install #6792
Copy link
Copy link
Open
Labels
P2Normal backlog priority with limited blast radius.Normal backlog priority with limited blast radius.clawsweeper:needs-maintainer-reviewClawSweeper marked this issue as needing maintainer review before automation.ClawSweeper marked this issue as needing maintainer review before automation.clawsweeper:needs-product-decisionClawSweeper marked this issue as needing a product or behavior decision.ClawSweeper marked this issue as needing a product or behavior decision.clawsweeper:needs-security-reviewClawSweeper marked this issue as needing security-sensitive review.ClawSweeper marked this issue as needing security-sensitive review.clawsweeper:no-new-fix-prClawSweeper does not recommend queueing a new automated fix PR for this issue.ClawSweeper does not recommend queueing a new automated fix PR for this issue.clawsweeper:source-reproClawSweeper found a high-confidence source-level issue reproduction.ClawSweeper found a high-confidence source-level issue reproduction.enhancementNew feature or requestNew feature or requestimpact:securitySecurity boundary, credential, authz, sandbox, or sensitive-data risk.Security boundary, credential, authz, sandbox, or sensitive-data risk.impact:ux-frictionUser-facing flow adds avoidable confusion or support burden without fully blocking progress.User-facing flow adds avoidable confusion or support burden without fully blocking progress.issue-rating: 🦞 diamond lobsterVery strong issue quality with high-confidence source-level or clear reproduction.Very strong issue quality with high-confidence source-level or clear reproduction.maturity:stableIssue affects a taxonomy feature currently scored M4/M5.Issue affects a taxonomy feature currently scored M4/M5.
Description
Metadata
Metadata
Assignees
Labels
P2Normal backlog priority with limited blast radius.Normal backlog priority with limited blast radius.clawsweeper:needs-maintainer-reviewClawSweeper marked this issue as needing maintainer review before automation.ClawSweeper marked this issue as needing maintainer review before automation.clawsweeper:needs-product-decisionClawSweeper marked this issue as needing a product or behavior decision.ClawSweeper marked this issue as needing a product or behavior decision.clawsweeper:needs-security-reviewClawSweeper marked this issue as needing security-sensitive review.ClawSweeper marked this issue as needing security-sensitive review.clawsweeper:no-new-fix-prClawSweeper does not recommend queueing a new automated fix PR for this issue.ClawSweeper does not recommend queueing a new automated fix PR for this issue.clawsweeper:source-reproClawSweeper found a high-confidence source-level issue reproduction.ClawSweeper found a high-confidence source-level issue reproduction.enhancementNew feature or requestNew feature or requestimpact:securitySecurity boundary, credential, authz, sandbox, or sensitive-data risk.Security boundary, credential, authz, sandbox, or sensitive-data risk.impact:ux-frictionUser-facing flow adds avoidable confusion or support burden without fully blocking progress.User-facing flow adds avoidable confusion or support burden without fully blocking progress.issue-rating: 🦞 diamond lobsterVery strong issue quality with high-confidence source-level or clear reproduction.Very strong issue quality with high-confidence source-level or clear reproduction.maturity:stableIssue affects a taxonomy feature currently scored M4/M5.Issue affects a taxonomy feature currently scored M4/M5.
Type
Fields
Priority
None yet
Problem
Installing an OpenClaw plugin that requires config changes is a multi-step, error-prone process:
Step 3 creates real friction:
This affects any plugin that needs more than just
plugins.entries.<id>.enabled: true— search providers, webhook configs, tool settings, service endpoints, etc.Proposal
Allow plugins to declare a
configPatchfield in theiropenclaw.plugin.jsonmanifest. Whenopenclaw plugins installruns, it deep-merges the patch into the user's config automatically.Manifest example
{ "id": "claude-search-proxy", "services": ["claude-search-proxy"], "configSchema": { "type": "object", "additionalProperties": false, "properties": {} }, "configPatch": { "tools": { "web": { "search": { "provider": "perplexity", "perplexity": { "baseUrl": "http://localhost:52480", "apiKey": "not-needed" } } } } } }Install behavior (proposed)
The user sees exactly what changed. One command does everything.
Merge semantics
Deep merge, not replace. A plugin adding
tools.web.searchmust not blow away an existingtools.web.fetchconfig:Example merge behavior:
Key design decisions
installonlyremove?--no-patchflag to skipRemoval behavior (optional)
Prior art within OpenClaw
The
registerProviderauth flow already returns aconfigPatchobject. Here's how copilot-proxy does it today:This works great for LLM providers because they go through the auth flow. But plugins that provide services (not models) have no equivalent path. The manifest-level
configPatchfills that gap.Real-world use case
claude-search-proxy is an OpenClaw extension that runs a managed HTTP proxy as a service — turning any Claude subscription's WebSearch into an OpenAI-compatible API. The extension starts/stops the proxy with the gateway, monitors health, and handles graceful shutdown.
The proxy works immediately after install. But OpenClaw's
web_searchtool doesn't route through it until the user manually adds the search config. Currently the extension detects this and logs the config snippet needed — but aconfigPatchwould eliminate the problem entirely.Current experience (3 steps):
Proposed experience (2 steps):
Other plugins that would benefit
Any plugin that needs config beyond being enabled:
hooksconfigtools.*settingsImplementation sketch
The change is localized to the plugin install CLI command (
cli/plugins-cli.js):Happy to contribute a PR if this direction looks right. Thanks for considering it!