deleteToken

abstract suspend fun deleteToken(deviceId: String): Boolean

Removes the device’s push-notification association on the backend.

Call this when the member turns push notifications off. It needs the member's session, so call it before authentication().logout(), never after. logout() removes the last registration made with updateToken itself, but only while the access token is still valid; call this first when the removal must happen, or before a different member signs in without logout(). Removing another install's id, such as a stale registration, keeps this install's registration and the token getToken falls back to.

Return

true if the backend answered with a 2xx; false when the request failed or was refused.

Parameters

deviceId

The stable identifier used during updateToken.