Struct slack_api_client::SlackClient
source · pub struct SlackClient {
pub client: Client,
}Fields§
§client: ClientImplementations§
source§impl SlackClient
impl SlackClient
pub fn new(bearer_token: String) -> Self
sourcepub async fn get_conversation_list(&self) -> Result<String, Error>
pub async fn get_conversation_list(&self) -> Result<String, Error>
https://api.slack.com/methods/conversations.list
sourcepub async fn send_message(
&self,
request: String,
response_url: Option<&str>
) -> Result<Response, Error>
pub async fn send_message( &self, request: String, response_url: Option<&str> ) -> Result<Response, Error>
https://api.slack.com/methods/chat.postMessage errors: https://api.slack.com/methods/chat.postMessage#errors
sourcepub async fn delete_message(
&self,
channel_id: &str,
message_ts: &str
) -> Result<Response, Error>
pub async fn delete_message( &self, channel_id: &str, message_ts: &str ) -> Result<Response, Error>
https://api.slack.com/methods/chat.delete
pub async fn get_user_profile( &self, user_id: &str ) -> Result<GetUserProfileResponse, Error>
Auto Trait Implementations§
impl !RefUnwindSafe for SlackClient
impl Send for SlackClient
impl Sync for SlackClient
impl Unpin for SlackClient
impl !UnwindSafe for SlackClient
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