Struct shippo::Rate [−][src]
pub struct Rate {}Show fields
pub object_id: String, pub object_created: DateTime<Utc>, pub object_owner: String, pub attributes: Vec<String>, pub shipment: String, pub amount: String, pub currency: String, pub amount_local: String, pub currency_local: String, pub provider: String, pub provider_image_75: String, pub provider_image_200: String, pub servicelevel: ServiceLevel, pub estimated_days: Option<i64>, pub duration_terms: String, pub carrier_account: String, pub test: bool,
The data type for a rate. A rate is an available service of a shipping provider for a given shipment, typically including the price and transit time. FROM: https://goshippo.com/docs/reference#rates
Fields
object_id: String
Unique identifier of the given Rate object.
object_created: DateTime<Utc>
Date and time of Rate creation.
object_owner: String
Username of the user who created the rate object.
attributes: Vec<String>
An array containing specific attributes of this Rate in context of the entire shipment. Attributes can be assigned ‘CHEAPEST’, ‘FASTEST’, or ‘BESTVALUE’.
shipment: String
amount: String
Final Rate price, expressed in the currency used in the sender’s country.
currency: String
Currency used in the sender’s country, refers to “amount”. The official ISO 4217 currency codes are used, e.g. “USD” or “EUR”.
amount_local: String
Final Rate price, expressed in the currency used in the recipient’s country.
currency_local: String
Currency used in the recipient’s country, refers to “amount_local”. The official ISO 4217 currency codes are used, e.g. “USD” or “EUR”.
provider: String
Carrier offering the rate, e.g., “FedEx” or “Deutsche Post DHL”.
provider_image_75: String
URL to the provider logo with max. dimensions of 75*75px. Please refer to the provider’s Logo Usage Guidelines before using the logo.
provider_image_200: String
URL to the provider logo with max. dimensions of 200*200px. Please refer to the provider’s Logo Usage Guidelines before using the logo.
servicelevel: ServiceLevel
Contains details regarding the service level for the given rate.
estimated_days: Option<i64>
Estimated transit time (duration) in days of the Parcel at the given servicelevel. Please note that this is not binding, but only an average value as given by the provider. Shippo is not able to guarantee any transit times.
duration_terms: String
Further clarification of the transit times. Often, this includes notes that the transit time as given in “days” is only an average, not a guaranteed time.
carrier_account: String
Object ID of the carrier account that has been used to retrieve the rate.
test: bool
Indicates whether the object has been created in test mode.
Trait Implementations
impl<'de> Deserialize<'de> for Rate
[src]
impl<'de> Deserialize<'de> for Rate
[src]fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error> where
__D: Deserializer<'de>,
[src]
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error> where
__D: Deserializer<'de>,
[src]Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations
impl RefUnwindSafe for Rate
impl Send for Rate
impl Sync for Rate
impl Unpin for Rate
impl UnwindSafe for Rate
Blanket Implementations
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]pub fn borrow_mut(&mut self) -> &mut T
[src]
pub fn borrow_mut(&mut self) -> &mut T
[src]Mutably borrows from an owned value. Read more
impl<T> Instrument for T
[src]
impl<T> Instrument for T
[src]fn instrument(self, span: Span) -> Instrumented<Self>
[src]
fn instrument(self, span: Span) -> Instrumented<Self>
[src]Instruments this type with the provided Span
, returning an
Instrumented
wrapper. Read more
fn in_current_span(self) -> Instrumented<Self>
[src]
fn in_current_span(self) -> Instrumented<Self>
[src]impl<T> ToOwned for T where
T: Clone,
[src]
impl<T> ToOwned for T where
T: Clone,
[src]type Owned = T
type Owned = T
The resulting type after obtaining ownership.
pub fn to_owned(&self) -> T
[src]
pub fn to_owned(&self) -> T
[src]Creates owned data from borrowed data, usually by cloning. Read more
pub fn clone_into(&self, target: &mut T)
[src]
pub fn clone_into(&self, target: &mut T)
[src]🔬 This is a nightly-only experimental API. (toowned_clone_into
)
recently added
Uses borrowed data to replace owned data, usually by cloning. Read more
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
pub fn vzip(self) -> V
impl<T> DeserializeOwned for T where
T: for<'de> Deserialize<'de>,
[src]
T: for<'de> Deserialize<'de>,