Skip to content

Mark notifications as read

PATCH
/notifications/central/read
curl --request PATCH \
--url https://work.optidata.cloud/api/notifications/central/read \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{}'

Marks one notification as read when userNotificationId is given, or every unread notification of the caller when it is omitted.

Media typeapplication/json
object
userNotificationId

Id of a single notification. Omit to mark all of the caller’s unread notifications.

integer | null format: int64
Examples

Mark everything read

{}

Confirmation message.

Media typeapplication/json

Generic error envelope used by policy, binding and framework failures.

object
message
required

Human-readable description of the failure.

string
Examples
Exampleok
{
"message": "Notification marked as read."
}

Missing, malformed or expired authentication key.

Media typeapplication/json

Authentication failures use an error key rather than message.

object
error
required
string
Examples
Examplemissing

No bearer token sent

{
"error": "JWT passport exception: Missing bearer token in request"
}

The request body or query string failed validation.

Media typeapplication/json
object
message
required

The first validation message.

string
errors
required

Validation messages keyed by field name.

object
key
additional properties
Array<string>
Examples
Exampleinvalid
{
"message": "The name field is required.",
"errors": {
"name": [
"The name field is required."
]
}
}

Rate limit exceeded. Retry after the window resets.

Media typeapplication/json

Generic error envelope used by policy, binding and framework failures.

object
message
required

Human-readable description of the failure.

string
Examples
Examplethrottled
{
"message": "Too Many Attempts."
}