mirror of
https://github.com/openai/codex.git
synced 2026-04-24 22:54:54 +00:00
move rate limits updated notification to v2
This commit is contained in:
@@ -9,7 +9,6 @@ use crate::protocol::v2;
|
||||
use codex_protocol::ConversationId;
|
||||
use codex_protocol::parse_command::ParsedCommand;
|
||||
use codex_protocol::protocol::FileChange;
|
||||
use codex_protocol::protocol::RateLimitSnapshot;
|
||||
use codex_protocol::protocol::ReviewDecision;
|
||||
use codex_protocol::protocol::SandboxCommandAssessment;
|
||||
use paste::paste;
|
||||
@@ -439,7 +438,7 @@ pub enum ServerNotification {
|
||||
#[serde(rename = "account/rateLimits/updated")]
|
||||
#[ts(rename = "account/rateLimits/updated")]
|
||||
#[strum(serialize = "account/rateLimits/updated")]
|
||||
AccountRateLimitsUpdated(RateLimitSnapshot),
|
||||
AccountRateLimitsUpdated(v2::AccountRateLimitsUpdatedNotification),
|
||||
|
||||
/// DEPRECATED NOTIFICATIONS below
|
||||
/// Authentication status changed
|
||||
|
||||
@@ -429,3 +429,13 @@ pub struct TodoItem {
|
||||
pub text: String,
|
||||
pub completed: bool,
|
||||
}
|
||||
|
||||
// === Server Notifications ===
|
||||
#[derive(Serialize, Deserialize, Debug, Clone, PartialEq, JsonSchema, TS)]
|
||||
#[serde(rename_all = "camelCase")]
|
||||
#[ts(export_to = "v2/")]
|
||||
pub struct AccountRateLimitsUpdatedNotification {
|
||||
// TODO: create our own RateLimitSnapshot type that doesn't depend on codex_protocol
|
||||
// so we can camelcase that bad boy.
|
||||
pub rate_limits: RateLimitSnapshot,
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user