Alexa Haus landing page

Handling payments in your Alexa skill

Published: April 14, 2023

Key takeaways

Customers can use your skill to make purchases with their voice. Depending on your situation, you might consider using a customer’s account data you have on file to process a payment for goods and services you will offer outside your skill.

Learn how to design a skill to offer products and services, help a customer manage their cart, and what kinds of information you’ll need to collect from them to process a payment.

 

Need quick advice?

View the Checklist for designing skills that process payments.

 

In this article:

line-break

About payments & purchases

You can offer goods for sale that your customers can purchase using your skill. There are two options to achieve this:

  1. First, if your product already has (or will have) an Amazon ASIN, you can use Alexa Shopping Actions to help customers make the purchase.
  2. Second, customers can use the payment information they have stored in their account with your service to make the purchase. Learn more about Account Linking.

This article covers the second case: Using your customer’s account information to facilitate a purchase of any non-digital product not offered on Amazon.

Note: If you plan on offering digital goods and content that the customer will pay for and use within your Alexa skill, you will need to use In-Skill Purchasing.

Checklist for designing a skill to handle payments:

▢ Determine which method of payment is appropriate to use per the products you will sell, learn more with Earn Money with an Alexa Skill

▢  If you will process payments in your skill using a customer’s account with your service, learn how to design a skill with Account Linking

▢ Determine what information you need to process the payment, and create error messages for those cases where the information is missing from the customer’s account, including but not limited to …

        ▢ Missing or invalid shipping or billing address

        ▢ Missing, invalid, or expired payment method on file

        ▢ General processing failure

▢ If your skill will have multiple products, determine how a customer will easily browse and learn about them, and how they might manage a “cart” with multiple items, including but not limited to …

        ▢ Adding items

        ▢ Asking to remove items

        ▢ Asking to change or modify an item, if possible (for example, size)

        ▢ Asking for more details about an item

▢ Determine whether your skill needs to use a PIN code to protect customers’ personal information

▢ Include all purchase details, including item name, total price with tax and shipping (if applicable), before asking the customer if they want to place their order

▢ Don’t offer unrelated and unsolicited prompts to make a purchase

▢ Determine how the customer may keep using the skill if they decline the offer to make a purchase

line-break

Prerequisites

To process payments using your customer’s account information, a customer will have to link an existing account they have with your service to their Alexa app, so you’ll need to design your skill with account linking in mind while you also consider the payment experience.

To learn more about designing your skill with account linking, read Expand your skill: Account linking.

The customer’s account information must contain everything needed to process the payment (such as valid payment method) and deliver any physical goods to the correct address (if applicable). (Because of this, your skill will also need to handle a number of possible errors if that information is missing or invalid.)


What should your skill offer for purchase?

Remember many Alexa customers don’t have devices with a screen to display photos of items, or additional descriptions or information about items. You may want to create different purchasing or ordering experiences based on whether you want to support devices with a screen, devices without a screen, or both. For example, a skill that helps customers order food might let customers browse and order the full menu when there is a screen, and let customers re-order a previous, regular, or favorite order from their devices without a screen.

Note: If you have a skill that was previously using Amazon Pay, you will need to use one of the other payment methods above, as Amazon Pay for Alexa skills was disabled on the following dates: December 31, 2022 in the EU and the UK, January 31, 2023 in Japan, and March 31, 2023 in the US. For more details, see Deprecated Features.

line-break

Browsing items & managing a "cart"

If you will offer more than one product or service for sale within your skill, you’ll want to consider how customers will browse those products, as well as how they might “manage” their virtual cart if they can purchase more than one thing.

For example, a hypothetical skill that helps customers order breakfast should be designed to allow a customer to browse the breakfast items, coffee drinks, and their options to customize those items, as well as add and remove multiple items. Consider that customers may also want to change or remove something that’s already in their cart.

A conversation that supports “cart management” might sound something like the following …

Customer: Alexa, open Breakfast Buddy.

Alexa: Welcome to Breakfast Buddy. Would you like delivery, or pickup?

Customer: For pickup please.

Alexa: Got it. For pickup at the closest Breakfast Buddy on 11th Avenue, in Seattle. I have Coffee, pastries, sandwiches, and more. What would you like?

Customer: Two old fashioned donuts.

Alexa: Two Frosted Old Fashioned Donuts, added. What else?

Customer: Large black coffee, with two cream.

Alexa: Large black coffee, with two cream, added. Anything else?

Customer: What’s in my cart?

Alexa: So far, that’s two Frosted Old Fashioned Donuts, and a Large black coffee, with two cream. Ready to check out?

Customer: Remove one doughnut from my order.

Alexa: One frosted old fashioned doughnut, removed from your cart. What else?

Customer: Change my coffee.

Alexa: What would you like to change?

Customer: Make it one cream.

Alexa: One cream. Ok. What else would you like?

<conversation continues until the customer indicates they want to check out>

If your skill supports functions that aren’t purchase-related, allow the customer to say things like “shop”, “what can I buy?”, or “order” during their session so they can easily learn about what your skill offers for purchase.

Note: The above conversation uses <amazon:domain name="conversational"> for Alexa’s voice. To learn more about using different voices in your skill, read Improve Your Audio Experience

line-break

Design the call to action

Once you’ve thought about how your customer will find what you’re offering, and, if needed, manage a cart of different items and their attributes, it’s time to ask them if they’d like to make the purchase (or, add something to their cart if there are many goods or services to choose from).

If the customer has a cart load of items, such as when they’ve ordered a few breakfast items, you’ll want to ask if they’re ready to check out first, or wait for some indicator that they’re done with their order (such as in the hypothetical Breakfast Buddy example above).

If your skill only offers one item or service for purchase, your skill should ask the customer directly if they’re ready to check out:

Customer: Alexa, open Fit Friend.

Kendra: Welcome back to Fit Friend. Your next class is at Ultimate Barre, today at 5:30 pm. Are you ready to book another class?

Customer: Yes.

Kendra: Ok. When do you want to go?

Customer: Tomorrow after 5.

Kendra: Ok. I found a few classes you might like tomorrow, including Ultimate Barre at 5:30 pm, Pilates Nation at 6:30 pm, Ultimate Barre at 7:00 pm, and more. What would you like?

Customer: Give me Ultimate Barre at 5:30.

Kendra: The class at Ultimate Barre, tomorrow at 5:30 pm, costs $18 plus tax. Do you want to book it?

Customer: Yep!

Don't:

Customer: Alexa, ask My Capital to check my balance.

Alexa: Welcome back to My Capital. Your balance is due in 20 days, on March 1. Did you know that you can enroll in the MyCapital rewards program to earn 2% cash back on all your grocery purchases, for $18.99 a year, plus tax. Want to add it to your cart?

Customer: No!

Alexa: Ok. Want to check your balance?

Customer: Yes!

In the previous examples, the customer indicated in some way that they wanted to make a purchase (they added items to their cart, and they selected a class to book, respectively). Avoid surfacing unsolicited offers for products or services that are unrelated to what the customer was doing.

line-break

Confirm the purchase

The customer will need to give explicit confirmation (a “yes” answer) before you process the payment. This confirmation needs to include the full details of their purchase to assure them of the final total (plus tax and any fees), the payment method charged, and the delivery address if applicable. For example …

Customer: Alexa, open Breakfast Buddy.

Alexa: Welcome to Breakfast Buddy. Would you like delivery, or pickup?

Customer: I'd like to pick it up.

Alexa: Got it. For pickup at the closest Breakfast Buddy on 11th Avenue, in Seattle. I have Coffee, pastries, sandwiches, and more. What would you like?

Customer: An old fashioned doughnut and a large black coffee.

Alexa: Old fashioned doughnut and large black coffee, added. Anything else?

Customer: Nope.

Alexa: Ok, that’s an old fashioned doughnut and a large black coffee, for pickup at the Breakfast Buddy on 11th Avenue, in Seattle. Your total $6.85, including tax, charged to your card ending in 5-5-5-5. Should I place your order now? 

When a payment is (hopefully) successful, you will need to inform the customer and send them a receipt to their email associated with their account with your service. For example:

Customer: Alexa, ask Fit Friend to book another class.

Kendra: Welcome back to Fit Friend. When do you want to go?

Customer: Tomorrow after 5.

Kendra: Ok. I found a few classes you might like tomorrow, including Ultimate Barre at 5:30 pm, Pilates Nation at 6:30 pm, Ultimate Barre at 7:00 pm, and more. What would you like?

Customer: Give me Ultimate Barre at 5:30.

Kendra: The class tomorrow at Ultimate Barre at 5:30 pm, costs $18, plus tax. Want to start booking?

Customer: Yep!

Kendra: Your total for your class at the Ultimate Barre on Fifth Avenue, tomorrow at 5:30 pm, is $19.52, including tax, charged to your Fit Friend account. Do you want me to book it now?

Customer: Yes!

Kendra: You’re all set. I booked your class at Ultimate Barre on Fifth Avenue, tomorrow at 5:30 pm. Check your email for your receipt. Would you like to book another class?

line-break

Handle errors in payment & processing

There are a number of errors a customer can encounter based on whether they linked their account to their Alexa app, and whether the information on their account is complete or valid. Your service requirements may vary, but below are a few errors that might result from a failed transaction.

Where possible, tell the customer specifically and clearly what went wrong, and what action is required of them to resolve the issue. Learn more about handling errors gracefully with Conversation Patterns: Handling Errors.

The following customer hasn’t linked an account yet:

Customer: Alexa, open Breakfast Buddy.

Alexa: Welcome to Breakfast Buddy. You’ll need to link an account to place an order. I sent some information to your Alexa app to help you. Want to browse the menu?

Customer: Yeah!

Alexa: Ok. I have coffee, pastries, breakfast sandwiches and more. What sounds good?

Customer: I want to order.

Alexa: To start your order, you’ll need to link your Breakfast Buddy account. Check your Alexa app for details. Would you like to keep browsing?

Customer: No thanks.

Alexa: Alright. Goodbye.

<session ends>

The payment method on file is expired (or missing):

Customer: Alexa, open Breakfast Buddy.

Alexa: Welcome to Breakfast Buddy. The payment method on your account is expired. Please use your Breakfast Buddy app to update it. Do you want to browse the menu?

There’s no delivery address on their account:

Customer: Alexa, open Breakfast Buddy.

Alexa: Welcome to Breakfast Buddy. I couldn’t find an address for delivery on your account. Would you like to order for pickup?

Customer: I want delivery.

Alexa: To order delivery, use your Breakfast Buddy app to update your address. 

The payment was declined:

Alexa: Old fashioned doughnut and large black coffee, added. Anything else?

Customer: Nope.

Alexa: Ok, that’s an old fashioned doughnut and a large black coffee, for delivery to 440 Forrest Way, Seattle. Your total $6.85, including tax, charged to the card on your Breakfast Buddy account. Ready to place your order?

Customer: Yes.

Alexa: Sorry, I’m having trouble with your payment. Please use your Breakfast Buddy app to update it. When ready, ask Breakfast Buddy to check out.

Your skill uses a PIN code, but the customer doesn’t enter the correct one:

To learn more about handling PIN codes, read Add PIN Confirmation to Alexa Skills.

Alexa: Old fashioned doughnut and large black coffee, added. Anything else?

Customer: Nope.

Alexa: Ok, that’s an old fashioned doughnut and a large black coffee, for delivery to 440 Forrest Way, Seattle. Your total $6.85, including tax, charged to the card on your Breakfast Buddy account. Ready to place your order?

Customer: Yes.

Alexa: What’s your security code?

Customer: 1-2-3-4.

Alexa: Hmm. That’s not right. What’s your security code?

Customer: 2-4-6-8?

Alexa: Hmm. That’s not right. You’ll need to reset your security code to place your order. I sent some information to your Alexa app to help you. When ready, ask Breakfast Buddy to check out.

The purchase failed for some other reason (you may not know the origin of the error):

Alexa: Old fashioned doughnut and large black coffee, added. Anything else?

Customer: Nope.

Alexa: Ok, that’s an old fashioned doughnut and a large black coffee, for delivery to 440 Forrest Way, Seattle. Your total $6.85, including tax, charged to the card on your Breakfast Buddy account. Ready to place your order?

Customer: Yes.

Alexa: Hmm. I’m having trouble placing your order right now. To try again later, ask Breakfast Buddy to check out.

<Session ends>

Also keep in mind that at any time, the customer could say “no” to one of your calls to action. Where possible, provide a way for them to keep using the skill (rather than reaching a dead end) if this happens. For example:

Customer: Alexa, open Fit Friend.

Kendra: Welcome back, Fit Friend. Your next class is at Ultimate Barre, today at 5:30 pm. Are you ready to book another class?

Customer: Yes.

Kendra: Ok. When do you want to go?

Customer: Tomorrow after 5.

Kendra: Ok. I found a few classes you might like tomorrow, including Ultimate Barre at 5:30 pm, Pilates Nation at 6:30 pm, Ultimate Barre at 7:00 pm, and more. What would you like?

Customer: Give me Ultimate Barre at 5:30.

Kendra: The class tomorrow at Ultimate Barre at 5:30 pm, costs $18, plus tax. Want to start booking?

Customer: No thanks.

Kendra: No problem. Do you want to search for another class?

line-break

Consider guardrails

Depending on the kind of products and services you will offer, you may want to (or be required to, per Alexa Policy) have the following guard rails in place to prevent poor or unexpected experiences and protect customer trust and personal information:

Maximum purchase limit: You may want to add a maximum purchase limit to protect your customers from accidental large-volume purchases on a communal device (such as accidentally ordering 50 large coffees instead of 5). You’ll want to interrupt a customer once their “cart” total reaches or exceeds that number.

Voice PIN: You may want to, or be required to, implement a voice pin to protect your customers’ financial information and from accidental or fraudulent large purchases. The customer will need to create a PIN with your service, and they’ll be required to enter it to complete a transaction. To learn more about requirements and implementing a voice PIN, read Add PIN Confirmation to Alexa Skills.

Related Article: