pub struct RateLimitInfo {Show 15 fields
pub status: RateLimitStatus,
pub resets_at: Option<u64>,
pub rate_limit_type: Option<RateLimitWindow>,
pub utilization: Option<f64>,
pub overage_status: Option<OverageStatus>,
pub overage_resets_at: Option<u64>,
pub overage_disabled_reason: Option<OverageDisabledReason>,
pub is_using_overage: Option<bool>,
pub overage_in_use: Option<bool>,
pub surpassed_threshold: Option<f64>,
pub overage_period_monthly: Option<OveragePeriodUtilization>,
pub overage_period_channel: Option<OveragePeriodUtilization>,
pub error_code: Option<RateLimitErrorCode>,
pub can_user_purchase_credits: Option<bool>,
pub has_chargeable_saved_payment_method: Option<bool>,
}Expand description
Rate limit status information.
Fields§
§status: RateLimitStatusCurrent rate limit status
resets_at: Option<u64>Unix timestamp when the rate limit resets
rate_limit_type: Option<RateLimitWindow>Type of rate limit window
utilization: Option<f64>Utilization of the rate limit (0.0 to 1.0)
overage_status: Option<OverageStatus>Overage status (e.g., rejected, allowed)
overage_resets_at: Option<u64>Unix timestamp when the overage window resets
overage_disabled_reason: Option<OverageDisabledReason>Reason overage is disabled, if applicable
is_using_overage: Option<bool>Whether overage billing is active for the current request
overage_in_use: Option<bool>Whether overage billing is in use for the account
surpassed_threshold: Option<f64>Utilization warning threshold that was crossed (0.0 to 1.0)
overage_period_monthly: Option<OveragePeriodUtilization>Monthly service spend-cap utilization (Claude-in-Slack surface)
overage_period_channel: Option<OveragePeriodUtilization>Per-channel spend-cap utilization (Claude-in-Slack surface)
error_code: Option<RateLimitErrorCode>Error code attached when a request was refused outright
can_user_purchase_credits: Option<bool>Whether the user is able to purchase credits themselves
has_chargeable_saved_payment_method: Option<bool>Whether the account has a chargeable saved payment method
Trait Implementations§
Source§impl Clone for RateLimitInfo
impl Clone for RateLimitInfo
Source§fn clone(&self) -> RateLimitInfo
fn clone(&self) -> RateLimitInfo
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for RateLimitInfo
impl Debug for RateLimitInfo
Source§impl<'de> Deserialize<'de> for RateLimitInfo
impl<'de> Deserialize<'de> for RateLimitInfo
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for RateLimitInfo
impl RefUnwindSafe for RateLimitInfo
impl Send for RateLimitInfo
impl Sync for RateLimitInfo
impl Unpin for RateLimitInfo
impl UnsafeUnpin for RateLimitInfo
impl UnwindSafe for RateLimitInfo
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more