amazon_spapi/models/shipping/
accepted_rate.rs

1/*
2 * Selling Partner API for Shipping
3 *
4 * Provides programmatic access to Amazon Shipping APIs.   **Note:** If you are new to the Amazon Shipping API, refer to the latest version of <a href=\"https://developer-docs.amazon.com/amazon-shipping/docs/shipping-api-v2-reference\">Amazon Shipping API (v2)</a> on the <a href=\"https://developer-docs.amazon.com/amazon-shipping/\">Amazon Shipping Developer Documentation</a> site.
5 *
6 * The version of the OpenAPI document: v1
7 * 
8 * Generated by: https://openapi-generator.tech
9 */
10
11use crate::models;
12use serde::{Deserialize, Serialize};
13
14/// AcceptedRate : The specific rate purchased for the shipment, or null if unpurchased.
15#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
16pub struct AcceptedRate {
17    #[serde(rename = "totalCharge", skip_serializing_if = "Option::is_none")]
18    pub total_charge: Option<Box<models::shipping::Currency>>,
19    #[serde(rename = "billedWeight", skip_serializing_if = "Option::is_none")]
20    pub billed_weight: Option<Box<models::shipping::Weight>>,
21    #[serde(rename = "serviceType", skip_serializing_if = "Option::is_none")]
22    pub service_type: Option<models::shipping::ServiceType>,
23    #[serde(rename = "promise", skip_serializing_if = "Option::is_none")]
24    pub promise: Option<Box<models::shipping::ShippingPromiseSet>>,
25}
26
27impl AcceptedRate {
28    /// The specific rate purchased for the shipment, or null if unpurchased.
29    pub fn new() -> AcceptedRate {
30        AcceptedRate {
31            total_charge: None,
32            billed_weight: None,
33            service_type: None,
34            promise: None,
35        }
36    }
37}
38