pub struct MessengerConfig {Show 13 fields
pub name: String,
pub messenger_type: String,
pub enabled: bool,
pub config_path: Option<PathBuf>,
pub token: Option<String>,
pub webhook_url: Option<String>,
pub homeserver: Option<String>,
pub user_id: Option<String>,
pub password: Option<String>,
pub access_token: Option<String>,
pub phone: Option<String>,
pub allowed_chats: Vec<String>,
pub allowed_users: Vec<String>,
}Expand description
Configuration for a messenger backend.
Fields§
§name: StringDisplay name for this messenger instance.
messenger_type: StringMessenger type: telegram, discord, signal, matrix, webhook.
enabled: boolWhether this messenger is enabled.
config_path: Option<PathBuf>Path to external config file (optional).
token: Option<String>Bot/API token (Telegram, Discord).
webhook_url: Option<String>Webhook URL (for webhook messenger).
homeserver: Option<String>Matrix homeserver URL.
user_id: Option<String>Matrix user ID (@user:homeserver).
password: Option<String>Password (Matrix).
access_token: Option<String>Access token (Matrix).
phone: Option<String>Phone number (Signal).
allowed_chats: Vec<String>Allowed chat IDs/channels (whitelist).
allowed_users: Vec<String>Allowed user IDs (whitelist).
Trait Implementations§
Source§impl Clone for MessengerConfig
impl Clone for MessengerConfig
Source§fn clone(&self) -> MessengerConfig
fn clone(&self) -> MessengerConfig
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for MessengerConfig
impl Debug for MessengerConfig
Source§impl Default for MessengerConfig
impl Default for MessengerConfig
Source§fn default() -> MessengerConfig
fn default() -> MessengerConfig
Returns the “default value” for a type. Read more
Source§impl<'de> Deserialize<'de> for MessengerConfig
impl<'de> Deserialize<'de> for MessengerConfig
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for MessengerConfig
impl RefUnwindSafe for MessengerConfig
impl Send for MessengerConfig
impl Sync for MessengerConfig
impl Unpin for MessengerConfig
impl UnsafeUnpin for MessengerConfig
impl UnwindSafe for MessengerConfig
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more