Handle push tokens
Last updated
Was this helpful?
Last updated
Was this helpful?
Was this helpful?
void updateToken(@NonNull final Context context,
@Nullable final String token) {
final ProvisioningBusinessService provisioningService =
ProvisioningServiceManager.getProvisioningBusinessService();
provisioningService.updatePushToken(token, new PushServiceListener() {
@Override
public void onComplete() {
// Success
}
@Override
public void onError(final ProvisioningServiceError provisioningServiceError) {
// Handle error.
}
@Override
public void onUnsupportedPushContent(final Bundle bundle) {
// Not relevant for push token updates.
}
@Override
public void onServerMessage(final String message, final ProvisioningServiceMessage provisioningServiceMessage) {
// Not relevant for push token updates.
}
});
}