/*
 * Zernio API
 *
 * API reference for Zernio. Authenticate with a Bearer API key. Base URL: https://zernio.com/api
 *
 * The version of the OpenAPI document: 1.0.4
 * Contact: support@zernio.com
 * Generated by: https://openapi-generator.tech
 */

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

#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
pub struct WebhookPayloadMessageMetadataOrderProductItemsInner {
    /// Retailer ID (SKU) of the ordered product.
    #[serde(
        rename = "product_retailer_id",
        skip_serializing_if = "Option::is_none"
    )]
    pub product_retailer_id: Option<String>,
    /// Quantity ordered for this line item.
    #[serde(rename = "quantity", skip_serializing_if = "Option::is_none")]
    pub quantity: Option<i32>,
    /// Unit price of the item.
    #[serde(rename = "item_price", skip_serializing_if = "Option::is_none")]
    pub item_price: Option<f64>,
    /// ISO 4217 currency code (e.g. USD).
    #[serde(rename = "currency", skip_serializing_if = "Option::is_none")]
    pub currency: Option<String>,
}

impl WebhookPayloadMessageMetadataOrderProductItemsInner {
    pub fn new() -> WebhookPayloadMessageMetadataOrderProductItemsInner {
        WebhookPayloadMessageMetadataOrderProductItemsInner {
            product_retailer_id: None,
            quantity: None,
            item_price: None,
            currency: None,
        }
    }
}
