enbbox 1.0.1

Notification infrastructure API — open-source alternative to Novu/Courier
Documentation
/*
 * enbbox API
 *
 * Notification infrastructure API — open-source alternative to Novu/Courier
 *
 * The version of the OpenAPI document: 1.0.0
 * 
 * Generated by: https://openapi-generator.tech
 */

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

/// ChannelType : Notification delivery channels (from Novu ChannelTypeEnum).
/// Notification delivery channels (from Novu ChannelTypeEnum).
#[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)]
pub enum ChannelType {
    #[serde(rename = "in_app")]
    InApp,
    #[serde(rename = "email")]
    Email,
    #[serde(rename = "sms")]
    Sms,
    #[serde(rename = "chat")]
    Chat,
    #[serde(rename = "push")]
    Push,

}

impl std::fmt::Display for ChannelType {
    fn fmt(&self, f: &mut std::fmt::Formatter) -> std::fmt::Result {
        match self {
            Self::InApp => write!(f, "in_app"),
            Self::Email => write!(f, "email"),
            Self::Sms => write!(f, "sms"),
            Self::Chat => write!(f, "chat"),
            Self::Push => write!(f, "push"),
        }
    }
}

impl Default for ChannelType {
    fn default() -> ChannelType {
        Self::InApp
    }
}