chore(sync): mirror docs from openclaw/openclaw@3bd2ee78b6

This commit is contained in:
openclaw-docs-sync[bot] 2026-04-24 18:39:54 +00:00
parent dbd9dd8731
commit c41424aff5
2 changed files with 12 additions and 3 deletions

View File

@ -1,5 +1,5 @@
{
"repository": "openclaw/openclaw",
"sha": "a43c1f880757e830b5fb4d3c7b5532a625f0e3e4",
"syncedAt": "2026-04-24T18:34:48.414Z"
"sha": "3bd2ee78b6acf105c23656bb2d61416d6ccb2fa7",
"syncedAt": "2026-04-24T18:38:29.642Z"
}

View File

@ -159,6 +159,9 @@ Use the phase-specific hooks for new plugins:
`before_agent_start` remains for compatibility. Prefer the explicit hooks above
so your plugin does not depend on a legacy combined phase.
`before_agent_start` and `agent_end` include `event.runId` when OpenClaw can
identify the active run. The same value is also available on `ctx.runId`.
Non-bundled plugins that need `llm_input`, `llm_output`, or `agent_end` must set:
```json
@ -182,10 +185,16 @@ Prompt-mutating hooks can be disabled per plugin with
Use message hooks for channel-level routing and delivery policy:
- `message_received`: observe inbound content, sender, `threadId`, and metadata.
- `message_received`: observe inbound content, sender, `threadId`, `messageId`,
`senderId`, optional run/session correlation, and metadata.
- `message_sending`: rewrite `content` or return `{ cancel: true }`.
- `message_sent`: observe final success or failure.
Message hook contexts expose stable correlation fields when available:
`ctx.sessionKey`, `ctx.runId`, `ctx.messageId`, `ctx.senderId`, `ctx.trace`,
`ctx.traceId`, `ctx.spanId`, `ctx.parentSpanId`, and `ctx.callDepth`. Prefer
these first-class fields before reading legacy metadata.
Prefer typed `threadId` and `replyToId` fields before using channel-specific
metadata.