This small Node.js library demonstrates a rudimentary Lambda function and supporting IntentSchemas and Utterances for an Jack Handey as an Alexa Skill.
This integrates with Contentful using the request library to allow for dynamically managed/loaded Deep Thoughts.
- Node 6.10+
- Node Version Manager highly recommended
- Yarn
- Sign up for a free Contentful account and create a Management Token (under APIs -> Content management tokens -> Generate personal token)
- Sign up for an AWS account
- Install AWS CLI
- Create/configure an AWS IAM user with a
LambdaFullAccess
policy attached to it - Create a blank Alexa Skills Kit Lambda Function called
JackHandeySkillFunction
- Create a local aws-cli profile called
PERSONAL:LAMBDA
and utilize the access key and secret key from the user you made in Step 3aws configure --profile PERSONAL:LAMBDA
Environment Variable | Source |
---|---|
CONTENTFUL_CDN_TOKEN |
The Contentful CDN token from your account |
CONTENTFUL_SPACE_ID |
The Contentful Space ID from your account |
CONTENTFUL_BASE_URL |
The base URL for Contentful, e.g. https://cdn.contentful.com or https://preview.contentful.com |
Note: Contentful creates a default key called Example Key
upon creation of your free account
- Install contentful-import
cd contentful
contentful-import --space-id YOUR_SPACE_ID_HERE --management-token YOUR_MANAGEMENT_TOKEN_HERE --content-file contentful-export-jackhandey.json
- Clone this repo
yarn install
npm run aws:deploy