traq 0.1.5

⚠️ Community Driven ⚠️ traQ v3 API
Documentation
/*
 * traQ v3
 *
 * traQ v3 API
 *
 * The version of the OpenAPI document: 3.0
 *
 * Generated by: https://openapi-generator.tech
 */

/// OAuth2ClientDetail : OAuth2クライアント詳細情報

#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)]
pub struct OAuth2ClientDetail {
    /// クライアントUUID
    #[serde(rename = "id")]
    pub id: String,
    /// クライアント開発者UUID
    #[serde(rename = "developerId")]
    pub developer_id: uuid::Uuid,
    /// 説明
    #[serde(rename = "description")]
    pub description: String,
    /// クライアント名
    #[serde(rename = "name")]
    pub name: String,
    /// 要求スコープの配列
    #[serde(rename = "scopes")]
    pub scopes: Vec<crate::models::OAuth2Scope>,
    /// コールバックURL
    #[serde(rename = "callbackUrl")]
    pub callback_url: String,
    /// クライアントシークレット
    #[serde(rename = "secret")]
    pub secret: String,
    /// confidential client なら true, public client なら false
    #[serde(rename = "confidential")]
    pub confidential: bool,
}

impl OAuth2ClientDetail {
    /// OAuth2クライアント詳細情報
    pub fn new(
        id: String,
        developer_id: uuid::Uuid,
        description: String,
        name: String,
        scopes: Vec<crate::models::OAuth2Scope>,
        callback_url: String,
        secret: String,
        confidential: bool,
    ) -> OAuth2ClientDetail {
        OAuth2ClientDetail {
            id,
            developer_id,
            description,
            name,
            scopes,
            callback_url,
            secret,
            confidential,
        }
    }
}