question

Steve L. avatar image
Steve L. asked

How to get alexa to listen for a second response?

How do I format my json response to get alexa to keep listening for another response? I am setting shouldEndSession to false but each time it is sending a new session.
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.

Galactoise avatar image
Galactoise answered
Can you elaborate on what you mean by "sending a new session"?
10 |5000

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

Steve L. avatar image
Steve L. answered
Alexa, open myskilltest {"version":"1.0","response":{"outputSpeech":{"type":"PlainText","text":"Pick a difficulty level: easy, medium, hard, or genius."}},"shouldEndSession":"false","reprompt":{"outputSpeech":{"type":"PlainText","text":null}},"sessionAttributes":null} Then I want to listen for my response but alexa does not.
10 |5000

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

Galactoise avatar image
Galactoise answered
Oh, you're just trying to get the session to stay open after your output speech? That json looks pretty good to my eyes. I notice you aren't returning a card, but I wouldn't expect that to mess with the session state. The only other suggestion I have is maybe don't return a reprompt with a null text. Either add some text in there, or just make the entire reprompt object null.
10 |5000

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

Steve L. avatar image
Steve L. answered
I have tried with and without the reprompt without any success. I have also added a card but have the same problem with or without it. The only other thing that might be causing it is that I am using a Lambda function as a passthru. The json is fetched from an external server and passed to AWS. Would that cause this?
10 |5000

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

Steve L. avatar image
Steve L. answered
Got the answer in the debug forum, wahoo!
10 |5000

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

April L. Hamilton avatar image
April L. Hamilton answered
Steve - could you provide the link, so anyone who finds [i]this[/i] thread first can drill down to the solution from 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.

Levon@Amazon avatar image
Levon@Amazon 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.