Sub topic 15
Triggering Shortcuts with Siri
This chapter covers how Siri runs Shortcuts on a Mac, how to build one that works well by voice, and how to diagnose the cases where it doesn't. It assumes you can move around System Settings and the menu bar, and that Siri is already turned on and responding (covered earlier in this tutorial). You don't need prior experience with Shortcuts.
How Siri and Shortcuts relate
A Shortcut is a named sequence of actions that you build in the Shortcuts app. Examples are "resize these images", "get directions home", or "append a line to a note". Siri is one of several ways to start a Shortcut. The others are the Shortcuts app itself, the menu bar, Spotlight, a keyboard shortcut, a Finder Quick Action, and the command line.
Siri matches what you say against the names of your Shortcuts. The name is the phrase. If a Shortcut is called "Daily Summary", saying "Daily Summary" to Siri runs it. This has three consequences:
- Naming matters more than any setting. A name that Siri mishears, or that sounds like a built-in command, will fail.
- Siri speaks and displays results from the Shortcut's last step if that step produces output.
- Any Shortcut on your Mac can be run this way, including ones synced from your iPhone through iCloud.
Building a Shortcut for voice use
- Open the Shortcuts app and choose File > New Shortcut.
- Give it a name by clicking the title at the top. Do this early, because the name is how Siri finds it.
- Add actions from the sidebar by searching or dragging them into the editor.
- Click the play button to test it by hand before you try Siri.
- Run it by voice.
A simple example is a Shortcut named "Start Focus Session". It could contain "Set Focus" (Do Not Disturb for one hour), then "Open App" (your notes app), then "Show Result" with a short text. Because it asks for no input, it runs from a single spoken phrase.
Naming rules that help
- Use two to four ordinary words. "Clean Up Text" works better than "CUT_v2".
- Avoid names that collide with built-in Siri commands, such as "Set a timer" or "Play music". Siri will usually take the built-in meaning.
- Avoid names that sound alike. "Add Note" and "Add Notes" are hard to tell apart by voice.
- Avoid unusual spellings, acronyms, and numbers written as digits. Siri hears words, not characters.
- Keep the name unique across all the Shortcuts you have, including synced ones.
Input, prompts and follow-up questions
Many Shortcuts need information. In the Shortcuts editor you can ask for it with actions such as "Ask for Input", "Choose from Menu", or "Choose from List". When Siri runs such a Shortcut, it pauses and asks you the question aloud or on screen, and you answer by speaking or typing.
Design for this on purpose:
- Put the prompt text in plain words, for example "Which project?" rather than "Enter value".
- Give a default answer where one makes sense, so an empty reply doesn't fail.
- Prefer "Choose from Menu" for a short fixed set of options. It is easier to answer by voice than free text.
- Keep the number of questions low. Each one is another turn in the conversation.
If the Shortcut accepts input from Share Sheet or Quick Actions, Siri does not supply that input automatically. Set the "If there's no input" option to ask for it, or use an "Ask for Input" action.
Showing and speaking results
What Siri says or shows depends on the final action:
| Final action | What you get |
|---|---|
| Show Result | The text appears in a window or Siri's result view |
| Speak Text | Siri reads the text aloud |
| Show Notification | A notification appears; nothing is spoken |
| Stop and Output | The value is returned to the caller, which matters for command-line use |
| No output action | The Shortcut runs silently |
If you want confirmation by voice, end the Shortcut with "Speak Text". Silent Shortcuts are fine for background tasks, but you can't tell by sound whether they ran.
Permissions and privacy prompts
The first time a Shortcut touches something sensitive, macOS asks you to allow it. Typical prompts cover files and folders, Contacts, Calendar, location, and running shell scripts or AppleScript. Approve them by running the Shortcut manually once. After that, a voice run proceeds without asking again.
Two settings in the Shortcuts app are worth knowing about. Under Settings > Advanced, "Allow Running Scripts" must be on for Shortcuts that include shell or AppleScript actions. Individual Shortcuts that share data with other apps may also show a one-time confirmation the first time they do.
Folders, Siri suggestions and the menu bar
You can group Shortcuts into folders for your own organization. Folders don't affect what Siri hears, because Siri matches on the Shortcut name alone.
Each Shortcut has details you can open with the information button in the editor. There you can turn on "Pin in Menu Bar", which puts the Shortcut in the menu bar for mouse access, and "Use as Quick Action", which exposes it in Finder and Services. These are useful companions to Siri because you can use the pointer when talking is awkward.
Typing instead of speaking
Type to Siri works the same way. You type the Shortcut name instead of saying it, which avoids misrecognition and works in quiet places. If a Shortcut works by typing and fails by voice, the problem is almost always recognition of the name, so rename it.
Checking and debugging from the command line
When Siri can't find a Shortcut, test whether the Shortcut itself works and whether macOS can see it. The shortcuts tool lists the Shortcuts available to the current user and runs one by name:
# List the Shortcuts available to the current user
shortcuts list
# Run a Shortcut by name
shortcuts run "Daily Summary"If a name appears in shortcuts list, it exists for your account. If it runs from Terminal but not from Siri, the fault is in speech recognition or a name collision. If it fails in both, the fault is in the Shortcut. A later chapter covers input and output options for scripting in detail.
Common errors
| Symptom | Likely cause | Fix |
|---|---|---|
| Siri runs a built-in feature instead | The name matches a system command | Rename to something distinctive |
| Siri does a web search | No Shortcut name matched | Check spelling in `shortcuts list`, then rename |
| Shortcut runs by hand but stalls by voice | A permission prompt is waiting | Run it by hand once and approve prompts |
| Siri asks for input you didn't expect | An "Ask for Input" action or empty input | Add defaults or remove the action |
| Shortcut from iPhone is missing | iCloud sync for Shortcuts is off | Turn on Shortcuts under iCloud in System Settings |
| Wrong Shortcut runs | Two similar names | Rename so they sound different |
A repeatable test routine
- Run the Shortcut with the play button and fix any errors.
- Approve every permission prompt.
- Run it with
shortcuts run "Name"from Terminal. - Say the name to Siri in a quiet room.
- Say it again at normal speaking distance with background noise.
- If recognition fails, rename and repeat from step 4.
Exercise
You created a Shortcut named "CUT v2" that cleans up pasted text. It runs from the play button and from shortcuts run "CUT v2", but Siri opens a web search when you say it. What is the most likely cause, and what is your fix?
Show answer
The Shortcut works, so the fault is in matching the spoken phrase. "CUT v2" is hard for speech recognition to turn into the exact name. Rename it to ordinary words such as "Clean Up Text", confirm the new name with shortcuts list, and test again by voice.
Exercise
A Shortcut named "Archive Old Files" moves files to a folder when Siri hears its name. Name two changes that make it safer to trigger by voice.
Show answer
Add a confirmation step before the move, such as "Show Alert" or "Choose from Menu" with a Cancel option. Also make sure the name is distinctive and unlikely to be confused with another Shortcut, and run it by hand once so permission prompts are already approved.