pub struct PaymentError {
pub code: Option<String>,
pub message: Option<String>,
pub occurred_at: Option<DateTime<Utc>>,
}Expand description
An error that occurred during a payment operation.
JSON schema
{
"description": "An error that occurred during a payment operation.",
"examples": [
{
"code": "insufficient_funds",
"message": "The payer does not have sufficient funds.",
"occurredAt": "2025-06-15T12:00:00.000Z"
}
],
"type": "object",
"properties": {
"code": {
"description": "A machine-readable error code.",
"examples": [
"insufficient_funds"
],
"type": "string"
},
"message": {
"description": "A human-readable description of the error.",
"examples": [
"The payer does not have sufficient funds."
],
"type": "string"
},
"occurredAt": {
"description": "The UTC ISO 8601 timestamp at which the error occurred.",
"examples": [
"2025-06-15T12:00:00.000Z"
],
"type": "string",
"format": "date-time"
}
}
}Fields§
§code: Option<String>A machine-readable error code.
message: Option<String>A human-readable description of the error.
occurred_at: Option<DateTime<Utc>>The UTC ISO 8601 timestamp at which the error occurred.
Implementations§
Source§impl PaymentError
impl PaymentError
pub fn builder() -> PaymentError
Trait Implementations§
Source§impl Clone for PaymentError
impl Clone for PaymentError
Source§impl Debug for PaymentError
impl Debug for PaymentError
Source§impl Default for PaymentError
impl Default for PaymentError
Source§impl<'de> Deserialize<'de> for PaymentError
impl<'de> Deserialize<'de> for PaymentError
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
Source§impl From<&PaymentError> for PaymentError
impl From<&PaymentError> for PaymentError
Source§fn from(value: &PaymentError) -> Self
fn from(value: &PaymentError) -> Self
Converts to this type from the input type.
Source§impl From<PaymentError> for PaymentError
impl From<PaymentError> for PaymentError
Source§fn from(value: PaymentError) -> Self
fn from(value: PaymentError) -> Self
Converts to this type from the input type.
Source§impl Serialize for PaymentError
impl Serialize for PaymentError
Source§impl TryFrom<PaymentError> for PaymentError
impl TryFrom<PaymentError> for PaymentError
Source§type Error = ConversionError
type Error = ConversionError
The type returned in the event of a conversion error.
Source§fn try_from(value: PaymentError) -> Result<Self, ConversionError>
fn try_from(value: PaymentError) -> Result<Self, ConversionError>
Performs the conversion.
Auto Trait Implementations§
impl Freeze for PaymentError
impl RefUnwindSafe for PaymentError
impl Send for PaymentError
impl Sync for PaymentError
impl Unpin for PaymentError
impl UnsafeUnpin for PaymentError
impl UnwindSafe for PaymentError
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