There are a dozen related actions that users of my app can perform, and I'd like to let them do it with Siri, but I'm unsure how to effectively do that. I know I can donate a INIntent
when a user performs an action, but is it possible to donate an action with a customizable parameter? The user could, for example say "Perform action 1
", 1
being the parameter. Would the user have to perform each of the 12 actions before they could do that with Siri? I also know it's possible to use NSUserActivity
and INInteraction
s to make it easier for users to use Siri with an app, but I can't find any resources that will let me know if what I want to do is at all possible...
Asked
Active
Viewed 4,784 times
8

se_puede_dev
- 585
- 7
- 16
-
Did you find the solution for your problem? I'm also having this issue. – Shamsiddin Saidov Sep 13 '20 at 12:53
1 Answers
2
It is not possible to have a variable parameter. Siri shortcuts are for actions, which are executed by the user, so all needed information should be available when donated. If you want to perform actions with different parameters, you have to donate for each of these actions.
You can also check this post in the apple developer forum about the same problem: https://forums.developer.apple.com/message/326487#326487

Phil_G
- 293
- 1
- 9
-
-
Please provide me a concrete example what Things 3 can do regarding to your problem. I do not have the app. But from their description, they do not have variable parameters from Siri. – Phil_G Dec 03 '18 at 14:09
-
It's basically the same as if you f.e. take a reminder shortcut. You get a card with fields where you can define f.e. that the user has to input something. So Things 3 is a 3rd party app and it can do something a first party app can do. But I haven't found out how... – Georg Dec 03 '18 at 14:36
-
2I have looked a little bit at an online article about Things. What I have understood from there, is that through the Siri Shortcut, a task is created inside the app. The view, which is presented to add information, should be in the application itself, and not in the "Siri view". The shortcut does not take any of these parameters from the spoken phrase. The spoken phrase just triggers the creation of a task. So basically, Things 3 is opened by a shortcut and recognizes that it was opened by a shortcut, so it can present you the necessary view to input the information. – Phil_G Dec 04 '18 at 12:03
-
5In iOS 13 you can finally add parameters in shortcuts. You can look at the WWDC 2019 section for more details: https://developer.apple.com/videos/play/wwdc2019/213/ – Patrick Jul 18 '19 at 14:49