A builder that creates API-compatible JSON data for context menu commands.
default_member_permissions:Permissions_2 | null | undefined
The set of permissions represented as a bit set for the command.
Indicates whether the command is available in direct messages with the application.
By default, commands are visible. This property is only for global commands.
The name localizations of this command.
The type of this command.
Sets the default permissions a member should have in order to run this command.
You can set this to
'0' to disable the command by default.
Sets whether the command is enabled by default when the application is added to a guild.
If set to
false, you will have to later
PUT the permissions for this command.
Whether to enable this command by default
Sets if the command is available in direct messages with the application.
By default, commands are visible. This method is only for global commands.
|boolean | null | undefined
Whether the command should be enabled in direct messages
Sets the name of this command.
The name to use
Sets a name localization for this command.
Sets the name localizations for this command.
Sets the type of this command.
Serializes this builder to API-compatible JSON data.
This method runs validations on the data before serializing it. As such, it may throw an error if the data is invalid.