jchadwick / mr_math

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

AWS Lambda Hosted Alexa Skill w/ Typescript Boilerplate

This repository is a template repository you can use as a quickstart to building your own Alex Skills.

Requirements

Before you begin using this repository, please ensure that you have:

Getting Started

  1. Use GitHub's "Create from Template" functionality via either:
  1. Once the repo is created, clone it and run the following script:
> ./init_repo

This will initialize the template with a skill name and invocation name matching your current directory.
Alternately, provide the skill name you would like to use:

> ./init_repo the_coolest_skill_ever

Or, the skill name and the invocation:

> ./init_repo the_coolest_skill_ever "coolest skill"
  1. Open up skill/lambda/src/index.ts and start coding
  2. When you're ready to deploy your skill:
  • Get an ASK Access Token:
> npm run refresh-token
  • Deploy to Alexa:
> npm run build-deploy
  1. Profit!

Repository Structure

This repository contains the following files:

.
├── .vscode            # configuration files for VS Code editor
├── scripts            # scripts for local development
│   ├── get_ask_skill_id   # reads the Skill ID from local files
│   ├── get_ask_token      # requests ASK token from ASK website
│   ├── get_env            # reads variables into memory for running tasks
│   └── set_ask_token      # generates and saves a new ASK Access Token
│                          # using the ASK CLI
├── skill              # source code and config for the Alexa Skill
│   ├── lambda         # source code for the Alexa Skill Lambda
│   └── skill-package  # configuration for the Alexa Skill
├── init_repo          # initialization script (will self-destruct!)
└── README.md

About


Languages

Language:TypeScript 60.9%Language:Shell 39.1%