Skip to content

Mark notifications as read

PUT
/notifications

Marks all notifications as “read” for the current user. If the number of notifications is too large to complete in one request, you will receive a 202 Accepted status and GitHub will run an asynchronous process to mark notifications as “read.” To check whether any “unread” notifications remain, you can use the List notifications for the authenticated user endpoint and pass the query parameter all=false.

API method documentation

Media type application/json
object
last_read_at

Describes the last point that notifications were checked. Anything updated since this time will not be marked as read. If you omit this parameter, all notifications are marked as read. This is a timestamp in ISO 8601 format: YYYY-MM-DDTHH:MM:SSZ. Default: The current timestamp.

string format: date-time
read

Whether the notification has been read.

boolean
Examples
Example default
{
"last_read_at": "2022-06-10T00:00:00Z",
"read": true
}

Response

Media type application/json
object
message
string
Examples
Example default
{
"message": "Unread notifications couldn't be marked in a single request. Notifications are being marked as read in the background."
}

Reset Content

Not modified

Requires authentication

Media type application/json
Basic Error

Basic Error

object
message
string
documentation_url
string
url
string
status
string
Example generated
{
"message": "example",
"documentation_url": "example",
"url": "example",
"status": "example"
}

Forbidden

Media type application/json
Basic Error

Basic Error

object
message
string
documentation_url
string
url
string
status
string
Example generated
{
"message": "example",
"documentation_url": "example",
"url": "example",
"status": "example"
}