From c07f5e4805067d0f52203371838e9e2eddf9ee08 Mon Sep 17 00:00:00 2001 From: Simon Woolf Date: Thu, 12 Mar 2026 18:15:19 +0000 Subject: [PATCH] Appends: note about append on a new attachment, remove note about continuous history not being supported yet --- src/pages/docs/messages/annotations.mdx | 2 -- src/pages/docs/messages/updates-deletes.mdx | 4 ++-- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/src/pages/docs/messages/annotations.mdx b/src/pages/docs/messages/annotations.mdx index 4931ae8331..929f7cb6c5 100644 --- a/src/pages/docs/messages/annotations.mdx +++ b/src/pages/docs/messages/annotations.mdx @@ -23,8 +23,6 @@ Annotations can be enabled for a channel or channel namespace with the *Message 1. Go to the **Settings** tab of an app in your dashboard. diff --git a/src/pages/docs/messages/updates-deletes.mdx b/src/pages/docs/messages/updates-deletes.mdx index 3c9cdf4757..bc396a07b0 100644 --- a/src/pages/docs/messages/updates-deletes.mdx +++ b/src/pages/docs/messages/updates-deletes.mdx @@ -27,8 +27,6 @@ Message updates and deletes can be enabled for a channel or channel namespace wi 1. Go to the **Settings** tab of an app in your dashboard. @@ -411,6 +409,8 @@ If you are publishing appends at a high rate, use a [Realtime](/docs/api/realtim When Ably receives an append, it concatenates the provided data with the current latest version to calculate a full (non-incremental) version of the message. That version (with an action of `message.update`) is then used in contexts like [History](/docs/storage-history/history) and [rewind](/docs/channels/options/rewind), so that when using those APIs, you will always receive complete messages without needing to do any concatenation yourself, and can specify e.g. `rewind=10` to get the most recent 10 full, distinct messages. +The first append you receive for a given message on an attachment is delivered as a fully-aggregated `message.update`, so that you don't need to reach into history to discover the full prior state of the message. You can then just concatenate the payloads of any subsequent `message.append`s for that message onto that first one to get the full payload. Note that Ably may at any time deliver an append as a `message.update` with the full rolled-up payload, so you should always check the `action` field to know whether to concatenate onto the existing payload or replace it. + ### Comparison with update | Aspect | `updateMessage()` | `appendMessage()` |