opencode-agy-bridge 0.2.5 → 0.2.6

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
@@ -54,7 +54,7 @@ Add the plugin and provider to `~/.config/opencode/opencode.json`.
54
54
  ```jsonc
55
55
  {
56
56
  "plugin": [
57
- "opencode-agy-bridge@0.2.5"
57
+ "opencode-agy-bridge@0.2.6"
58
58
  ],
59
59
  "provider": {
60
60
  "agy": {
@@ -0,0 +1 @@
1
+ export default function unified(input?: any): any;
package/dist/index.js ADDED
@@ -0,0 +1,16 @@
1
+ import { createAgyProvider } from "./provider.js";
2
+ export default function unified(input) {
3
+ if (input && typeof input === "object" && "client" in input) {
4
+ return {
5
+ config: async () => { },
6
+ "chat.headers": async (incoming, output) => {
7
+ if (incoming?.model?.providerID !== "agy")
8
+ return;
9
+ if (!output?.headers)
10
+ return;
11
+ output.headers["x-agy-session-id"] = incoming.sessionID;
12
+ },
13
+ };
14
+ }
15
+ return createAgyProvider(input);
16
+ }
package/package.json CHANGED
@@ -1,12 +1,12 @@
1
1
  {
2
2
  "name": "opencode-agy-bridge",
3
- "version": "0.2.5",
3
+ "version": "0.2.6",
4
4
  "type": "module",
5
- "main": "./dist/provider.js",
5
+ "main": "./dist/index.js",
6
6
  "license": "MIT",
7
7
  "description": "OpenCode plugin + provider that routes LLM prompts to agy (Google Antigravity CLI)",
8
8
  "exports": {
9
- ".": "./dist/provider.js",
9
+ ".": "./dist/index.js",
10
10
  "./provider": "./dist/provider.js",
11
11
  "./plugin": "./dist/plugin.js"
12
12
  },
package/plugin.js CHANGED
@@ -1,2 +1 @@
1
- export { default } from "./dist/plugin.js";
2
- export * from "./dist/plugin.js";
1
+ export { default } from "./dist/index.js";
package/provider.js CHANGED
@@ -1,2 +1 @@
1
- export { default } from "./dist/provider.js";
2
- export * from "./dist/provider.js";
1
+ export { default } from "./dist/index.js";