Alexa Publishing Auto & Manual

Objective

This document will demonstrate how to automatically publish a Custom Skill from the VoiceWorx platform to Alexa or setup the skill manually in Alexa.

Introduction

After a skill is configured on the VoiceWorx platform, the platform has the inbuilt capability to publish the skill to Alexa, using the different configurations and permissions set in the publishing page of the VoiceWorx platform.

Goal

Our goal is to demonstrate that a skill can be setup in the VoiceWorx channel and automatically published to Alexa verses having to manually set up the skill in the VoiceWorx platform and again manually setup in Alexa Developer Console. Auto-publish can significantly reduce the skill setup process. This document will focus on the manual process, for the auto publish steps, please consult this link here.

Steps

The following shows the general steps/activities that will be carried out in setting up this integration. Note: It is advisable to use same email for signup across the 3 channels below. Step 1 -3 below are required.

  1. Ensure you Login With Amazon (LWA) https://developer.amazon.com/alexa/console/ask account is setup by your admin. If you are the account admin, you can follow this instruction to set it up.

  2. Set up connection to the external web API

  3. Create a custom skill in VoiceWorx.

  4. Create a skill in Alexa Developer Console

  5. Test the Alexa skill.

Set up connection to the external web API

  1. Login to the VoiceWorx platform, use left navigation menu and click “Integration” then select “Connect System”. In the resulting page, click “Connect External Systems”.

  1. In “Connect External System” select or do the following:

Select Integration Category: Custom

Select System Type: Rest API Service

Click: Connect System.

  1. Once in “Rest API Service Setup” select or enter the following:

System Instance Name: ContactFinder

Authorization Type: Basic Auth

Add Web API URL: https://demo.VoiceWorx.ai

Under Basic Auth Settings

Enter Username and Password

Click: Validate System to ensure you have access to the web API endpoint.

Create Custom Skill in VoiceWorx.ai

  1. To create a custom skill, use left navigation menu and click “Custom Skills” then select “Manage Skills”. Then click “Create New Custom Skill”.

  1. Now add Custom Skill by doing the following:

Name: Contact Finder

Custom Skill Type: Search

Category: None

Click: Save

  1. In the top menu tabs, select “Data Sources” then “Create New Data Source”. Select or enter the following:

Name: ContactFinderDS

Integration Configuration: Rest API Service: ContactFinder

Manage Connections to create the external platform WebAPI integration

Click: Save

  1. In the top menu tabs, select “Methods” then select “Create New Methods”. Then select or enter the following:

    • Name: GetPhoneNumberByName

    • Request Type: GET

    • Query Path: ?name={{Person}}

    • Result Type: Record

    • Method Path: /api/contacts

    • Method Result-Empty Result Template: Phone Number Not Found For Requested Contact

    • Result Template: {{Person}} phone number is {{Phone}}

    • Click: Save

  1. In the top menu tabs, select “Intents” and “Create New Intent”. Then select or enter the following:

Name: GetPhoneNumberByName

Intent Type: Search

Intent Action: Executive Method

DataSource: ContactFinderDS

DataSource Method: GetPhoneNumberByName

Click: Save

  1. In the top menu tabs, select “Slots” and select “Create New Slot”. Note the Reprompt message is what Alexa will ask if it can’t fill/resolve the person slot. Then select or enter the following:

Name: Person

Slot Order: Blank

Reprompt Message: What is the person name

Type: Person

Custom Skill: ContactFinder

Intent: GetPhoneNumber

Click: Save

  1. In the top menu tabs, select “Utterance” and select “Create New Utterance”. Utterance are words spoken to launch specific intents. Now input or select the following:

Value: What is the phone number for (Person)

Custom Skill: ContactFinder

Intent: GetPhoneNumber

Click: Save

  1. In the top menu tabs, select “Input” and select “Create New Input”. Then input or select the following:

Name: Person

Custom Skill: ContactFinder

Custom Intent: GetPhoneNumber

Data Source: ContactFinderDS

Data Source Method: GetPhoneNumberByName

Publish to Alexa

  1. To publish to Alexa, select “Publish” in the top menu tabs then click “Add Skill Publishing”. Then input or select the following:

External Skill Name: ContactFinder. (This will be the name of the skill in Alexa. Therefore, make it unique and different from the names of your other skills in Alexa.)

Skill Type: Select Search

Channel: Select Alexa

Uncheck the following: Require account linking, Auto Publish

Skill Invocation Name: ContactFinder. (This will be what users say to launch your skill in Alexa. It must be in lower case alphabets cannot contain START, BEGIN, STOP, EXIT, LAUNCH and cannot contain number or special characters.)

Optional: Replace all placeholder values in all “Message”. Uncheck all the settings shown in the second image below.

Click: Save.

Create a skill in Alexa Developer Console

Note: This section shows how to manually set up a skill in the Alexa Developer Console. Please not that this step can be automatically performed by publishing directly from the VoiceWorx platform. To learn how to publish directly from the VoiceWorx platform please follow this tutorial.

  1. Login to https://developer.amazon.com/alexa/console/ask with the credentials set up in step 2 above.

  2. Click “Create Skill” in the resulting page.

  1. Now do the following:

Add a Skill Name: Contact Finder.

Custom Skill: Select

Click: Create skill in top right-hand corner.

  1. On the resulting page, ensure “Start from Scratch” is selected and select “Continue with template” in top right-hand corner.

  1. A “Creating A Custom Skill” screen will appear as seen below.

  1. After the skill is built, click “Invocation” and type in a simple unique word. When Alexa hears this, it will invoke the skill. For this exercise, Type in “Contact Finder”. To invoke the skill, say “Alexa Start Contact Finder”.

  2. On the left navigation menu click “Interaction Model” then click “Intents” then click, “Add Intent”.

  1. Type “PhoneByName” in the text box and click “Create Custom Intent

  2. Add Utterances: Utterances are what the users say to invoke the intent. Utterance contain “Slots”. Slots are the unique variables in utterances. In this exercise we will add a Slot “Person” in the utterance. In the Alexa console, to add a Slot, type “{“. Once you type in “ { “ in the Utterance text box, a “Add/Create New Slot” modal shows. Add a slot named Person in the Utterance. Note: Your slot names must match what was defined in VoiceWorx.

  1. Update the “Person” Slot we just created. Make it a Slot Type “AMAZON.SEARCHQUERY”. To do this, scroll down the utterance page, to the “Intent Slots” section. In the Slot Type column, expand the Slot Type drop down and select “AMAZON.SEARCHQUERY”.

  1. Click “save” then click “Build Model”.

  1. To set the VoiceWorx endpoint in Alexa developer console do the following:

Click: Endpoint

Select: “Https endpoint

Set “Default Region”: Visit https://alexa.VoiceWorx.ai/api/v1/alexa/request and select “My Development Endpoint Is a Subdomain of a Domain that has a wildcard certificate”

Click: Save Endpoint

  1. Go to the skills list home page in Alexa Developer Console, copy the skill ID and update the Skill ID in the VoiceWorx.

  1. Go to the VoiceWorx platform (https://portal.VoiceWorx.ai/) and in the left navigation menu select “Custom Skill” then select “Manage Skills”. Select the “Contact Finder Skill”.

  2. Then in the top menu tabs click Publish” tab and click “Edit”.

  1. On the “Edit Skill Page”, update the External ID to the ID you copied from Alexa Developer Console then click “save”.

Test the Skill

  1. Goto Alexa Developer Console. Select “Contact Finder” Skill. Click “Test” tab in the top menu, then below “Test” tab change the skill test status from “Off” to “Development”.

  1. Invoke skill by typing the invocation name “Contact Finder” inserted in the publishing step in VoiceWorx. If the invocation is successful, your configured welcome message will be displayed in the Alexa Developer Console.

Congratulations!

You have successfully completed Alexa Publishing.

Last updated