pub struct X402McpError {
pub code: i64,
pub data: Map<String, Value>,
pub message: String,
}Expand description
JSON-RPC 2.0 error object.
JSON schema
{
"description": "JSON-RPC 2.0 error object.",
"examples": [
{
"code": -32600,
"data": {},
"message": "Invalid Request"
}
],
"type": "object",
"required": [
"code",
"message"
],
"properties": {
"code": {
"description": "Error code.",
"examples": [
-32600
],
"type": "integer"
},
"data": {
"description": "Additional error data.",
"examples": [
{}
],
"type": "object",
"additionalProperties": true
},
"message": {
"description": "Error message.",
"examples": [
"Invalid Request"
],
"type": "string"
}
}
}Fields§
§code: i64Error code.
data: Map<String, Value>Additional error data.
message: StringError message.
Implementations§
Source§impl X402McpError
impl X402McpError
pub fn builder() -> X402McpError
Trait Implementations§
Source§impl Clone for X402McpError
impl Clone for X402McpError
Source§fn clone(&self) -> X402McpError
fn clone(&self) -> X402McpError
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 X402McpError
impl Debug for X402McpError
Source§impl<'de> Deserialize<'de> for X402McpError
impl<'de> Deserialize<'de> for X402McpError
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<&X402McpError> for X402McpError
impl From<&X402McpError> for X402McpError
Source§fn from(value: &X402McpError) -> Self
fn from(value: &X402McpError) -> Self
Converts to this type from the input type.
Source§impl From<X402McpError> for X402McpError
impl From<X402McpError> for X402McpError
Source§fn from(value: X402McpError) -> Self
fn from(value: X402McpError) -> Self
Converts to this type from the input type.
Source§impl Serialize for X402McpError
impl Serialize for X402McpError
Source§impl TryFrom<X402McpError> for X402McpError
impl TryFrom<X402McpError> for X402McpError
Source§type Error = ConversionError
type Error = ConversionError
The type returned in the event of a conversion error.
Source§fn try_from(value: X402McpError) -> Result<Self, ConversionError>
fn try_from(value: X402McpError) -> Result<Self, ConversionError>
Performs the conversion.
Auto Trait Implementations§
impl Freeze for X402McpError
impl RefUnwindSafe for X402McpError
impl Send for X402McpError
impl Sync for X402McpError
impl Unpin for X402McpError
impl UnsafeUnpin for X402McpError
impl UnwindSafe for X402McpError
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