/*
 * doqium - service-auth REST API
 *
 * doqium - service-auth REST API
 *
 * The version of the OpenAPI document: 1.0
 *
 * Generated by: https://openapi-generator.tech
 */

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

#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
pub struct UserKey {
    #[serde(rename = "id")]
    pub id: String,
    #[serde(rename = "alias", skip_serializing_if = "Option::is_none")]
    pub alias: Option<String>,
    #[serde(rename = "type")]
    pub r#type: String,
    #[serde(rename = "source")]
    pub source: String,
    #[serde(rename = "created")]
    pub created: String,
}

impl UserKey {
    pub fn new(id: String, r#type: String, source: String, created: String) -> UserKey {
        UserKey {
            id,
            alias: None,
            r#type,
            source,
            created,
        }
    }
}
