Skip to content

Update a comment.

PUT
/api/workspace/comments/{commentId}
curl --request PUT \
--url https://example.com/api/workspace/comments/example \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{ "CommentText": "example", "OperationKey": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0", "RowVersion": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0", "Owner": { "ModuleKey": "example", "ResourceKind": "example", "ContextResourceId": "example", "ResourceObjectId": "example" }, "Mentions": [ { "UserId": "example", "StartIndex": 1, "Length": 1, "DisplayText": "example" } ], "MentionSurface": { "ModuleKey": "example", "ResourceKind": "example", "ContextResourceId": "example", "ResourceObjectId": "example" }, "UnlinkFileReferenceIds": [ "example" ] }'
commentId
required
string
access_token
string

Optional access token for clients that cannot set Authorization headers. Prefer Authorization: Bearer <token> when possible.

Request payload to update a comment.

object
CommentText

Updated comment text.

string
nullable
OperationKey

Caller-owned idempotency key. Required for Core Entity and provider-owned resource mutations.

string format: uuid
RowVersion

Expected comment row version. Required for Core Entity and provider-owned resource mutations.

string format: uuid
Owner

Stable identity of one Moltaro resource instance.

object
ModuleKey
string
nullable
ResourceKind
string
nullable
ContextResourceId
string
nullable
ResourceObjectId
string
nullable
Mentions

Replacement mentions embedded in Moltaro.Comments.Requests.UpdateCommentRequest.CommentText. Null preserves the current set.

Array<object>
nullable

Stable user mention embedded in comment text.

object
UserId

Mentioned user identifier.

string
nullable
StartIndex

Zero-based UTF-16 token start.

integer format: int32
Length

UTF-16 token length.

integer format: int32
DisplayText

Readable token stored in the comment text.

string
nullable
MentionSurface

Stable identity of one Moltaro resource instance.

object
ModuleKey
string
nullable
ResourceKind
string
nullable
ContextResourceId
string
nullable
ResourceObjectId
string
nullable
UnlinkFileReferenceIds

Placement links to remove from this message. File references and bodies are not deleted.

Array<string>
nullable
Examplegenerated
{
"CommentText": "example",
"OperationKey": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0",
"RowVersion": "2489E9AD-2EE2-8E00-8EC9-32D5F69181C0",
"Owner": {
"ModuleKey": "example",
"ResourceKind": "example",
"ContextResourceId": "example",
"ResourceObjectId": "example"
},
"Mentions": [
{
"UserId": "example",
"StartIndex": 1,
"Length": 1,
"DisplayText": "example"
}
],
"MentionSurface": {
"ModuleKey": "example",
"ResourceKind": "example",
"ContextResourceId": "example",
"ResourceObjectId": "example"
},
"UnlinkFileReferenceIds": [
"example"
]
}

OK

Media typeapplication/json
object
Data
object
Errors
Array<object>
nullable
object
Code
required
string
nullable
Message
required
string
nullable
Target
string
nullable
Field
string
nullable
Metadata
object
key
additional properties
string
nullable
Type
integer format: int32
Allowed values: 0 1 2
Severity
integer format: int32
Allowed values: 0 1 2
Warnings
Array<object>
nullable
object
Code
required
string
nullable
Message
required
string
nullable
Target
string
nullable
Field
string
nullable
Metadata
object
key
additional properties
string
nullable
Type
integer format: int32
Allowed values: 0 1 2
Severity
integer format: int32
Allowed values: 0 1 2
Success
boolean
Example
{
"Errors": [
{
"Type": 0,
"Severity": 0
}
],
"Warnings": [
{
"Type": 0,
"Severity": 0
}
]
}

Bad Request

Media typeapplication/json
object
Data

Comment details.

object
Id

Comment identifier.

string
nullable
Owner

Stable identity of one Moltaro resource instance.

object
ModuleKey
string
nullable
ResourceKind
string
nullable
ContextResourceId
string
nullable
ResourceObjectId
string
nullable
CommentText

Comment text.

string
nullable
DetectedLanguage

Detected language for search.

string
nullable
Quote

A flat quote. Unavailable sources expose no identifier, text or version.

object
Available

Whether the source is currently readable and active.

boolean
CommentId

Authorized source identifier.

string
nullable
Text

Server snapshot, or current source text for a historical link without a snapshot.

string
nullable
SourceVersion

Version captured with the snapshot.

string format: uuid
nullable
IsSnapshot

False for migrated historical links.

boolean
Relations

Resource relations attached to the comment.

Array<object>
nullable

Stored relation between one content item and a target resource.

object
Id
string
nullable
Target

Stable identity of one Moltaro resource instance.

object
ModuleKey
string
nullable
ResourceKind
string
nullable
ContextResourceId
string
nullable
ResourceObjectId
string
nullable
RelationKind

Relation kind between content and a resource.

integer format: int32
Allowed values: 0
Source

Stable identity of one Moltaro resource instance.

object
ModuleKey
string
nullable
ResourceKind
string
nullable
ContextResourceId
string
nullable
ResourceObjectId
string
nullable
PolicyCode
string
nullable
CorrelationId
string
nullable
CreatedByUserId
string
nullable
CreatedAt
string format: date-time
DeletedAt
string format: date-time
nullable
Origin

Stored technical origin metadata for content created through another resource context.

object
Source

Stable identity of one Moltaro resource instance.

object
ModuleKey
string
nullable
ResourceKind
string
nullable
ContextResourceId
string
nullable
ResourceObjectId
string
nullable
PolicyCode
string
nullable
CorrelationId
string
nullable
CreatedByUserId

Creator user identifier.

string
nullable
CreatedByUserName

Creator display name.

string
nullable
ModifiedByUserId

Last modifier user identifier.

string
nullable
ModifiedByUserName

Last modifier display name.

string
nullable
EditDeadline

Edit deadline timestamp.

string format: date-time
nullable
IsEdited

Whether the comment has been edited.

boolean
CreatedAt

Creation timestamp.

string format: date-time
ModifiedAt

Last modification timestamp.

string format: date-time
nullable
IsDeleted

Whether the comment is soft deleted.

boolean
RowVersion

Deterministic concurrency token for comment mutations.

string format: uuid
Mentions

Stable user mentions embedded in the text.

Array<object>
nullable

Materialized user mention embedded in a comment.

object
UserId
string
nullable
UserName
string
nullable
DisplayName
string
nullable
StartIndex
integer format: int32
Length
integer format: int32
DisplayText
string
nullable
Permissions

Permissions for a comment evaluated for the current user.

object
CanView

Whether the comment can be viewed.

boolean
CanEdit

Whether the comment can be edited.

boolean
CanDelete

Whether the comment can be deleted.

boolean
CanReply

Whether a reply can be created.

boolean
Files

Currently readable linked file placements in message order.

Array<object>
nullable
object
Id
required
string
FolderId
required
string
Owner
object
ModuleKey
required
string
ResourceKind
required
string
ContextResourceId
required
string
ResourceObjectId
required
string
Relations
required
Array<object>

Stored relation between one content item and a target resource.

object
Id
string
nullable
Target

Stable identity of one Moltaro resource instance.

object
ModuleKey
string
nullable
ResourceKind
string
nullable
ContextResourceId
string
nullable
ResourceObjectId
string
nullable
RelationKind

Relation kind between content and a resource.

integer format: int32
Allowed values: 0
Source

Stable identity of one Moltaro resource instance.

object
ModuleKey
string
nullable
ResourceKind
string
nullable
ContextResourceId
string
nullable
ResourceObjectId
string
nullable
PolicyCode
string
nullable
CorrelationId
string
nullable
CreatedByUserId
string
nullable
CreatedAt
string format: date-time
DeletedAt
string format: date-time
nullable
Origin
Any of:

Stored technical origin metadata for content created through another resource context.

object
Source

Stable identity of one Moltaro resource instance.

object
ModuleKey
string
nullable
ResourceKind
string
nullable
ContextResourceId
string
nullable
ResourceObjectId
string
nullable
PolicyCode
string
nullable
CorrelationId
string
nullable
IsDeleted
required
boolean
EditDeadline
required
string format: date-time
RowVersion
required
string format: uuid
Descriptor
required
object
Id
required
string
FileName
required
string
Description
string
nullable
MimeType
required
string
StorageType
required
integer format: int32
Allowed values: 0 1 2 3 4 5
AvailabilityState
required
integer format: int32
Allowed values: 0 1 2 3 4
DetectedMimeType
string
nullable
ImageWidth
integer format: int32
nullable
ImageHeight
integer format: int32
nullable
ContentGeneration
required
integer format: int64
InspectedChecksumSha256
string
nullable
InspectedContentGeneration
integer format: int64
nullable
SizeBytes
required
integer format: int64
ChecksumSha256
required
string
CreatedAt
required
string format: date-time
ModifiedAt
string format: date-time
nullable
CreatedByUserId
string
nullable
CreatedByUserName
string
nullable
ModifiedByUserId
string
nullable
ModifiedByUserName
string
nullable
Errors
Array<object>
nullable
object
Code
required
string
nullable
Message
required
string
nullable
Target
string
nullable
Field
string
nullable
Metadata
object
key
additional properties
string
nullable
Type
integer format: int32
Allowed values: 0 1 2
Severity
integer format: int32
Allowed values: 0 1 2
Warnings
Array<object>
nullable
object
Code
required
string
nullable
Message
required
string
nullable
Target
string
nullable
Field
string
nullable
Metadata
object
key
additional properties
string
nullable
Type
integer format: int32
Allowed values: 0 1 2
Severity
integer format: int32
Allowed values: 0 1 2
Success
boolean
Example
{
"Data": {
"Relations": [
{
"RelationKind": 0
}
],
"Files": [
{
"Relations": [
{
"RelationKind": 0
}
],
"Origin": null,
"Descriptor": {
"StorageType": 0,
"AvailabilityState": 0
}
}
]
},
"Errors": [
{
"Type": 0,
"Severity": 0
}
],
"Warnings": [
{
"Type": 0,
"Severity": 0
}
]
}

Forbidden

Media typeapplication/json
object
type
string
nullable
title
string
nullable
status
integer format: int32
nullable
detail
string
nullable
instance
string
nullable
key
additional properties
Examplegenerated
{
"type": "example",
"title": "example",
"status": 1,
"detail": "example",
"instance": "example"
}

Not Found

Media typeapplication/json
object
Data

Comment details.

object
Id

Comment identifier.

string
nullable
Owner

Stable identity of one Moltaro resource instance.

object
ModuleKey
string
nullable
ResourceKind
string
nullable
ContextResourceId
string
nullable
ResourceObjectId
string
nullable
CommentText

Comment text.

string
nullable
DetectedLanguage

Detected language for search.

string
nullable
Quote

A flat quote. Unavailable sources expose no identifier, text or version.

object
Available

Whether the source is currently readable and active.

boolean
CommentId

Authorized source identifier.

string
nullable
Text

Server snapshot, or current source text for a historical link without a snapshot.

string
nullable
SourceVersion

Version captured with the snapshot.

string format: uuid
nullable
IsSnapshot

False for migrated historical links.

boolean
Relations

Resource relations attached to the comment.

Array<object>
nullable

Stored relation between one content item and a target resource.

object
Id
string
nullable
Target

Stable identity of one Moltaro resource instance.

object
ModuleKey
string
nullable
ResourceKind
string
nullable
ContextResourceId
string
nullable
ResourceObjectId
string
nullable
RelationKind

Relation kind between content and a resource.

integer format: int32
Allowed values: 0
Source

Stable identity of one Moltaro resource instance.

object
ModuleKey
string
nullable
ResourceKind
string
nullable
ContextResourceId
string
nullable
ResourceObjectId
string
nullable
PolicyCode
string
nullable
CorrelationId
string
nullable
CreatedByUserId
string
nullable
CreatedAt
string format: date-time
DeletedAt
string format: date-time
nullable
Origin

Stored technical origin metadata for content created through another resource context.

object
Source

Stable identity of one Moltaro resource instance.

object
ModuleKey
string
nullable
ResourceKind
string
nullable
ContextResourceId
string
nullable
ResourceObjectId
string
nullable
PolicyCode
string
nullable
CorrelationId
string
nullable
CreatedByUserId

Creator user identifier.

string
nullable
CreatedByUserName

Creator display name.

string
nullable
ModifiedByUserId

Last modifier user identifier.

string
nullable
ModifiedByUserName

Last modifier display name.

string
nullable
EditDeadline

Edit deadline timestamp.

string format: date-time
nullable
IsEdited

Whether the comment has been edited.

boolean
CreatedAt

Creation timestamp.

string format: date-time
ModifiedAt

Last modification timestamp.

string format: date-time
nullable
IsDeleted

Whether the comment is soft deleted.

boolean
RowVersion

Deterministic concurrency token for comment mutations.

string format: uuid
Mentions

Stable user mentions embedded in the text.

Array<object>
nullable

Materialized user mention embedded in a comment.

object
UserId
string
nullable
UserName
string
nullable
DisplayName
string
nullable
StartIndex
integer format: int32
Length
integer format: int32
DisplayText
string
nullable
Permissions

Permissions for a comment evaluated for the current user.

object
CanView

Whether the comment can be viewed.

boolean
CanEdit

Whether the comment can be edited.

boolean
CanDelete

Whether the comment can be deleted.

boolean
CanReply

Whether a reply can be created.

boolean
Files

Currently readable linked file placements in message order.

Array<object>
nullable
object
Id
required
string
FolderId
required
string
Owner
object
ModuleKey
required
string
ResourceKind
required
string
ContextResourceId
required
string
ResourceObjectId
required
string
Relations
required
Array<object>

Stored relation between one content item and a target resource.

object
Id
string
nullable
Target

Stable identity of one Moltaro resource instance.

object
ModuleKey
string
nullable
ResourceKind
string
nullable
ContextResourceId
string
nullable
ResourceObjectId
string
nullable
RelationKind

Relation kind between content and a resource.

integer format: int32
Allowed values: 0
Source

Stable identity of one Moltaro resource instance.

object
ModuleKey
string
nullable
ResourceKind
string
nullable
ContextResourceId
string
nullable
ResourceObjectId
string
nullable
PolicyCode
string
nullable
CorrelationId
string
nullable
CreatedByUserId
string
nullable
CreatedAt
string format: date-time
DeletedAt
string format: date-time
nullable
Origin
Any of:

Stored technical origin metadata for content created through another resource context.

object
Source

Stable identity of one Moltaro resource instance.

object
ModuleKey
string
nullable
ResourceKind
string
nullable
ContextResourceId
string
nullable
ResourceObjectId
string
nullable
PolicyCode
string
nullable
CorrelationId
string
nullable
IsDeleted
required
boolean
EditDeadline
required
string format: date-time
RowVersion
required
string format: uuid
Descriptor
required
object
Id
required
string
FileName
required
string
Description
string
nullable
MimeType
required
string
StorageType
required
integer format: int32
Allowed values: 0 1 2 3 4 5
AvailabilityState
required
integer format: int32
Allowed values: 0 1 2 3 4
DetectedMimeType
string
nullable
ImageWidth
integer format: int32
nullable
ImageHeight
integer format: int32
nullable
ContentGeneration
required
integer format: int64
InspectedChecksumSha256
string
nullable
InspectedContentGeneration
integer format: int64
nullable
SizeBytes
required
integer format: int64
ChecksumSha256
required
string
CreatedAt
required
string format: date-time
ModifiedAt
string format: date-time
nullable
CreatedByUserId
string
nullable
CreatedByUserName
string
nullable
ModifiedByUserId
string
nullable
ModifiedByUserName
string
nullable
Errors
Array<object>
nullable
object
Code
required
string
nullable
Message
required
string
nullable
Target
string
nullable
Field
string
nullable
Metadata
object
key
additional properties
string
nullable
Type
integer format: int32
Allowed values: 0 1 2
Severity
integer format: int32
Allowed values: 0 1 2
Warnings
Array<object>
nullable
object
Code
required
string
nullable
Message
required
string
nullable
Target
string
nullable
Field
string
nullable
Metadata
object
key
additional properties
string
nullable
Type
integer format: int32
Allowed values: 0 1 2
Severity
integer format: int32
Allowed values: 0 1 2
Success
boolean
Example
{
"Data": {
"Relations": [
{
"RelationKind": 0
}
],
"Files": [
{
"Relations": [
{
"RelationKind": 0
}
],
"Origin": null,
"Descriptor": {
"StorageType": 0,
"AvailabilityState": 0
}
}
]
},
"Errors": [
{
"Type": 0,
"Severity": 0
}
],
"Warnings": [
{
"Type": 0,
"Severity": 0
}
]
}