/AlexaSkillTemplate

Basic Alexa Skill Template in NodeJS taken from Amazon's example

Primary LanguageJavaScriptApache License 2.0Apache-2.0

Basic Alexa Skill Template

This is a fork / simplified version of the Amazon How to build a skill example.

Usage

Alexa, launch "How old is"

How old is Chris
How old is Mandy
How old is Madeleine

Repository Contents

Setup w/ ASK CLI

Pre-requisites

Installation

  1. Clone the repository.

    $ git clone https://github.com/MrChrisBarker/AlexaSkillTemplate.git
  2. Initiatialize the ASK CLI by Navigating into the repository and running npm command: ask init. Follow the prompts.

    $ cd AlexaSkillTemplate
    $ ask init
  3. Install npm dependencies by navigating into the /lambda/custom directory and running the npm command: npm install

    $ cd lambda/custom
    $ npm install

Deployment

ASK CLI will create the skill and the lambda function for you. The Lambda function will be created in us-east-1 (Northern Virginia) by default.

  1. Deploy the skill and the lambda function in one step by running the following command:

    $ ask deploy

Testing

  1. To test, you need to login to Alexa Developer Console, and enable the "Test" switch on your skill from the "Test" Tab.

Lambda Updates

  1. Once your skill has been deployed you can make changes directly on the Alexa Developer Console (utterances, slots, slot values etc..). However if you require changes to your Lambda you can re-deploy this straight though the ASK CLI.

    $ ask deploy --target lambda

Customization

  1. ./skill.json

    Change the skill name, example phrase, icons, testing instructions etc ...

    Remember that many information is locale-specific and must be changed for each locale (en-GB and en-US)

    See the Skill Manifest Documentation for more information.

  2. ./lambda/custom/index.js

    Modify messages, and facts from the source code to customize the skill.

  3. ./models/*.json

    Change the model definition to replace the invocation name and the sample phrase for each intent. Repeat the operation for each locale you are planning to support.

Additional Resources

Community

Tutorials & Guides

  • Voice Design Guide - A great resource for learning conversational and voice user interface design.
  • CodeAcademy: Learn Alexa - Learn how to build an Alexa Skill from within your browser with this beginner friendly tutorial on CodeAcademy!

Documentation

Contact