pub struct RequestQuoteResponseDataResult {
pub expires: DateTime<Utc>,
pub quote_id: String,
pub quoted_receive: Option<RequestQuoteResponseDataResultQuotedReceive>,
pub quoted_spend: Option<RequestQuoteResponseDataResultQuotedSpend>,
pub quoted_unit_price: Option<RequestQuoteResponseDataResultQuotedUnitPrice>,
pub receive: RequestQuoteResponseDataResultReceive,
pub spend: RequestQuoteResponseDataResultSpend,
pub status: RequestQuoteResponseDataResultStatus,
pub type_: RequestQuoteResponseDataResultType,
pub unit_price: RequestQuoteResponseDataResultUnitPrice,
}Expand description
RequestQuoteResponseDataResult
JSON schema
{
"type": "object",
"required": [
"expires",
"quote_id",
"quoted_receive",
"quoted_spend",
"quoted_unit_price",
"receive",
"spend",
"status",
"type",
"unit_price"
],
"properties": {
"expires": {
"type": "string",
"format": "date-time"
},
"quote_id": {
"type": "string"
},
"quoted_receive": {
"type": [
"object",
"null"
],
"required": [
"asset",
"asset_class",
"fee",
"subtotal",
"total"
],
"properties": {
"asset": {
"type": "string",
"maxLength": 16
},
"asset_class": {
"type": [
"string",
"null"
],
"enum": [
"currency"
]
},
"fee": {
"type": "string",
"maxLength": 64,
"minLength": 1,
"pattern": "^-?[0-9]+(\\.[0-9]+)?$"
},
"subtotal": {
"type": "string",
"maxLength": 64,
"minLength": 1,
"pattern": "^-?[0-9]+(\\.[0-9]+)?$"
},
"total": {
"type": "string",
"maxLength": 64,
"minLength": 1,
"pattern": "^-?[0-9]+(\\.[0-9]+)?$"
}
}
},
"quoted_spend": {
"type": [
"object",
"null"
],
"required": [
"asset",
"asset_class",
"fee",
"subtotal",
"total"
],
"properties": {
"asset": {
"type": "string",
"maxLength": 16
},
"asset_class": {
"type": [
"string",
"null"
],
"enum": [
"currency"
]
},
"fee": {
"type": "string",
"maxLength": 64,
"minLength": 1,
"pattern": "^-?[0-9]+(\\.[0-9]+)?$"
},
"subtotal": {
"type": "string",
"maxLength": 64,
"minLength": 1,
"pattern": "^-?[0-9]+(\\.[0-9]+)?$"
},
"total": {
"type": "string",
"maxLength": 64,
"minLength": 1,
"pattern": "^-?[0-9]+(\\.[0-9]+)?$"
}
}
},
"quoted_unit_price": {
"type": [
"object",
"null"
],
"required": [
"asset",
"asset_class",
"denomination_asset",
"denomination_asset_class",
"unit_price"
],
"properties": {
"asset": {
"type": "string",
"maxLength": 16
},
"asset_class": {
"type": [
"string",
"null"
],
"enum": [
"currency"
]
},
"denomination_asset": {
"type": "string",
"maxLength": 16
},
"denomination_asset_class": {
"type": [
"string",
"null"
],
"enum": [
"currency"
]
},
"unit_price": {
"type": "string",
"maxLength": 64,
"minLength": 1,
"pattern": "^-?[0-9]+(\\.[0-9]+)?$"
}
}
},
"receive": {
"type": "object",
"required": [
"asset",
"asset_class",
"fee",
"subtotal",
"total"
],
"properties": {
"asset": {
"type": "string",
"maxLength": 16
},
"asset_class": {
"type": [
"string",
"null"
],
"enum": [
"currency"
]
},
"fee": {
"type": "string",
"maxLength": 64,
"minLength": 1,
"pattern": "^-?[0-9]+(\\.[0-9]+)?$"
},
"subtotal": {
"type": "string",
"maxLength": 64,
"minLength": 1,
"pattern": "^-?[0-9]+(\\.[0-9]+)?$"
},
"total": {
"type": "string",
"maxLength": 64,
"minLength": 1,
"pattern": "^-?[0-9]+(\\.[0-9]+)?$"
}
}
},
"spend": {
"type": "object",
"required": [
"asset",
"asset_class",
"fee",
"subtotal",
"total"
],
"properties": {
"asset": {
"type": "string",
"maxLength": 16
},
"asset_class": {
"type": [
"string",
"null"
],
"enum": [
"currency"
]
},
"fee": {
"type": "string",
"maxLength": 64,
"minLength": 1,
"pattern": "^-?[0-9]+(\\.[0-9]+)?$"
},
"subtotal": {
"type": "string",
"maxLength": 64,
"minLength": 1,
"pattern": "^-?[0-9]+(\\.[0-9]+)?$"
},
"total": {
"type": "string",
"maxLength": 64,
"minLength": 1,
"pattern": "^-?[0-9]+(\\.[0-9]+)?$"
}
}
},
"status": {
"oneOf": [
{
"type": "string",
"enum": [
"accepted",
"credit_transfer_complete",
"new",
"order_complete",
"quote_cancelled",
"quote_execution_failed"
]
},
{
"type": "object",
"required": [
"unknown"
],
"properties": {
"unknown": {
"type": "string"
}
}
}
]
},
"type": {
"type": "string",
"enum": [
"receive",
"spend"
]
},
"unit_price": {
"type": "object",
"required": [
"asset",
"asset_class",
"denomination_asset",
"denomination_asset_class",
"unit_price"
],
"properties": {
"asset": {
"type": "string",
"maxLength": 16
},
"asset_class": {
"type": [
"string",
"null"
],
"enum": [
"currency"
]
},
"denomination_asset": {
"type": "string",
"maxLength": 16
},
"denomination_asset_class": {
"type": [
"string",
"null"
],
"enum": [
"currency"
]
},
"unit_price": {
"type": "string",
"maxLength": 64,
"minLength": 1,
"pattern": "^-?[0-9]+(\\.[0-9]+)?$"
}
}
}
}
}Fields§
§expires: DateTime<Utc>§quote_id: String§quoted_receive: Option<RequestQuoteResponseDataResultQuotedReceive>§quoted_spend: Option<RequestQuoteResponseDataResultQuotedSpend>§quoted_unit_price: Option<RequestQuoteResponseDataResultQuotedUnitPrice>§receive: RequestQuoteResponseDataResultReceive§spend: RequestQuoteResponseDataResultSpend§status: RequestQuoteResponseDataResultStatus§type_: RequestQuoteResponseDataResultType§unit_price: RequestQuoteResponseDataResultUnitPriceTrait Implementations§
Source§impl Clone for RequestQuoteResponseDataResult
impl Clone for RequestQuoteResponseDataResult
Source§fn clone(&self) -> RequestQuoteResponseDataResult
fn clone(&self) -> RequestQuoteResponseDataResult
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl<'de> Deserialize<'de> for RequestQuoteResponseDataResult
impl<'de> Deserialize<'de> for RequestQuoteResponseDataResult
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<&RequestQuoteResponseDataResult> for RequestQuoteResponseDataResult
impl From<&RequestQuoteResponseDataResult> for RequestQuoteResponseDataResult
Source§fn from(value: &RequestQuoteResponseDataResult) -> Self
fn from(value: &RequestQuoteResponseDataResult) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl Freeze for RequestQuoteResponseDataResult
impl RefUnwindSafe for RequestQuoteResponseDataResult
impl Send for RequestQuoteResponseDataResult
impl Sync for RequestQuoteResponseDataResult
impl Unpin for RequestQuoteResponseDataResult
impl UnwindSafe for RequestQuoteResponseDataResult
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