Getting Started
Get up and running with OpenCode agents in under 5 minutes.
Prerequisites
- OpenCode CLI installed
- Node.js/npm
- Any project (existing repos work perfectly)
Quick Setup (60 seconds)
Via npx (Recommended)
# Global install
npx agents-opencode --global
# Project install
npx agents-opencode --project .
# Filter language instruction references for a lighter install
npx agents-opencode --global --languages python,typescript
# Update existing installation
npx agents-opencode --update
# Force update both global + current project scopes
npx agents-opencode --update --all
--languages filters language instruction reference files. Runtime skills still load on demand via agent skill allowlists.
Via curl
Global Installation
curl -fsSL https://raw.githubusercontent.com/shahboura/agents-opencode/main/install.js \
-o install.js && node install.js --global && rm install.js
Project Installation
curl -fsSL https://raw.githubusercontent.com/shahboura/agents-opencode/main/install.js \
-o install.js && node install.js --project /path/to/your/project && rm install.js
Windows (PowerShell)
curl -fsSL https://raw.githubusercontent.com/shahboura/agents-opencode/main/install.js `
-o install.js; node install.js --global; rm install.js
Uninstall
# Current project scope (default)
npx agents-opencode --uninstall
# Global scope only
npx agents-opencode --uninstall --global
# Both global + current project scopes
npx agents-opencode --uninstall --all
# Check detected install scopes
npx agents-opencode --status
- Default uninstall applies to the current project scope.
- Use
--globalor--allto target non-project scope. - Removes installer-managed files using install manifest tracking.
- Project backups:
<project>/.opencode/.backups/<timestamp>--<operation>--<scope>/ - Global backups:
~/.config/opencode/.backups/<timestamp>--<operation>--<scope>/ - Backup retention: latest 10 sessions and sessions newer than 30 days.
- Installer only merges missing permission defaults into existing
opencode.json. - Existing provider/model/instruction configuration remains unchanged.
To restore files, use backup-manifest.json from a backup session and copy the files back to their original paths.
Your First Run
-
Open OpenCode:
opencode -
Initialize context:
/init -
Ask for help:
@orchestrator Build a user authentication API with JWT tokens
What gets installed
.opencode/agent configsopencode.jsonproject config
Notes
- Package/installer command:
agents-opencode - OpenCode runtime command:
opencode - Git is not required for
npx/npminstalls. AGENTS.mdis created on first run or via/init.- Coding standards in
.opencode/instructions/are available as reference for agents.