Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to get an array of all pending remote notification?

Tags:

ios

iphone

Scenario:

  1. My application is closed (not in background).
  2. I received more than 1 remote notification.
  3. I click on app icon (not on remote notifications).

How can I get array of JSON payload for received remote notification (more than 1).

Thanks in advance.

like image 322
Prabhat Kasera Avatar asked Dec 25 '22 12:12

Prabhat Kasera


1 Answers

Unfortunately this is not possible.

You will only receive information about the notification that was used to open your app. If a user opens your app, and you have more than one notification, you will not be able to retrieve all of them from in the app.

Only one recent notification for a particular application is stored. If multiple notifications are sent while the device is offline, each new notification causes the prior notification to be discarded.

Apple Push Notification Service

like image 159
Rafa de King Avatar answered Dec 28 '22 02:12

Rafa de King