@caplets/opencode 0.2.0 → 0.3.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -21,15 +21,16 @@ tools still requires restarting OpenCode; newly added tools are not advertised u
21
21
  By default the plugin reads local Caplets config. To use a remote `caplets serve --transport http` service, set environment variables:
22
22
 
23
23
  ```sh
24
- CAPLETS_REMOTE_URL=http://127.0.0.1:5387/mcp opencode
24
+ CAPLETS_MODE=remote CAPLETS_SERVER_URL=http://127.0.0.1:5387/caplets opencode
25
25
  ```
26
26
 
27
27
  For authenticated remote services, keep the password in the environment:
28
28
 
29
29
  ```sh
30
- CAPLETS_REMOTE_URL=https://caplets.example.com/mcp \
31
- CAPLETS_REMOTE_USER=caplets \
32
- CAPLETS_REMOTE_PASSWORD=... \
30
+ CAPLETS_MODE=remote \
31
+ CAPLETS_SERVER_URL=https://caplets.example.com/caplets \
32
+ CAPLETS_SERVER_USER=caplets \
33
+ CAPLETS_SERVER_PASSWORD=... \
33
34
  opencode
34
35
  ```
35
36
 
@@ -42,14 +43,17 @@ export default {
42
43
  "@caplets/opencode",
43
44
  {
44
45
  mode: "remote",
45
- remote: {
46
- url: "https://caplets.example.com/mcp",
46
+ server: {
47
+ url: "https://caplets.example.com/caplets",
47
48
  user: "caplets",
48
49
  },
50
+ remote: {
51
+ pollIntervalMs: 5_000,
52
+ },
49
53
  },
50
54
  ],
51
55
  ],
52
56
  };
53
57
  ```
54
58
 
55
- Plugin config overrides environment variables. Prefer `CAPLETS_REMOTE_PASSWORD` for the Basic Auth password unless your OpenCode setup provides secure secret storage.
59
+ Plugin config overrides environment variables. The explicit config shape is `{ mode, server: { url, user }, remote: { pollIntervalMs } }`. Prefer `CAPLETS_SERVER_PASSWORD` for the Basic Auth password unless your OpenCode setup provides secure secret storage.
package/dist/index.js CHANGED
@@ -56,6 +56,7 @@ function normalizeOpenCodeConfig(config) {
56
56
  if (!config) return {};
57
57
  return {
58
58
  ...config.mode ? { mode: config.mode } : {},
59
+ ...config.server ? { server: config.server } : {},
59
60
  ...config.remote ? { remote: config.remote } : {}
60
61
  };
61
62
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@caplets/opencode",
3
- "version": "0.2.0",
3
+ "version": "0.3.0",
4
4
  "description": "Native OpenCode plugin for Caplets.",
5
5
  "homepage": "https://github.com/spiritledsoftware/caplets#readme",
6
6
  "bugs": {
@@ -26,7 +26,7 @@
26
26
  "access": "public"
27
27
  },
28
28
  "dependencies": {
29
- "@caplets/core": "0.16.0"
29
+ "@caplets/core": "0.17.0"
30
30
  },
31
31
  "devDependencies": {
32
32
  "@types/node": "^25.9.0",