pub struct SlackMessage {
pub text: Option<String>,
pub blocks: Vec<SlackBlock>,
pub attachments: Vec<SlackAttachment>,
pub thread_ts: Option<String>,
pub reply_broadcast: Option<bool>,
pub username: Option<String>,
pub icon_emoji: Option<String>,
pub icon_url: Option<String>,
}Expand description
A Slack webhook message.
Fields§
§text: Option<String>Plain text content.
blocks: Vec<SlackBlock>Block Kit blocks for rich formatting.
attachments: Vec<SlackAttachment>Legacy attachments.
thread_ts: Option<String>Thread timestamp to reply in a thread.
reply_broadcast: Option<bool>Broadcast reply to the channel.
username: Option<String>Override the webhook’s username.
icon_emoji: Option<String>Override the webhook’s icon (emoji).
icon_url: Option<String>Override the webhook’s icon (URL).
Implementations§
Source§impl SlackMessage
impl SlackMessage
Sourcepub fn builder() -> SlackMessageBuilder
pub fn builder() -> SlackMessageBuilder
Builder for messages
Trait Implementations§
Source§impl Clone for SlackMessage
impl Clone for SlackMessage
Source§impl Debug for SlackMessage
impl Debug for SlackMessage
Source§impl Default for SlackMessage
impl Default for SlackMessage
Source§impl MessageConverter<SlackMessage> for SlackMessageConverter
impl MessageConverter<SlackMessage> for SlackMessageConverter
Source§fn to_service(
&self,
generic: &GenericMessage,
) -> Result<SlackMessage, CoreError>
fn to_service( &self, generic: &GenericMessage, ) -> Result<SlackMessage, CoreError>
Convert a generic message to service-specific format.
Source§fn to_generic(
&self,
service_msg: &SlackMessage,
) -> Result<GenericMessage, CoreError>
fn to_generic( &self, service_msg: &SlackMessage, ) -> Result<GenericMessage, CoreError>
Convert a service-specific message back to generic format.
Auto Trait Implementations§
impl Freeze for SlackMessage
impl RefUnwindSafe for SlackMessage
impl Send for SlackMessage
impl Sync for SlackMessage
impl Unpin for SlackMessage
impl UnsafeUnpin for SlackMessage
impl UnwindSafe for SlackMessage
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