---
title: "Clear your notifications"
description: "Empties the bell, as Clear notifications in the app does."
url: "https://nextmail.sh/docs/api/notifications/clear"
area: "API"
category: "Your account"
---

# Clear your notifications

Empties the bell, as Clear notifications in the app does.

`POST /notifications/clear`

## POST /notifications/clear

Empties the bell, as Clear notifications in the app does.

## Keep open invitations

Needs `account:write`, and the body is optional. Every notification goes except those of invitations that are still open, which keep waiting for an answer. `openInvitations` counts them.

**curl**

```
curl -X POST "$API/notifications/clear" -H "$AUTH"
```

**Response**

```
{ "object": "notifications_cleared", "cleared": 4, "declinedInvitations": 0, "openInvitations": 1, "unreadCount": 1 }
```

## Decline them too

`declineInvitations: true` declines every open invitation first, as declining one does, and whoever sent it is told. A declined invitation cannot be accepted, so only a new invitation brings the person in.

**curl**

```
curl -X POST "$API/notifications/clear" -H "$AUTH" \
  -H "Content-Type: application/json" -d '{ "declineInvitations": true }'
```

**Response**

```
{ "object": "notifications_cleared", "cleared": 5, "declinedInvitations": 1, "openInvitations": 0, "unreadCount": 0 }
```

## Reference

- [`POST /notifications/clear`](https://nextmail.sh/docs/api/reference/your-account#post-notifications-clear): full reference
