# Delete member push notification token

`DELETE /api/members/{memberID}/push-notification-token`

- **Products:** Operator (`FOH`), Consumer (`CONSUMER`) (any one of these products, not all)
- **Features:** Online Bookings (`ONLINEBOOK`), Online Joining (`ONLINEJOIN`), Front of House Generic Access (`FOHGENERIC`) (any one of these features, not all)

HTML version: [Delete member push notification token](https://support.gladstonesoftware.cloud/reference/members/delete-member-push-notification-token)

## Overview

Unregisters a member's device from push notifications by deleting the stored device token. Call this when a member signs out of your app, uninstalls it, or opts out of notifications — otherwise the platform keeps sending to a token that is no longer valid.

A member can hold several registrations at once, one per app bundle, plus at most one registration with no bundle at all. Which registrations this call removes depends on `appBundleId`:

- **With `appBundleId`** — removes only the registration for that bundle. Other apps' registrations are untouched.
- **Without `appBundleId`** — removes only the registration that has no bundle recorded against it. Bundle-scoped registrations are deliberately left alone, so a single-app client cannot wipe the tokens another app registered for the same member.

That second rule is the trap: if the member's tokens were all registered *with* a bundle id and you call without one, nothing matches and you get `404` — not a silent success. Always send the same `appBundleId` you registered with.

A successful call returns `204 No Content`.

## Endpoint

`DELETE {base_url}/api/members/{memberID}/push-notification-token`

`{base_url}` is the environment URL issued to your integration. See [Authenticating with Gladstone APIs](../../guides/authenticating-with-gladstone-apis.md).

## Path parameters

| Name | Type | Required | Description |
|------|------|----------|-------------|
| `memberID` | integer (int32) | Yes | The member whose device registration you are removing. The member must exist — an unknown id gives `404` before any token lookup happens. When you call with a member-scoped token, this must be the member the token was issued for; linked members are not accepted here. |

## Query parameters

| Name | Type | Required | Description |
|------|------|----------|-------------|
| `appBundleId` | string | No | The bundle identifier of the app the device token was registered under — the same value you sent when creating the registration. It is lower-cased before matching, so case does not matter. Omit it (or send an empty or whitespace-only value, which is treated as omitted) to target the registration that has no bundle recorded; that will **not** match bundle-scoped registrations. There is no wildcard: you cannot remove every registration for a member in one call. |

## Sample request

```bash title="cURL"
curl -X DELETE '{base_url}/api/members/{memberID}/push-notification-token' \
  -H 'Authorization: Bearer {accessToken}' \
  -H 'X-Use-SSO: true'
```

## Errors

| Status | Meaning | When |
|--------|---------|------|
| `403` | Forbidden | The token identifies a specific member and `memberID` is not that member. The body is `The given member ID of {memberID} does not belong to the logged in member`. |
| `404` | Not found | `memberID` does not exist. The body is `The member does not exist.` |
| `404` | Not found | `appBundleId` was omitted and the member has no registration without a bundle id. The body is `The member does not have any push notification preferences set.` The member may still have bundle-scoped registrations — this is not proof that they have none. |
| `404` | Not found | `appBundleId` was supplied and the member has no registration under that bundle. The body is `The member does not have a push notification preference for the specified app bundle ID: {appBundleId}.` |
| `500` | Internal server error | An unexpected server-side failure while reading or deleting the registration. |
