Skip to content

Commit 86641ea

Browse files
shaydewaelSam Shihvaldotle
authored
Message forwarding (#6833)
* [docs] Message Forwards feature Add documentation for message forwards. A message forward gives users the ability to send a snapshot of a message in one channel to another channel. - snapshots are immutable, and do not receive updates from the original message (unlike replies) - similar to a REPLY message, a forward is created using a `message_reference` # Examples ## Responses ```json { "author": { "id": 123456789012345678, }, "message_reference": { "type": 1, // FORWARD "message_id": 123456789012345678, "channel_id": 123456789012345678, "guild_id": 123456789012345678 }, "message_snapshot": { "content": "hello world", "embeds": [ // Embed objects ], "attachments": [ // Attachment objects ], } } ``` * udpate how reference pseudo types are defined * multi snapshots + forward restrictions * table formatting lint is too damn sensitive * field name split blockquotes * better formatting and some grammer cleanups * add changelog * suggestion updates * Update docs/resources/Channel.md Co-authored-by: val.le <81811276+valdotle@users.noreply.github.com> * Update docs/resources/Channel.md Co-authored-by: val.le <81811276+valdotle@users.noreply.github.com> * Update docs/resources/Channel.md Co-authored-by: val.le <81811276+valdotle@users.noreply.github.com> * Update docs/resources/Channel.md Co-authored-by: val.le <81811276+valdotle@users.noreply.github.com> --------- Co-authored-by: Sam Shih <shih@discordapp.com> Co-authored-by: val.le <81811276+valdotle@users.noreply.github.com>
1 parent d881693 commit 86641ea

File tree

4 files changed

+161
-71
lines changed

4 files changed

+161
-71
lines changed

docs/Change_Log.md

Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,43 @@
11
# Change Log
22

3+
## Message Forwarding rollout
4+
5+
#### July 15, 2024
6+
7+
We are slowly rolling out the message forwarding feature to users. This feature allows callers to create a message using `message_reference.type = FORWARD` and have the API generate a `message_snapshot` for the sent message. The feature has [some limitations](#DOCS_RESOURCES_CHANNEL/message-reference-types) and the snapshot is a minimal version of a standard `MessageObject`, but does capture the core parts of a message.
8+
9+
The resulting message will look something like:
10+
```json
11+
{
12+
"id": "1255957733279273083",
13+
"message_reference": {
14+
"type": 1, // Forward
15+
...
16+
}
17+
"message_snapshots": [
18+
{
19+
"message": {
20+
"content": "original message",
21+
"embeds": [...],
22+
"attachments": [...],
23+
...
24+
}
25+
}
26+
],
27+
...
28+
}
29+
```
30+
31+
We have applied stricter rate limits for this feature based on the following:
32+
- number of forwards sent by the user
33+
- total attachment size
34+
35+
###### API Updates since preview
36+
37+
This was [previously announced](https://discord.com/channels/613425648685547541/697138785317814292/1233463756160503859) but note that the final API has a few changes since the API was first previewed:
38+
- [`message snapshot`](#DOCS_RESOURCES_CHANNEL/message-snapshot-object) objects don't include a `guild` field anymore since the `message_reference` already provides that information
39+
- forwarded messages have a distinctive `message_reference` type of `FORWARD` now
40+
341
## User-Installed Apps General Availability
442

543
#### June 27, 2024

docs/interactions/Receiving_and_Responding.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -154,7 +154,7 @@ All options have names, and an option can either be a parameter and input value-
154154
This is sent on the [message object](#DOCS_RESOURCES_CHANNEL/message-object) when the message is a response to an Interaction without an existing message.
155155

156156
> info
157-
> This means responses to [Message Components](#DOCS_INTERACTIONS_MESSAGE_COMPONENTS/) do not include this property, instead including a [message reference](#DOCS_RESOURCES_CHANNEL/message-reference-object-message-reference-structure) object as components _always_ exist on preexisting messages.
157+
> This means responses to [Message Components](#DOCS_INTERACTIONS_MESSAGE_COMPONENTS/) do not include this property, instead including a [message reference](#DOCS_RESOURCES_CHANNEL/message-reference-structure) object as components _always_ exist on preexisting messages.
158158
159159
###### Message Interaction Structure
160160

0 commit comments

Comments
 (0)