Mark all unread messages in a thread as read

PUT /task/v1/comments/unread/update

Operation id: updateAllUnreadMessages

Description

Marks all unread messages (message_status=N) in a thread as read for the authenticated user's store. Updates only messages with assign_store=session.unitId.

Response variants:

  • Unread messages found and updated → {status: OK, unread_update: {msg_ids[], cluster_id, msg_main_id}}
  • No unread messages → {status: OK, message: "Unread messages updated successfully."}

Requires MSG_ACCESS line-of-sight authorization.

Tags: MyWorkComments

Security

  • AuthTokenHeader (apiKey)
    • Session authentication token validated server-side against the user session store.

Responses

200 — Success with updated messages → {status: OK, unread_update: {...}}.

No unread messages → {status: OK, message: "..."}.

Content type: application/json

400 — E121 — msg_main_id is mandatory / must be a valid integer

Content type: application/json

401 — Missing or invalid X-reflexis-csrf-token-X session token

Content type: application/json

500 — Unexpected server-side error

Content type: application/json

Request body

Required: Yes

application/x-www-form-urlencoded

Schema

PropertyTypeRequiredDescription
msg_main_idstringYesRoot/thread message ID — mandatory integer (E121 if missing or non-numeric)
{
  "type": "object",
  "required": [
    "msg_main_id"
  ],
  "properties": {
    "msg_main_id": {
      "type": "string",
      "description": "Root/thread message ID — mandatory integer (E121 if missing or non-numeric)"
    }
  }
}

Response models

200 — Success with updated messages → {status: OK, unread_update: {...}}.

No unread messages → {status: OK, message: "..."}.

Content type: application/json

Schema

JSON object (structure varies by endpoint).

{
  "type": "object",
  "description": "JSON object (structure varies by endpoint)."
}

400 — E121 — msg_main_id is mandatory / must be a valid integer

Content type: application/json

Schema

PropertyTypeRequiredDescription
statusstringYesAlways "ER" for error responses
errorCodestringYesApplication-level error code (e.g. E202, E105, E404)
responsestringYesHuman-readable error message
{
  "type": "object",
  "example": {
    "status": "ER",
    "errorCode": "E202",
    "response": "User session is invalid"
  },
  "required": [
    "status",
    "errorCode",
    "response"
  ],
  "properties": {
    "status": {
      "type": "string",
      "description": "Always \"ER\" for error responses",
      "enum": [
        "ER"
      ]
    },
    "errorCode": {
      "type": "string",
      "description": "Application-level error code (e.g. E202, E105, E404)"
    },
    "response": {
      "type": "string",
      "description": "Human-readable error message"
    }
  }
}

401 — Missing or invalid X-reflexis-csrf-token-X session token

Content type: application/json

Schema

PropertyTypeRequiredDescription
statusstringYesAlways "ER" for error responses
errorCodestringYesApplication-level error code (e.g. E202, E105, E404)
responsestringYesHuman-readable error message
{
  "type": "object",
  "example": {
    "status": "ER",
    "errorCode": "E202",
    "response": "User session is invalid"
  },
  "required": [
    "status",
    "errorCode",
    "response"
  ],
  "properties": {
    "status": {
      "type": "string",
      "description": "Always \"ER\" for error responses",
      "enum": [
        "ER"
      ]
    },
    "errorCode": {
      "type": "string",
      "description": "Application-level error code (e.g. E202, E105, E404)"
    },
    "response": {
      "type": "string",
      "description": "Human-readable error message"
    }
  }
}

Example:

{
  "status": "ER",
  "errorCode": "E202",
  "response": "User session is invalid"
}

500 — Unexpected server-side error

Content type: application/json

Schema

PropertyTypeRequiredDescription
statusstringYesAlways "ER" for error responses
errorCodestringYesApplication-level error code (e.g. E202, E105, E404)
responsestringYesHuman-readable error message
{
  "type": "object",
  "example": {
    "status": "ER",
    "errorCode": "E202",
    "response": "User session is invalid"
  },
  "required": [
    "status",
    "errorCode",
    "response"
  ],
  "properties": {
    "status": {
      "type": "string",
      "description": "Always \"ER\" for error responses",
      "enum": [
        "ER"
      ]
    },
    "errorCode": {
      "type": "string",
      "description": "Application-level error code (e.g. E202, E105, E404)"
    },
    "response": {
      "type": "string",
      "description": "Human-readable error message"
    }
  }
}

Example:

{
  "status": "ER",
  "errorCode": "E302",
  "response": "Internal server error"
}