@cortexkit/opencode-openai-auth 0.1.0 → 0.1.1

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
@@ -39,6 +39,7 @@ Settings resolve as environment variable → config file (`~/.config/opencode/op
39
39
  | `rawWebSocket` | `CORTEXKIT_OPENAI_AUTH_RAW_WS` | `false` | Use the hand-rolled raw TCP/TLS client with Codex-style incremental streaming. Bun uses `Bun.connect`; Node/OpenCode Desktop uses `node:net`/`node:tls`. |
40
40
  | `dump` | `CORTEXKIT_OPENAI_AUTH_DUMP` | `false` | Dump final Codex request bodies for cache debugging. |
41
41
  | `dumpDir` | `OPENCODE_OPENAI_AUTH_DUMP_DIR` | OS temp dir: `opencode-openai-auth-dumps` | Directory for request dump files. |
42
+ | `codexApiEndpoint` | `CORTEXKIT_OPENAI_AUTH_CODEX_ENDPOINT` | `https://chatgpt.com/backend-api/codex/responses` | Send rewritten Codex requests to a compatible proxy/relay instead of ChatGPT's backend endpoint. |
42
43
 
43
44
  See the [repository README](https://github.com/cortexkit/openai-auth#readme) for transport differences and why `web_search` is needed.
44
45
 
package/dist/config.d.ts CHANGED
@@ -1,3 +1,4 @@
1
+ export declare const DEFAULT_CODEX_API_ENDPOINT = "https://chatgpt.com/backend-api/codex/responses";
1
2
  /** Shape of ~/.config/opencode/openai-auth.json (all fields optional). */
2
3
  export interface OpenAIAuthConfig {
3
4
  /** Inject the native web_search tool to keep the Codex prompt cache stable. Default true. */
@@ -10,6 +11,8 @@ export interface OpenAIAuthConfig {
10
11
  dump?: boolean;
11
12
  /** Directory for request dumps. Defaults to the OS temp directory. */
12
13
  dumpDir?: string;
14
+ /** Codex-compatible Responses endpoint. Defaults to ChatGPT's Codex backend. */
15
+ codexApiEndpoint?: string;
13
16
  }
14
17
  export interface ResolvedSettings {
15
18
  webSearch: boolean;
@@ -17,6 +20,7 @@ export interface ResolvedSettings {
17
20
  rawWebSocket: boolean;
18
21
  dump: boolean;
19
22
  dumpDir: string;
23
+ codexApiEndpoint: string;
20
24
  }
21
25
  export declare function getConfigDir(): string;
22
26
  export declare function getConfigPath(): string;