Module twitch_api2::helix::moderation::manage_held_automod_messages
source · [−]Available on crate feature
helix
only.Expand description
Allow or deny a message that was held for review by AutoMod.
manage-held-automod-messages
Accessing the endpoint
Request: ManageHeldAutoModMessagesRequest
To use this endpoint, construct a ManageHeldAutoModMessagesRequest
with the ManageHeldAutoModMessagesRequest::builder()
method.
use twitch_api2::helix::moderation::manage_held_automod_messages;
let request = manage_held_automod_messages::ManageHeldAutoModMessagesRequest::new();
Body: ManageHeldAutoModMessagesBody
We also need to provide a body to the request containing what we want to change.
let body = manage_held_automod_messages::ManageHeldAutoModMessagesBody::builder()
.action(true)
.user_id("9327994")
.msg_id("836013710")
.build();
Response: ManageHeldAutoModMessages
Send the request to receive the response with HelixClient::req_post()
.
use twitch_api2::helix::{self, moderation::manage_held_automod_messages};
let request = manage_held_automod_messages::ManageHeldAutoModMessagesRequest::new();
let body = manage_held_automod_messages::ManageHeldAutoModMessagesBody::builder()
.action(true)
.user_id("9327994")
.msg_id("836013710")
.build();
let response: manage_held_automod_messages::ManageHeldAutoModMessages = client.req_post(request, body, &token).await?.data;
You can also get the http::Request
with request.create_request(&token, &client_id)
and parse the http::Response
with ManageHeldAutoModMessagesRequest::parse_response(None, &request.get_uri(), response)
Structs
Body Parameters for Manage Held AutoMod Messages
Query Parameters for Manage Held AutoMod Messages
Enums
Action to take for a message.
Return Values for Manage Held AutoMod Messages