Is there anyway I could refresh the built-in Apple Mail based on an event in My App?
So,:
So essentially everything happens in the background with Mail app eventually receiving the push notification of a new mail as it would receive or fetch or manual refresh.
I read the Inter-App Communication page but it doesn't answer my question so I'm wondering if its even possible.
Modifying a program's executable code without the knowledge of the user. At startup, an application may query the Internet for an update and apply the change without prompting the user. For example, Google's Chrome browser performs routine silent updating to ensure that the latest vulnerabilities are fixed.
Open the Play Store and tap your profile picture on the top right. Go to Settings, select Network preferences, and go to Auto-update apps. Select Don't auto-update apps and tap DONE. You could also select the Over Wi-Fi only option if you'd prefer automatic updates on Wi-Fi.
Let me try to break down what you are asking:
My App receives a silent push notification, gets some information, and sends a request to a server (all in the background).
When the server receives that request, it sends out an email to the device.
You want that email to appear instantly.
Apple does not give developers explicit control to change a user's mail settings. As a developer you probably won't even know what mail accounts are on the device (or if the user even has the right account available). I would say that what you are asking is impossible with the current structure of Apple's APIs.
Push notifications in the Mail app do not work like other apps. Either mail is pushed to the device instantly (the Push switch is enabled), mail is fetched on an interval, or the user manually refreshes the mail every time they open the app. If the user has Fetch set to manual, they will not get your email.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With