amazon-spapi 2.0.3

A Rust client library for Amazon Selling Partner API (SP-API)
Documentation
/*
 * The Selling Partner API for FBA inbound operations.
 *
 * The Selling Partner API for Fulfillment By Amazon (FBA) Inbound. The FBA Inbound API enables building inbound workflows to create, manage, and send shipments into Amazon's fulfillment network. The API has interoperability with the Send-to-Amazon user interface.
 *
 * The version of the OpenAPI document: 2024-03-20
 * 
 * Generated by: https://openapi-generator.tech
 */

use crate::models;
use serde::{Deserialize, Serialize};

/// Quote : The estimated shipping cost associated with the transportation option.
#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
pub struct Quote {
    #[serde(rename = "cost")]
    pub cost: Box<models::fulfillment_inbound_2024_03_20::Currency>,
    /// The time at which this transportation option quote expires. In [ISO 8601](https://developer-docs.amazon.com/sp-api/docs/iso-8601) datetime with pattern `yyyy-MM-ddTHH:mm:ss.sssZ`.
    #[serde(rename = "expiration", skip_serializing_if = "Option::is_none")]
    pub expiration: Option<String>,
    /// Voidable until timestamp.
    #[serde(rename = "voidableUntil", skip_serializing_if = "Option::is_none")]
    pub voidable_until: Option<String>,
}

impl Quote {
    /// The estimated shipping cost associated with the transportation option.
    pub fn new(cost: models::fulfillment_inbound_2024_03_20::Currency) -> Quote {
        Quote {
            cost: Box::new(cost),
            expiration: None,
            voidable_until: None,
        }
    }
}