The main configuration file is opencode.json in the repository root. This is a sanitized template - you should copy it to your OpenCode config directory:
cp opencode.json ~/.config/opencode/opencode.json{
"provider": {
"fireworks-ai": {
"options": {
"baseURL": "https://sinatorpool-router.delqhi.com/inference/v1",
"apiKey": "your-api-key"
}
}
}
}{
"model": {
"default": "accounts/fireworks/models/deepseek-v4-flash",
"vision": "accounts/fireworks/routers/kimi-k2p6-turbo"
}
}{
"skills": {
"enabled": true,
"directory": "~/.config/opencode/skills"
}
}{
"plugins": {
"enabled": true,
"directory": "~/.config/opencode/plugins"
}
}{
"agents": {
"sin-zeus": {
"enabled": true,
"role": "orchestrator",
"max_agents": 10
}
}
}{
"agents": {
"omoc-swarm": {
"enabled": true,
"mode": "parallel",
"max_workers": 5
}
}
}# Fireworks AI API Key
export FIREWORKS_AI_API_KEY="fw_..."
# GitHub Token
export GITHUB_TOKEN="ghp_..."
# OpenCode API Key
export OPENCODE_API_KEY="oc_..."# Antigravity API Key
export ANTIGRAVITY_API_KEY="ag_..."
# Qwen API Key
export QWEN_API_KEY="qwen_..."
# OpenRouter API Key
export OPENROUTER_API_KEY="or_..."# Install
npm install -g @opencode/plugin-antigravity
# Configure
opencode plugin config antigravity
# Enter your API key when prompted# Install
npm install -g @opencode/plugin-qwen
# Configure
opencode plugin config qwen
# Enter your API key when prompted# Install
npm install -g @opencode/plugin-openrouter
# Configure
opencode plugin config openrouter
# Enter your API key when prompted{
"skills": {
"browser-automation": {
"cdp_port": 9222,
"headless": false,
"user_data_dir": "~/Library/Application Support/Google Chrome"
}
}
}{
"skills": {
"github-mgmt": {
"token": "${GITHUB_TOKEN}",
"org": "SIN-Hermes-Bundles"
}
}
}{
"commands": {
"swarm": {
"max_agents": 10,
"timeout": 300,
"retry_count": 3
}
}
}{
"commands": {
"terminal": {
"default_shell": "zsh",
"max_sessions": 5
}
}
}To create a custom skill:
# Create skill directory
mkdir -p ~/.config/opencode/skills/my-skill
# Create SKILL.md
cat > ~/.config/opencode/skills/my-skill/SKILL.md << 'EOF'
# My Custom Skill
## Description
Describe what this skill does.
## Usage
```bash
opencode skill run my-skill- param1: Description
- param2: Description EOF
### Custom Commands
To create a custom command:
```bash
# Create command file
mkdir -p ~/.config/opencode/commands
cat > ~/.config/opencode/commands/my-command << 'EOF'
#!/bin/bash
# My Custom Command
echo "Running my command..."
# Your logic here
EOF
chmod +x ~/.config/opencode/commands/my-command
# Check config syntax
opencode config validate
# Reset config
opencode config reset
# Reload config
opencode config reload# Check plugin status
opencode plugin list
# Reinstall plugin
opencode plugin install <plugin-name>
# Check plugin logs
opencode plugin logs <plugin-name># Backup old config
cp ~/.config/opencode/opencode.json ~/.config/opencode/opencode.json.bak
# Run migration
./install.sh --migrate
# Verify
opencode config validateLast updated: 2026-05-30 Version: 2025.1