Deploy your Alexa Skill in AWS Lambda

Renjith P
Renjith P
Jan 5 · 4 min read

In my previous tutorial you might have seen running Alexa skill locally. Now its time to get your skill deployed in AWS Lambda.

To start please go through the tutorial on “Alexa Custom Skill Development”, if you havn’t already went through it.


Now please get the “Hello World” skill service source code from GitHub. Do npm install to install the dependencies.Then rename asl-config-copy.json to asl-config.json in the project directory and replace skillId with your skill id from the alexa console.

Creating AWS Lambda Function

  • Click the region drop-down in the upper-right corner of the console and select one of the regions supported for Alexa skills.
  • If you have no Lambda functions yet, click Get Started Now. Otherwise, click Create a Lambda Function.
  • Select Author From Scratch.
  • Enter a Name for the function.
  • Select the Role for the function. This defines the AWS resources the function can access.
  • To use an existing role, select the role under Existing role.
  • To create a new role, see Defining a new Role for the Function. Remember that we need a Simple Microservice permissions for this role!
  • Select the language you want to use for the Runtime. For this tutorial, we are using Node.js.
  • Click Create function.
  • Configure the Alexa Skills Kit trigger.

Build better voice apps. Get more articles & interviews from voice technology experts at voicetechpodcast.com


Adding Alexa Skills Kit Trigger

  • First go to developer.amazon.com and from there to amazon alexa.
  • Now click Alexa Developer Console from the dropdown menu seen in the top right side corner of the page
  • This opens the developer console and displays any skills you have created.
  • Find the skill in the list. The ID is displayed below the skill name.

Once you have your skill ID, add the trigger to the function:

  • Log in to the AWS Management Console and navigate to AWS Lambda.
  • Click your function in the list to open the configuration details.
  • Make sure you are on the Configuration page.
  • In the Designer section, under Add triggers, click Alexa Skills Kit to select the trigger.
  • Under Configure triggers, select Enable for Skill ID verification.
  • Enter your skill ID in the Skill ID edit box.
  • Click Add.
  • Click Save to save the change.

Creating the Skill Package

With the skill code complete, you can create the skill package. To prepare the skill for upload to AWS Lambda, create a zip file that contains the skill file plus the node_modules folder. Make sure to compress all project files directly, NOT the project folder.

Uploading Your Skill to AWS Lambda

Once you’ve created your AWS Lambda function and configured “Alexa Skills Kit” as a trigger, upload the .zip file produced in the previous step. Leave the handler as default index.handler. If you find difficulty in uploading the zip directly , try uploading via AWS S3. Then copy the ARN for your AWS Lambda function because you’ll need it when configuring your skill in the Amazon Developer console.

Configuring Amazon Alexa Skill

Configure the endpoint for the skill. Under Endpoint select AWS Lambda ARN and paste in the ARN of the function you created previously. The rest of the settings can be left at their default values.

Finally click Save Endpoints and your skill is ready to test.

Test Your Skill

We are all set to test the skill developed and deployed locally. Make sure that the Test is enabled for this skill option is enabled. You can use the Test page to simulate requests, in text and voice form. Use the invocation name along with one of the sample utterances. For example, “tell my skill to say hi” should result in your skill responding with “Hello world”.


Something just for you

Voice Tech Podcast

Voice technology interviews & articles. Learn from the experts.

Renjith P

Written by

Renjith P

Software Engineer

Voice Tech Podcast

Voice technology interviews & articles. Learn from the experts.

Welcome to a place where words matter. On Medium, smart voices and original ideas take center stage - with no ads in sight. Watch
Follow all the topics you care about, and we’ll deliver the best stories for you to your homepage and inbox. Explore
Get unlimited access to the best stories on Medium — and support writers while you’re at it. Just $5/month. Upgrade