webhook_line/models/
attached_module_content.rs

1/*
2 * Webhook Type Definition
3 *
4 * Webhook event definition of the LINE Messaging API
5 *
6 * The version of the OpenAPI document: 1.0.0
7 *
8 * Generated by: https://openapi-generator.tech
9 */
10
11use crate::models;
12use serde::{Deserialize, Serialize};
13
14#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
15pub struct AttachedModuleContent {
16    /// Type
17    #[serde(rename = "type", skip_serializing_if = "Option::is_none")]
18    pub r#type: Option<String>,
19    /// User ID of the bot on the attached LINE Official Account
20    #[serde(rename = "botId")]
21    pub bot_id: String,
22    /// An array of strings indicating the scope permitted by the admin of the LINE Official Account.
23    #[serde(rename = "scopes")]
24    pub scopes: Vec<String>,
25}
26
27impl AttachedModuleContent {
28    pub fn new(r#type: String, bot_id: String, scopes: Vec<String>) -> AttachedModuleContent {
29        AttachedModuleContent {
30            r#type: Some(r#type),
31            bot_id,
32            scopes,
33        }
34    }
35}