Skip to main content
Deno 2 is finally here 🎉️
Learn more
Extremely Popular
Go to Latest
interface CreateSlashApplicationCommand
import { type CreateSlashApplicationCommand } from "https://deno.land/x/discordeno@17.2.0/plugins/permissions/deps.ts";

Properties

name: string

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.UserandApplicationCommandTypes.Message` commands may be mixed case and can include spaces.

optional
nameLocalizations: Localization

Localization object for the name field. Values follow the same restrictions as name

description: string

1-100 character description

optional
descriptionLocalizations: Localization

Localization object for the description field. Values follow the same restrictions as description

Type of command, defaults ApplicationCommandTypes.ChatInput if not set

optional
options: ApplicationCommandOption[]

Parameters for the command

optional
defaultMemberPermissions: PermissionStrings[]

Set of permissions represented as a bit set

optional
dmPermission: boolean

Indicates whether the command is available in DMs with the app, only for globally-scoped commands. By default, commands are visible.