macOS Shortcuts Generator
Generate valid .shortcut files that can be signed and imported into Apple's Shortcuts app.
Quick Start
A shortcut is a binary plist with this structure:
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>WFWorkflowActions</key>
<array>
<!-- Actions go here -->
</array>
<key>WFWorkflowClientVersion</key>
<string>2700.0.4</string>
<key>WFWorkflowHasOutputFallback</key>
<false/>
<key>WFWorkflowIcon</key>
<dict>
<key>WFWorkflowIconGlyphNumber</key>
<integer>59511</integer>
<key>WFWorkflowIconStartColor</key>
<integer>4282601983</integer>
</dict>
<key>WFWorkflowImportQuestions</key>
<array/>
<key>WFWorkflowMinimumClientVersion</key>
<integer>900</integer>
<key>WFWorkflowMinimumClientVersionString</key>
<string>900</string>
<key>WFWorkflowName</key>
<string>My Shortcut</string>
<key>WFWorkflowOutputContentItemClasses</key>
<array/>
<key>WFWorkflowTypes</key>
<array/>
</dict>
</plist>
Minimal Hello World
<dict>
<key>WFWorkflowActionIdentifier</key>
<string>is.workflow.actions.gettext</string>
<key>WFWorkflowActionParameters</key>
<dict>
<key>UUID</key>
<string>A1B2C3D4-E5F6-7890-ABCD-EF1234567890</string>
<key>WFTextActionText</key>
<string>Hello World!</string>
</dict>
</dict>
<dict>
<key>WFWorkflowActionIdentifier</key>
<string>is.workflow.actions.showresult</string>
<key>WFWorkflowActionParameters</key>
<dict>
<key>Text</key>
<dict>
<key>Value</key>
<dict>
<key>attachmentsByRange</key>
<dict>
<key>{0, 1}</key>
<dict>
<key>OutputName</key>
<string>Text</string>
<key>OutputUUID</key>
<string>A1B2C3D4-E5F6-7890-ABCD-EF1234567890</string>
<key>Type</key>
<string>ActionOutput</string>
</dict>
</dict>
<key>string</key>
<string></string>
</dict>
<key>WFSerializationType</key>
<string>WFTextTokenString</string>
</dict>
</dict>
</dict>
Core Concepts
1. Actions
Every action has:
- Identifier:
is.workflow.actions.<name> (e.g., is.workflow.actions.showresult)
- Parameters: Action-specific configuration in
WFWorkflowActionParameters
- UUID: Unique identifier for referencing this action's output
2. Variable References
To use output from a previous action:
- The source action needs a
UUID parameter
- Reference it using
OutputUUID in an attachmentsByRange dictionary
- Use
 (U+FFFC) as placeholder in the string where the variable goes
- Set
WFSerializationType to WFTextTokenString
3. Control Flow
Control flow actions (repeat, conditional, menu) use:
GroupingIdentifier: UUID linking start/middle/end actions
WFControlFlowMode: 0=start, 1=middle (else/case), 2=end
Common Actions Quick Reference
| Action |
Identifier |
Key Parameters |
| Text |
is.workflow.actions.gettext |
WFTextActionText |
| Show Result |
is.workflow.actions.showresult |
Text |
| Ask for Input |
is.workflow.actions.ask |
WFAskActionPrompt, WFInputType |
| Use AI Model |
is.workflow.actions.askllm |
WFLLMPrompt, WFLLMModel, WFGenerativeResultType |
| Comment |
is.workflow.actions.comment |
WFCommentActionText |
| URL |
is.workflow.actions.url |
WFURLActionURL |
| Get Contents of URL |
is.workflow.actions.downloadurl |
WFURL, WFHTTPMethod |
| Get Weather |
is.workflow.actions.weather.currentconditions |
(none required) |
| Open App |
is.workflow.actions.openapp |
WFAppIdentifier |
| Open URL |
is.workflow.actions.openurl |
WFInput |
| Alert |
is.workflow.actions.alert |
WFAlertActionTitle, WFAlertActionMessage |
| Notification |
is.workflow.actions.notification |
WFNotificationActionTitle, WFNotificationActionBody |
| Set Variable |
is.workflow.actions.setvariable |
WFVariableName, WFInput |
| Get Variable |
is.workflow.actions.getvariable |
WFVariable |
| Number |
is.workflow.actions.number |
WFNumberActionNumber |
| List |
is.workflow.actions.list |
WFItems |
| Dictionary |
is.workflow.actions.dictionary |
WFItems |
| Repeat (count) |
is.workflow.actions.repeat.count |
WFRepeatCount, GroupingIdentifier, WFControlFlowMode |
| Repeat (each) |
is.workflow.actions.repeat.each |
WFInput, GroupingIdentifier, WFControlFlowMode |
| If/Otherwise |
is.workflow.actions.conditional |
WFInput, WFCondition, GroupingIdentifier, WFControlFlowMode |
| Choose from Menu |
is.workflow.actions.choosefrommenu |
WFMenuPrompt, WFMenuItems, GroupingIdentifier, WFControlFlowMode |
| Find Photos |
is.workflow.actions.filter.photos |
WFContentItemFilter (see FILTERS.md) |
| Delete Photos |
is.workflow.actions.deletephotos |
photos (NOT WFInput!) |
Detailed Reference Files
For complete documentation, see:
- PLIST_FORMAT.md - Complete plist structure
- ACTIONS.md - All 427 WF*Action identifiers and parameters
- APPINTENTS.md - All 728 AppIntent actions
- PARAMETER_TYPES.md - All parameter value types and serialization formats
- VARIABLES.md - Variable reference system
- CONTROL_FLOW.md - Repeat, Conditional, Menu patterns
- FILTERS.md - Content filters for Find/Filter actions (photos, files, etc.)
- EXAMPLES.md - Complete working examples
Signing Shortcuts
Shortcuts MUST be signed before they can be imported. Use the macOS shortcuts CLI:
# Sign for anyone to use
shortcuts sign --mode anyone --input MyShortcut.shortcut --output MyShortcut_signed.shortcut
# Sign for people who know you
shortcuts sign --mode people-who-know-me --input MyShortcut.shortcut --output MyShortcut_signed.shortcut
The signing process:
- Write your plist as XML to a
.shortcut file
- Run
shortcuts sign to add cryptographic signature (~19KB added)
- The signed file can be opened/imported into Shortcuts.app
Workflow for Creating Shortcuts
- Define actions - List what the shortcut should do
- Generate UUIDs - Each action that produces output needs a unique UUID
- Build action array - Create each action dictionary with identifier and parameters
- Wire variable references - Connect outputs to inputs using
OutputUUID
- Wrap in plist - Add the root structure with icon, name, version
- Write to file - Save as
.shortcut (XML plist format is fine)
- Sign - Run
shortcuts sign to make it importable
Key Rules
- UUIDs must be uppercase:
A1B2C3D4-E5F6-7890-ABCD-EF1234567890
- WFControlFlowMode is an integer: Use
<integer>0</integer> not <string>0</string>
- Range keys use format:
{position, length} - e.g., {0, 1} for first character
- The placeholder character:
 (U+FFFC) marks where variables are inserted
- Control flow needs matching ends: Every repeat/if/menu start needs an end action with same
GroupingIdentifier
1---
2name: shortcuts-generator
3description: Generate macOS/iOS Shortcuts by creating plist files. Use when asked to create shortcuts, automate workflows, build .shortcut files, or generate Shortcuts plists. Covers 1,155 actions (427 WF*Actions + 728 AppIntents), variable references, and control flow.
4allowed-tools: Write, Bash
5metadata:
6 source: https://skillmd.com/skills/modbender/shortcuts-generator
7---
8
9# macOS Shortcuts Generator
10
11Generate valid `.shortcut` files that can be signed and imported into Apple's Shortcuts app.
12
13## Quick Start
14
15A shortcut is a binary plist with this structure:
16
17```xml
18<?xml version="1.0" encoding="UTF-8"?>
19<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
20<plist version="1.0">
21<dict>
22 <key>WFWorkflowActions</key>
23 <array>
24 <!-- Actions go here -->
25 </array>
26 <key>WFWorkflowClientVersion</key>
27 <string>2700.0.4</string>
28 <key>WFWorkflowHasOutputFallback</key>
29 <false/>
30 <key>WFWorkflowIcon</key>
31 <dict>
32 <key>WFWorkflowIconGlyphNumber</key>
33 <integer>59511</integer>
34 <key>WFWorkflowIconStartColor</key>
35 <integer>4282601983</integer>
36 </dict>
37 <key>WFWorkflowImportQuestions</key>
38 <array/>
39 <key>WFWorkflowMinimumClientVersion</key>
40 <integer>900</integer>
41 <key>WFWorkflowMinimumClientVersionString</key>
42 <string>900</string>
43 <key>WFWorkflowName</key>
44 <string>My Shortcut</string>
45 <key>WFWorkflowOutputContentItemClasses</key>
46 <array/>
47 <key>WFWorkflowTypes</key>
48 <array/>
49</dict>
50</plist>
51```
52
53### Minimal Hello World
54
55```xml
56<dict>
57 <key>WFWorkflowActionIdentifier</key>
58 <string>is.workflow.actions.gettext</string>
59 <key>WFWorkflowActionParameters</key>
60 <dict>
61 <key>UUID</key>
62 <string>A1B2C3D4-E5F6-7890-ABCD-EF1234567890</string>
63 <key>WFTextActionText</key>
64 <string>Hello World!</string>
65 </dict>
66</dict>
67<dict>
68 <key>WFWorkflowActionIdentifier</key>
69 <string>is.workflow.actions.showresult</string>
70 <key>WFWorkflowActionParameters</key>
71 <dict>
72 <key>Text</key>
73 <dict>
74 <key>Value</key>
75 <dict>
76 <key>attachmentsByRange</key>
77 <dict>
78 <key>{0, 1}</key>
79 <dict>
80 <key>OutputName</key>
81 <string>Text</string>
82 <key>OutputUUID</key>
83 <string>A1B2C3D4-E5F6-7890-ABCD-EF1234567890</string>
84 <key>Type</key>
85 <string>ActionOutput</string>
86 </dict>
87 </dict>
88 <key>string</key>
89 <string></string>
90 </dict>
91 <key>WFSerializationType</key>
92 <string>WFTextTokenString</string>
93 </dict>
94 </dict>
95</dict>
96```
97
98## Core Concepts
99
100### 1. Actions
101Every action has:
102- **Identifier**: `is.workflow.actions.<name>` (e.g., `is.workflow.actions.showresult`)
103- **Parameters**: Action-specific configuration in `WFWorkflowActionParameters`
104- **UUID**: Unique identifier for referencing this action's output
105
106### 2. Variable References
107To use output from a previous action:
1081. The source action needs a `UUID` parameter
1092. Reference it using `OutputUUID` in an `attachmentsByRange` dictionary
1103. Use `` (U+FFFC) as placeholder in the string where the variable goes
1114. Set `WFSerializationType` to `WFTextTokenString`
112
113### 3. Control Flow
114Control flow actions (repeat, conditional, menu) use:
115- `GroupingIdentifier`: UUID linking start/middle/end actions
116- `WFControlFlowMode`: 0=start, 1=middle (else/case), 2=end
117
118## Common Actions Quick Reference
119
120| Action | Identifier | Key Parameters |
121|--------|------------|----------------|
122| Text | `is.workflow.actions.gettext` | `WFTextActionText` |
123| Show Result | `is.workflow.actions.showresult` | `Text` |
124| Ask for Input | `is.workflow.actions.ask` | `WFAskActionPrompt`, `WFInputType` |
125| Use AI Model | `is.workflow.actions.askllm` | `WFLLMPrompt`, `WFLLMModel`, `WFGenerativeResultType` |
126| Comment | `is.workflow.actions.comment` | `WFCommentActionText` |
127| URL | `is.workflow.actions.url` | `WFURLActionURL` |
128| Get Contents of URL | `is.workflow.actions.downloadurl` | `WFURL`, `WFHTTPMethod` |
129| Get Weather | `is.workflow.actions.weather.currentconditions` | (none required) |
130| Open App | `is.workflow.actions.openapp` | `WFAppIdentifier` |
131| Open URL | `is.workflow.actions.openurl` | `WFInput` |
132| Alert | `is.workflow.actions.alert` | `WFAlertActionTitle`, `WFAlertActionMessage` |
133| Notification | `is.workflow.actions.notification` | `WFNotificationActionTitle`, `WFNotificationActionBody` |
134| Set Variable | `is.workflow.actions.setvariable` | `WFVariableName`, `WFInput` |
135| Get Variable | `is.workflow.actions.getvariable` | `WFVariable` |
136| Number | `is.workflow.actions.number` | `WFNumberActionNumber` |
137| List | `is.workflow.actions.list` | `WFItems` |
138| Dictionary | `is.workflow.actions.dictionary` | `WFItems` |
139| Repeat (count) | `is.workflow.actions.repeat.count` | `WFRepeatCount`, `GroupingIdentifier`, `WFControlFlowMode` |
140| Repeat (each) | `is.workflow.actions.repeat.each` | `WFInput`, `GroupingIdentifier`, `WFControlFlowMode` |
141| If/Otherwise | `is.workflow.actions.conditional` | `WFInput`, `WFCondition`, `GroupingIdentifier`, `WFControlFlowMode` |
142| Choose from Menu | `is.workflow.actions.choosefrommenu` | `WFMenuPrompt`, `WFMenuItems`, `GroupingIdentifier`, `WFControlFlowMode` |
143| Find Photos | `is.workflow.actions.filter.photos` | `WFContentItemFilter` (see FILTERS.md) |
144| Delete Photos | `is.workflow.actions.deletephotos` | `photos` (**NOT** `WFInput`!) |
145
146## Detailed Reference Files
147
148For complete documentation, see:
149- [PLIST_FORMAT.md](PLIST_FORMAT.md) - Complete plist structure
150- [ACTIONS.md](ACTIONS.md) - All 427 WF*Action identifiers and parameters
151- [APPINTENTS.md](APPINTENTS.md) - All 728 AppIntent actions
152- [PARAMETER_TYPES.md](PARAMETER_TYPES.md) - All parameter value types and serialization formats
153- [VARIABLES.md](VARIABLES.md) - Variable reference system
154- [CONTROL_FLOW.md](CONTROL_FLOW.md) - Repeat, Conditional, Menu patterns
155- [FILTERS.md](FILTERS.md) - Content filters for Find/Filter actions (photos, files, etc.)
156- [EXAMPLES.md](EXAMPLES.md) - Complete working examples
157
158## Signing Shortcuts
159
160Shortcuts MUST be signed before they can be imported. Use the macOS `shortcuts` CLI:
161
162```bash
163# Sign for anyone to use
164shortcuts sign --mode anyone --input MyShortcut.shortcut --output MyShortcut_signed.shortcut
165
166# Sign for people who know you
167shortcuts sign --mode people-who-know-me --input MyShortcut.shortcut --output MyShortcut_signed.shortcut
168```
169
170The signing process:
1711. Write your plist as XML to a `.shortcut` file
1722. Run `shortcuts sign` to add cryptographic signature (~19KB added)
1733. The signed file can be opened/imported into Shortcuts.app
174
175## Workflow for Creating Shortcuts
176
1771. **Define actions** - List what the shortcut should do
1782. **Generate UUIDs** - Each action that produces output needs a unique UUID
1793. **Build action array** - Create each action dictionary with identifier and parameters
1804. **Wire variable references** - Connect outputs to inputs using `OutputUUID`
1815. **Wrap in plist** - Add the root structure with icon, name, version
1826. **Write to file** - Save as `.shortcut` (XML plist format is fine)
1837. **Sign** - Run `shortcuts sign` to make it importable
184
185## Key Rules
186
1871. **UUIDs must be uppercase**: `A1B2C3D4-E5F6-7890-ABCD-EF1234567890`
1882. **WFControlFlowMode is an integer**: Use `<integer>0</integer>` not `<string>0</string>`
1893. **Range keys use format**: `{position, length}` - e.g., `{0, 1}` for first character
1904. **The placeholder character**: `` (U+FFFC) marks where variables are inserted
1915. **Control flow needs matching ends**: Every repeat/if/menu start needs an end action with same `GroupingIdentifier`