opencode-aicodewith-auth 0.1.11 → 0.1.12

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/dist/index.js CHANGED
@@ -68,7 +68,7 @@ var PLUGIN_NAME = "opencode-aicodewith-auth";
68
68
  var PROVIDER_ID = "aicodewith";
69
69
  var AUTH_METHOD_LABEL = "AICodewith API Key";
70
70
  var CODEX_BASE_URL = "https://api.aicodewith.com/chatgpt/v1";
71
- var AICODEWITH_ANTHROPIC_BASE_URL = "https://api.aicodewith.com";
71
+ var AICODEWITH_ANTHROPIC_BASE_URL = "https://api.aicodewith.com/v1";
72
72
  var AICODEWITH_GEMINI_BASE_URL = "https://api.aicodewith.com/gemini_cli";
73
73
  var GEMINI_USER_AGENT = "GeminiCLI/v25.2.1 (darwin; arm64)";
74
74
  var GEMINI_API_CLIENT = "google-genai-sdk/1.30.0 gl-node/v25.2.1";
@@ -853,7 +853,6 @@ async function transformRequestBody(body, codexInstructions) {
853
853
  hasTools: !!body.tools
854
854
  });
855
855
  body.model = normalizedModel;
856
- body.store = false;
857
856
  body.stream = true;
858
857
  body.instructions = codexInstructions;
859
858
  if (body.input && Array.isArray(body.input)) {
@@ -1675,7 +1674,11 @@ var rewriteUrl = (originalUrl, baseUrl) => {
1675
1674
  const rewritten = new URL(original.toString());
1676
1675
  rewritten.protocol = base.protocol;
1677
1676
  rewritten.host = base.host;
1678
- rewritten.pathname = `${basePath}${original.pathname}`;
1677
+ let targetPath = original.pathname;
1678
+ if (basePath.endsWith("/v1") && targetPath.startsWith("/v1/")) {
1679
+ targetPath = targetPath.slice(3);
1680
+ }
1681
+ rewritten.pathname = `${basePath}${targetPath}`;
1679
1682
  return rewritten.toString();
1680
1683
  };
1681
1684
  var ensureGeminiSseParam = (url) => {
@@ -10,7 +10,7 @@ export declare const PLUGIN_NAME = "opencode-aicodewith-auth";
10
10
  export declare const PROVIDER_ID = "aicodewith";
11
11
  export declare const AUTH_METHOD_LABEL = "AICodewith API Key";
12
12
  export declare const CODEX_BASE_URL = "https://api.aicodewith.com/chatgpt/v1";
13
- export declare const AICODEWITH_ANTHROPIC_BASE_URL = "https://api.aicodewith.com";
13
+ export declare const AICODEWITH_ANTHROPIC_BASE_URL = "https://api.aicodewith.com/v1";
14
14
  export declare const AICODEWITH_GEMINI_BASE_URL = "https://api.aicodewith.com/gemini_cli";
15
15
  export declare const GEMINI_USER_AGENT = "GeminiCLI/v25.2.1 (darwin; arm64)";
16
16
  export declare const GEMINI_API_CLIENT = "google-genai-sdk/1.30.0 gl-node/v25.2.1";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "opencode-aicodewith-auth",
3
- "version": "0.1.11",
3
+ "version": "0.1.12",
4
4
  "description": "OpenCode plugin for AICodewith authentication - Access GPT-5.2, Claude, and Gemini models through AICodewith API",
5
5
  "type": "module",
6
6
  "main": "dist/index.js",