Receiving Push Notifications issue while in background

I have already followed below setting

and also can receive push notifications but cannot get any delegate to be called when the app is in the background - receivedBackgroundNotification is not called.

-Here's our code:
(void)receivedBackgroundNotification:(NSDictionary *)notification fetchCompletionHandler:(void (^)(UIBackgroundFetchResult))completionHandler {
// App received a background notification
NSLog(@"receivedBackgroundNotification fetchCompletionHandler");
// Call the completion handler

Didn't find what you were looking for?

New post



  • I have use the SDK version 7.0.2 to do the implementation. Is it any bug about receiving background notification in this version? Or anything else I can do to fix the issue?

    Comment actions Permalink
  • Hello,

    Do you have an App Key and Device Id I could take a look at?

    Also, have you taken a look at our iOS Background Push Troubleshooting Documentation?

    Thank you,
    Sean Conlin
    Urban Airship Technical Support
    Portland, Oregon

    Comment actions Permalink
  • Yes, I also try to open a new APP id and just send one push for testing to prevent below issue.

    "Background time is not guaranteed"

    But the result is the same.

    Here's the info for your reference

    DEVICE ID: 61138a2212227c126cc9d96b91d9b38a20830c6a

    Thanks for your help!

    Comment actions Permalink
  • Hi,

    If you are looking to handle push notifications I would recommend that you implement a custom push handler that conforms to the "UAPushNotificationDelegate" protocol. We have an iOS Integration Best Practices Knowledge Base Article that explains how you can do this.

    If you must expose the "receivedBackgroundNotification" method, you will need to manually integrate our SDK into your app. To do this, you must ensure that you set "automaticSetupEnabled" to NO in your AirshipConfig.plist or UAConfig object. You will also need to expose a number of additional methods in your AppDelegate class and include some code in these methods to ensure that our SDK correctly handles push notifications. Our documentation on Automatic Integration details the methods that you need to include.

     Kind Regards,

    Martin Foster
    Urban Airship Technical Support, London

    Comment actions Permalink
  • I had the same issue.  I found that when composing a message I needed to turn on the "Background Processing: Send content-available flag to device to wake app for processing." in order to hook this event.

    Comment actions Permalink

Please sign in to leave a comment.