Clicky

iOS Dev Nugget 250 Reset Push Notification Permissions Alert on iOS and More

.

Need to run a code review on your codebase? Hire me

There's a great technote from Apple that collects many useful pieces of information about Push Notifications in a single place.

Eg. ports used for push:

  • 2195 for binary provider API
  • 443 for HTTP/2 provider API
  • 5223 and 443 for devices receiving push
  • 80 inbound + outbound for OS X

That the entire 17.0.0.0/8 address block is assigned to Apple (useful for firewall rules)

and how to reset the push notification permissions alert on iOS:

The first time a push-enabled app registers for push notifications, iOS asks the user if they wish to receive notifications for that app. Once the user has responded to this alert it is not presented again unless the device is restored or the app has been uninstalled for at least a day.

If you want to simulate a first-time run of your app, you can leave the app uninstalled for a day. You can achieve the latter without actually waiting a day by following these steps:

  1. Delete your app from the device.
  2. Turn the device off completely and turn it back on.
  3. Go to Settings > General > Date & Time and set the date ahead a day or more.
  4. Turn the device off completely again and turn it back on.

Your feedback is valuable: Do you want more nuggets like this?   Yes   or   No

.

.

Like this and want such iOS dev nuggets to be emailed to you, weekly?

Sign Me Up! or follow @iosdevnuggets on Twitter

.

View archives of past issues