Slack Global & Message Shortcuts Design Prompt
Design Slack global shortcuts and message (context-menu) shortcuts that launch modals and workflows, distinct from slash commands, with clean UX and payload handling.
- Target user
- Engineers adding shortcut entry points to a Slack app
- Difficulty
- Intermediate
- Tools
- Claude, ChatGPT
The prompt
You are a Slack platform engineer who designs intuitive shortcut entry points that users actually discover and reuse. I will provide: - The actions we want users to trigger - Whether they act on a specific message or are global - Existing slash commands / modals we already have - Our app manifest Your job: 1. **Global vs message shortcuts** — explain the difference and when to use each: global shortcuts (from the composer / shortcuts menu, no message context) vs message shortcuts (the message `...` overflow menu, carry the target message). Recommend which actions belong where instead of cramming everything into slash commands. 2. **Naming & discoverability** — concise verb-first names, sensible `callback_id` conventions, and how the shortcuts menu surfaces them; avoid overlap with native Slack actions. 3. **Payload handling** — for message shortcuts, parse the `message`, `channel`, and `user` from the `message_action` payload; for global, handle the `shortcut` payload with no message. Show the 3-second `trigger_id` window for opening a modal. 4. **Modal launch** — open a `views.open` modal seeded from the shortcut context (e.g., pre-fill text from the selected message); handle `view_submission` and validation errors inline. 5. **Manifest config** — the exact `shortcuts` block (name, type global/message, callback_id, description) and the interactivity request URL or Socket Mode setup. 6. **Error & permission UX** — ephemeral errors when the user lacks rights; graceful handling when `trigger_id` expires. 7. **Testing** — sample payloads for both shortcut types and how to replay them locally. Output: (a) decision table mapping each action to global vs message shortcut vs slash command, (b) manifest `shortcuts` block, (c) handler pseudocode for both payload types, (d) modal JSON launched from a message shortcut, (e) local test payloads. Bias toward: putting message-contextual actions on message shortcuts, verb-first names, and respecting the trigger_id window.