How to create a media launcher with Shortcuts

How to create a media launcher with Shortcuts
How to create a media launcher with Shortcuts (Image credit: Joseph Keller/iMore)

Shortcuts has proven to be an excellent tool for productivity and everyday tasks, but what about entertainment? When I sit back and relax in the evenings with my iPad, I often find myself wanting to binge a few episodes of a favorite show, or put on a favorite movie. The Shortcuts app helps me work and take care of life's little tasks — can it entertain me, too?

Turns out, yes, it can. There are several ways you can use Shortcuts for everything from playing music to jumping to your favorite TV show on Netflix. We'll be focusing on the latter ability in this guide by building a media launcher.

Inspired by the work of Federico Viticci of MacStories and his Apple TV+ Launcher, I've created a couple of similar shortcuts that I find particularly useful when I want to watch a particular favorite show or movie. These shortcuts utilize the Dictionary action in Shortcuts, as well as a few other scripting capabilities.

What is a dictionary in Shortcuts?

While every part of these shortcuts is important, the central piece of the puzzle is the dictionary. Like the dictionary for a language, a dictionary in Shortcuts is split into terms, or keys, and definitions, or key values. When you choose the Dictionary action from the Scripting section when building your shortcut, you'll be asked to choose what type of value to add to your dictionary (in this case, you'll want to choose Text). When that happens, you'll see a new row added to your dictionary, with a blank "Key" and "Text" section, like this:

Blank dictionary (Image credit: iMore)

Every time you activate this shortcut, you'll be given a list of items to choose from. The "Key" is the name of the item that will appear on the list, while the "Text" is what that item actually is, or rather, its definition. So, in this example, 'Stranger Things' is what you'll see on the list presented to you when you activate the shortcut, while "https://www.netflix.com/title/80057281?s=i&trkid=13752289" is the URL that will open when you select 'Stranger Things' from the list:

Example dictionary entry (Image credit: iMore)

We'll now demonstrate just how to build a media launcher, using Netflix as an example. This will require a little work on your part to find the shows and movies you want to watch in the Netflix app (or the app of whatever service you want to use) and get their links. In the Netflix app, here's how you do it:

  1. Open Netflix on your iPhone or iPad.
  2. Tap on the show or movie you want to find, either from the main Netflix screen or through search.

Open Netflix, tap on a show or movie (Image credit: iMore)
  1. Tap share.
  2. Tap Copy Link.

Tap share, tap Copy Link

Tap share, tap Copy Link (Image credit: iMore)

The link for your movie or show will now be copied and will be ready to be placed in your dictionary.

Building your media launcher dictionary

  1. Open Shortcuts on your iPhone or iPad.
  2. Tap Create Shortcut or the + button.
  3. Tap Add Action.

Open Shortcuts, tap +, tap Add Action (Image credit: iMore)
  1. Tap Scripting.
  2. Tap Dictionary.
  3. Tap Add new item.

Tap Scripting, tap Dictionary, tap Add new item (Image credit: iMore)
  1. Tap Text.
  2. Tap Key to enter your first key. This will be the name of the show or movie you want to launch, like 'Stranger Things' or 'Sex Education.'
  3. Paste the link that corresponds with the key you just entered into the Text field.

Tap Text, tap Key, past link (Image credit: iMore)

To add more items, just repeat Steps 6-9 until you've added everything you want. Then your dictionary will be complete.

But that on its own isn't enough. If you try to activate the shortcut now, nothing will happen. That dictionary is just sitting there, and the shortcut needs to be told what to do with it. This is where scripting comes in.

Making your dictionary work for you

Now we're going to add the pieces that actually make the dictionary work. You'll do all of this in your newly-created shortcut.

  1. Tap the blue + button that sits under your dictionary.
  2. Tap Scripting.
  3. Tap Get Dictionary Value.

Tap +, tap Scripting, tap Get Dictionary Value (Image credit: iMore)
  1. Tap the blue Value parameter.
  2. Tap All Keys. This tells the shortcut to get all of the items for which you've added entries.
  3. Swipe up on the action sheet.

Tap Value, tap All Keys, swipe up (Image credit: iMore)
  1. Tap Choose from List. The Dictionary Value will already be set.
  2. Tap Show More.
  3. Type a title on the Prompt line if you want your list to have a heading like 'Netflix.'

Tap Choose from List, tap Show More, type title (Image credit: iMore)
  1. Swipe up on the action sheet.
  2. Tap Get Dictionary Value.
  3. Tap the Key parameter.

Swipe up, tap Get Dictionary Value, tap Key (Image credit: iMore)
  1. Tap Chosen Item from the bar above the keyboard.
  2. Tap the second Chosen Item parameter at the end of the action.
  3. Tap Clear.

Tap Chosen Item, tap Chosen Item, tap Clear (Image credit: iMore)
  1. Tap the Dictionary parameter.
  2. Tap Set Magic Variable.
  3. Tap Dictionary.

Tap Dictionary parameter, tap Set Magic Variable, tap Dictionary (Image credit: iMore)
  1. Tap x in the right corner of the action sheet.
  2. Tap the blue + button.
  3. Tap Web.

Tap x, tap +, tap Web (Image credit: iMore)
  1. Tap Get URLs from Input.
  2. Swipe up on the action sheet.
  3. Tap Open URLs.

Tap Get URLs from Input, swipe up, tap Open URLs (Image credit: iMore)

And there you have it. This Shortcut will now be able to open the specific pages for your chosen shows or movies in the Netflix app. Follow the steps for naming your shortcut and you'll be all finished.

By the way, I know this can look in intimidating, which is why I've got a link to this shortcut right here:

Get the shortcut

Now, as it is, this shortcut comes with links for my favorite shows on Netflix. But assuming you have your own list of favorites that are different from mine, you can just replace the keys and links in the dictionary with your favorites, and that's all you have to do to make this your own.

Launchers for other services

While the launcher we built here is for Netflix, it can also work for other services, including Disney+. This is because links to content in Netflix and Disney+ will open in the apps rather than on the web on iPhone and iPad. This is also true for HBO Now (though not HBO Go, the streaming service for HBO cable subscribers).

Other services have proven more troublesome. Standard links for Hulu, Amazon Prime Video, and HBO Go all send you to Safari, and if you try replacing the 'https://' with app URLs (hulu://, aiv://, or hbogo://), you'll be greeted with errors or, in the case of Hulu, it opens the app but not the specific content you want to find.

Any media launcher you make can work on the same principle as the Netflix launcher, assuming the links work properly, so the easiest way to build one for another service is to duplicate the Netflix shortcut as needed, then edit the titles and links in the dictionary in each duplicate for the services you want to use.

Fortunately, there is a workaround, so long as the app that you're hoping to use can display its programming inside the Apple TV app.

TV app launchers

The TV app that comes bundled with iOS and iPadOS allows you to share shows and movies via the standard share sheet, which means you can get a link to a specific item that will open up the TV app. This is how the launcher for Apple TV+ that Federico Viticci made works: it links to the shows directly in the TV app, and tapping on your desired show takes you directly to it.

But shows from other providers, including Apple TV channels and third-party apps whose content can be seen in the TV app, such as Hulu, HBO, and even Netflix, can also be shared from the app. The links from the app will take you to the content's landing page in the TV app, and you can play it in its native app from there as you normally would when browsing TV.

Here's how to get a link for any show or movie in the Apple TV app to be added to your media launcher.

  1. Open the TV app on your iPhone or iPad.
  2. Open the page for the show or movie that you want to link either by tapping on it or searching for it.

Open TV app, open show or movie (Image credit: iMore)
  1. Tap the share button in the top-right corner of the app.
  2. Tap Copy.

Tap share button, tap Copy (Image credit: iMore)

Now the link can be inserted into your dictionary as desired. Note: if you just use the standard link that you copy from the TV app, when you tap an item after activating your shortcut, you'll first be thrown to Safari before ending up in the TV app. To avoid this, simply edit the link in your dictionary and remove the 'https://' from the start of it, replacing it instead with 'com.apple.tv://'.

Questions?

If you have any additional questions about building or editing your own media-launching shortcuts, let us know in the comments.

Joseph Keller

Joseph Keller is the former Editor in Chief of iMore. An Apple user for almost 20 years, he spends his time learning the ins and outs of iOS and macOS, always finding ways of getting the most out of his iPhone, iPad, Apple Watch, and Mac.