Replace the editor content of an existing comment. Requires authentication, the DOCUMENTS feature flag, and ADMIN, EDIT_COMMENT, UPDATE_DOCUMENT, or MANAGE_DOCUMENTS permissions.
Editor JSON object containing the comment content, not a plain text string.
body.path*
string
Full Firestore path of the document or draft that owns the comments. Do not include /comments/:commentId or an /api prefix.
body.updatedAt
number
Last known comment update timestamp in milliseconds. Omit only when the comment has no stored updatedAt value (typically the first edit).
body.path selects the record whose comment collection and embedded comment metadata are updated. For a site draft, use sites/:siteId/S_:siteId/:siteId/documents/:documentId/versions/draft, replacing every placeholder with its actual ID. This Firestore path is distinct from the HTTP target path. The service requires updatedAt to exactly match the stored comment timestamp. A missing or stale value after an earlier edit returns HTTP 400. Replace the example timestamp with the current comment timestamp, or omit it for an unedited comment.
Edit Document Comment
Replace the editor content of an existing comment. Requires authentication, the DOCUMENTS feature flag, and ADMIN, EDIT_COMMENT, UPDATE_DOCUMENT, or MANAGE_DOCUMENTS permissions.
Parameters
documentId*commentId*body.comment*body.path*/comments/:commentIdor an/apiprefix.body.updatedAtupdatedAtvalue (typically the first edit).body.pathselects the record whose comment collection and embedded comment metadata are updated. For a site draft, usesites/:siteId/S_:siteId/:siteId/documents/:documentId/versions/draft, replacing every placeholder with its actual ID. This Firestore path is distinct from the HTTP target path. The service requiresupdatedAtto exactly match the stored comment timestamp. A missing or stale value after an earlier edit returns HTTP 400. Replace the example timestamp with the current comment timestamp, or omit it for an unedited comment.Return Value
HTTP 201 Created. The JSON body is:
Examples