Skip to main content

Command overview

beacon endpoint opencode supplements the live OpenCode plugin by reading OpenCode’s committed local session store and converting those records into Beacon endpoint events.
Command syntax
Beacon reads opencode.db when present and falls back to OpenCode’s legacy storage/session, storage/message, storage/part, and storage/project tree. This path is useful for historical sessions and sessions that ran before Beacon’s OpenCode plugin was installed or loaded. Every event is marked harness.collection_method=poll. Beacon sees what OpenCode already wrote, so nothing here can hold or deny a tool call. Keep the managed plugin installed when you need live approval telemetry and richer hook timing. Reading is local and offline. Nothing this command does reaches the network.

Commands

Flags

Both subcommands accept: sync also accepts:

Sweeping

Sweep once
Preview without writing anything
--print is a dry run in both directions: it neither writes the runtime log nor advances the cursor.
Sweep continuously
Nothing sweeps on its own. Run sync under whatever scheduler the platform already uses, or leave --watch running in the user context that owns OpenCode’s data directory. A tool call that OpenCode has started but not finished is written twice: once as the invocation, and again with its output, exit code, and diff when it returns. Beacon emits both. The invocation arrives as tool.invoked on the sweep that first sees it, and the completion arrives on a later sweep as command.executed, file.modified, or whichever action the finished call turns out to be. OpenCode rewrites the record in place for the second one, so the cursor tracks the events it has already written by id rather than how far it read: a repeated sweep over an unchanged session writes nothing, and one over a session whose call has since returned writes only the completion.

Status

Show OpenCode sessions and collection progress
collected means the cursor is level with the records Beacon read from that OpenCode session source. SQLite-backed sessions and legacy JSON sessions are tracked separately so upgrading OpenCode’s storage format does not confuse the cursor.

OpenCode

Telemetry coverage, plugin setup, and known gaps for the runtime.

Hooks

Install the live OpenCode plugin for hook-time telemetry.