Zsolt Szatmari
Zsolt Szatmari

Reputation: 1239

How to make my app default for a given IntentKit domain in Siri?

Is there a way to make my app default Siri app for a specified domain? For example in this article:

https://www.smashingmagazine.com/2018/04/sirikit-intents-app-guide/

The author goes to great lengths on letting the system know how the app name is to be expected, e.g. in the phrase "In List-o-Mat, show the grocery store list". But if I omit the app name in my Siri request, iOS default Reminder app seems to always take precedence.

Even if I actually delete iOS Reminder app, Siri is complaining of having no compatible app, instead of using the next logical choice.

Thank You!

Upvotes: 2

Views: 103

Answers (1)

Emre Gürses
Emre Gürses

Reputation: 2180

No way. Default apps will open firstly if you say common words like "set alarm daily" or "call Zsolt". But you can add your app special shortcut for siri,

Firstly, you should create custom intent that can be used with Siri.

func scene(_ scene: UIScene, continue userActivity: NSUserActivity) {
        if let _ = userActivity.interaction?.intent as? DoSomethingIntent {

            if let windowScene = scene as? UIWindowScene {
                self.window = UIWindow(windowScene: windowScene)
                let storyboard = UIStoryboard(name: "Main", bundle: nil)
                let initialViewController = storyboard.instantiateViewController(withIdentifier: "ViewController") as! ViewController
                self.window!.rootViewController = initialViewController
                self.window!.makeKeyAndVisible()
                initialViewController.showMessage()
            }
        }
    }

You need to add Siri from "signing & capacity" also.

Upvotes: 1

Related Questions