pub struct ChatbotMessages {
pub client: Client,
}
Fields§
§client: Client
Implementations§
Source§impl ChatbotMessages
impl ChatbotMessages
Sourcepub async fn sendchatbot(
&self,
body: &SendchatbotRequest,
) -> Result<Response<()>, ClientError>
pub async fn sendchatbot( &self, body: &SendchatbotRequest, ) -> Result<Response<()>, ClientError>
Send chatbot messages.
This function performs a POST
to the /im/chat/messages
endpoint.
Send chatbot messages from your marketplace chatbot app.
Scopes: imchat:bot
Rate Limit Label: Medium
Authorization Flow: Client Credentials Flow
To get authorized, make a POST request to /oauth/token
endpoint with grant type as client_credentials
.
Use https://api.zoom.us/oauth/token?grant_type=client_credentials
as the endpoint for the request.
You will need to send your ClientID and Secret as a Basic base64 encoded AUthorization header. Ex. Basic base64Encode({client_id}:{client_sceret})
Next, use the token recieved (access_token) as a bearer token while making the POST /im/chat/messages request to send chatbot messages.
Learn more about how to authorize chatbots in the Chatbot Authorization guide.
Sourcepub async fn edit(
&self,
message_id: &str,
body: &EditChatbotMessageRequest,
) -> Result<Response<EditChatbotMessageResponse>, ClientError>
pub async fn edit( &self, message_id: &str, body: &EditChatbotMessageRequest, ) -> Result<Response<EditChatbotMessageResponse>, ClientError>
Edit a chatbot message.
This function performs a PUT
to the /im/chat/messages/{message_id}
endpoint.
Edit a message that was sent by your Chatbot app.
After sending a message using the Send Chatbot Message API, you must store the messageId returned in the response so that you can make edits to the associated message using this API.
Scope: imchat:bot
Rate Limit Label: Medium
Authorization Flow: Client Credentials Flow
To get authorized, make a POST request to /oauth/token
endpoint with grant type as client_credentials
.
Use https://api.zoom.us/oauth/token?grant_type=client_credentials
as the endpoint for the request.
You will need to send your ClientID and Secret as a Basic base64 encoded AUthorization header. Ex. Basic base64Encode({client_id}:{client_sceret})
Next, use the token received (access_token) as a bearer token while making the PUT /im/chat/messages/{message_id} request to edit a chatbot message.
Learn more about how to authotize chatbots in the Chatbot Authorization guide.
Parameters:
message_id: &str
– Unique Identifier of the message that needs to be updated. This should be retrieved from the response of Send Chatbot Message API.
Sourcepub async fn delete(
&self,
message_id: &str,
body: &DeleteChatbotMessageRequest,
) -> Result<Response<DeleteChatbotMessageResponse>, ClientError>
pub async fn delete( &self, message_id: &str, body: &DeleteChatbotMessageRequest, ) -> Result<Response<DeleteChatbotMessageResponse>, ClientError>
Delete a chatbot message.
This function performs a DELETE
to the /im/chat/messages/{message_id}
endpoint.
Delete a message that was sent by your chatbot app.
Scopes: imchat:bot
Rate Limit Label: Medium
Authorization Flow: Client Credentials Flow
To get authorized, make a POST request to /oauth/token
endpoint with grant type as client_credentials
.
Use https://api.zoom.us/oauth/token?grant_type=client_credentials
as the endpoint for the request.
You will need to send your ClientID and Secret as a Basic base64 encoded AUthorization header. Ex. Basic base64Encode({client_id}:{client_sceret})
Next, use the token received (access_token) as a bearer token while making the DELETE /im/chat/messages/{message_id} request to delete a message.
Learn more about how to authotize chatbots in the Chatbot Authorization guide.