amazon-spapi 2.0.3

A Rust client library for Amazon Selling Partner API (SP-API)
Documentation
/*
 * The Selling Partner API for Finances
 *
 * The Selling Partner API for Finances helps you obtain financial information relevant to a seller's business. You can obtain financial events for a given order or date range without having to wait until a statement period closes.
 *
 * The version of the OpenAPI document: 2024-06-19
 * 
 * Generated by: https://openapi-generator.tech
 */

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

/// Item : Additional information about the items in Transaction.
#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
pub struct Item {
    /// Description of items in the transaction
    #[serde(rename = "description", skip_serializing_if = "Option::is_none")]
    pub description: Option<String>,
    /// Related Business identifiers of the item in Transaction.
    #[serde(rename = "relatedIdentifiers", skip_serializing_if = "Option::is_none")]
    pub related_identifiers: Option<Vec<models::finances_2024_06_19::ItemRelatedIdentifier>>,
    #[serde(rename = "totalAmount", skip_serializing_if = "Option::is_none")]
    pub total_amount: Option<Box<models::finances_2024_06_19::Currency>>,
    /// A list of breakdowns that detail how the total amount is calculated for the transaction.
    #[serde(rename = "breakdowns", skip_serializing_if = "Option::is_none")]
    pub breakdowns: Option<Vec<models::finances_2024_06_19::Breakdown>>,
    /// List of additional Information about the item.
    #[serde(rename = "contexts", skip_serializing_if = "Option::is_none")]
    pub contexts: Option<Vec<models::finances_2024_06_19::Context>>,
}

impl Item {
    /// Additional information about the items in Transaction.
    pub fn new() -> Item {
        Item {
            description: None,
            related_identifiers: None,
            total_amount: None,
            breakdowns: None,
            contexts: None,
        }
    }
}