Struct twilight_http::request::application::command::create_global_command::CreateGlobalCommand [−][src]
pub struct CreateGlobalCommand<'a> { /* fields omitted */ }
Expand description
Create a new global command.
The name must be between 1 and 32 characters in length. Creating a command with the same name as an already-existing global command will overwrite the old command. See the discord docs for more information.
Implementations
pub fn chat_input(
self,
description: &'a str
) -> Result<CreateGlobalChatInputCommand<'a>, InteractionError>
pub fn chat_input(
self,
description: &'a str
) -> Result<CreateGlobalChatInputCommand<'a>, InteractionError>
Create a new chat input global command.
The description must be between 1 and 100 characters in length. Creating a command with the same name as an already-existing global command will overwrite the old command. See the discord docs for more information.
Errors
Returns an InteractionErrorType::CommandDescriptionValidationFailed
error type if the command description is not between 1 and
100 characters.
Create a new message global command.
Creating a command with the same name as an already-existing global command will overwrite the old command. See the discord docs for more information.
Create a new user global command.
Creating a command with the same name as an already-existing global command will overwrite the old command. See the discord docs for more information.
Auto Trait Implementations
impl<'a> !RefUnwindSafe for CreateGlobalCommand<'a>
impl<'a> Send for CreateGlobalCommand<'a>
impl<'a> Sync for CreateGlobalCommand<'a>
impl<'a> Unpin for CreateGlobalCommand<'a>
impl<'a> !UnwindSafe for CreateGlobalCommand<'a>
Blanket Implementations
Mutably borrows from an owned value. Read more
Instruments this type with the provided Span
, returning an
Instrumented
wrapper. Read more
pub fn vzip(self) -> V
Attaches the provided Subscriber
to this type, returning a
WithDispatch
wrapper. Read more
Attaches the current default Subscriber
to this type, returning a
WithDispatch
wrapper. Read more