v1

latestOpenAPI 3.0.12026-07-17310206.9 KB

Registers a global slash command for a Discord bot.

This function creates a new slash command that can be used in any guild where the bot is present. It takes a single object parameter defining the command's properties and returns a Promise that resolves to the registered command object.

post/registerGlobalSlashCommand

Request body

Response

Successfully registered the global slash command

idstring

The unique identifier of the registered command

application_idstring

The ID of the application the command belongs to

namestring

The name of the registered command

descriptionstring

The description of the registered command