pub struct ChannelConfig {
pub channel_type: String,
pub token_env: Option<String>,
pub webhook_secret_env: Option<String>,
pub allowed_user_ids: Vec<String>,
pub rate_limit_per_user: u32,
pub settings: HashMap<String, Value>,
}Expand description
Configuration for a communication channel.
Fields§
§channel_type: StringChannel type identifier (e.g. “slack”, “discord”, “webhook”).
token_env: Option<String>Environment variable holding the authentication token.
webhook_secret_env: Option<String>Environment variable holding the webhook signing secret (for signature verification). Slack: signing secret. Telegram: secret_token header value. Discord: public key.
allowed_user_ids: Vec<String>Allowlisted user/chat IDs. Only these users can interact with fighters. Empty list = open access (logs a security warning on startup).
rate_limit_per_user: u32Per-user rate limit in messages per minute. Default: 20.
settings: HashMap<String, Value>Additional channel-specific settings.
Trait Implementations§
Source§impl Clone for ChannelConfig
impl Clone for ChannelConfig
Source§fn clone(&self) -> ChannelConfig
fn clone(&self) -> ChannelConfig
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 ChannelConfig
impl Debug for ChannelConfig
Source§impl<'de> Deserialize<'de> for ChannelConfig
impl<'de> Deserialize<'de> for ChannelConfig
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 ChannelConfig
impl RefUnwindSafe for ChannelConfig
impl Send for ChannelConfig
impl Sync for ChannelConfig
impl Unpin for ChannelConfig
impl UnsafeUnpin for ChannelConfig
impl UnwindSafe for ChannelConfig
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