opencode-cli-runtime

Installation
SKILL.md

OpenCode Runtime

Call OpenCode headlessly from a non-OpenCode runtime with one canonical command shape.

Contract

  • Resolve the active workspace authority contract before composing the prompt. It governs writes, credentials, external actions, production changes, destructive operations, and human gates. Include the exact contract in any delegated prompt that may reach those surfaces.
  • Without a workspace contract, use the read-only tool set and stop before external effects.
  • Run from the target repository so OpenCode discovers its local instructions (AGENTS.md, opencode.json).
  • Capture the returned session id from the event stream; it is the only reliable follow-up handle.

Preamble

command -v opencode >/dev/null 2>&1 && OC=opencode || OC="$HOME/.local/bin/opencode"
$OC --version >/dev/null 2>&1 || echo "OPENCODE: missing"

OPENCODE: missing → stop and report the missing runtime.

Installs
2
GitHub Stars
1
First Seen
Jul 31, 2026
opencode-cli-runtime — jorgemenadev/skills