Skip to main content

amazon_spapi/models/product_pricing_v0/
item_identifier.rs

1/*
2 * Selling Partner API for Pricing
3 *
4 * The Selling Partner API for Pricing helps you programmatically retrieve product pricing and offer information for Amazon Marketplace products.
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/// ItemIdentifier : Information that identifies an item.
15#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
16pub struct ItemIdentifier {
17    /// A marketplace identifier. Specifies the marketplace from which prices are returned.
18    #[serde(rename = "MarketplaceId")]
19    pub marketplace_id: String,
20    /// The Amazon Standard Identification Number (ASIN) of the item.
21    #[serde(rename = "ASIN", skip_serializing_if = "Option::is_none")]
22    pub asin: Option<String>,
23    /// The seller stock keeping unit (SKU) of the item.
24    #[serde(rename = "SellerSKU", skip_serializing_if = "Option::is_none")]
25    pub seller_sku: Option<String>,
26    #[serde(rename = "ItemCondition")]
27    pub item_condition: models::product_pricing_v0::ConditionType,
28}
29
30impl ItemIdentifier {
31    /// Information that identifies an item.
32    pub fn new(marketplace_id: String, item_condition: models::product_pricing_v0::ConditionType) -> ItemIdentifier {
33        ItemIdentifier {
34            marketplace_id,
35            asin: None,
36            seller_sku: None,
37            item_condition,
38        }
39    }
40}
41