




























@@ -78,6 +78,9 @@ and provider plugins have dedicated guides linked above.
7878 "id": "my-plugin",
7979 "name": "My Plugin",
8080 "description": "Adds a custom tool to OpenClaw",
81+ "contracts": {
82+ "tools": ["my_tool"]
83+ },
8184 "activation": {
8285 "onStartup": true
8386 },
@@ -89,9 +92,10 @@ and provider plugins have dedicated guides linked above.
8992```
9093</CodeGroup>
919492-Every plugin needs a manifest, even with no config, and every plugin should
93-declare `activation.onStartup` intentionally. Runtime-registered tools need
94-startup import, so this example sets it to `true`. See
95+Every plugin needs a manifest, even with no config. Runtime-registered tools
96+must be listed in `contracts.tools` so OpenClaw can discover the owning
97+plugin without loading every plugin runtime. Plugins should also declare
98+`activation.onStartup` intentionally. This example sets it to `true`. See
9599[Manifest](/plugins/manifest) for the full schema. The canonical ClawHub
96100publish snippets live in `docs/snippets/plugin-publish/`.
97101@@ -242,6 +246,17 @@ register(api) {
242246}
243247```
244248249+Every tool registered with `api.registerTool(...)` must also be declared in the
250+plugin manifest:
251+252+```json
253+{
254+"contracts": {
255+"tools": ["my_tool", "workflow_tool"]
256+ }
257+}
258+```
259+245260Users enable optional tools in config:
246261247262```json5
此内容由惯性聚合(RSS阅读器)自动聚合整理,仅供阅读参考。 原文来自 — 版权归原作者所有。