Background
OpenCode supports custom tools defined in .opencode/tools/ (see Custom Tools Docs). Tools are TypeScript/JavaScript definitions that can invoke scripts in any language.
Goal
Extend the V2 bundle manifest to optionally declare custom tools that should be installed alongside a preset.
Contract Ownership
This feature requires changes to the bundle contract defined in sven1103-agent/opencode-agents. See docs/bundle-contract.md for the current contract specification.
Proposed Manifest Extension
Add optional tools field to opencode-bundle.manifest.json:
{
"manifest_version": 1,
"bundle_name": "qbic-opencode-config-bundle",
"bundle_version": "v1.1.0",
"presets": [...],
"tools": [
{
"name": "database",
"entrypoint": ".opencode/tools/database.ts",
"description": "Query the project database"
}
]
}
Implementation Steps
- Update CLI manifest schema validation to accept optional
tools field (in opencode-agents)
- Update
bundle apply to copy tool definitions to .opencode/tools/ in target project (in opencode-agents)
- Update bundle manifest to v1.1.0 when tools are added (in opencode-config-bundle)
Dependencies
- CLI changes in sven1103-agent/opencode-agents
- Bundle manifest v1.1.0 (forward-compatible with v1.0.0 CLIs)
Labels
Background
OpenCode supports custom tools defined in
.opencode/tools/(see Custom Tools Docs). Tools are TypeScript/JavaScript definitions that can invoke scripts in any language.Goal
Extend the V2 bundle manifest to optionally declare custom tools that should be installed alongside a preset.
Contract Ownership
This feature requires changes to the bundle contract defined in sven1103-agent/opencode-agents. See
docs/bundle-contract.mdfor the current contract specification.Proposed Manifest Extension
Add optional
toolsfield toopencode-bundle.manifest.json:{ "manifest_version": 1, "bundle_name": "qbic-opencode-config-bundle", "bundle_version": "v1.1.0", "presets": [...], "tools": [ { "name": "database", "entrypoint": ".opencode/tools/database.ts", "description": "Query the project database" } ] }Implementation Steps
toolsfield (in opencode-agents)bundle applyto copy tool definitions to.opencode/tools/in target project (in opencode-agents)Dependencies
Labels