Skip to content
This repository was archived by the owner on Aug 10, 2026. It is now read-only.

Commit 9236f1a

Browse files
committed
annotations: add sentence clarifying getMessage/history includes latest summary
1 parent 1168c44 commit 9236f1a

1 file changed

Lines changed: 4 additions & 2 deletions

File tree

src/pages/docs/messages/annotations.mdx

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -505,9 +505,11 @@ await channel.annotations.delete(message.serial, annotation)
505505

506506
## Subscribe to annotation summaries <a id="subscribe" />
507507

508-
The simplest way to receive annotation updates is via annotation summaries. A message that has annotations also includes a summary which is a synopsis of certain details of all annotations for that message. Summaries are updated in response to further annotation events for that message, and summary changes are delivered by default to subscribing clients.
508+
The simplest way to receive annotation updates is via annotation summaries. A message that has annotations also includes a summary, which is a synopsis of certain details of all annotations for that message. Summaries are updated in response to further annotation events for that message, and summary changes are delivered by default to subscribing clients.
509509

510-
Annotation summaries are delivered to subscribers as messages with an `action` of `message.summary`, and a `serial` matching the `serial` of the message that they are updating. They have an `annotations` field which contains a `summary` of all the annotations for the message.
510+
When an already-existing message has an updated summary, the new version of that message will be delivered to subscribers with an [`action`](/docs/api/realtime-sdk/types#action) of `message.summary` (as opposed to `message.create` for the originally-published one), and a `serial` matching the `serial` of the original message. It will have an `annotations` field which contains a `summary` of all the annotations for the message.
511+
512+
If you're not subscribing, you also retrieve the current version of a message, including the latest version of its summary, using [`channel.getMessage()`](/docs/api/rest-sdk/channels#get-message). Messages returned from [history](/docs/storage-history/history) also include the latest summary at the time the history request is made.
511513

512514
The value of that `summary` field is an object where the keys are the [annotation types](#annotation-types). The structure of the value of each key depends on the summarization method used, for example `total.v1` will have a `total` field, while `flag.v1` will have `total` and `clientIds` fields.
513515

0 commit comments

Comments
 (0)