7
votes

According to Apple's APNs docs, as of iOS 13 clients of the http api must send header fields for apns-push-type and apns-priority or the requests will fail. Sure enough, our users who've udpated to the iOS 13 beta aren't getting silent push notifications that we send through AWS/SNS.

AFAICT, there's no way to "inject" these header fields into the request that SNS actually sends. But it seems like Amazon should just be doing this as a matter of course since without it, billions of notifications will soon start to fail.

Anyone know if they have plans to do this soon? Or maybe they're doing it already and I'm missing something?

3

3 Answers

3
votes

Amazon responded to our support ticket:

Thank you for contacting AWS Support. I'm *** and I'll be assisting you today regarding this case.

I understand that Apple is going to enforce a new protocol in iOS 13. As per new protocol, all the HTTP notifications must have 'apns-push-type' and 'apns-priority' fields in their headers.

We are aware of this issue and the engineering team is working towards to resolve the issue. Unfortunately, there is no workarounds and the support team does not have any visibility into the engineering team's roadmap and ETA for features so I'm unable to provide a date when support for iOS 13 headers will be available. I strongly recommend you to keep an eye on AWS Release notes for an update regarding this issue[1].

I apologize for the inconvenience and I hope that the engineering team resolves the issue as early as possible.

3
votes

Good news! AWS announced that SNS now supports additional mobile push notification headers as message attributes.

This change is good for iOS 13, and includes the apns-push-type, apns-priority, and apns-topic headers.

https://aws.amazon.com/about-aws/whats-new/2019/10/amazon-sns-now-supports-additional-mobile-push-notification-headers-as-message-attributes/

0
votes

In my testing it seems like SNS does add the apns-push-type field. Actually, it seems like Apple / iOS is not yet enforcing the apns-push-type field requirement. Pushes sent via Knuff do not contain this header, and yet they are received by an iOS 13 beta 8 device. I can also receive prominent notifications (i.e. user visible notifications) on an iOS 13 device, sent via SNS. Do prominent notifications work for you?

Since you said that you're only noticing problems with silent notifications, perhaps you are running into this conflict with the apns-priority value:

apns-priority The priority of the notification. If you omit this header, APNs sets the notification priority to 10.

Specify 10 to send the notification immediately. A value of 10 is appropriate for notifications that trigger an alert, play a sound, or badge the app’s icon. It's an error to specify this priority for a notification whose payload contains the content-available key.

Specify 5 to send the notification based on power considerations on the user’s device. Use this priority for notifications whose payload includes the content-available key. Notifications with this priority might be grouped and delivered in bursts to the user’s device. They may also be throttled, and in some cases not delivered.

Attempting to send a notification with apns-priority = 10 and the content-available key (used for silent pushes) is an error. Maybe that's why your silent pushes are being dropped?