pub struct ErrorBody {
pub code: ErrorCode,
pub message: String,
pub retryable: bool,
pub details: BTreeMap<String, Value>,
pub fields: BTreeMap<String, String>,
pub request_id: Option<String>,
}Expand description
The error object of one item in a batch result (crate::BatchOrderResult,
crate::CancelBatchResult), as the server sent it. A whole response’s error is an
ApiError instead.
Fields§
§code: ErrorCodeMachine-readable code. Branch on it, never on the message.
message: StringHuman-readable; may change between releases.
retryable: boolWhether an identical retry could succeed.
details: BTreeMap<String, Value>Structured context: for ALREADY_EXISTS, the order_id and status of the order that
took the client_order_id.
fields: BTreeMap<String, String>Per-field validation messages.
request_id: Option<String>Quote it in support requests.
Implementations§
Trait Implementations§
Source§impl<'de> Deserialize<'de> for ErrorBody
impl<'de> Deserialize<'de> for ErrorBody
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
impl StructuralPartialEq for ErrorBody
Auto Trait Implementations§
impl Freeze for ErrorBody
impl RefUnwindSafe for ErrorBody
impl Send for ErrorBody
impl Sync for ErrorBody
impl Unpin for ErrorBody
impl UnsafeUnpin for ErrorBody
impl UnwindSafe for ErrorBody
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