OpenCode
OpenCode, like Pi, reports its own model list, and its integration is a single Saggar-owned plugin file. Unlike Pi, its plugin hears permission and question prompts directly.
| Command | opencode |
| Install | curl -fsSL https://opencode.ai/install | bash |
| Hook configuration | ~/.config/opencode/plugins/saggar-presence.js |
| Skill location | ~/.config/opencode/skills/saggar-cli/SKILL.md |
| Resume | opencode --session <id>, or opencode --continue without an id |
Launching
The default row launches opencode with its configured model. The provider
card runs opencode models, which prints one provider/model per line, and
lets you pick which get a row. OpenCode takes no reasoning-effort flag.
Hooks
Installing hooks writes one JavaScript plugin into OpenCode's plugins directory. OpenCode loads it automatically, so nothing else of yours is touched, and removal deletes only that file. With it installed Saggar:
- captures the native session id;
- names the session from its first prompt;
- follows busy, idle, and clean-exit events;
- shows the model the session last used in the terminal's chat info;
- hears permission prompts and questions the moment OpenCode asks them;
- restores each session to its exact conversation.
Saggar replaces an older copy of its plugin each time it starts. If the file on disk still doesn't match this build's copy, for example because it was edited, the provider card asks you to install again. Nothing is version gated.
Prompts and automatic approval
A permission request or a question from OpenCode reaches Saggar through the plugin, so the session turns Needs you by contract rather than by screen inference. Saggar doesn't answer OpenCode prompts on your behalf: there is no dialog vocabulary for it and the plugin only reports.
Resume
With a recorded id, restore runs opencode --session <id>. Without one it runs
opencode --continue.
Further reading
- OpenCode's keybinds, attention, and themes pages cover its keys, notifications, and colors. Set up your terminal for agents says which of those Saggar already handles.