Skip to content

Area: Developers

POST

Mark all messages as read

Path
/inbox/messages/read-all
Auth
Access token · browser or app
POST
/inbox/messages/read-all
curl --request POST \
--url https://releva.ai/api/v0/inbox/messages/read-all \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{ "userId": "DEMO-CUSTOMER-1001" }'

Marks every unread message of the shopper as read and records one inboxMessageRead event per message. Answers 202 also when nothing was unread.

Send as application/json. Without that content type the body is not read and the call answers 400.

Media typeapplication/json
object
userId
required
string
>= 1 characters <= 96 characters

Example

{
"userId": "DEMO-CUSTOMER-1001"
}

Accepted for asynchronous processing.

Media typeapplication/json
object
0

Example

{}

Authentication error, or userId missing or longer than 96 characters.

Media typeapplication/json
object
message
required

Human-readable error. Several validation errors are joined with a space.

string

Examples

{
"message": "Authorization header is missing",
"and accessToken url parameters is also missing. At least one of them is required.": null
}

The domain is disabled.

Media typeapplication/json
object
message
required

Human-readable error. Several validation errors are joined with a space.

string

Example

{
"message": "Domain is disabled. Please reach out to support@releva.ai to enable it."
}

Unexpected error. Currently also returned for malformed input: a messageId that is not a UUID, a userId that is not a string, userId only in the query string of a POST or DELETE, or a negative limit.

Media typeapplication/json
object
message
required

Human-readable error. Several validation errors are joined with a space.

string

Example

{
"message": "An internal error occurred."
}