Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Invoke programmatically iOS App Extensions

After reading on Apple documentation and checking on stackoverflow, I could not completely understand if it is possible or not to invoke programmatically an specific app extension of type "Action" or "Share".

Mainly, I have built an app extension of type "Action" and I'd like to invoke it programmatically from a second app (so I can send some input attributes and get the output from the extension) without having to open the UIActivityViewController.

Is there any way to do it?

like image 220
vilanovi Avatar asked Apr 09 '15 10:04

vilanovi


1 Answers

Not exactly. The way to invoke other action in other app is to use custom URL Scheme as mentioned in the Apple docs - https://developer.apple.com/library/archive/documentation/iPhone/Conceptual/iPhoneOSProgrammingGuide/Inter-AppCommunication/Inter-AppCommunication.html#//apple_ref/doc/uid/TP40007072-CH6-SW8

You can than pass some arguments as mentioned in the docs, and in your other app you'll need to parse the URL and act according to those parameters.

like image 151
Asaf Avatar answered Nov 12 '22 03:11

Asaf