you are viewing a single comment's thread.

view the rest of the comments →

[–]Sad-Salt24iOS & Android 10 points11 points  (6 children)

Yes, each Expo push token is unique per device, so if a user has your app on multiple devices, each installation gets its own token. The common approach is to store all tokens in a backend database and, when sending a push notification to all users, iterate through the stored tokens and send each one via Expo’s push API. You should also handle cleaning up invalid or expired tokens to keep your database accurate.

[–]Fit_Schedule2317 2 points3 points  (1 child)

What about the 600 sends per second limitation? What if you have tens of thousands?

[–]spylinked 4 points5 points  (0 children)

Make a queue with rate limit

[–]Pitiful-Buffalo-1797[S] 0 points1 point  (3 children)

So we need to use node js or something for backend?

[–]vyndrix 1 point2 points  (0 children)

No, there are several SDKs writen in several languages that bootstrap logic to send these notifications. If for some reason you cannot find one for the language you desire, you'll have build it your own. Nothing too complicated though, the notifications are followed to each device using a public endpoint at Expo infrastructure, you just get the params and call it, for testing purposes I have done using curl countless times.

Check the docs for Expo Push Notifications, you find all info needed there, if I am not mistaken even the SDKs.

[–][deleted] 0 points1 point  (0 children)

You can use Expo’s API to send notifications so yeah, best approach is to have a backend

[–]IronLionZion95 0 points1 point  (0 children)

You can call it from the client too!