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

/// PostWebhookRequest : Webhook作成リクエスト

#[derive(Clone, Debug, PartialEq, Default, Serialize, Deserialize)]
pub struct PostWebhookRequest {
    /// Webhookユーザーの表示名
    #[serde(rename = "name")]
    pub name: String,
    /// 説明
    #[serde(rename = "description")]
    pub description: String,
    /// デフォルトの投稿先チャンネルUUID
    #[serde(rename = "channelId")]
    pub channel_id: uuid::Uuid,
    /// Webhookシークレット
    #[serde(rename = "secret")]
    pub secret: String,
}

impl PostWebhookRequest {
    /// Webhook作成リクエスト
    pub fn new(
        name: String,
        description: String,
        channel_id: uuid::Uuid,
        secret: String,
    ) -> PostWebhookRequest {
        PostWebhookRequest {
            name,
            description,
            channel_id,
            secret,
        }
    }
}