pub struct ApiErrorPayload {
pub model: String,
pub error_kind: String,
pub http_status: Option<u16>,
pub error_message: String,
pub latency_ms: u64,
}Expand description
A model call that failed: the provider refused it, or its stream broke before the reply was complete. Emitted once per failed attempt, whether or not the turn then recovers.
Fields§
§model: String§error_kind: Stringapi, auth, rate_limited, overloaded, network, internal,
unsupported.
http_status: Option<u16>The HTTP status, for an api error.
error_message: String§latency_ms: u64Trait Implementations§
Source§impl Clone for ApiErrorPayload
impl Clone for ApiErrorPayload
Source§fn clone(&self) -> ApiErrorPayload
fn clone(&self) -> ApiErrorPayload
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 ApiErrorPayload
impl Debug for ApiErrorPayload
Source§impl JsonSchema for ApiErrorPayload
impl JsonSchema for ApiErrorPayload
Source§fn schema_id() -> Cow<'static, str>
fn schema_id() -> Cow<'static, str>
Returns a string that uniquely identifies the schema produced by this type. Read more
Source§fn json_schema(generator: &mut SchemaGenerator) -> Schema
fn json_schema(generator: &mut SchemaGenerator) -> Schema
Generates a JSON Schema for this type. Read more
Source§fn inline_schema() -> bool
fn inline_schema() -> bool
Whether JSON Schemas generated for this type should be included directly in parent schemas,
rather than being re-used where possible using the
$ref keyword. Read moreSource§impl Redact for ApiErrorPayload
impl Redact for ApiErrorPayload
fn redact(self, policy: &RedactionPolicy) -> Self
Source§impl Serialize for ApiErrorPayload
impl Serialize for ApiErrorPayload
Source§fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
Serialize this value into the given Serde serializer. Read more
Auto Trait Implementations§
impl Forget for ApiErrorPayload
impl Freeze for ApiErrorPayload
impl Move for ApiErrorPayload
impl RefUnwindSafe for ApiErrorPayload
impl Send for ApiErrorPayloadwhere
RawVecInner: Send,
impl Sync for ApiErrorPayloadwhere
RawVecInner: Sync,
impl Unpin for ApiErrorPayload
impl UnsafeUnpin for ApiErrorPayload
impl UnwindSafe for ApiErrorPayloadwhere
RawVecInner: UnwindSafe,
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