Push Notifications with existing server


#1

Hi there,

Is the only way to achieve this to detach?

We are overhauling an existing app that has a push notification solution, with everything already setup in GCM and APNS. I’m hoping to re-integrate without having to detach, but having not used Push Notifications before, I’m unsure the best approach


Expo Push Notifications at Amazon SNS
#2

hey, as far as I understand, If you want to use non-expo push services then you have to detach.

from this post it seems like expo needs some extra metadata to correctly send the notification to your javascript code. I’m not sure about the case where your server communicates directly with apple and google, but it seems like you need to detach for that.

if i’m correct and this is the only solution, Notification.getDevicePushTokenAsync() should be useful for setting things up (seems to not be in the docs for some reason).

More details about push notifications in detached app.


#3

@samee thank you for this and to the Expo team - that function was what I needed.

I’m now able to pass the GCM/APNS token to the third party push notification server - I get a valid token from both iOS and Android which should be all I need to get PN working for my app.

It looks like I won’t need to detach after all and I’ll get all of Expo’s benefits.

Best
David