0% found this document useful (0 votes)
29 views

Ap Alexa Integration Tutorial

ap-alexa-integration-tutorial

Uploaded by

Karthik Adabala
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
29 views

Ap Alexa Integration Tutorial

ap-alexa-integration-tutorial

Uploaded by

Karthik Adabala
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 15

ServiceNow Integration with

Alexa

© 2018 ServiceNow, Inc. All rights reserved.

ServiceNow, the ServiceNow logo, Now, and other ServiceNow marks are trademarks and/or registered trademarks of ServiceNow, Inc., in the United States
and/or other countries. Other company names, product names, and logos may be trademarks of the respective companies with which they are associated. 1
Table of Contents
Overview.................................................................................................................................................. 3
Retrieve Update Set ............................................................................................................................... 4
Create OAuth Application Registry ...................................................................................................... 5
Create Intents ......................................................................................................................................... 6
Create Phrases ........................................................................................................................................ 7
Amazon Setup......................................................................................................................................... 8
Alexa Skill Testing Tool ........................................................................................................................... 13

© 2018 ServiceNow, Inc. All rights reserved.

ServiceNow, the ServiceNow logo, Now, and other ServiceNow marks are trademarks and/or registered trademarks of ServiceNow, Inc., in the United States
and/or other countries. Other company names, product names, and logos may be trademarks of the respective companies with which they are associated. 2
Overview
To Integrate your ServiceNow Instance with Alexa you will need to set up the following.
1. ServiceNow Instance
a. Retrieved Update Set
b. Create OAuth application registry
c. Create Intents
d. Create Phases
2. Amazon Set Up
a. Create Alexa Skill
b. Create Alexa Intent
c. Set Up Endpoint
d. Account Linking

© 2018 ServiceNow, Inc. All rights reserved.

ServiceNow, the ServiceNow logo, Now, and other ServiceNow marks are trademarks and/or registered trademarks of ServiceNow, Inc., in the United States
and/or other countries. Other company names, product names, and logos may be trademarks of the respective companies with which they are associated. 3
Retrieve Update Set
1. In the ServiceNow application navigator, search Retrieved Update Sets. Click on
“Retrieve Update Sets” module under “System Update Sets”.

2. In the Related Links sections, click “Import Update Set from XML”.

3. Click the “Choose File” button under “Step 1: Choose file to upload” section. Select the
XML file. When done, click the “Upload” button under “Step 2: Upload the file”.

4. Open the “Amazon Echo” Update Set


5. Click on “Preview Update Set” button

The update set will now load. When done, click the “Close” button.

a. Under the “Update Set Preview Problems”, select all the Update Set with type
“Error”. When done, click on the “Actions on selected row…” drop-down list and
select “Skip remote update”.

© 2018 ServiceNow, Inc. All rights reserved.

ServiceNow, the ServiceNow logo, Now, and other ServiceNow marks are trademarks and/or registered trademarks of ServiceNow, Inc., in the United States
and/or other countries. Other company names, product names, and logos may be trademarks of the respective companies with which they are associated. 4
b. Click on the “Commit Update Set” button. After the update set has been
successfully committed 100%, close the dialog box.

Create OAuth Application Registry


OAuth
Steps
1. Log into you ServiceNow instance, for example, https://<yourinstancename>.service-
now.com/
2. Make sure you are in the global scope and not in an application scope
3. Go to System OAuth > Application Registry

4. Click button
5. Select the Create an OAuth API endpoint for external client’s option.
6. Enter the following Values for the fields below:
a. Name = Amazon Alexa
b. Client Secret = alexa
c. Redirect URL = Skip this section until you complete “Account Linking” section in
this tutorial.

© 2018 ServiceNow, Inc. All rights reserved.

ServiceNow, the ServiceNow logo, Now, and other ServiceNow marks are trademarks and/or registered trademarks of ServiceNow, Inc., in the United States
and/or other countries. Other company names, product names, and logos may be trademarks of the respective companies with which they are associated. 5
7. Take note of the fields just entered as they are custom to your implementation and will
be needed during the Amazon setup phase:
a. Client ID
b. Client Secret
8. You will need to come back and enter the redirect URL once you have completed the
Amazon setup. Enter the following values for the field below:
a. Redirect URL = Skip this section until you complete “Account Linking” section in
this tutorial. Paste URL’s provided in the “Account Linking” step 4 section.

Create Intents
1. In the ServiceNow application navigator, search “All Intents”. Click “All Intents” module
under the Amazon Echo section.

2. Click the “New” button.

3. Enter the following values for the fields below:


a. Name = List Active Incidents

© 2018 ServiceNow, Inc. All rights reserved.

ServiceNow, the ServiceNow logo, Now, and other ServiceNow marks are trademarks and/or registered trademarks of ServiceNow, Inc., in the United States
and/or other countries. Other company names, product names, and logos may be trademarks of the respective companies with which they are associated. 6
b. Intent keyword = ListIncidents
c. Script (Copy the script in the screenshot below)

4. Under the “Response attributes” section, select the “None” dropdown list option next to
“Output speech format” and select “SSML”. When done, click on the “submit” button.

Create Phrases
1. After submitting, open the “List Incidents” Intent.
2. Scroll down to the Phrases section and click on the “New” button.

3. Enter the following values for the fields below:


a. Phrase = List Incidents
b. Intent = List Incidents

4. Click on the “Submit” button.

© 2018 ServiceNow, Inc. All rights reserved.

ServiceNow, the ServiceNow logo, Now, and other ServiceNow marks are trademarks and/or registered trademarks of ServiceNow, Inc., in the United States
and/or other countries. Other company names, product names, and logos may be trademarks of the respective companies with which they are associated. 7
Amazon Setup

Create new Skill


1. Login to Amazon Alexa Developer Console
2. Click the Alexa icon and select the Skill Builders tab

3. Click the button


4. Click the button
5. Enter the following values:
a. Skill name = ServiceNow Integration

6. Click on the “Create Skill” button.


7. Select the Start from scratch option and click the choose button.
8. Click the Invocation name button.

© 2018 ServiceNow, Inc. All rights reserved.

ServiceNow, the ServiceNow logo, Now, and other ServiceNow marks are trademarks and/or registered trademarks of ServiceNow, Inc., in the United States
and/or other countries. Other company names, product names, and logos may be trademarks of the respective companies with which they are associated. 8
9. Enter the following values for the field below:
a. Skill Invocation Name = now

10. Click on the “Save Modal” button.

Create new Intent


1. Click the next to the Intents dropdown.
2. Enter the following value for the field below:
a. Create custom intent = ListIncidents

3. Click on the “Create custom intent” button.

© 2018 ServiceNow, Inc. All rights reserved.

ServiceNow, the ServiceNow logo, Now, and other ServiceNow marks are trademarks and/or registered trademarks of ServiceNow, Inc., in the United States
and/or other countries. Other company names, product names, and logos may be trademarks of the respective companies with which they are associated. 9
4. Enter a Sample Utterances under the “Sample Utterances” section. Enter the following
value for the field below:
a. Sample Utterances = List Incidents
5. Press enter or click the ‘+’ symbol.

6. Click on the “Save Model” button.


7. Click on the “Build Model” button.

Endpoint
1. On the left sidebar navigation, select the “Endpoint” option.

2. Select the HTTP radio button.


3. Enter the following value in the field below replacing <yourinstancename> with your
actual instance:
a. Default Region: https://<yourinstancename>.service-
now.com/api/x_snc_amazon_echo/alexa
4. Select the “My development endpoint is a sub-domain of a domain that has a wildcard
certificate from a certificate authority” option from the dropdown.

© 2018 ServiceNow, Inc. All rights reserved.

ServiceNow, the ServiceNow logo, Now, and other ServiceNow marks are trademarks and/or registered trademarks of ServiceNow, Inc., in the United States
and/or other countries. Other company names, product names, and logos may be trademarks of the respective companies with which they are associated. 10
5. Click on the “Save Endpoints” button.

Account Linking
1. On the left sidebar navigation, select the “Account Linking” option.

2. Enable “Do you allow users to create an account or link to an existing account with
you? option.

3. Under the “Security Provider Information” section, select the “Auth Code Grant” radio
button and enter the following values for the fields below:
a. Authorization URI = https://<yourinstancename>.service-now.com/oauth_auth.do
b. Access Token URI = https://<yourinstancename>.service-
now.com/oauth_token.do
c. Client ID = <Client ID>

© 2018 ServiceNow, Inc. All rights reserved.

ServiceNow, the ServiceNow logo, Now, and other ServiceNow marks are trademarks and/or registered trademarks of ServiceNow, Inc., in the United States
and/or other countries. Other company names, product names, and logos may be trademarks of the respective companies with which they are associated. 11
i. To get the Client ID, in the ServiceNow application navigator, you will
need to search and click “Application Registry” and open “Amazon
Alexa”.
System OAuth > Application Registry > Amazon Alexa > Client ID

d. Client Secret = alexa


e. Client Authentication Scheme = HTTP Basic (Recommended)

4. Under the “Security Provider Information” section, scroll down and find “Redirect URLs”.
Copy URL’s and go back to “ServiceNow Setup OAuth” section step 8 in this tutorial.
5. Click on the “Save” button.

Enable Skills
1. Go to https://alexa.amazon.com
2. On the left sidebar navigation, select the “Skills” option.

3. On the top tight hand corner of your screen, click on “Your Skills” button.
4. Click on “DEV SKILL” option.

5. Select you <ServiceNow> Application

© 2018 ServiceNow, Inc. All rights reserved.

ServiceNow, the ServiceNow logo, Now, and other ServiceNow marks are trademarks and/or registered trademarks of ServiceNow, Inc., in the United States
and/or other countries. Other company names, product names, and logos may be trademarks of the respective companies with which they are associated. 12
6. Click the Enable button

7. Click the “Allow” button.

8. You will receive a message saying, “Now Application has been successfully linked”.

9. Exit windows

Alexa Skill Testing Tool


Testing Alexa Skill
If you do not have a device you can use echoism, a free, community-run project that is an Echo
in a webpage, for testing.

© 2018 ServiceNow, Inc. All rights reserved.

ServiceNow, the ServiceNow logo, Now, and other ServiceNow marks are trademarks and/or registered trademarks of ServiceNow, Inc., in the United States
and/or other countries. Other company names, product names, and logos may be trademarks of the respective companies with which they are associated. 13
1. Log in to https://echosim.io
2. Use Amazon credentials
a. Email : [email protected]
b. Password: xxxxx

3. Click and hold the microphone button and speak a command as you would on the
Echo. For example, say, “Alexa, Open Now”. After invocating your skill, say “List
Incidents”.

© 2018 ServiceNow, Inc. All rights reserved.

ServiceNow, the ServiceNow logo, Now, and other ServiceNow marks are trademarks and/or registered trademarks of ServiceNow, Inc., in the United States
and/or other countries. Other company names, product names, and logos may be trademarks of the respective companies with which they are associated. 14
Testing Alexa Skill (Mobile)
1. Go to Reverb Application
2. Download the Reverb App from your App Store

3. Open the Reverb App from mobile


4. Login Using your Amazon credentials
5. Hold the microphone button and speak a command as you would on the Echo. For
example, say, “Alexa, Open Now”. After invocating your skill, say “List Incidents”.

© 2018 ServiceNow, Inc. All rights reserved.

ServiceNow, the ServiceNow logo, Now, and other ServiceNow marks are trademarks and/or registered trademarks of ServiceNow, Inc., in the United States
and/or other countries. Other company names, product names, and logos may be trademarks of the respective companies with which they are associated. 15

You might also like