Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

APIs Build an Alexa Skill Building an Alexa Skill Uploading an Alexa Skill to AWS Lambda

Alexander Sanchez
Alexander Sanchez
1,181 Points

What do all the different files in the zip folder do?

If I've understood correctly, the course only goes through the steps of planning a skill and adding it to the alexa dev console, not to mention getting it ready for certification. But, what about the code that I write for the skill?? There are a number of files in the zipped folder. I'd like to know what those do and how that map back to the skill that I'm creating.

Andrew Chalkley can you add more color on this please? Just a simple mapping for the files necessary for creating the Treehouse skill would super helpful. Thanks.

1 Answer

Andrew Chalkley
STAFF
Andrew Chalkley
Treehouse Guest Teacher

I cover some of these files later but here's a break down.

node_modules - folder for the software libraries needed for the skill service to run you don't need to touch anything in there.
index.js- the JavaScript code that responds to the Alexa voice service. This is where all the code is for responding to the request. It's using JavaScript on the Node.js platform. If you're new to JavaScript check out the Beginner JavaScript Track or check out Node.js Basics if you're already familiar with JavaScript.
definitions.json - contains all the definitions that you can change for your dictionary skill
responses.json - contains all the questions, and prompts that the user will hear from your skill.

Hope that helps.