About Alexa for Apps V2
Alexa for Apps lets customers use voice to access content and functionality in your apps and websites.
The Alexa for Apps mobile experience, introduced in Alexa for Apps V1, lets customers use voice on mobile devices, such as Alexa Mobile Accessories or Alexa Built-in phones, or the Alexa mobile app, to access your iOS and Android apps and websites.
Alexa for Apps V2 introduces the Alexa for Apps non-mobile experience, also known as "Send to Phone," which lets customers use an Alexa-enabled device (such as an Amazon Echo) to access your mobile apps and websites.
In Alexa for Apps, a single Alexa skill can provide deep links to both iOS and Android apps. If you already have existing deep links, you can use them in your skill as-is, without changing your app.
Alexa for Apps capabilities and limitations
Alexa for Apps lets you connect customers to content or functionality in your iOS app, Android app, or website. If a customer invokes your skill on an Alexa-enabled device, you can send an app link to their phone in a push notification and an Alexa app activity card. If they do so on a mobile device, you can directly open your app or website on the device.
Alexa for Apps can deep-link to your app even if your customer doesn't have the app installed yet. In that case, you can redirect them to the iOS App Store, the Google Play Store, or your website.
Alexa for Apps is available in all locales.
Amazon only supports Alexa for Apps for Alexa custom skills. You can't use Alexa for Apps with skills that use pre-built interaction models, such as Smart Home, music, or video skills.
How Alexa for Apps works
When your skill makes an Alexa for Apps request, your customer has a mobile or non-mobile experience, depending on the device they're using. If they're on an Alexa-enabled mobile device or the Alexa app, Alexa launches your app on their phone and takes them to the deep-linked content. If they're on a non-mobile Alexa-enabled device, such as an Amazon Echo device, Alexa sends your deep link to their phone as a push notification. When they tap the notification, the link takes them to your app or website.
Alexa for Apps mobile experience (Direct launch)
When a customer invokes your skill on an Alexa built-in phone, an Alexa Mobile Accessory (such as Echo Buds), or the Alexa app, your skill can use Alexa for Apps to directly launch your app or website on a phone. The following diagram shows the mobile request flow for a City Guide custom skill.
- An Alexa app user says, "Alexa, ask City Guide to search for coffee" on their iPhone or Android phone.
- The Alexa app sends the request to the City Guide skill. The skill checks for the presence of a
directLaunchfield in the
AppLinkobject in the request payload. This field is present, indicating that the device supports the Alexa for Apps mobile experience and can directly launch your app or website on the phone.
- The City Guide skill decides to send the customer to the City Guide app, by using a managed skill connection request to send an iOS or Android deep link to the Alexa for Apps skill. Along with the link, it sends a mandatory topic and other custom fields. The topic is a prompt helps the customer know what the deep-link does, for example, "See search results." On an iPhone, the City Guide skill might request to send a universal link of
https://www.cityguide.com/search?search_terms=coffee. For details about the connection request, see Alexa for Apps V2 Skill Connection Request Reference.
- The Alexa for Apps provider skill passes the deep link request to the Alexa app.
- The Alexa app uses the universal link to open the City Guide app, and then takes the user to the search results for coffee.
- The City Guide app displays the search results.
- The Alexa for Apps provider skill tells the City Guide skill whether the deep link request is successful. If the request isn't successful, Alexa transfers control back to the City Guide skill.
Alexa for Apps non-mobile experience (Send to Phone)
When a customer invokes your skill on a non-mobile Alexa-enabled device, your skill can use Alexa for Apps to send a link via a push notification to the customer's phone. Alexa also sends a card to the customer's Alexa app home page. Customers receive the notification in the Alexa app on their Android or iOS phone. The following diagram shows the non-mobile request flow for a recipe skill.
- An Amazon Echo device user says, "Alexa, ask MyRecipe to search for lasagna recipes."
- The Echo device sends the request to the MyRecipe skill. The skill checks for the presence of a
sendToDevicefield in the
context.AppLinkobject in the request payload. If this field is present, the device supports the Alexa for Apps non-mobile experience and can send a link to the customer's phone by using a managed skill connection request. In its request to the Alexa for Apps skill, the MyRecipe skill sends an iOS or Android deep link, or both (if it has links for both). Along with each link, it sends a topic and any custom fields. The topic is a prompt that tells the customer what the deep link does, for example, "See lasagna recipes." In this example, the users has an iPhone, and the MyRecipe skill sends a universal link of
https://www.myrecipe.com/search?search_terms=lasagna. For details about the connection request, see Alexa for Apps V2 Skill Connection Request Reference.
- Alexa for Apps confirms the notification recipient with the customer.
- Alexa for Apps sends the appropriate deep-link to the Alexa app installed on the customer's phone, both as a push notification and a home card in the Alexa app.
- Alexa for Apps tells the MyRecipe skill whether the notification was sent successfully, and transfers control back to the MyRecipe skill.
- The user sees the notification and taps it to view the search results in the MyRecipe app.
- The MyRecipe app displays the search results.
Alexa for Apps supported deep link types
In Alexa for Apps, your skill uses a managed skill connection request to send a deep link to your app or website. The request contains the following pieces of information:
- A mandatory primary deep link, which connects the customer to the desired content or functionality in your mobile app or website
- An optional deep link to handle fallback cases, such as when your app isn't installed. A fallback deep link can be a website link, to fulfill the customer's request even when the user hasn't installed your app; or a URI to the Apple App Store or Google Play Store for the customer to download your app.
- A mandatory verb-first call to action topic field to indicate what the link is doing, for example, "See lasagna recipes", "Get your boarding pass", or "View your messages."
You can also include a voice prompt as part of your skill response that calls Alexa for Apps. Alexa plays this prompt before any additional Send to Phone-related TTS that Alexa plays to determine the correct recipient. An example of this might be to provide initial information by voice, such as, "Your flight from Los Angeles International Airport to Madrid is on time."
Alexa for Apps supports the following types of deep links: Universal link, custom scheme, common scheme, Android custom intent, Android common intent, Android Package Manager app launch, and website link.
A universal link is a HTTP or HTTPS URL that can be opened by your mobile app when the app is available, or by a web browser, if the app isn't installed on the customer's phone.
A custom scheme is a link to functionality within your app. You must also provide the package name or app ID.
A common URI scheme is a well-known URI type that typically accomplishes functionality at a system level. The target app doesn't need to be specified. Alexa for Apps allows the following common URI schemes:
"tel:<phone number>" for telephone numbers,
"maps:q=<physical location>" for iOS maps, and
"geo:<physical location>" for Android maps.
Android custom intent
An Android custom intent is an app-specific Android intent. You must specify the package name in the custom intent, so customers can only be sent to the specified app.
Android common intent
Android common intents are a set of Android intents that an app can use to perform common actions through another app. The target app doesn't need to be specified. Alexa for Apps allows the following Android common intents:
Android Package Manager app launch
Sometimes you might want to simply launch an app, for example, to open a game or a news feed. For launching Android apps, just include the package name by using the Android Package Manager.
In case your skill doesn't own a relevant app or doesn't want to launch an app, your skill can launch a website link in a browser. The web domains must adhere to Alexa content policies.
Enable deep links in your app
If you already have deep links enabled in your mobile app, you can use Alexa for Apps to call those existing deep links. If you're new to deep links and want to add them to your app, see the following resources.
- To enable universal links, follow the instructions from Apple at Universal Link.
- To enable a custom URI scheme on iOS, follow the instructions from Apple at Defining a Custom URL Scheme for Your App.
- To enable Android App Links, follow the instructions from Android at Handling Android App Links.