BaseContext
↳ ContextMenuCommandInteraction
↳↳ MessageContextMenuCommandInteraction
↳↳ UserContextMenuCommandInteraction
client
, data
): ContextMenuCommandInteraction
Represents a context menu command
Name | Type | Description |
---|---|---|
client | YorClient | The client object. |
data | APIUserApplicationCommandInteraction | APIMessageApplicationCommandInteraction | The data object. |
ContextMenuCommandInteraction
string
YorClient
string
APIUserApplicationCommandInteraction
| APIMessageApplicationCommandInteraction
string
string
name
, data
): unknown
Decorates the object with a new property.
Name | Type | Description |
---|---|---|
name | string | The name of the property. |
data | unknown | The data to assign to the property. |
unknown
The decorated object.
ephemeral?
): Promise
<void
>
Defers the execution of the function.
Name | Type | Default value | Description |
---|---|---|---|
ephemeral | boolean | false | Whether the message is ephemeral or not. |
Promise
<void
>
A promise that resolves when the deferral is complete.
Promise
<void
>
Deletes a reply.
Promise
<void
>
A promise that resolves when the reply is deleted.
data
): Promise
<APIMessage
>
Edits a reply.
Name | Type | Description |
---|---|---|
data | Omit <RESTPostAPIWebhookWithTokenJSONBody , "username" | "avatar_url" > & { flags? : MessageFlags } & { files? : RawFile [] } | The data for editing the reply. |
Promise
<APIMessage
>
A promise that resolves when the reply is edited.
Promise
<APIMessage
>
Fetches the reply asynchronously.
Promise
<APIMessage
>
A promise that resolves when the original reply is fetched.
data
): Promise
<APIMessage
>
Calls the followUp method of the API class with the provided data.
Name | Type | Description |
---|---|---|
data | Omit <RESTPostAPIWebhookWithTokenJSONBody , "username" | "avatar_url" > & { flags? : MessageFlags } & { files? : RawFile [] } | The data to be passed to the followUp method. |
Promise
<APIMessage
>
A promise that resolves to an APIMessage object.
data
): Promise
<void
>
Replies to an interaction.
Name | Type | Description |
---|---|---|
data | Omit <RESTPostAPIWebhookWithTokenJSONBody , "username" | "avatar_url" > & { flags? : MessageFlags } & { files? : RawFile [] } | The data for creating the reply. |
Promise
<void
>
A promise that resolves when the reply is sent.
data
): Promise
<void
>
Reply to a modal.
Name | Type | Description |
---|---|---|
data | APIModalInteractionResponseCallbackData | The data for creating the modal. |
Promise
<void
>
A promise that resolves when the modal is created.