Don’t send Push to users who no longer have the app?

Asked

Viewed 131 times

4

I have a GSM PUSH panel and it turns out that when user installs the app I record his id to send future notifications.

But after it uninstalls I continue with his ID saved in the bank and whenever I have my routine run, it sends the push to these users even without having the app installed.

The problem is that I already have thousands of id’s and now it is taking longer and longer to send.

There is the possibility to know who no longer has the app installed and put a flag on the bank so that it is no longer sent?

Example of Json return:

{"multicast_id":5157270514039936452,"success":2,"failure":1,"canonical_ids":0,"results":[{"message_id":"0:1474029083357948%0e3f0485f9fd7acv"},{"error":"MismatchSenderId"},{"message_id":"0:1474029083356778%f17b55e1f9fd7erf"}]}
  • 1

    If you are using GCM you can get a response to the status of sending the notification. When the notification fails to find a non-existent user (uninstalled app, for example), the error is returned NotRegistered. https://developers.google.com/cloud-messaging/gcm#unreg_device. For Apns there is also feedback (return). When the user receives a token is returned.

  • Daniel, thanks for the return, but the GSM returns me the following Jason: {"multicast_id":5157270514039936786,"Success":2,"Failure":1,"canonical_ids":0,"Results":[{"message_id":"0:1474029083357948%0e3f0485f9fd7ecd"},{"error":"Matmischsenderid"},{"message_id":"0:1474029083356778%f17b55e1f9fd7ecd"}]} I have successful and error return.

  • A question. How are you managing to send push messages if you don’t know the id of users?

  • I have all ids saved in my BD, however in return the id is not sent successfully or failed.

1 answer

0

William, good morning

This answer I’m giving you is only logical, because I didn’t work with push(still rs)

You said the return doesn’t come with the ID, and you don’t have to! You have the Ids at the time you send, just set up a routine that monitors sending and receiving status.

If you sent it to the XXX999 device, you don’t need that ID returned because you already know who sent it to, just monitor the status!

  • Good Afternoon, Lucas The problem is that shipping is done in batches of 1000 records. If it was sending from 1 to 1 could have the return, but with 1000 record and without the return of the ids it is difficult to identify.

  • This number of batch records is parameterizable?

  • No, Lucas I only get an ID

Browser other questions tagged

You are not signed in. Login or sign up in order to post.