alexa-skill

How to use async functions within Alexa skill properly?

蹲街弑〆低调 提交于 2021-02-11 17:41:58
问题 I am very new to async programming, so forgive me for the lack of understanding, but I am currently building an Alexa skill which calls a private parking API. You can call this API and it will give you the nearest parking spots. const getParkingSpots_Handler = { canHandle(handlerInput) { const request = handlerInput.requestEnvelope.request; return request.type === 'IntentRequest' && request.intent.name === 'getParkingSpots' ; }, handle(handlerInput) { const request = handlerInput

How to get and use confirmation 'yes' or 'no' for Alexa skill intent response

99封情书 提交于 2021-02-07 06:25:07
问题 I am developing a Alexa skill in which on launch it will ask Do you want to perform something ? Depending upon user's reply 'yes' or 'no' I want to launch another intent. var handlers = { 'LaunchRequest': function () { let prompt = this.t("ASK_FOR_SOMETHING"); let reprompt = this.t("LAUNCH_REPROMPT"); this.response.speak(this.t("WELCOME_MSG") + ' ' + prompt).listen(reprompt); this.emit(':responseReady'); }, "SomethingIntent": function () { //Launch this intent if the user's response is 'yes'

How to get and use confirmation 'yes' or 'no' for Alexa skill intent response

怎甘沉沦 提交于 2021-02-07 06:24:32
问题 I am developing a Alexa skill in which on launch it will ask Do you want to perform something ? Depending upon user's reply 'yes' or 'no' I want to launch another intent. var handlers = { 'LaunchRequest': function () { let prompt = this.t("ASK_FOR_SOMETHING"); let reprompt = this.t("LAUNCH_REPROMPT"); this.response.speak(this.t("WELCOME_MSG") + ' ' + prompt).listen(reprompt); this.emit(':responseReady'); }, "SomethingIntent": function () { //Launch this intent if the user's response is 'yes'

Trigger Alexa speaking

放肆的年华 提交于 2021-01-29 02:20:34
问题 I'd like to be able to remotely cause Alexa to say something on my Echo. A specific use case would be to notify my wife that I'm leaving work. I currently use Waze to do this, but it would be very convenient if Alexa could be triggered to say "Ron is on his way home" also. I've talked with people about this, and I don't think Amazon supports this yet. I'm posting here to give us a place to find out if/when that support happens, or inform us if it is somehow possible now. 来源: https:/

Trigger Alexa speaking

蹲街弑〆低调 提交于 2021-01-29 02:11:29
问题 I'd like to be able to remotely cause Alexa to say something on my Echo. A specific use case would be to notify my wife that I'm leaving work. I currently use Waze to do this, but it would be very convenient if Alexa could be triggered to say "Ron is on his way home" also. I've talked with people about this, and I don't think Amazon supports this yet. I'm posting here to give us a place to find out if/when that support happens, or inform us if it is somehow possible now. 来源: https:/

Trigger Alexa speaking

瘦欲@ 提交于 2021-01-29 02:08:35
问题 I'd like to be able to remotely cause Alexa to say something on my Echo. A specific use case would be to notify my wife that I'm leaving work. I currently use Waze to do this, but it would be very convenient if Alexa could be triggered to say "Ron is on his way home" also. I've talked with people about this, and I don't think Amazon supports this yet. I'm posting here to give us a place to find out if/when that support happens, or inform us if it is somehow possible now. 来源: https:/

How to add single word invocation name alexa?

南笙酒味 提交于 2021-01-27 20:12:11
问题 I want to add a single word invocation name for Alexa, in documentation its mentioned that a single word is allowed. One-word invocation names are not allowed, unless: The invocation name is unique to your brand/intellectual property with proof of ownership established through legitimate documentation, or (German skills only) The invocation name is a compound of two or more words. In this case, the word must form an actual word in the skill's language to ensure that Alexa can recognize it.

How to make Alexa countdown in seconds

不羁的心 提交于 2021-01-27 11:53:45
问题 I want to be able to have alexa (audibly) countdown 15 seconds in my skill. I know I can just <break time="15s" /> in SSML. But that isn't audible. I also know I can just do: 15<break time="1s" /> 14<break time="1s" /> or better yet (to account for the time it takes to say the number) 15<break time="0.85s" /> 14<break time="0.85s" /> But that's going to be a ton of repeated code if I do this many times over. So I'm probably going to write a function that takes in a number and a number of

How to make Alexa countdown in seconds

馋奶兔 提交于 2021-01-27 11:52:12
问题 I want to be able to have alexa (audibly) countdown 15 seconds in my skill. I know I can just <break time="15s" /> in SSML. But that isn't audible. I also know I can just do: 15<break time="1s" /> 14<break time="1s" /> or better yet (to account for the time it takes to say the number) 15<break time="0.85s" /> 14<break time="0.85s" /> But that's going to be a ton of repeated code if I do this many times over. So I'm probably going to write a function that takes in a number and a number of

How to make Alexa countdown in seconds

坚强是说给别人听的谎言 提交于 2021-01-27 11:51:02
问题 I want to be able to have alexa (audibly) countdown 15 seconds in my skill. I know I can just <break time="15s" /> in SSML. But that isn't audible. I also know I can just do: 15<break time="1s" /> 14<break time="1s" /> or better yet (to account for the time it takes to say the number) 15<break time="0.85s" /> 14<break time="0.85s" /> But that's going to be a ton of repeated code if I do this many times over. So I'm probably going to write a function that takes in a number and a number of