Skip to main content

Channel

Trait Channel 

Source
pub trait Channel: Send + Sync {
    // Required methods
    fn send(&self, message: &str) -> Result<(), DeliveryError>;
    fn channel_type(&self) -> &str;
}
Expand description

Trait for outbound message delivery to external channels.

Required Methods§

Source

fn send(&self, message: &str) -> Result<(), DeliveryError>

Send a text message to the channel destination.

Source

fn channel_type(&self) -> &str

Channel type identifier (e.g., “telegram”).

Implementors§