/*
 * 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};

/// PurchaseWhatsAppPhoneNumber200ResponseOneOf2 : A number was already purchased under the supplied purchaseIntentId; no new number was provisioned.
#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
pub struct PurchaseWhatsAppPhoneNumber200ResponseOneOf2 {
    #[serde(rename = "status", skip_serializing_if = "Option::is_none")]
    pub status: Option<Status>,
    #[serde(rename = "numberId", skip_serializing_if = "Option::is_none")]
    pub number_id: Option<String>,
    #[serde(rename = "phoneNumber", skip_serializing_if = "Option::is_none")]
    pub phone_number: Option<String>,
}

impl PurchaseWhatsAppPhoneNumber200ResponseOneOf2 {
    /// A number was already purchased under the supplied purchaseIntentId; no new number was provisioned.
    pub fn new() -> PurchaseWhatsAppPhoneNumber200ResponseOneOf2 {
        PurchaseWhatsAppPhoneNumber200ResponseOneOf2 {
            status: None,
            number_id: None,
            phone_number: None,
        }
    }
}
///
#[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)]
pub enum Status {
    #[serde(rename = "already_purchased")]
    AlreadyPurchased,
}

impl Default for Status {
    fn default() -> Status {
        Self::AlreadyPurchased
    }
}
