Questions tagged [apple-push-notifications]

The Apple Push Notification Service is a service created by Apple Inc. that was launched together with iOS 3.0.APNS is used together with Mac OS X Lion Server to push update notifications to clients that have registered to receive updates via a configuration profile and are also using the server's mail, calendar and contacts services. This means that devices such as the iPhone and applications like iCal on the Mac can receive a notification

The Apple Push Notification Service (APNS) is a service created by Apple Inc.

It is the centerpiece of the remote notifications feature, and was launched together with iOS 3.0 on June 17, 2009. APNS is used to send notifications to applications on Apple devices (iOS, tvOS, macOS, watchOS) that have registered to receive those notifications.

Apple push notification service is a cloud service which allows to send notifications from any back-end server to an API provided by Apple. Apple has recently introduced an HTTP/2 API to send the push notifications which is the recommended way from Apple.

Third-party service providers offer a higher level interface to Apple API, making it easier to handle notification for a large number of registered devices.

Official Apple Push Notification Documentation

8015 questions
479
votes
14 answers

This certificate has an invalid issuer Apple Push Services

I have created certificate to enable Push Services in my app, but every time I try to add certificate in my Keychain, after adding certificate it shows me following error: This certificate has an invalid issuer
Aamir
  • 16,329
  • 10
  • 59
  • 65
307
votes
8 answers

Generate .pem file used to set up Apple Push Notifications

I tried and tried to generate a .pem file, every time generating certificates from the client's account and then generating the .pem file using the terminal, but it's of no use. Can anyone give a step-by-step procedure?
Harsh Parikh
  • 3,845
  • 3
  • 14
  • 14
227
votes
7 answers

Will iOS launch my app into the background if it was force-quit by the user?

I am triggering a background fetch by using the content-available flag on a push notification. I have the fetch and remote-notification UIBackgroundModes enabled. Here is the implementation I am using in my AppDelegate.m: -…
Andrew
  • 15,357
  • 6
  • 66
  • 101
211
votes
19 answers

Determine on iPhone if user has enabled push notifications

I'm looking for a way to determine if the user has, via settings, enabled or disabled their push notifications for my application.
Kevin
  • 3,690
  • 5
  • 35
  • 38
210
votes
15 answers

registerForRemoteNotificationTypes: is not supported in iOS 8.0 and later

When trying to register for push notifications under iOS 8.x: application.registerForRemoteNotificationTypes(UIRemoteNotificationType.Alert | UIRemoteNotificationType.Badge | UIRemoteNotificationType.Sound) I get the following…
Wojtek Turowicz
  • 4,086
  • 3
  • 27
  • 38
192
votes
29 answers

Detect if the app was launched/opened from a push notification

Is it possible to know if the app was launched/opened from a push notification? I guess the launching event can be caught here: - (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions { if…
189
votes
11 answers

Creating .pem file for APNS?

How do I create a .pem file to be stored in the hosting server for APN payload data?
Biranchi
  • 16,120
  • 23
  • 124
  • 161
187
votes
31 answers

How can I convert my device token (NSData) into an NSString?

I am implementing push notifications. I'd like to save my APNS Token as a String. - (void)application:(UIApplication *)application didRegisterForRemoteNotificationsWithDeviceToken:(NSData *)newDeviceToken { NSString *tokenString = [NSString…
Sheehan Alam
  • 60,111
  • 124
  • 355
  • 556
159
votes
24 answers

How to fix "no valid 'aps-environment' entitlement string found for application" in Xcode 4.3?

I've been trying very very hard to create a simple simple iOS app which can recieve push notifications. My only reason for doing this is to establish a procedure for some other team members to use, and have not been able to find an up to date,…
jwl
  • 10,268
  • 14
  • 53
  • 91
149
votes
6 answers

Renew Push certificate and keep current App Store App working

I have an app on app store, which is using an iOS Provisioning Profile (Distribution) which is expired. This Profile contains Push Certificate that's also expired (and does not appear anymore in the portal). Question 1: Is there a way to recreate…
Franck
  • 8,939
  • 8
  • 39
  • 57
149
votes
17 answers

Missing Push Notification Entitlement

I have an app for submission when it got rejected and I got the message Missing Push Notification Entitlement - Your app appears to register with the Apple Push Notification service, but the app signature's entitlements do not include the…
mirageservo
  • 2,387
  • 4
  • 22
  • 31
143
votes
15 answers

iOS push notification: how to detect if the user tapped on notification when the app is in background?

There are a lot of stackoverflow threads regarding this topic, but I still didn't find a good solution. If the app is not in the background, I can check launchOptions[UIApplicationLaunchOptionsRemoteNotificationKey] in…
Bao Lei
  • 3,515
  • 3
  • 19
  • 17
136
votes
11 answers

Displaying a stock iOS notification banner when your app is open and in the foreground?

When Apple's official iOS Messages app is open and in the foreground, new messages from other contacts trigger a stock, native iOS notification alert banner. See image below. Is this possible in 3rd party apps on the App Store? Local and/or Push…
pkamb
  • 33,281
  • 23
  • 160
  • 191
136
votes
10 answers

No valid 'aps-environment' entitlement string found for application on app store

So I have this app called Dripper that I put out about a month ago and then an update a couple days ago. The update added push notifications and a few little tweaks. I tested it with the sandbox-apn using the development profile and things worked…
Jessiah
  • 1,464
  • 2
  • 9
  • 9
133
votes
5 answers

How do iOS Push Notifications work?

How do iOS "push" notifications get delivered to a particular device without that device needing to poll a server? For example, let's say I have received a new message on Facebook. Facebook notifies Apple that my device should receive a notification…
Andy Hin
  • 30,345
  • 42
  • 99
  • 142
1
2 3
99 100