feat: make @youdotcom-oss/openclaw a real OpenClaw 2.0 plugin - #55
Open
brainsparker wants to merge 1 commit into
Open
feat: make @youdotcom-oss/openclaw a real OpenClaw 2.0 plugin#55brainsparker wants to merge 1 commit into
brainsparker wants to merge 1 commit into
Conversation
The package shipped `register: () => {}` with an empty config schema and no
capability contracts, so OpenClaw could see skills but had no way to know
You.com is a search engine. Declare the capability ownership and wire a real
runtime entry, built against the 2026.8.1 plugin SDK.
Manifest:
- contracts.webSearchProviders ["you", "you-free"], webFetchProviders ["you"]
- activation.onStartup false; 2.0 no longer startup-loads implicitly, and the
contracts above are the capability-triggered load path
- full configSchema: apiKey, baseUrl, timeouts, count, safesearch, country,
freshness, extractionMode
- configContracts.secretInputs routes apiKey through SecretRef with
ownerKind "capability", plus sensitive uiHints
Runtime:
- plugin.ts builds its config schema from the manifest via
buildJsonPluginConfigSchema, resolves settings, warns on a missing
credential, and debug-logs a redacted summary
- settings.ts normalizes plugin config for the providers DX-806/DX-807 add,
reading credentials through the SDK's resolveSecretInputString and
rejecting a non-http(s) baseUrl instead of falling back silently
Packaging targets 2026.8.1 via compat.pluginApi, install.minHostVersion, and
the openclaw peer dependency.
Verified with the 2026.8.1 CLI against an isolated state dir: `plugins doctor`
passes, `plugins inspect you` reports the plugin loaded with web-search
"you, you-free" and web-fetch "you", `health` returns ok with no plugin errors,
all five skills stay ready, and out-of-range config is rejected by the schema.
Refs DX-805
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Contributor
|
Droid finished @brainsparker's task —— View job Code review completeStatus: approved — no high-confidence actionable issues found. The PR cleanly converts No inline review comments were posted. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes DX-805.
@youdotcom-oss/openclawshipped as a skill and setup-metadata bundle, not a plugin. Its runtime was literallyregister: () => {}, its config schema was empty, and it declared no capability contracts — so OpenClaw knew a plugin with some skills existed, but had no way to know You.com is a search engine. This is the blocker for the rest of the milestone: OpenClaw 2.0's Agent Plugin bundle contract keeps providers, configuration schemas, and runtime entry points outside the bundle, so no amount of skill work reaches the provider picker.This is the plumbing that makes providers registerable. Actual provider implementations stay in DX-806 / DX-807.
Manifest
contracts.webSearchProviders: ["you", "you-free"]andcontracts.webFetchProviders: ["you"]. This is what OpenClaw validates provider ids against, andresolveManifestDeclaredWebProviderCandidatePluginIdsuses it to pick which plugin runtimes to load when a web capability is requested.activation.onStartup: false. 2.0 stopped startup-loading implicitly and asks every plugin to set this intentionally; we're inert at startup, and the contracts above are the load trigger.configSchema:apiKey,baseUrl,timeoutMs,crawlTimeoutSeconds,count,safesearch,country,freshness,extractionMode— bounded and patterned, with defaults.configContracts.secretInputsroutesapiKeythrough SecretRef withownerKind: "capability", so a stale credential fails cold rather than staying active.uiHintsmarks it sensitive.setup.providers[].authMethods: ["api-key"]. Skills andYDC_API_KEYmetadata are unchanged.Runtime
plugin.tsbuilds its runtime config schema from the manifest throughbuildJsonPluginConfigSchema, so the JSON Schema has one home.register(api)resolves settings, warns when no credential is reachable, and debug-logs a redacted summary. The DX-806/807 provider registrations slot into the same closure.settings.tsis the shared normalizer those tickets consume. Credentials go through the SDK'sresolveSecretInputString(openclaw/plugin-sdk/secret-input) ininspectmode, so a configured-but-unresolved SecretRef reports itself instead of throwing. A non-http(s)baseUrlthrows — that's where the API key gets sent, so it fails loud and lands inplugins doctorinstead of quietly redirecting the credential.Packaging
Built against 2026.8.1, not the retired July/August SDK paths:
openclaw.compat.pluginApi,openclaw.install.minHostVersion(replacing the undocumentedcompat.minGatewayVersion), and theopenclawpeer dependency. Rootbun.lockresolvesopenclaw@2026.8.1.No
semver-release.tschange needed:packages/openclaw/**already matches by path prefix, andopenclaw.plugin.jsonis already version-bumped in lockstep on apply.Verification
Against the real 2026.8.1 CLI with an isolated
OPENCLAW_STATE_DIR/OPENCLAW_CONFIG_PATH, plugin loaded viaplugins.load.paths:openclaw plugins doctor— "Plugin discovery, module loading, compatibility, and configuration checks passed."openclaw plugins inspect you—Status: loaded,Shape: hybrid-capability,web-search: you, you-free,web-fetch: youopenclaw health(loopback gateway, since stopped) —ok: true,plugins.errors: [],unavailable: [].youis deliberately absent fromplugins.loaded: that'sonStartup: falseworking, not a failure.openclaw skills list— all five You.com skills✓ readycount: 0is rejected withplugins.entries.you.config.count: invalid config: must be >= 1bun test packages/openclaw— 21 pass.tsc --noEmit,biome check,format-package --checkclean.bun testat the repo root has one failure,Pi extension > … from real endpoints(duplicateyou-search-free), which also fails on a clean checkout ofmain— live-endpoint test, unrelated. Python checks were skipped: nothing Python changed.One deviation
The ticket asks to use "the shared Plugin SDK stream and
SecretRefutilities."plugin-sdk/provider-streamis the LLM-inference stream-wrapper surface — nothing in a web search or fetch provider consumes it, so it's left out. The SecretRef half is done viaplugin-sdk/secret-input.🤖 Generated with Claude Code