diff --git a/.openclaw-sync/source.json b/.openclaw-sync/source.json index 0b9e2d3fe..4a6e09266 100644 --- a/.openclaw-sync/source.json +++ b/.openclaw-sync/source.json @@ -1,5 +1,5 @@ { "repository": "openclaw/openclaw", - "sha": "2495585a32ebe1b6b66cd7900cce04a403fd344f", - "syncedAt": "2026-04-26T01:35:43.982Z" + "sha": "c7b336d83e13a44678a155bda40098d7d33b8232", + "syncedAt": "2026-04-26T01:39:34.957Z" } diff --git a/docs/plugins/hooks.md b/docs/plugins/hooks.md index abd5a3e2e..a46129680 100644 --- a/docs/plugins/hooks.md +++ b/docs/plugins/hooks.md @@ -112,8 +112,8 @@ observation-only. - `event.params` - optional `event.runId` - optional `event.toolCallId` -- context fields such as `ctx.agentId`, `ctx.sessionKey`, `ctx.sessionId`, and - diagnostic `ctx.trace` +- context fields such as `ctx.agentId`, `ctx.sessionKey`, `ctx.sessionId`, + `ctx.runId`, `ctx.jobId` (set on cron-driven runs), and diagnostic `ctx.trace` It can return: @@ -178,6 +178,9 @@ 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`. +Cron-driven runs also expose `ctx.jobId` (the originating cron job id) so +plugin hooks can scope metrics, side effects, or state to a specific scheduled +job. Use `model_call_started` and `model_call_ended` for provider-call telemetry that should not receive raw prompts, history, responses, headers, request