* docs(plugins): mark generated reference pages and fix their shared template Two generator files change; the other 153 files are their regenerated output from `pnpm plugins:inventory:gen`. - Emit a "generated, do not edit" banner naming the regeneration command and the manual-block markers. None of the 151 reference pages said they were generated, so a contributor edit was silently overwritten. - Give generated reference titles a `reference` suffix. Eight of them collided with a hand-written guide title (beam, geolocation, google-meet, logbook, teams-meetings, webhooks, workboard, zoom-meetings). Duplicate frontmatter titles across docs/ now total 0. - Render the surface list as a list instead of a semicolon-joined sentence, and use plain conjunctions for install routes. Strict STE hard violations across docs/plugins/reference/ drop from 178 to 20. - Drop the body H1, which duplicated the frontmatter title Mintlify already renders. - Fix a generator bug found while testing: the marker-less fallback in `extractManualReferenceSections` matched only the first line under `## Surface`, so a second `--write` run captured later bullets into a fabricated manual block. `--write` is now idempotent and `--check` passes across repeated runs. All 12 hand-written manual blocks are preserved. * test(scripts): follow resolvePluginSurface to its list contract resolvePluginSurface now returns one string per surface item instead of a semicolon-joined sentence, so the generator can render a list. The four assertions move from toBe(<joined string>) to toEqual(<array>) and pick up the capitalised labels. The "generic fallback" case changes meaning rather than disappearing. The empty manifest now yields [], and renderSurface() prints "This plugin declares no channels, providers, commands, or contracts." for an empty list, which tells a reader more than the old "plugin". The test is renamed to say what it now checks, with a comment pointing at the new home of the fallback. No generated page has an empty Surface section, so no page changes because of this.
3.9 KiB
| summary | read_when | title | |
|---|---|---|---|
| Adds policy-backed doctor checks for workspace conformance. |
|
Policy plugin reference |
Adds policy-backed doctor checks for workspace conformance.
Distribution
- Package:
@openclaw/policy - Install route: included in OpenClaw
Surface
- CLI commands:
openclaw policy
Behavior
The Policy plugin contributes doctor health checks for policy-managed OpenClaw settings and governed workspace declarations. Policy currently covers channel conformance, governed tool metadata, MCP server posture, model-provider posture, private-network access posture, Gateway exposure posture, agent workspace/tool posture, configured global/per-agent tool posture, configured sandbox runtime posture, ingress/channel access posture, data-handling posture, and OpenClaw config secret provider/auth profile posture.
Policy stores authored requirements in policy.jsonc, observes existing
OpenClaw settings and workspace declarations as evidence, and reports drift
through openclaw policy check and openclaw doctor --lint. A clean policy
check emits policy, evidence, findings, and attestation hashes that operators
can record for audit.
openclaw policy check, watch, and workspace-relative compare accept
--agent <id>. Explicit multi-agent fleets must select the workspace owner;
the plugin does not infer one from roster order.
openclaw policy compare --baseline <file> compares one policy file to another
policy file. It is config-level conformance only: it uses policy rule metadata
to verify that the checked policy is not missing or weaker than the authored
baseline, and it does not inspect runtime state, credentials, or secret values.
Tool posture rules can require approved profiles, workspace-only filesystem
tools, bounded exec security/ask/host settings, disabled elevated mode, exact
alsoAllow entries, and required tool deny entries. The evidence records
additive alsoAllow entries because they can widen effective tool posture.
These checks observe config conformance only; they do not read runtime approval
state or add runtime enforcement.
Sandbox posture rules can require approved sandbox modes/backends, deny host container networking, deny container namespace joins, require read-only container mounts, deny container runtime socket mounts and unconfined container profiles, and require sandbox browser CDP source ranges. These checks observe config conformance only; they do not read runtime approval state, inspect live containers, or add runtime enforcement.
Data-handling rules can require sensitive logging redaction, deny telemetry content capture, require session retention maintenance, and deny session transcript memory indexing. These checks observe config conformance only; they do not inspect raw logs, telemetry exports, transcripts, memory files, secrets, or personal data.
Named policy scopes under scopes.<scopeName> can add stricter normal policy
sections for the selector they list. agentIds supports tools,
agents.workspace, sandbox, and dataHandling.memory; channelIds supports
ingress.channels.
Runtime agent ids that are not explicitly listed in agents.entries.* are checked
against inherited global/default posture rather than silently passing with no
evidence. Every scope present in policy.jsonc must be valid and enforceable
for its selector. Overlay rules are additional claims, so they do not weaken
top-level policy and can produce their own findings when the same observed
config violates both scopes.