question

sandeep0803 avatar image
sandeep0803 asked

Help with creating Alexa App

Hey, i received the permission for the echoSDK documents recently. I just needed some help on how to get started with the development. I didn't received the Alexa AppKit. I wanted to create a app that redirects request for purchasing option. I've gone through those docs but I am not able to figure out the starting point without the appkit. I'll be really thankful.
alexa skills kitdebugging
10 |5000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

James Chivers avatar image
James Chivers answered
Hi Sandeep, welcome to the Echo forums :) The Alexa AppKit you reference is the framework upon which you develop and deploy your app - it's the backend between the Echo device, and your hosted app endpoint. From: https://developer.amazon.com/public/solutions/devices/echo/alexa-app-kit/docs/getting-started-with-the-alexa-appkit "Developing apps with the Alexa AppKit is different than developing for other devices such as Android or iOS. Alexa apps are not installed on an actual device. Instead, they are web services hosted in the cloud. When a user wakes an Echo device and makes a request, that request is sent to the Alexa service in the cloud. If the request was intended for your app, the Alexa service sends a request to your app, waits for the response, and delivers the response to the user. Note that you can develop the web service for your app using any programming language" ...that page then goes on to give a good overview of what you need to get started - have you read that yet? What language(s) are you familiar with? If Java, then you're in luck, because Amazon provide the libraries which you can download it here: https://developer.amazon.com/edw/res/sdk/download/AlexaAppKit.zip ...build your app around, and then host, say in their Elastic Beanstalk service. If you have experience with Node.js, Matt Kruse (a member on these forums) developed and shared an implementation, that you can read about here: https://forums.developer.amazon.com/forums/thread.jspa?threadID=5262 ...which you'll need to host somewhere yourself. If .NET is your thing, then freebusy (another forum member) released an implementation, here: https://forums.developer.amazon.com/forums/message.jspa?messageID=16276 Amazon recently announced the ability to develop your apps on their Lambda service: https://developer.amazon.com/public/solutions/devices/echo/alexa-app-kit/docs/developing-your-alexa-appkit-app-as-a-lambda-function ...which might be a good place to get started as I imagine it'll be a snap to develop against and get something going quickly. Else, you can write your backend in any language, as long as you adhere to the interface reference: https://developer.amazon.com/public/solutions/devices/echo/alexa-app-kit/docs/alexa-appkit-app-interface-reference That's probably quite a lot to get started with, but the Echo forum is really friendly and helpful so with a little effort on your side, and us supporting you - you'll be up and running in no time I'm sure :) Cheers, James
10 |5000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

James Chivers avatar image
James Chivers answered
Oh, I almost forgot - if you're into Ruby then Damian Finol (yes, another forum member!) created both a Ruby Gem AppKit implementation and sample Sinatra server app, see: https://forums.developer.amazon.com/forums/thread.jspa?threadID=5363
10 |5000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

sandeep0803 avatar image
sandeep0803 answered
Hey Thanks James but i couldn't find the AppKit.zip files on the link instead i land-up on " page not found" Page Not Found We're sorry, but we couldn't find the page you requested. You may want to go to the homepage or read our FAQs. Any idea where i can get it from? Also Lambda supports code written in Node.js. So while coding in the lambda console do i get access to those libraries? The document just state how to create a lambda function, will i have those support function available in lambda too?
10 |5000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

James Chivers avatar image
James Chivers answered
The Amazon dev forum login/session management is janky, so maybe you're either not authenticated correctly, or, they (Amazon) need to flip a bit to give you access properly I would guess. If you visit: https://developer.amazon.com/edw/res/sdk/download/AlexaAppKit.zip ...and get a login page, then sign in - and you'll get dropped on the developer home page - so then paste that link into your browser again, and you *should* get the zip file served to you. If not - then Amazon need to investigate - or you're getting blocked somewhere. I would just send you the zip file, but the license agreement says that I cannot distribute (even though in this case, I think it would be ok). Your questions on the Lambda stuff is out of my scope, as I've not spent any time with it yet sorry (although I see your other Lambda post, so maybe you got started ok with it). Amazon folk - can you assist Sandeep on getting the AppKit Java libs zip please?
10 |5000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

Nick Gardner avatar image
Nick Gardner answered
Hi, When coding in Lambda, you have access by default to the AWS Node.js SDK, all you need to do is add the requires line: var AWS = require('aws-sdk'); For any other node.js modules, you can include them in a folder that is included in the zip you uploaded, and they will work fine. You will have to include them manually however, they aren't automatically included like the AWS SDK is. Here is some documentation on the Node SDK for AWS: aws.amazon.com/sdk-for-node-js/ @James: Yes, we'll look into it and see why there are access issues. Thanks, Nick
10 |5000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

sandeep0803 avatar image
sandeep0803 answered
thanks James and Nick I've started with lambda :) Hopefully i'll get sometthing running up in few days. Thanks Message was edited by: sandeep0803
10 |5000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

sandeep0803 avatar image
sandeep0803 answered
hey i've some questions if my slot contains more than one values (let take two) and i need the user to be able to call it with single intent also taking the other as not compulsory. Will it work? Also at certain time i need the user to provide the second slot value too after some processing (mainly in some cases where the the result returned is not unique). How to prompt the user for the same so that now only second slot value is filled. Message was edited by: sandeep0803
10 |5000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

sandeep0803 avatar image
sandeep0803 answered
10 |5000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.

James Chivers avatar image
James Chivers answered
Hi Sandeep, sounds like you're making progress :) You can have Slots with one or more values with a single Intent, e.g.: FooIntent some spoken phrase here {blue green|TwoColours} ...or - you can break the Slots down into multiple Slots (but with the same name), e.g.: FooIntent some spoken phrase here {blue|Colour} {green|Color} ...and Alexa will combine those two Slot values into the single Slot name - Color and pass that to your backend. If I understand you correctly - you'll need to keep the session open after you receive the first phrase (and Slot values), run your processing, then prompt the user for the next Slot value. In that case, you'd need to use two different Intents - one with two Slots (that you hope are filled) - the second Intent with just the second Slot if you need to prompt the user for that second value. You could use a single Intent with two Slots, then check to see if both Slots received a value from the user - if not - then prompt for the Slot value you need. If you provide some sample interactions, I might be able to help further. Good luck! Cheers, James
10 |5000

Up to 2 attachments (including images) can be used with a maximum of 512.0 KiB each and 1.0 MiB total.