mirror of
https://github.com/openai/codex.git
synced 2026-11-13 14:46:14 +00:00
Support prolite plan type (#17419)
Addresses #17353 Problem: Codex rate-limit fetching failed when the backend returned the new `prolite` subscription plan type. Solution: Add `prolite` to the backend/account/auth plan mappings, keep unknown WHAM plan values decodable, and regenerate app-server plan schemas.
This commit is contained in:
1 parent
163ae7d3e6
commit
3b948d9dd8
17 files changed
+40
-4
No files matched your search
@@ -12,6 +12,7 @@ pub enum PlanType {
|
||||
Go,
|
||||
Plus,
|
||||
Pro,
|
||||
ProLite,
|
||||
Team,
|
||||
#[serde(rename = "self_serve_business_usage_based")]
|
||||
#[ts(rename = "self_serve_business_usage_based")]
|
||||
@@ -53,11 +54,19 @@ mod tests {
|
||||
.expect("enterprise cbp usage based should serialize"),
|
||||
"\"enterprise_cbp_usage_based\""
|
||||
);
|
||||
assert_eq!(
|
||||
serde_json::to_string(&PlanType::ProLite).expect("prolite should serialize"),
|
||||
"\"prolite\""
|
||||
);
|
||||
assert_eq!(
|
||||
serde_json::from_str::<PlanType>("\"self_serve_business_usage_based\"")
|
||||
.expect("self-serve business usage based should deserialize"),
|
||||
PlanType::SelfServeBusinessUsageBased
|
||||
);
|
||||
assert_eq!(
|
||||
serde_json::from_str::<PlanType>("\"prolite\"").expect("prolite should deserialize"),
|
||||
PlanType::ProLite
|
||||
);
|
||||
assert_eq!(
|
||||
serde_json::from_str::<PlanType>("\"enterprise_cbp_usage_based\"")
|
||||
.expect("enterprise cbp usage based should deserialize"),
|
||||
|
||||
Reference in new issue
Block a user