Extends
Methods
addMessageReaction(messageID, reaction) → {Promise}
Add a reaction to a message
- Inherited From:
- Source:
Parameters:
| Name | Type | Description |
|---|---|---|
messageID |
String
|
The ID of the message |
reaction |
String
|
The reaction (Unicode string if Unicode emoji, |
Returns:
- Type:
-
Promise
createInstance(options) → {Promise.<StageInstance>}
Create a stage instance
- Source:
Parameters:
| Name | Type | Description | ||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
options |
Object
|
The stage instance options
|
Returns:
- Type:
-
Promise.<StageInstance>
createInvite(optionsopt, reasonopt) → {Promise.<Invite>}
Create an invite for the channel
- Inherited From:
- Source:
Parameters:
| Name | Type | Attributes | Description | ||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
options |
Object
|
<optional> |
Invite generation options
|
||||||||||||||||||||
reason |
String
|
<optional> |
The reason to be displayed in audit logs |
Returns:
- Type:
-
Promise.<Invite>
createMessage(content, fileopt) → {Promise.<Message>}
Create a message in the channel
- Inherited From:
- Source:
Parameters:
| Name | Type | Attributes | Description | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
content |
String
|
Object
|
A string or object. If an object is passed:
|
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
file |
Object
|
Array.<Object>
|
<optional> |
A file object (or an Array of them)
|
Returns:
- Type:
-
Promise.<Message>
deleteInstance() → {Promise}
Delete the stage instance for this channel
- Source:
Returns:
- Type:
-
Promise
deleteMessage(messageID, reasonopt) → {Promise}
Delete a message
- Inherited From:
- Source:
Parameters:
| Name | Type | Attributes | Description |
|---|---|---|---|
messageID |
String
|
The ID of the message |
|
reason |
String
|
<optional> |
The reason to be displayed in audit logs |
Returns:
- Type:
-
Promise
deleteMessages(messageIDs, reasonopt) → {Promise}
Bulk delete messages (bot accounts only)
- Inherited From:
- Source:
Parameters:
| Name | Type | Attributes | Description |
|---|---|---|---|
messageIDs |
Array.<String>
|
Array of message IDs to delete |
|
reason |
String
|
<optional> |
The reason to be displayed in audit logs |
Returns:
- Type:
-
Promise
deletePermission(overwriteID, reasonopt) → {Promise}
Delete a channel permission overwrite
- Inherited From:
- Source:
Parameters:
| Name | Type | Attributes | Description |
|---|---|---|---|
overwriteID |
String
|
The ID of the overwritten user or role |
|
reason |
String
|
<optional> |
The reason to be displayed in audit logs |
Returns:
- Type:
-
Promise
editInstance(options) → {Promise.<StageInstance>}
Update the stage instance for this channel
- Source:
Parameters:
| Name | Type | Description | ||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
options |
Object
|
The properties to edit
|
Returns:
- Type:
-
Promise.<StageInstance>
editMessage(messageID, content) → {Promise.<Message>}
Edit a message
- Inherited From:
- Source:
Parameters:
| Name | Type | Description | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
messageID |
String
|
The ID of the message |
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
content |
String
|
Array
|
Object
|
A string, array of strings, or object. If an object is passed:
|
Returns:
- Type:
-
Promise.<Message>
editPermission(overwriteID, allow, deny, type, reasonopt) → {Promise.<PermissionOverwrite>}
Create a channel permission overwrite
- Inherited From:
- Source:
Parameters:
| Name | Type | Attributes | Description |
|---|---|---|---|
overwriteID |
String
|
The ID of the overwritten user or role |
|
allow |
BigInt
|
Number
|
String
|
The permissions number for allowed permissions |
|
deny |
BigInt
|
Number
|
String
|
The permissions number for denied permissions |
|
type |
Number
|
The object type of the overwrite, either 1 for "member" or 0 for "role" |
|
reason |
String
|
<optional> |
The reason to be displayed in audit logs |
Returns:
- Type:
-
Promise.<PermissionOverwrite>
endPoll(messageID) → {Promise.<Message>}
Immediately end a poll. Note: You cannot end polls from other users.
- Inherited From:
- Source:
Parameters:
| Name | Type | Description |
|---|---|---|
messageID |
String
|
The ID of the message that the poll is in |
Returns:
- Type:
-
Promise.<Message>
getInstance() → {Promise.<StageInstance>}
Get the stage instance for this channel
- Source:
Returns:
- Type:
-
Promise.<StageInstance>
getInvites() → {Promise.<Array.<Invite>>}
Get all invites in the channel
- Inherited From:
- Source:
Returns:
- Type:
-
Promise.<Array.<Invite>>
getMessage(messageID) → {Promise.<Message>}
Get a previous message in the channel
- Inherited From:
- Source:
Parameters:
| Name | Type | Description |
|---|---|---|
messageID |
String
|
The ID of the message |
Returns:
- Type:
-
Promise.<Message>
getMessageReaction(messageID, reaction, optionsopt, beforeopt, afteropt) → {Promise.<Array.<User>>}
Get a list of users who reacted with a specific reaction
- Inherited From:
- Source:
Parameters:
| Name | Type | Attributes | Description | ||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
messageID |
String
|
The ID of the message |
|||||||||||||||||||||
reaction |
String
|
The reaction (Unicode string if Unicode emoji, |
|||||||||||||||||||||
options |
Object
|
<optional> |
Options for the request. If this is a number, it is treated as
|
||||||||||||||||||||
before |
String
|
<optional> |
[DEPRECATED] Get users before this user ID. Discord no longer supports this parameter |
||||||||||||||||||||
after |
String
|
<optional> |
[DEPRECATED] Get users after this user ID |
Returns:
- Type:
-
Promise.<Array.<User>>
getMessages(optionsopt, beforeopt, afteropt, aroundopt) → {Promise.<Array.<Message>>}
Get previous messages in the channel
- Inherited From:
- Source:
Parameters:
| Name | Type | Attributes | Description | |||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
options |
Object
|
<optional> |
Options for the request. If this is a number ([DEPRECATED] behavior), it is treated as
|
|||||||||||||||||||||||||
before |
String
|
<optional> |
[DEPRECATED] Get messages before this message ID |
|||||||||||||||||||||||||
after |
String
|
<optional> |
[DEPRECATED] Get messages after this message ID |
|||||||||||||||||||||||||
around |
String
|
<optional> |
[DEPRECATED] Get messages around this message ID (does not work with limit > 100) |
Returns:
- Type:
-
Promise.<Array.<Message>>
getPollAnswerVoters(messageID, answerID, optionsopt) → {Promise.<Array.<User>>}
Get a list of users that voted for a specific poll answer
- Inherited From:
- Source:
Parameters:
| Name | Type | Attributes | Description | |||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
messageID |
String
|
The ID of the message that the poll is in |
||||||||||||||||
answerID |
Number
|
The ID of the answer to get voters for |
||||||||||||||||
options |
Object
|
<optional> |
Options for the request
|
join(optionsopt) → {Promise.<VoiceConnection>}
Joins the channel
- Inherited From:
- Source:
Parameters:
| Name | Type | Attributes | Description | ||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
options |
Object
|
<optional> |
VoiceConnection constructor options
|
leave()
Leaves the channel
- Inherited From:
- Source:
purge(options, filteropt, beforeopt, afteropt, reasonopt) → {Promise.<Number>}
Purge previous messages in the channel with an optional filter
- Inherited From:
- Source:
Parameters:
| Name | Type | Attributes | Description | ||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
options |
Object
|
Options for the request. If this is a number ([DEPRECATED] behavior), it is treated as
|
|||||||||||||||||||||||||
filter |
function
|
<optional> |
[DEPRECATED] Optional filter function that returns a boolean when passed a Message object |
||||||||||||||||||||||||
before |
String
|
<optional> |
[DEPRECATED] Get messages before this message ID |
||||||||||||||||||||||||
after |
String
|
<optional> |
[DEPRECATED] Get messages after this message ID |
||||||||||||||||||||||||
reason |
String
|
<optional> |
[DEPRECATED] The reason to be displayed in audit logs |
Returns:
- Type:
-
Promise.<Number>
Resolves with the number of messages deleted
removeMessageReaction(messageID, reaction, userIDopt) → {Promise}
Remove a reaction from a message
- Inherited From:
- Source:
Parameters:
| Name | Type | Attributes | Default | Description |
|---|---|---|---|---|
messageID |
String
|
The ID of the message |
||
reaction |
String
|
The reaction (Unicode string if Unicode emoji, |
||
userID |
String
|
<optional> |
"@me" |
The ID of the user to remove the reaction for |
Returns:
- Type:
-
Promise
removeMessageReactionEmoji(messageID, reaction) → {Promise}
Remove all reactions from a message for a single emoji
- Inherited From:
- Source:
Parameters:
| Name | Type | Description |
|---|---|---|
messageID |
String
|
The ID of the message |
reaction |
String
|
The reaction (Unicode string if Unicode emoji, |
Returns:
- Type:
-
Promise
removeMessageReactions(messageID) → {Promise}
Remove all reactions from a message
- Inherited From:
- Source:
Parameters:
| Name | Type | Description |
|---|---|---|
messageID |
String
|
The ID of the message |
Returns:
- Type:
-
Promise
sendSoundboardSound(options) → {Promise}
Send a soundboard sound to the voice channel
- Inherited From:
- Source:
Parameters:
| Name | Type | Description | ||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
options |
Object
|
The soundboard sound options
|
Returns:
- Type:
-
Promise
sendTyping() → {Promise}
Send typing status in the channel
- Inherited From:
- Source:
Returns:
- Type:
-
Promise
setStatus(status, reasonopt) → {Promise}
Set the status of the voice channel. Note: This will not work in stage channels
- Inherited From:
- Source:
Parameters:
| Name | Type | Attributes | Description |
|---|---|---|---|
status |
String
|
The new voice channel status |
|
reason |
String
|
<optional> |
The reason to be displayed in audit logs |
Returns:
- Type:
-
Promise
unsendMessage(messageID) → {Promise}
Un-send a message. You're welcome Programmix
- Inherited From:
- Source:
Parameters:
| Name | Type | Description |
|---|---|---|
messageID |
String
|
The ID of the message |
Returns:
- Type:
-
Promise