@khanglvm/llm-router 1.2.0 → 1.3.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/CHANGELOG.md CHANGED
@@ -5,6 +5,37 @@ All notable changes to this project will be documented in this file.
5
5
  The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
6
6
  and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
7
7
 
8
+ ## [1.3.1] - 2026-03-05
9
+
10
+ ### Changed
11
+ - Upgraded `@levu/snap` dependency to `^0.3.13`:
12
+ - TUI `Esc` now defaults to stepping back to previous workflow step.
13
+ - On root step, `Esc` still exits.
14
+ - Added compliance warning in interactive provider setup: using provider resources through `llm-router` may violate provider terms; users are solely responsible for compliance.
15
+
16
+ ## [1.3.0] - 2026-03-05
17
+
18
+ ### Added
19
+ - Added Claude Code OAuth subscription provider support end-to-end:
20
+ - new subscription type: `claude-code`
21
+ - Claude OAuth constants and runtime request config (`anthropic-beta`, OAuth token endpoint, Claude messages endpoint)
22
+ - default Claude subscription model seed list for new subscription providers
23
+ - Added CLI support for Claude subscription auth operations:
24
+ - `llm-router subscription login --subscription-type=claude-code`
25
+ - `llm-router subscription logout --subscription-type=claude-code`
26
+ - `llm-router subscription status --subscription-type=claude-code`
27
+ - Added runtime and CLI test coverage for Claude subscription request translation/headers and setup flows.
28
+
29
+ ### Changed
30
+ - Updated subscription probe and provider upsert flow to build type-specific probe payloads:
31
+ - ChatGPT Codex keeps Responses/Codex probe shape
32
+ - Claude Code uses Claude messages probe shape
33
+ - Updated subscription config normalization/workflows so default format and model seed list are selected by `subscriptionType`.
34
+ - Updated README and CLI help text/examples to document both supported OAuth subscription types (`chatgpt-codex`, `claude-code`).
35
+
36
+ ### Fixed
37
+ - Fixed new Claude subscription provider creation default model seeding to correctly use Claude defaults instead of ChatGPT defaults.
38
+
8
39
  ## [1.2.0] - 2026-03-04
9
40
 
10
41
  ### Added
package/README.md CHANGED
@@ -81,28 +81,40 @@ Flow:
81
81
  - `API Key` -> endpoint + API key + model list
82
82
  - `OAuth` -> browser OAuth + editable model list
83
83
  4. For `OAuth`:
84
- - Choose subscription provider (`ChatGPT` for now)
84
+ - Choose subscription provider (`ChatGPT` or `Claude Code`)
85
85
  - Enter Friendly Name and Provider ID
86
86
  - Complete browser OAuth login inside this same flow
87
87
  - Edit model list (pre-filled defaults; you can add/remove)
88
88
  - llm-router live-tests every selected model before save
89
89
  5. Save
90
90
 
91
- ### 1b) Add Subscription Provider (ChatGPT Codex)
92
- Commandline example:
91
+ ### 1b) Add Subscription Provider (OAuth)
92
+ Commandline examples:
93
93
 
94
94
  ```bash
95
+ # ChatGPT Codex subscription
95
96
  llm-router config \
96
97
  --operation=upsert-provider \
97
98
  --provider-id=chatgpt \
98
99
  --name="GPT Sub" \
99
100
  --type=subscription
101
+
102
+ # Claude Code subscription
103
+ llm-router config \
104
+ --operation=upsert-provider \
105
+ --provider-id=claude-sub \
106
+ --name="Claude Sub" \
107
+ --type=subscription \
108
+ --subscription-type=claude-code
100
109
  ```
101
110
 
102
111
  Notes:
103
112
  - OAuth login is run during provider upsert (browser flow by default).
104
- - `chatgpt-codex` is the current subscription type and its default model list is prefilled, but editable.
113
+ - Supported `subscription-type`: `chatgpt-codex` and `claude-code` (defaults to `chatgpt-codex`).
114
+ - Default model lists are prefilled by subscription type, then editable.
115
+ - Device-code login is available for `chatgpt-codex` only.
105
116
  - No provider API key or endpoint probe input is required for subscription mode.
117
+ - Compliance notice: provider account/resource usage via `llm-router` may violate a provider's terms. You are solely responsible for compliance; `llm-router` maintainers take no responsibility for misuse.
106
118
 
107
119
  ### 2) Configure Model Fallback (Optional)
108
120
  Flow:
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@khanglvm/llm-router",
3
- "version": "1.2.0",
3
+ "version": "1.3.1",
4
4
  "description": "Single gateway endpoint for multi-provider LLMs with unified OpenAI+Anthropic format and seamless fallback",
5
5
  "keywords": [
6
6
  "llm-router",
@@ -30,7 +30,7 @@
30
30
  "test:provider-smoke": "node ./scripts/provider-smoke-suite.mjs"
31
31
  },
32
32
  "dependencies": {
33
- "@levu/snap": "^0.3.12"
33
+ "@levu/snap": "^0.3.13"
34
34
  },
35
35
  "devDependencies": {
36
36
  "wrangler": "^4.68.1"