iOS swift URLScheme post silently without opening another app

Viewed 151

Is there a way to send a data to another app using URLScheme without opening the other app? Once the data is received by the other app, data will be processed by the other app. Is this possible do this in iOS with swift?

1 Answers

No, you can't do that using URLScheme.

If you are the owner/developer of both apps you can use the App Groups to share data between these apps. One problem in this approach is your second app won't know when the data is being shared. To tackle this issue, you can use any of the following approach:

  1. When user opens the app next time, check whether new data is available or not
  2. Use a Silent Push Notification to notify your second app when there is a change. For this to work, your first app needs to notify the server after sharing the data and your server needs to send the notification to your second app
  3. Use Background Fetch API to launch your app in background and check for the shared data
Related