DiscordCreateApplicationCommand
Documentation / @discordeno/bot / DiscordCreateApplicationCommand
Interface: DiscordCreateApplicationCommand
Defined in: packages/types/dist/types/discord.d.ts:2434
Extended by
Properties
contexts?
optional
contexts:null
|DiscordInteractionContextType
[]
Defined in: packages/types/dist/types/discord.d.ts:2470
Interaction context(s) where the command can be used
Remarks
This value is available only for globally-scoped commands By default, all interaction context types included for new commands.
default_member_permissions?
optional
default_member_permissions:null
|string
Defined in: packages/types/dist/types/discord.d.ts:2454
Set of permissions represented as a bit set
description?
optional
description:string
Defined in: packages/types/dist/types/discord.d.ts:2448
Description for ApplicationCommandTypes.ChatInput
commands, 1-100 characters.
description_localizations?
optional
description_localizations:null
|Partial
<Record
<Locales
,string
>>
Defined in: packages/types/dist/types/discord.d.ts:2450
Localization object for description
field. Values follow the same restrictions as description
dm_permission?
optional
dm_permission:boolean
Defined in: packages/types/dist/types/discord.d.ts:2476
Indicates whether the command is available in DMs with the app, only for globally-scoped commands. By default, commands are visible.
Deprecated
use contexts instead
handler?
optional
handler:DiscordInteractionEntryPointCommandHandlerType
Defined in: packages/types/dist/types/discord.d.ts:2487
Determines whether the interaction is handled by the app's interactions handler or by Discord
Remarks
This can only be set for application commands of type PRIMARY_ENTRY_POINT
for applications with the EMBEDDED
flag (i.e. applications that have an Activity).
integration_types?
optional
integration_types:DiscordApplicationIntegrationType
[]
Defined in: packages/types/dist/types/discord.d.ts:2462
Installation contexts where the command is available
Remarks
This value is available only for globally-scoped commands Defaults to the application configured contexts
name
name:
string
Defined in: packages/types/dist/types/discord.d.ts:2444
Name of command, 1-32 characters.
ApplicationCommandTypes.ChatInput
command names must match the following regex ^[-_\p{L}\p{N}\p{sc=Deva}\p{sc=Thai}]{1,32}$
with the unicode flag set.
If there is a lowercase variant of any letters used, you must use those.
Characters with no lowercase variants and/or uncased letters are still allowed.
ApplicationCommandTypes.Userand
ApplicationCommandTypes.Message` commands may be mixed case and can include spaces.
name_localizations?
optional
name_localizations:null
|Partial
<Record
<Locales
,string
>>
Defined in: packages/types/dist/types/discord.d.ts:2446
Localization object for name
field. Values follow the same restrictions as name
nsfw?
optional
nsfw:boolean
Defined in: packages/types/dist/types/discord.d.ts:2478
Indicates whether the command is age-restricted, defaults to false
options?
optional
options:DiscordApplicationCommandOption
[]
Defined in: packages/types/dist/types/discord.d.ts:2452
Parameters for the command, max of 25
type?
optional
type:ApplicationCommandTypes
Defined in: packages/types/dist/types/discord.d.ts:2436
Type of command, defaults to ApplicationCommandTypes.ChatInput
version?
optional
version:string
Defined in: packages/types/dist/types/discord.d.ts:2480
Auto incrementing version identifier updated during substantial record changes