question

cdburns123 avatar image
cdburns123 asked

Your Own HTTP....

I have things moving along somewhat, but wanted to ask if your own HTTP web has to be setup as a Web-Service (always listening) or can it just be a webpage that receives the JSON sent, respond back and if so, does anyone have anything to share in javascript perhaps? Thank you all for your help as I rack my brain around hosting my own server and creating it as a lambda proxy.
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.

jjaquinta avatar image
jjaquinta answered
I think you've got some misunderstandings. 1) A web-service isn't "always listening". It's only invoked when called. 2) Javascript on a web page cannot read any POST data. So your skill would be restricted to giving canned responses and would be unable to react to different intents. So you couldn't do much with it. If you want to code in Javascript, I'd look into nodejs, or else just use a Lambda function. What's your end goal here?
10 |5000

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

cdburns123 avatar image
cdburns123 answered
Thank you. My main project is as follows: "Alexa, ask Denise to run ScoreKeeper" How many players? "Three" Please state first player's name.... etc.. I have a VB.NET program that I can currently use my voice to add players, add points, remove points, who is winning, end game etc...but I want it to go through Alexa since I can move Alexa into our living room or even outside for games. I have setup an HTTP/HTTPS in IIS with a self-signed certificate. Added it to my router so it can be seen outside my network. I just get lost as I try to setup a lambda proxy to my server and what I need on my server to get it to respond. I have gone through several examples of code, but still get lost. I've never created a webservice, but have written in VB and C#....I didn't mean always listening in that sense...I meant it is waiting. :-) Anything you can share as simple as possible would be great. Thank you so much again.
10 |5000

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

jjaquinta avatar image
jjaquinta answered
Well, baseline, you are going to need something that listens to a socket and responds to that. You will need to learn how to do that. Once you have that, you will need to be able to interpret what Alexa sends you, and format a response in the correct format. Since you aren't using one of their supported languages, you'll need to do that yourself. I think I've seen some posts in the forum about a .NET library for Alexa. You might want to go that route.
10 |5000

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

cdburns123 avatar image
cdburns123 answered
Got it figured out. I'm using the proxy script I saw posted here and modified it. I can now launch my application on my home computer and have the Echo have a conversation. I am going to post a very easy to follow description on here since there isn't one.
10 |5000

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