Stegripe Monorepo Packages
Preparing search index...
@stegripe/command-context
CommandInteractionContext
Class CommandInteractionContext
Hierarchy (
View Summary
)
CommandContext
CommandInteractionContext
ChatInputCommandInteractionContext
MessageContextMenuCommandInteractionContext
UserContextMenuCommandInteractionContext
Index
Constructors
constructor
Properties
context
Accessors
application
Id
app
Permissions
author
channel
channel
Id
client
command
command
Guild
Id
command
Id
command
Name
command
Type
created
At
created
Timestamp
deferred
entitlements
ephemeral
guild
guild
Id
guild
Locale
id
locale
member
member
Permissions
options
replied
token
type
user
version
webhook
Methods
await
Modal
Submit
defer
Reply
delete
Reply
edit
Reply
fetch
Reply
follow
Up
in
Cached
Guild
in
Guild
in
Raw
Guild
is
Any
Select
Menu
is
Autocomplete
is
Button
is
Channel
Select
Menu
is
Chat
Input
Command
is
Chat
Input
Interaction
Context
is
Command
is
Command
Interaction
is
Context
Menu
Command
is
Mentionable
Select
Menu
is
Message
Component
is
Message
Context
is
Message
Context
Menu
Command
is
Message
Context
Menu
Interaction
Context
is
Modal
Submit
is
Repliable
is
Role
Select
Menu
is
Select
Menu
is
String
Select
Menu
is
User
Context
Menu
Command
is
User
Context
Menu
Interaction
Context
is
User
Select
Menu
reply
send
send
Premium
Required
show
Modal
to
JSON
to
String
value
Of
Constructors
constructor
new
CommandInteractionContext
(
context
:
CommandInteraction
,
)
:
CommandInteractionContext
Parameters
context
:
CommandInteraction
Returns
CommandInteractionContext
Properties
Readonly
context
context
:
CommandInteraction
Accessors
application
Id
get
applicationId
()
:
string
|
null
Returns
string
|
null
app
Permissions
get
appPermissions
()
:
Readonly
<
PermissionsBitField
>
Returns
Readonly
<
PermissionsBitField
>
author
get
author
()
:
User
Returns
User
channel
get
channel
()
:
TextBasedChannel
|
null
Returns
TextBasedChannel
|
null
channel
Id
get
channelId
()
:
string
Returns
string
client
get
client
()
:
Client
<
true
>
Returns
Client
<
true
>
command
get
command
()
:
|
ApplicationCommand
<
{}
>
|
ApplicationCommand
<
{
guild
:
GuildResolvable
}
>
|
null
Returns
ApplicationCommand
<
{}
>
|
ApplicationCommand
<
{
guild
:
GuildResolvable
}
>
|
null
command
Guild
Id
get
commandGuildId
()
:
string
|
null
Returns
string
|
null
command
Id
get
commandId
()
:
string
Returns
string
command
Name
get
commandName
()
:
string
Returns
string
command
Type
get
commandType
()
:
ApplicationCommandType
Returns
ApplicationCommandType
created
At
get
createdAt
()
:
Date
Returns
Date
created
Timestamp
get
createdTimestamp
()
:
number
Returns
number
deferred
get
deferred
()
:
boolean
Returns
boolean
entitlements
get
entitlements
()
:
Collection
<
string
,
Entitlement
>
Returns
Collection
<
string
,
Entitlement
>
ephemeral
get
ephemeral
()
:
boolean
|
null
Returns
boolean
|
null
guild
get
guild
()
:
Guild
|
null
Returns
Guild
|
null
guild
Id
get
guildId
()
:
string
|
null
Returns
string
|
null
guild
Locale
get
guildLocale
()
:
Locale
|
null
Returns
Locale
|
null
id
get
id
()
:
string
Returns
string
locale
get
locale
()
:
Locale
Returns
Locale
member
get
member
()
:
GuildMember
|
APIInteractionGuildMember
|
null
Returns
GuildMember
|
APIInteractionGuildMember
|
null
member
Permissions
get
memberPermissions
()
:
Readonly
<
PermissionsBitField
>
|
null
Returns
Readonly
<
PermissionsBitField
>
|
null
options
get
options
()
:
|
Omit
<
CommandInteractionOptionResolver
<
CacheType
>
,
|
"getFocused"
|
"getSubcommand"
|
"getSubcommandGroup"
|
"getBoolean"
|
"getChannel"
|
"getString"
|
"getInteger"
|
"getNumber"
|
"getUser"
|
"getRole"
|
"getAttachment"
|
"getMentionable"
,
>
|
Omit
<
CommandInteractionOptionResolver
<
CacheType
>
,
|
"getMessage"
|
"getFocused"
|
"getSubcommand"
|
"getSubcommandGroup"
|
"getBoolean"
|
"getChannel"
|
"getString"
|
"getInteger"
|
"getNumber"
|
"getRole"
|
"getAttachment"
|
"getMentionable"
,
>
|
null
Returns
|
Omit
<
CommandInteractionOptionResolver
<
CacheType
>
,
|
"getFocused"
|
"getSubcommand"
|
"getSubcommandGroup"
|
"getBoolean"
|
"getChannel"
|
"getString"
|
"getInteger"
|
"getNumber"
|
"getUser"
|
"getRole"
|
"getAttachment"
|
"getMentionable"
,
>
|
Omit
<
CommandInteractionOptionResolver
<
CacheType
>
,
|
"getMessage"
|
"getFocused"
|
"getSubcommand"
|
"getSubcommandGroup"
|
"getBoolean"
|
"getChannel"
|
"getString"
|
"getInteger"
|
"getNumber"
|
"getRole"
|
"getAttachment"
|
"getMentionable"
,
>
|
null
replied
get
replied
()
:
boolean
Returns
boolean
token
get
token
()
:
string
Returns
string
type
get
type
()
:
ApplicationCommand
|
MessageType
Returns
ApplicationCommand
|
MessageType
user
get
user
()
:
User
Returns
User
version
get
version
()
:
number
Returns
number
webhook
get
webhook
()
:
InteractionWebhook
Returns
InteractionWebhook
Methods
await
Modal
Submit
awaitModalSubmit
(
options
:
AwaitModalSubmitOptions
<
ModalSubmitInteraction
<
CacheType
>
>
,
)
:
Promise
<
ModalSubmitInteraction
<
CacheType
>
>
Parameters
options
:
AwaitModalSubmitOptions
<
ModalSubmitInteraction
<
CacheType
>
>
Returns
Promise
<
ModalSubmitInteraction
<
CacheType
>
>
defer
Reply
deferReply
(
options
:
InteractionDeferReplyOptions
,
)
:
Promise
<
Message
<
BooleanCache
<
CacheType
>
>
>
Parameters
options
:
InteractionDeferReplyOptions
Returns
Promise
<
Message
<
BooleanCache
<
CacheType
>
>
>
deferReply
(
options
?:
InteractionDeferReplyOptions
,
)
:
Promise
<
InteractionResponse
<
BooleanCache
<
CacheType
>
>
>
Parameters
Optional
options
:
InteractionDeferReplyOptions
Returns
Promise
<
InteractionResponse
<
BooleanCache
<
CacheType
>
>
>
delete
Reply
deleteReply
(
message
?:
MessageResolvable
)
:
Promise
<
void
>
Parameters
Optional
message
:
MessageResolvable
Returns
Promise
<
void
>
edit
Reply
editReply
(
options
:
string
|
MessagePayload
|
InteractionEditReplyOptions
,
)
:
Promise
<
Message
<
BooleanCache
<
CacheType
>
>
>
Parameters
options
:
string
|
MessagePayload
|
InteractionEditReplyOptions
Returns
Promise
<
Message
<
BooleanCache
<
CacheType
>
>
>
fetch
Reply
fetchReply
(
message
?:
string
)
:
Promise
<
Message
<
BooleanCache
<
CacheType
>
>
>
Parameters
Optional
message
:
string
Returns
Promise
<
Message
<
BooleanCache
<
CacheType
>
>
>
follow
Up
followUp
(
options
:
string
|
MessagePayload
|
InteractionReplyOptions
,
)
:
Promise
<
Message
<
BooleanCache
<
CacheType
>
>
>
Parameters
options
:
string
|
MessagePayload
|
InteractionReplyOptions
Returns
Promise
<
Message
<
BooleanCache
<
CacheType
>
>
>
in
Cached
Guild
inCachedGuild
()
:
this
is
CommandInteraction
<
"cached"
>
Returns
this
is
CommandInteraction
<
"cached"
>
in
Guild
inGuild
()
:
boolean
Returns
boolean
in
Raw
Guild
inRawGuild
()
:
this
is
CommandInteraction
<
"raw"
>
Returns
this
is
CommandInteraction
<
"raw"
>
is
Any
Select
Menu
isAnySelectMenu
()
:
this
is
AnySelectMenuInteraction
Returns
this
is
AnySelectMenuInteraction
is
Autocomplete
isAutocomplete
()
:
this
is
AutocompleteInteraction
<
CacheType
>
Returns
this
is
AutocompleteInteraction
<
CacheType
>
is
Button
isButton
()
:
this
is
ButtonInteraction
<
CacheType
>
Returns
this
is
ButtonInteraction
<
CacheType
>
is
Channel
Select
Menu
isChannelSelectMenu
()
:
this
is
ChannelSelectMenuInteraction
<
CacheType
>
Returns
this
is
ChannelSelectMenuInteraction
<
CacheType
>
is
Chat
Input
Command
isChatInputCommand
()
:
this
is
ChatInputCommandInteraction
<
CacheType
>
Returns
this
is
ChatInputCommandInteraction
<
CacheType
>
is
Chat
Input
Interaction
Context
isChatInputInteractionContext
()
:
this
is
ChatInputCommandInteractionContext
Returns
this
is
ChatInputCommandInteractionContext
is
Command
isCommand
()
:
this
is
CommandInteraction
<
CacheType
>
Returns
this
is
CommandInteraction
<
CacheType
>
is
Command
Interaction
isCommandInteraction
()
:
this
is
CommandInteractionContext
Returns
this
is
CommandInteractionContext
is
Context
Menu
Command
isContextMenuCommand
()
:
this
is
ContextMenuCommandInteraction
<
CacheType
>
Returns
this
is
ContextMenuCommandInteraction
<
CacheType
>
is
Mentionable
Select
Menu
isMentionableSelectMenu
()
:
this
is
MentionableSelectMenuInteraction
<
CacheType
>
Returns
this
is
MentionableSelectMenuInteraction
<
CacheType
>
is
Message
Component
isMessageComponent
()
:
this
is
MessageComponentInteraction
<
CacheType
>
Returns
this
is
MessageComponentInteraction
<
CacheType
>
is
Message
Context
isMessageContext
()
:
this
is
MessageContext
Returns
this
is
MessageContext
is
Message
Context
Menu
Command
isMessageContextMenuCommand
()
:
this
is
MessageContextMenuCommandInteraction
<
CacheType
,
>
Returns
this
is
MessageContextMenuCommandInteraction
<
CacheType
>
is
Message
Context
Menu
Interaction
Context
isMessageContextMenuInteractionContext
()
:
this
is
MessageContextMenuCommandInteractionContext
Returns
this
is
MessageContextMenuCommandInteractionContext
is
Modal
Submit
isModalSubmit
()
:
this
is
ModalSubmitInteraction
<
CacheType
>
Returns
this
is
ModalSubmitInteraction
<
CacheType
>
is
Repliable
isRepliable
()
:
this
is
RepliableInteraction
Returns
this
is
RepliableInteraction
is
Role
Select
Menu
isRoleSelectMenu
()
:
this
is
RoleSelectMenuInteraction
<
CacheType
>
Returns
this
is
RoleSelectMenuInteraction
<
CacheType
>
is
Select
Menu
isSelectMenu
()
:
this
is
StringSelectMenuInteraction
<
CacheType
>
Returns
this
is
StringSelectMenuInteraction
<
CacheType
>
is
String
Select
Menu
isStringSelectMenu
()
:
this
is
StringSelectMenuInteraction
<
CacheType
>
Returns
this
is
StringSelectMenuInteraction
<
CacheType
>
is
User
Context
Menu
Command
isUserContextMenuCommand
()
:
this
is
UserContextMenuCommandInteraction
<
CacheType
>
Returns
this
is
UserContextMenuCommandInteraction
<
CacheType
>
is
User
Context
Menu
Interaction
Context
isUserContextMenuInteractionContext
()
:
this
is
UserContextMenuCommandInteractionContext
Returns
this
is
UserContextMenuCommandInteractionContext
is
User
Select
Menu
isUserSelectMenu
()
:
this
is
UserSelectMenuInteraction
<
CacheType
>
Returns
this
is
UserSelectMenuInteraction
<
CacheType
>
reply
reply
(
options
:
string
|
MessagePayloadOption
)
:
Promise
<
Message
<
boolean
>
>
Parameters
options
:
string
|
MessagePayloadOption
Returns
Promise
<
Message
<
boolean
>
>
send
send
(
options
:
string
|
MessagePayloadOption
)
:
Promise
<
Message
<
boolean
>
>
Parameters
options
:
string
|
MessagePayloadOption
Returns
Promise
<
Message
<
boolean
>
>
send
Premium
Required
sendPremiumRequired
()
:
Promise
<
void
>
Returns
Promise
<
void
>
show
Modal
showModal
(
modal
:
|
APIModalInteractionResponseCallbackData
|
ModalComponentData
|
JSONEncodable
<
APIModalInteractionResponseCallbackData
>
,
)
:
Promise
<
InteractionCallbackResponse
<
boolean
>
>
Parameters
modal
:
|
APIModalInteractionResponseCallbackData
|
ModalComponentData
|
JSONEncodable
<
APIModalInteractionResponseCallbackData
>
Returns
Promise
<
InteractionCallbackResponse
<
boolean
>
>
to
JSON
toJSON
(
...
props
:
Record
<
string
,
string
|
boolean
>
[]
)
:
unknown
Parameters
...
props
:
Record
<
string
,
string
|
boolean
>
[]
Returns
unknown
to
String
toString
()
:
string
Returns
string
value
Of
valueOf
()
:
string
Returns
string
Settings
Member Visibility
Protected
Inherited
Theme
OS
Light
Dark
On This Page
Constructors
constructor
Properties
context
Accessors
application
Id
app
Permissions
author
channel
channel
Id
client
command
command
Guild
Id
command
Id
command
Name
command
Type
created
At
created
Timestamp
deferred
entitlements
ephemeral
guild
guild
Id
guild
Locale
id
locale
member
member
Permissions
options
replied
token
type
user
version
webhook
Methods
await
Modal
Submit
defer
Reply
delete
Reply
edit
Reply
fetch
Reply
follow
Up
in
Cached
Guild
in
Guild
in
Raw
Guild
is
Any
Select
Menu
is
Autocomplete
is
Button
is
Channel
Select
Menu
is
Chat
Input
Command
is
Chat
Input
Interaction
Context
is
Command
is
Command
Interaction
is
Context
Menu
Command
is
Mentionable
Select
Menu
is
Message
Component
is
Message
Context
is
Message
Context
Menu
Command
is
Message
Context
Menu
Interaction
Context
is
Modal
Submit
is
Repliable
is
Role
Select
Menu
is
Select
Menu
is
String
Select
Menu
is
User
Context
Menu
Command
is
User
Context
Menu
Interaction
Context
is
User
Select
Menu
reply
send
send
Premium
Required
show
Modal
to
JSON
to
String
value
Of
Stegripe Monorepo Packages
Loading...