pub enum ChatEvent {
Message {
thread_id: String,
message: IncomingMessage,
},
Mention {
thread_id: String,
message: IncomingMessage,
},
Reaction(ReactionEvent),
Action(ActionEvent),
SlashCommand(SlashCommandEvent),
ModalSubmit(ModalSubmitEvent),
ModalClose(ModalCloseEvent),
}Expand description
Top-level event dispatched from a chat adapter to the bot.
Covers all supported interaction types: plain messages, mentions, reactions, interactive actions, slash commands, and modal lifecycle.
Variants§
Message
A regular message was posted in a channel or thread.
Fields
§
message: IncomingMessageThe received message.
Mention
The bot was explicitly mentioned in a message.
Fields
§
message: IncomingMessageThe received message containing the mention.
Reaction(ReactionEvent)
A reaction was added or removed.
Action(ActionEvent)
An interactive element was activated.
SlashCommand(SlashCommandEvent)
A slash command was invoked.
ModalSubmit(ModalSubmitEvent)
A modal was submitted.
ModalClose(ModalCloseEvent)
A modal was closed without submitting.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for ChatEvent
impl RefUnwindSafe for ChatEvent
impl Send for ChatEvent
impl Sync for ChatEvent
impl Unpin for ChatEvent
impl UnsafeUnpin for ChatEvent
impl UnwindSafe for ChatEvent
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