amazon_spapi/models/orders_v0/
tax_collection.rs

1/*
2 * Selling Partner API for Orders
3 *
4 * Use the Orders Selling Partner API to programmatically retrieve order information. With this API, you can develop fast, flexible, and custom applications to manage order synchronization, perform order research, and create demand-based decision support tools.   _Note:_ For the JP, AU, and SG marketplaces, the Orders API supports orders from 2016 onward. For all other marketplaces, the Orders API supports orders for the last two years (orders older than this don't show up in the response).
5 *
6 * The version of the OpenAPI document: v0
7 * 
8 * Generated by: https://openapi-generator.tech
9 */
10
11use crate::models;
12use serde::{Deserialize, Serialize};
13
14/// TaxCollection : Information about withheld taxes.
15#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
16pub struct TaxCollection {
17    /// The tax collection model applied to the item.
18    #[serde(rename = "Model", skip_serializing_if = "Option::is_none")]
19    pub model: Option<Model>,
20    /// The party responsible for withholding the taxes and remitting them to the taxing authority.
21    #[serde(rename = "ResponsibleParty", skip_serializing_if = "Option::is_none")]
22    pub responsible_party: Option<ResponsibleParty>,
23}
24
25impl TaxCollection {
26    /// Information about withheld taxes.
27    pub fn new() -> TaxCollection {
28        TaxCollection {
29            model: None,
30            responsible_party: None,
31        }
32    }
33}
34/// The tax collection model applied to the item.
35#[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)]
36pub enum Model {
37    #[serde(rename = "MarketplaceFacilitator")]
38    MarketplaceFacilitator,
39}
40
41impl Default for Model {
42    fn default() -> Model {
43        Self::MarketplaceFacilitator
44    }
45}
46/// The party responsible for withholding the taxes and remitting them to the taxing authority.
47#[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)]
48pub enum ResponsibleParty {
49    #[serde(rename = "Amazon Services, Inc.")]
50    AmazonServicesCommaIncPeriod,
51}
52
53impl Default for ResponsibleParty {
54    fn default() -> ResponsibleParty {
55        Self::AmazonServicesCommaIncPeriod
56    }
57}
58