events

A command for reading the recorded event log of a crabbox run. The log contains ordered updates such as starting, syncing, command output, and failures.

In plain words
What is it for?
Use it to inspect a run by event type, phase, time position, or output stream, and to return the results as JSON.
Why use it?
It helps explain what happened during a run when the final result is not enough, while limiting how much output is displayed.

Command

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add commands/openclaw/crabbox/events
Clone the repo
git clone --depth 1 https://github.com/openclaw/crabbox
Per session 0 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 1,126 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00000 $0.01126
Opus 5 $0.00000 $0.00563
Sonnet 5 $0.00000 $0.00225
Haiku 4.5 $0.00000 $0.00113

Measured 2d ago against content hash 60b50ae157fe, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

events scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

docs/commands/events.md · 101 lines

How it starts

The opening of the file, as written. The whole thing — 101 lines — stays where its author put it; the contents beside it link to each section on GitHub.

events

crabbox events prints the broker's event log for a recorded run.

crabbox events run_abcdef123456
crabbox events --id run_abcdef123456 --after 42 --limit 100
crabbox events run_abcdef123456 --type stdout
crabbox events run_abcdef123456 --phase sync
crabbox events run_abcdef123456 --json

The run id (run_<hex>) is also accepted as a positional argument; --id and the positional form are equivalent. Reading events requires a configured broker, since the event log lives in the coordinator, not on the box.

What events are recorded

When crabbox run executes against a broker, a runRecorder creates a durable run_... record before it leases or syncs, then appends ordered events as the run advances. Each event has a monotonic sequence number, a type, a phase, an optional stream (stdout/stderr), a timestamp, and a short message or output text. Common event types include:

  • run.started
  • leasing.started, lease.created, lease.released
  • bootstrap.waiting
  • actions.hydrate.started, actions.hydrate.finished, actions.hydrate.failed
  • sync.started, sync.finished
  • command.started
  • stdout, stderr, output.truncated
  • lease.replace.started, lease.replace.finished, lease.replace.failed
  • run.failed

The exact set depends on the run: an Actions-hydrated run emits the actions.hydrate.* events, a run that swaps a dead box mid-flight emits the lease.replace.* events, and so on.

Output

Human-readable output prints the sequence number, type, phase, stream, and timestamp followed by the message (falling back to the event's data text):

0001 run.started        phase=starting   stream=- at=2026-05-07T07:42:18Z
0002 leasing.started    phase=leasing    stream=- at=2026-05-07T07:42:18Z
0003 lease.created      phase=leasing    stream=- at=2026-05-07T07:42:21Z leased=cbx_abcdef123456 slug=swift-crab
0004 bootstrap.waiting  phase=bootstrap  stream=- at=2026-05-07T07:42:21Z
0005 sync.started       phase=sync       stream=- at=2026-05-07T07:43:05Z
0006 sync.finished      phase=sync       stream=- at=2026-05-07T07:43:08Z files=184 bytes=12.4MiB
0007 command.started    phase=command    stream=- at=2026-05-07T07:43:08Z pnpm test
0008 stdout             phase=command    stream=stdout at=2026-05-07T07:43:09Z > vitest run
...
0043 lease.released     phase=release    stream=- at=2026-05-07T07:45:34Z

Read the full file on GitHub · 101 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 2d ago First seen · 101 lines · 0 tokens per session scan A 60b50ae157fe

Subscribe to this mod's changes

events is a command published in the GitHub repository openclaw/crabbox (1,343 stars, last pushed 2d ago), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 1,126 tokens. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.