Skip to content

Commit b45639a

Browse files
Merge pull request #223 from yousiki/fix/claude-team-plan-detection
fix(quota): detect Claude Team organizations instead of marking Free
2 parents 3212f65 + c43df08 commit b45639a

5 files changed

Lines changed: 15 additions & 4 deletions

File tree

src/components/quota/quotaConfigs.ts

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -974,6 +974,13 @@ const resolveClaudePlanType = (profile: ClaudeProfileResponse | null): string |
974974
const hasClaudePro = normalizeFlagValue(profile.account?.has_claude_pro);
975975
if (hasClaudePro) return 'plan_pro';
976976

977+
const organizationType = normalizeStringValue(profile.organization?.organization_type)?.toLowerCase();
978+
const subscriptionStatus = normalizeStringValue(profile.organization?.subscription_status)?.toLowerCase();
979+
980+
if (organizationType === 'claude_team' && subscriptionStatus === 'active') {
981+
return 'plan_team';
982+
}
983+
977984
if (hasClaudeMax === false && hasClaudePro === false) return 'plan_free';
978985

979986
return null;

src/i18n/locales/en.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -645,7 +645,8 @@
645645
"plan_pro": "Pro",
646646
"plan_max": "Max",
647647
"plan_max5": "Max 5x",
648-
"plan_max20": "Max 20x"
648+
"plan_max20": "Max 20x",
649+
"plan_team": "Team"
649650
},
650651
"codex_quota": {
651652
"title": "Codex Quota",

src/i18n/locales/ru.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -642,7 +642,8 @@
642642
"plan_pro": "Pro",
643643
"plan_max": "Max",
644644
"plan_max5": "Max 5x",
645-
"plan_max20": "Max 20x"
645+
"plan_max20": "Max 20x",
646+
"plan_team": "Team"
646647
},
647648
"codex_quota": {
648649
"title": "Квота Codex",

src/i18n/locales/zh-CN.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -645,7 +645,8 @@
645645
"plan_pro": "专业版",
646646
"plan_max": "Max",
647647
"plan_max5": "Max 5x",
648-
"plan_max20": "Max 20x"
648+
"plan_max20": "Max 20x",
649+
"plan_team": "团队版"
649650
},
650651
"codex_quota": {
651652
"title": "Codex 额度",

src/i18n/locales/zh-TW.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -645,7 +645,8 @@
645645
"plan_pro": "專業版",
646646
"plan_max": "Max",
647647
"plan_max5": "Max 5x",
648-
"plan_max20": "Max 20x"
648+
"plan_max20": "Max 20x",
649+
"plan_team": "團隊版"
649650
},
650651
"codex_quota": {
651652
"title": "Codex 配額",

0 commit comments

Comments
 (0)