When running this:
import { Permissions, Notifications } from 'expo'
// check for permission is 'granted' passes
const token = await Notifications.getExpoPushTokenAsync()
I’m getting this error in my standalone app (I see the message on Sentry):
Couldn’t get GCM token for device
I am checking for permissions with await Permissions.askAsync(Permissions.NOTIFICATIONS)
and getting status: 'granted'
.
This is for an Android standalone app on Expo SDK 32.0.0.
I have followed the steps to start using FCM and my app.json
has the following in the android
section:
"permissions": [
"CAMERA",
"ACCESS_FINE_LOCATION",
"ACCESS_COARSE_LOCATION",
"READ_EXTERNAL_STORAGE",
"READ_INTERNAL_STORAGE",
"VIBRATE",
"WAKE_LOCK",
"READ_PHONE_STATE",
"com.google.android.c2dm.permission.RECEIVE"
],
"googleServicesFile": "./google-services.json",
Any ideas why I’m getting an error?