Notifications

RSS for tag

Learn about the technical aspects of notification delivery on device, including notification types, priorities, and notification center management.

Notifications Documentation

Posts under Notifications subtopic

Post

Replies

Boosts

Views

Activity

track PushNotification delivery
Hello Team, We are working on a requirement where the business wants to track the delivery of push notifications on iOS devices. Specifically, they want to capture the moment when the device receives the notification and it appears as a badge in the Notification Center—regardless of whether the app is in the background or not—and then send that delivery status back to APNs. We have explored multiple approaches, but so far, we are only able to capture events when the user interacts with the notification banner. We would like to understand: Is it technically possible to send an event to APNs or another service upon receipt of the notification on the device without requiring user interaction? Any guidance or recommendations would be greatly appreciated.
8
0
67
May ’25
App notifications are failing to trigger
Facing issue while sending push notification through the application. The APNs certificate is valid. Below is the error log. System.AggregateException: One or more errors occurred. ---> PushSharp.Apple.ApnsNotificationException: Apns notification error: 'ConnectionError' ---> System.IO.IOException: Unable to write data to the transport connection: An existing connection was forcibly closed by the remote host. ---> System.Net.Sockets.SocketException: An existing connection was forcibly closed by the remote host at System.Net.Sockets.Socket.EndSend(IAsyncResult asyncResult) at System.Net.Sockets.NetworkStream.EndWrite(IAsyncResult asyncResult) --- End of inner exception stack trace --- at System.Net.Security._SslStream.EndWrite(IAsyncResult asyncResult) at System.Net.Security.SslStream.EndWrite(IAsyncResult asyncResult) at System.IO.Stream.<>c.b__53_1(Stream stream, IAsyncResult asyncResult) at System.Threading.Tasks.TaskFactory1.FromAsyncTrimPromise1.Complete(TInstance thisRef, Func3 endMethod, IAsyncResult asyncResult, Boolean requiresSynchronization) --- End of stack trace from previous location where exception was thrown --- at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task) at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) at System.Runtime.CompilerServices.TaskAwaiter.ValidateEnd(Task task) at PushSharp.Apple.ApnsConnection.<SendBatch>d__21.MoveNext() --- End of inner exception stack trace --- at PushSharp.Apple.ApnsServiceConnection.<Send>d__2.MoveNext() --- End of inner exception stack trace --- ---> (Inner Exception #0) PushSharp.Apple.ApnsNotificationException: Apns notification error: 'ConnectionError' ---> System.IO.IOException: Unable to write data to the transport connection: An existing connection was forcibly closed by the remote host. ---> System.Net.Sockets.SocketException: An existing connection was forcibly closed by the remote host at System.Net.Sockets.Socket.EndSend(IAsyncResult asyncResult) at System.Net.Sockets.NetworkStream.EndWrite(IAsyncResult asyncResult) --- End of inner exception stack trace --- at System.Net.Security._SslStream.EndWrite(IAsyncResult asyncResult) at System.Net.Security.SslStream.EndWrite(IAsyncResult asyncResult) at System.IO.Stream.<>c.<BeginEndWriteAsync>b__53_1(Stream stream, IAsyncResult asyncResult) at System.Threading.Tasks.TaskFactory1.FromAsyncTrimPromise1.Complete(TInstance thisRef, Func3 endMethod, IAsyncResult asyncResult, Boolean requiresSynchronization) --- End of stack trace from previous location where exception was thrown --- at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task) at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task) at System.Runtime.CompilerServices.TaskAwaiter.ValidateEnd(Task task) at PushSharp.Apple.ApnsConnection.d__21.MoveNext() --- End of inner exception stack trace --- at PushSharp.Apple.ApnsServiceConnection.d__2.MoveNext()<---
1
1
124
May ’25
Audio Session in Notification Service Extension
Is there anyway that I could use AVAudioSession, AVAudioPlayer or anything similar in Notification Service Extension? I am trying to implement Audio Playback in the Notification Service Extension to play specific audio file when receiving Notification regardless the app state(foreground, background or killed), but I am not able to activate audio session in Notification Service Extension. NSError *sessionError = nil; BOOL success = [[AVAudioSession sharedInstance] setCategory:AVAudioSessionCategoryPlayback error:&sessionError]; success = [[AVAudioSession sharedInstance] setActive:YES error:&sessionError]; if (!success) { NSLog(@"Error activating audio session: %@", sessionError); } Below is the error that I got when I am trying to run the code above in Notification Service Extension. Error Domain=NSOSStatusErrorDomain Code=561015905 "Session activation failed" UserInfo={NSLocalizedDescription=Session activation failed}
1
0
53
May ’25
Push notification volume for custom sound
Is there a way to configure the APNS notification sound volume to be louder? I am implementing some custom sounds(narrative sentences) for APNS, it does play the custom sound, but the volume of the custom sound is not loud enough even though I had set the device's volume and "RingTone and Alerts" volume to max. I tried to amplify the custom sound file, it does play louder but the result is minimum if I want to maintain the quality of the sound without it been distorted. I tried to use Notification Service Extension, AVAudioPlayer and AVAudioSession to play the sound, it does play louder in max volume compare with relying on default sound payload in APNS, but the problem is AVAudioPlayer and AVAudioSession do not seems to be usable when the application is in background or killed state, is there any other alternative I could use?
3
0
69
Apr ’25
Push notifications - Traffic gets "server-rst"
It seems our company server is sending to Apple push service the push notifications that are supposed to be transferred to devices our app is installed on – but you it seems you are blocking the request We can see traffic going out from our server side towards the apple gateway notification server using port 2195 and we can see that the traffic gets "server-rst" meaning that the apple gateway server kills the connection You might need to whitelist our external IP's
3
0
76
Apr ’25
Can I listen to user choice when asked for update permissions on Live Activity?
We would like to better understand the discrepancy between a Push To Start and the subsequent Updates where I see a number of recipients drop greatly. Our assumption is that this is a result of the end user not clicking the "Allow" prompt when a push to start widget is shown on the screen for the first time, but we currently do not have a way to listen to the user's choice when prompted. Is there any way of tapping into this, to determine if this is in fact where the variance is coming from, or if there is actually just a problem with the request to retrieve the update token from our end?
1
0
37
Apr ’25
Silent Push Notification Handling Behavior
I'm observing that when a silent push notification is sent to our app, is is started up in the background for 30 seconds before being suspended until the app is launched by the user. This causes data to persist from the silent push notification to the user app launch. I couldn't find documentation on this behavior for silent push notifications, and was wondering if it's possible to have the app terminate after handling the silent push notification. Is there documentation on the general flow of silent push notifications as well? I'm able to handle the edge cases if the app has to be suspended until user launch, but just want to confirm that this is the expected behavior before I go about handling it this way.
1
0
58
Apr ’25
/The notifications/test request was successful, but there were no notification messages from the Apple Store
requestUrl:https://api.storekit-sandbox.itunes.apple.com/inApps/v1/notifications/test method:Post responseCode:200 testNotificationToken:06beba6c-7587-44f6-a4b8-f12b11db6061_1745832671126 Request environment: ①APP from: TestFlight ②Apple acount : Sandbox account ③Apple originalTransactionId: 2000000907966801 App Store sandbox server notification configuration is fine(https://*.com/v2/apple_refund_notify), I have tried many times, but have not received any notification from Apple. Is this API not working?
2
0
68
Apr ’25
APNS Connection Timed out
This error has been continuously occurring for about 9 hours. We have not replaced the certificate, modified the server code, or changed the firewall policy. Some requests succeed, but many are timing out, with several timeouts occurring every minute. We are unable to find the cause. Please help. APNS Exception io netty channel ConnecttimeException: Connection timed out
APNSOutboundHandler api.push.apple.com/17.188.169.28:443 api.push.apple.com/(other ip):443 api.push.apple.com/(other ip):443 api.push.apple.com/(other ip):443 api.push.apple.com/(other ip):443 ...
2
0
586
Apr ’25
Push Notification Sound and Notification Service Extension When App is Killed
Dear Apple Developer Support, I am currently developing an iOS application that uses push notifications with custom .caf audio and a Notification Service Extension. I have implemented the extension to download and play a dynamic sound file from a remote sound_url. It works well when the app is in the foreground or background. However, when the app is force-closed (swiped up from multitasking), the Notification Service Extension does not seem to run. As a result, the custom sound is not downloaded or played. I would like to confirm: Is it possible to trigger the Notification Service Extension when the app is killed? If not, what is the correct way to play a custom .caf sound when the app is terminated? Should I preload and save the .caf file in App Group storage and reference it by name in the sound field? Are there any best practices or limitations regarding push notification customization when the app is killed? I appreciate your help in clarifying this issue. Thank you very much! Best regards, Phan Van Tung
1
0
45
Apr ’25
IMAP Extension XAPPLEPUSHSERVICE — Access to specific APNS Topic
Hi, I’m looking for guidance on enabling push notifications for new emails in the native iOS Mail app (com.apple.mobilemail). Currently, I send push notifications using macOS Server (formerly OS X Server) Mail, but since it has been discontinued and renewal is no longer possible, I want to transition to the standard method used by email providers to notify the stock Mail app about new messages. To achieve this, I need access to the com.apple.mobilemail.push.com.zuplu APNs topic. This follows the same pattern used by other providers: iCloud: com.apple.mobilemail.push.com.me.mail.castle Fastmail: com.apple.mobilemail.push.com.fastmail Since Fastmail (as a third-party provider) has access to this, I assume there is a way for independent mail providers to integrate with XAPPLEPUSHSERVICE. In the interest of a free market and fair competition, I trust that Apple provides a means for email providers to notify the stock Mail app of IMAP server changes, allowing it to fetch new messages instantly. Under EU competition law, particularly Article 102 TFEU, dominant companies must not engage in anti-competitive behavior, including restricting access to essential services in a discriminatory manner. Furthermore, the Digital Markets Act (DMA) explicitly prohibits gatekeepers from favoring their own services or restricting interoperability without justification. Any insights or official guidance would be greatly appreciated! Thanks, DragonWork
4
36
771
Apr ’25
push notifications are not receiving to device
iOS push notification is not working for in App since 03-Apr-2025. We are pushing the message to APNS from our application, but message is not delivered to iOS device. We have performed tests on both PROD and QA environment and following are the observations: PROD successfully pushing the notification to APNS but not receiving the notification on iOS device (100% failure). QA received notification on iOS device always (100% success). Analyzed PROD notification server log at our end and we do not observe any error and it is showing successful also when message is pushed to APNS all the time. Need to check from APNS why push messages are not delivered to iOS devices. Validated the PROD APNS certificate at our end which we are using during call to APNS - it is valid till Oct 2025. Please suggest me any possible solution because I don't have any clue where it is failing and what to do
2
0
120
Apr ’25
Clarification about ANCS being unavailable
Hello, I am working on a project that involves using external device to connect over BLE with users iPhone. I would like to be able to notify users on our device about eg. incoming calls, messages etc. I have been succesfull in using ANCS to achieve that but I am a little worried around consistency of this solution, especially taking into account following line from documentation: Due to the nature of iOS, the ANCS is not guaranteed to always be present. As a result, the NC should look for and subscribe to the Service Changed characteristic of the GATT service in order to monitor for the potential publishing and unpublishing of the ANCS at any time. I have not been able (yet?) to find or identify circumstances when ANCS would not be avilable or would be "removed in runtime", hence would it be possible to request some guidance and clarification on the conditions when ANCS can be unavailable or removed? Thank you!
2
0
63
Apr ’25
Push notifications not receiving for Brazil region
Hi Apple Support team, I would like to inform you that we were receiving push notifications to all regions. Recently we were facing push notifications are not receiving to brazil region. For all other regions we are receiving. We are using same APSN certificate. Any region specific permissions do we need to add. Please let me know. Thanks.
1
0
39
Apr ’25
APNS notifications of apns-push-type pushtotalk sometimes stop arriving after switching networks
PLATFORM AND VERSION: iOS Development environment: Other: .net MAUI with vscode Run-time configuration: iOS 18.1.1 DESCRIPTION OF PROBLEM APNS notifications of apns-push-type pushtotalk sometimes stop arriving after switching networks. STEPS TO REPRODUCE We have created a simple app which can be used to deminstrate this issue. When you launch the app it displays the APNS token which you can then use fromn the Apple Push Console to manually send it PTT push notifications. https://github.com/trampster/PttPushNotificationIssue On an iPhone SE (we havn't been able to reproduce on our iPhone 11) Start the APP to register for the APNS push notifications Turn off the WiFi wait for 5 seconds Attempt a push to the app manually using the Push Notifications Console (this should fail, which is fine) Turn on Cellular and wait for it to connect Attempt to push to the app manually using the Push Notifications Console -> This fails, and all attempts to send an pushtotalk push notifications fail until the we switch network again. Send a push while offline before connecting to the new network seems to make it happen more often but hard to tell for sure. The results of the failed push in the console look like this: Delivery LogLast updated: 30/01/25, 16:45:06 GMT+13 Refresh 30 Jan 2025, 16:45:03.661 GMT+13 received by APNS Server 30 Jan 2025, 16:45:03.662 GMT+13 discarded as device was offline The device is actually very much online. Switching networks again oftern makes things come right. But it doesn't seem to come right by itself. We can't respond to network changes and do anything as the whole point of using push-to-talk push notifications is to wake up the app when in the background to answer a call, this means we are not running and therefore cannot respond to network changes to try to work arround this issue.
6
0
449
Apr ’25