summaryrefslogtreecommitdiffhomepage
path: root/packages
diff options
context:
space:
mode:
authorSaatvik Arya <[email protected]>2025-06-21 02:57:58 +0530
committerGitHub <[email protected]>2025-06-20 17:27:58 -0400
commit53c18a64b48e715d65491392a013769d69ab0295 (patch)
tree381d12fe3f347c83d4cf7b98da0f55f3099cf91c /packages
parentb8144c56540fe0e138ba63a1f55497063eefec63 (diff)
downloadopencode-53c18a64b48e715d65491392a013769d69ab0295.tar.gz
opencode-53c18a64b48e715d65491392a013769d69ab0295.zip
docs: add API client generation instructions to README and AGENTS.md (#273)
Diffstat (limited to 'packages')
-rw-r--r--packages/opencode/AGENTS.md2
1 files changed, 2 insertions, 0 deletions
diff --git a/packages/opencode/AGENTS.md b/packages/opencode/AGENTS.md
index e899c689a..a24ccd7d5 100644
--- a/packages/opencode/AGENTS.md
+++ b/packages/opencode/AGENTS.md
@@ -7,6 +7,7 @@
- **Typecheck**: `bun run typecheck` (npm run typecheck)
- **Test**: `bun test` (runs all tests)
- **Single test**: `bun test test/tool/tool.test.ts` (specific test file)
+- **API Client Generation**: `cd packages/tui && go generate ./pkg/client/` (after changes to server endpoints)
## Code Style
@@ -37,3 +38,4 @@
- **Validation**: All inputs validated with Zod schemas
- **Logging**: Use `Log.create({ service: "name" })` pattern
- **Storage**: Use `Storage` namespace for persistence
+- **API Client**: Go TUI communicates with TypeScript server via generated client. When adding/modifying server endpoints in `packages/opencode/src/server/server.ts`, run `cd packages/tui && go generate ./pkg/client/` to update the Go client code and OpenAPI spec.