0

Is there a way in which an Amazon kindle device can get the device token from FCM?

I mean, our app already works with FCM for Android and iOS devices, but particularly for Kindle devices (part of Android ecosystem) they never receive a token from FCM on FirebaseInstanceIdService.

The token is always null, then I can't have the device token to send the notification:

String refreshedToken = FirebaseInstanceId.getInstance().getToken(); //always null

How can I get that token?

Carlos Daniel
  • 2,459
  • 25
  • 30
  • Strange. Doesn't the `onTokenRefresh()` trigger a moment after you call `getToken()`? – AL. May 02 '18 at 01:05
  • 1
    It is indeed, I've tried different approaches: uninstalling the app to force a call to onTokenRefresh(), but never do it, and also calling directly FirebaseInstanceId.getInstance().getToken() in several parts, but nothing happens. I've been reading some Amazon Dev doc, and it looks like for Amazon's devices is required to implement the push notification features using their own Amazon libraries :( – Carlos Daniel May 03 '18 at 02:17

1 Answers1

0

Kindles don't have Google Services, they have Amazon ones instead. In particular, notification service called ADM (Amazon Device Messaging): https://developer.amazon.com/docs/adm/overview.html

You can consider using Amazon SNS instead of FCM. It is also able to deliver notifications to FCM and APNS. But the support is a point of concern. E.g. it still doesn't support Apple notification authentication keys introduced in 2015: https://forums.aws.amazon.com/thread.jspa?threadID=213538

Artem Kirienko
  • 185
  • 1
  • 6