Skip to main content

Class: ApplicationCommand

Hierarchy​

  • Base

    ↳ ApplicationCommand

Constructors​

constructor​

• new ApplicationCommand(client, data)

Parameters​

NameType
clientClient
dataObject

Overrides​

Base.constructor

Defined in​

packages/libcord/src/structures/ApplicationCommand.ts:156

Properties​

client​

• Readonly client: Client

Inherited from​

Base.client

Defined in​

packages/libcord/src/structures/Base.ts:8


data​

• data: Object

Index signature​

▪ [index: string]: any

Defined in​

packages/libcord/src/structures/ApplicationCommand.ts:154


defaultPermission​

• defaultPermission: boolean

if the command is enable by default on add guild

Defined in​

packages/libcord/src/structures/ApplicationCommand.ts:150


description​

• description: string

the description of the command

Defined in​

packages/libcord/src/structures/ApplicationCommand.ts:141


guild​

• guild: null | Guild

the guild of the command (is null for global commands)

Defined in​

packages/libcord/src/structures/ApplicationCommand.ts:131


id​

• id: string

the id of the command

Defined in​

packages/libcord/src/structures/ApplicationCommand.ts:126


name​

• name: string

the name of the command

Defined in​

packages/libcord/src/structures/ApplicationCommand.ts:136


options​

• options: null | ApplicationCommandOption[]

the options of the command

Defined in​

packages/libcord/src/structures/ApplicationCommand.ts:146

Methods​

edit​

▸ edit(data, cache?): Promise<ApplicationCommand>

Parameters​

NameTypeDefault value
dataEditApplicationCommandOptionsundefined
cachebooleantrue

Returns​

Promise<ApplicationCommand>

Defined in​

packages/libcord/src/structures/ApplicationCommand.ts:174


toJSON​

▸ toJSON(space?): string

Parameters​

NameTypeDefault value
spacenumber1

Returns​

string

Defined in​

packages/libcord/src/structures/ApplicationCommand.ts:185


toString​

▸ toString(): string

Returns​

string

Defined in​

packages/libcord/src/structures/ApplicationCommand.ts:181


updateData​

▸ updateData(data): ApplicationCommand

Parameters​

NameType
dataAPIApplicationCommand

Returns​

ApplicationCommand

Defined in​

packages/libcord/src/structures/ApplicationCommand.ts:201