Update read/unread status for a single message

PUT /task/v1/comments/unread/count

Operation id: updateMessageStatus

Description

Updates the read/unread status of a single message. When msg_parent_id=0 (top-level), cascades the update to all child messages.

Session-derived defaults (client can override): time_zone → session short TZ; local_code → session langCode; logged_unit_id → session unitId.

userId is always from session (prevents identity spoofing). Blank msg_status → defaults to R (read) inside the service. 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 — {status: OK, message: "Status updated successfully."}

Content type: application/json

400 — E120 — msg_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_idstringYesID of the message to update — mandatory integer (E120 if missing or non-numeric)
msg_parent_idstringNoParent message ID; 0 = cascade to all children in thread (default 0)
msg_statusstringNoNew status: N=unread, R=read. Blank defaults to R (read) in service.
local_codestringNoLocale/language code for ETL datetime formatting (defaults to session langCode)
time_zonestringNoTimezone string for datetime resolution (defaults to session short TZ)
logged_unit_idstringNoStore/unit ID for assignStore WHERE clause (defaults to session unitId)
{
  "type": "object",
  "required": [
    "msg_id"
  ],
  "properties": {
    "msg_id": {
      "type": "string",
      "description": "ID of the message to update — mandatory integer (E120 if missing or non-numeric)"
    },
    "msg_parent_id": {
      "type": "string",
      "description": "Parent message ID; 0 = cascade to all children in thread (default 0)"
    },
    "msg_status": {
      "type": "string",
      "description": "New status: N=unread, R=read. Blank defaults to R (read) in service.",
      "enum": [
        "N",
        "R"
      ]
    },
    "local_code": {
      "type": "string",
      "description": "Locale/language code for ETL datetime formatting (defaults to session langCode)"
    },
    "time_zone": {
      "type": "string",
      "description": "Timezone string for datetime resolution (defaults to session short TZ)"
    },
    "logged_unit_id": {
      "type": "string",
      "description": "Store/unit ID for assignStore WHERE clause (defaults to session unitId)"
    }
  }
}

Response models

200 — Success — {status: OK, message: "Status updated successfully."}

Content type: application/json

Schema

JSON object (structure varies by endpoint).

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

400 — E120 — msg_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"
}