Skip to content

Commit

Permalink
new message field
Browse files Browse the repository at this point in the history
  • Loading branch information
msciotti committed Mar 3, 2021
1 parent 873e887 commit ddc0d13
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 0 deletions.
11 changes: 11 additions & 0 deletions docs/interactions/Slash_Commands.md
Original file line number Diff line number Diff line change
Expand Up @@ -877,3 +877,14 @@ Not all message fields are currently supported.
| embeds? | array of [embeds](#DOCS_RESOURCES_CHANNEL/embed-object) | supports up to 10 embeds |
| allowed_mentions? | allowed mentions | [allowed mentions](#DOCS_RESOURCES_CHANNEL/allowed-mentions-object) object |
| flags? | int | set to `64` to make your response ephemeral |

## MessageInteraction

This is sent on the [message object](#DOCS_RESOURCES_CHANNEL/message-object) when the message is a response to an Interaction.

| Name | Value | Description |
| --- | --- | --- |
| id | snowflake | id of the interaction |
| type | InteractionType | the type of interaction |
| name | string | the name of the [ApplicationCommand](#DOCS_INTERACTIONS_SLASH_COMMANDS/applicationcommand) |
| user | [user object](#DOCS_RESOURCES_USER/user-object) | the user who invoked the interaction |
1 change: 1 addition & 0 deletions docs/resources/Channel.md
Original file line number Diff line number Diff line change
Expand Up @@ -204,6 +204,7 @@ Represents a message sent in a channel within Discord.
| flags? | integer | [message flags](#DOCS_RESOURCES_CHANNEL/message-object-message-flags) combined as a [bitfield](https://en.wikipedia.org/wiki/Bit_field) |
| stickers? | array of [sticker](#DOCS_RESOURCES_CHANNEL/message-object-message-sticker-structure) objects | the stickers sent with the message (bots currently can only receive messages with stickers, not send) |
| referenced_message?\*\*\*\*\* | ?[message object](#DOCS_RESOURCES_CHANNEL/message-object) | the message associated with the message_reference |
| interaction? | [message interaction object](#DOCS_INTERACTIONS_SLASH_COMMANDS/messageinteraction) | sent if the message is a response to an [Interaction](#DOCS_INTERACTIONS_SLASH_COMMANDS/) |

\* The author object follows the structure of the user object, but is only a valid user in the case where the message is generated by a user or bot user. If the message is generated by a webhook, the author object corresponds to the webhook's id, username, and avatar. You can tell if a message is generated by a webhook by checking for the `webhook_id` on the message object.

Expand Down

0 comments on commit ddc0d13

Please sign in to comment.