#[non_exhaustive]pub struct ResponseValidationError {
pub status: u16,
pub field_path: String,
pub detail: String,
pub body: Option<Value>,
pub headers: HeaderMap,
pub endpoint: Option<String>,
}Expand description
A successful response whose body is missing or has structurally invalid required data.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.status: u16HTTP status code (2xx).
field_path: StringDotted path to the offending field, e.g. answers.tone.confidence.
detail: StringUnderlying decoder message.
body: Option<Value>The decoded body (or raw text), if any.
headers: HeaderMapResponse headers.
endpoint: Option<String>"METHOD url" without credentials, query or fragment.
Trait Implementations§
Source§impl Clone for ResponseValidationError
impl Clone for ResponseValidationError
Source§fn clone(&self) -> ResponseValidationError
fn clone(&self) -> ResponseValidationError
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 ResponseValidationError
impl Debug for ResponseValidationError
Source§impl Display for ResponseValidationError
impl Display for ResponseValidationError
Source§impl Error for ResponseValidationError
impl Error for ResponseValidationError
1.30.0 · Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
Returns the lower-level source of this error, if any. Read more
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0:
use the Display impl or to_string()
Auto Trait Implementations§
impl Freeze for ResponseValidationError
impl RefUnwindSafe for ResponseValidationError
impl Send for ResponseValidationError
impl Sync for ResponseValidationError
impl Unpin for ResponseValidationError
impl UnsafeUnpin for ResponseValidationError
impl UnwindSafe for ResponseValidationError
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