alexa-samples/skill-sample-nodejs-berry-bash

Instructions need lots of help

Closed this issue · 3 comments

There are almost too many problems to list in one issue:

  • The README.md indicates that we're to clone git clone https://github.com/Alexa/sample-skill-nodejs-berry-bash Berry-Bash but the repository's name is wrong (sample and skill are reversed).
  • Step 2 indicates at the end that we are expected to simply "follow the prompts": Initiatialize the ASK CLI by Navigating into the repository and running npm command: ask init. Follow the prompts.. This is anything but easy for the first-time user.
ask init
There is [sic] no AWS credentials file found in .aws directory, do you want to set u
p the credentials right now? (for lambda function deployment) 
Yes. Set up the AWS credentials.
Please follow the instruction from https://developer.amazon.com/docs/smapi/set-up-credentials-for-an-amazon-web-services-account.html
Fill in the AWS Access Key ID and AWS Secret Access Key below. CLI will generate/modify the AWS credential file for you.
? AWS Access Key ID:

At this point, the user then must go to the ASK console (wrong place), then the AWS side of the house to find out where an access key can be created.

The new user is then asked a bewildering collection of questions about what rights the IAM needs and this is not mentioned in the least in your tutorial under prerequisites. So I guessed, crossed my fingers and drove on, eventually having an Access Key ID and Secret.

Switch to 'Login with Amazon' page...
Tokens fetched and recorded in ask-cli config.

Some information was stored in ~/.ask/cli_config but nothing got stored in the project's root folder under .ask.

Your instructions under Deploy indicate Deploy the skill and the lambda function in one step by running the following command (from the folder root):

...but this fails since there's no .ask/config at this level and there won't be if you don't run an ask new command at this level. Running ask init doesn't seem to create this folder/file pair. At the project root I ran ask new but it then created a folder under this level. I then mv "Berry-Bash/.ask" . the hidden folder up a level, reviewed it and only then was ask deploy slightly happier. It ultimately failed though with:

-------------------- Create Skill Project --------------------
Profile for the deployment: [default]
Skill Id: amzn1.ask.skill.redacted
Skill deployment finished.
Model deployment finished.
Create role error.
InvalidClientTokenId: The security token included in the request is invalid.

This resulted in an ASK Skill but no Lambda function.


Is it too much to ask that someone there start from scratch, use an uninitiated ASK/AWS user and go through your tutorial from the beginning to document this in such a way that your users can succeed? "Follow the prompts" isn't useful if Amazon's prompting for an overwhelming collection of rights that could be issued.

Thanks in advance

Good comments. I'll just add that I got the following failure:
"message": "No interaction model was found for the specified locale. Please ensure that your skill has an interaction model defined for this locale."
Resolved by modifying locale in the listed test command from 'en-GB' to 'en-US'

@OutsourcedGuru Thanks for the feedback. We've fixed a few of the issues you mentioned, and I'd also check out the ASK CLI documentation which covers some of the problems you brought up - you'll find it listed under prerequisites, but here it is directly for convenience:

https://developer.amazon.com/docs/smapi/quick-start-alexa-skills-kit-command-line-interface.html

If you set that up, follow the steps in the repo and you should be good to go. Otherwise, as mentioned in the readme, you can follow along the more detailed steps without touching CLI - just hit 'Get Started!'.

@catwood2 I recently updated the sample to V2 and made a few changes (ie. GB model removed). I've changed that part you mentioned to US in the readme, so it should work now. I'll try to make a few more improvements too to make it all clearer. Thanks for the heads up.

Closing issue.