Skip to content

Commit fb529c7

Browse files
committed
docs: add US-EXT-001 for custom tools support
1 parent aba5d7b commit fb529c7

1 file changed

Lines changed: 89 additions & 0 deletions

File tree

docs/user-stories.md

Lines changed: 89 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,89 @@
1+
# User Stories - Future Enhancements
2+
3+
---
4+
5+
## US-EXT-001 - Support Custom Tools in Configuration Bundles
6+
7+
**Status**: Backlog
8+
**Priority**: Medium
9+
**Milestone**: v1.1.0 - Custom Tool Support
10+
11+
### Background
12+
13+
OpenCode supports custom tools defined in `.opencode/tools/` (see [Custom Tools Docs](https://opencode.ai/docs/custom-tools)). Tools are TypeScript/JavaScript definitions that can invoke scripts in any language.
14+
15+
### User Story
16+
17+
**As a**: bundle maintainer
18+
**I want to**: include custom tools with my configuration presets
19+
**So that**: agents can use specialized tooling beyond OpenCode's built-in tools
20+
21+
### Acceptance Criteria
22+
23+
1. Bundle manifest can optionally declare custom tools via a `tools` field
24+
2. Tool definitions are installed to `.opencode/tools/` in the target project
25+
3. Bundle manifest v1.1.0 is backward-compatible with v1.0.0 CLIs
26+
4. Documentation explains tool installation flow
27+
28+
### Proposed Manifest Extension
29+
30+
```json
31+
{
32+
"manifest_version": 1,
33+
"bundle_name": "qbic-opencode-config-bundle",
34+
"bundle_version": "v1.1.0",
35+
"presets": [...],
36+
"tools": [
37+
{
38+
"name": "database",
39+
"entrypoint": ".opencode/tools/database.ts",
40+
"description": "Query the project database"
41+
}
42+
]
43+
}
44+
```
45+
46+
### Implementation Dependencies
47+
48+
- CLI: Update manifest schema validation to accept optional `tools` field
49+
- CLI: Update `bundle apply` to copy tool definitions to `.opencode/tools/`
50+
- Bundle: Update manifest version to v1.1.0 when tools are added
51+
- Docs: Document tool installation flow
52+
53+
### Notes
54+
55+
- Tools are independent of agent prompts - prompts reference tools by name
56+
- Multiple tools can be defined in a single file or spread across files
57+
- Tool runtime can be Node.js, Python, or any system executable
58+
59+
---
60+
61+
## Future Extension Ideas
62+
63+
### Tool Runtime Dependencies
64+
65+
Future iterations could include dependency management for tools:
66+
67+
```json
68+
{
69+
"tools": [
70+
{
71+
"name": "database",
72+
"entrypoint": ".opencode/tools/database.ts",
73+
"runtime": "node",
74+
"dependencies": ["pg", "dotenv"]
75+
}
76+
]
77+
}
78+
```
79+
80+
### Global vs Project Tools
81+
82+
Future iterations could distinguish between:
83+
84+
- **Project tools**: Installed per-project in `.opencode/tools/`
85+
- **Global tools**: Installed in `~/.config/opencode/tools/`
86+
87+
---
88+
89+
*Last updated: 2026-03-30*

0 commit comments

Comments
 (0)