alexa

How to get the time zone or local time of Alexa device

99封情书 提交于 2019-12-23 14:47:48
问题 I want to get the "time zone" set in the settings or local date time of the Alexa device. Is there any API available for it? Or is there any option to get the date-time of the user using his postal code? Any help will be highly appreciable? 回答1: Yes, there is a native Alexa API that you can use. Here is a perfect solution for what you're looking for. What you will need is a device ID and an API access token. Also, few tools like axios ( npm i axios) and zip-to-country-code (npm i zipcode-to

How to get the time zone or local time of Alexa device

本小妞迷上赌 提交于 2019-12-23 14:45:52
问题 I want to get the "time zone" set in the settings or local date time of the Alexa device. Is there any API available for it? Or is there any option to get the date-time of the user using his postal code? Any help will be highly appreciable? 回答1: Yes, there is a native Alexa API that you can use. Here is a perfect solution for what you're looking for. What you will need is a device ID and an API access token. Also, few tools like axios ( npm i axios) and zip-to-country-code (npm i zipcode-to

Alexa Dialog Model Step and dialogState is never in COMPLETED

*爱你&永不变心* 提交于 2019-12-23 05:15:52
问题 I'm implementing an Alexa Dialog Model with an PHP Endpoint. I used the Alexa doc (https://developer.amazon.com/fr/docs/custom-skills/dialog-interface-reference.html) Here is my example: My skill: RequestIntent Utterance : add an {obj} in the bedroom Slots : {obj} / Slot Filling Phrase: Me : Alexa, Add an object in the bedroom Alexa : What object do you want to add in bedroom ? Me : I would like to add a cars in the bedroom Alexa : You want to add a car in the bedroom ? Me : Yes STEP1:

Alexa input validation for type AMAZON.NUMBER using dialog model

試著忘記壹切 提交于 2019-12-22 10:37:47
问题 I am using the ASK SDK 2.0 for Node.js. I have a skill that uses a dialog model to prompt the user for a series of inputs, all of which are required slots with the type AMAZON.NUMBER. When a user gives a numerical response, everything works fine. However, if the user gives a non-numeric response, such as "yellow", the slot value is filled in with: "value": "?" and moves on to propmpt the user for the input for the next slot. How can I get it to reprompt the user for that slot again if they

Returning handler.ResponseBuilder from promise.then() method

柔情痞子 提交于 2019-12-22 10:34:30
问题 In one of the intent handler for my Alexa skill I have to return response once my promise is resolved. Code looks like this : var rcvPromise = receiveMsgQ(); rcvPromise.then(function(speechText) { console.log('rcv Promise resolved with ',speechText); return handlerInput.responseBuilder .speak(speechText) .withSimpleCard('skill_name', speechText) .withShouldEndSession(false) .getResponse(); }); Skill returns with ERROR message with no additional details about error. Is there any way to fix

Issue decrypting Alexa request signature using openssl_public_decrypt

早过忘川 提交于 2019-12-22 00:00:31
问题 I'm implementing a validator for validating incoming requests from Amazon Alexa. I'm on step 5 and 6 which state: 5) base64-decode the Signature header value on the request to obtain the encrypted signature. 6) Use the public key extracted from the signing certificate to decrypt the encrypted signature to produce the asserted hash value. I've managed to extract the public key from the PEM-encoded X.509 certificate by doing: $publicKey = openssl_pkey_get_public($pem); $keyData = openssl_pkey

How to loop audio in Alexa

柔情痞子 提交于 2019-12-21 06:23:15
问题 I am building a ambient audio skill for sleep for Alexa! I am trying to loop the audio so I don't have to download 10 hour versions of the audio. How do I get the audio to work? I have it build to where it will play the audio, but not loop. 回答1: I've solved this problem in my skill Rainmaker: https://www.amazon.com/Arif-Gebhardt-Rainmaker/dp/B079V11ZDM The trick is to handle the PlaybackNearlyFinished event. https://developer.amazon.com/de/docs/alexa-voice-service/audioplayer.html

Hosting a custom skill to Alexa by implementing a web service

巧了我就是萌 提交于 2019-12-21 02:51:38
问题 I am working on developing a web service which is used to Handling Requests Sent by Alexa and respond back with specific response in .net framework. The request body sent by Alexa to your service in JSON format like below : { "version": "string", "session": { "new": true, "sessionId": "string", "application": { "applicationId": "string" }, "attributes": { "string": {} }, "user": { "userId": "string", "accessToken": "string" } }, "context": { "System": { "application": { "applicationId":

How can I access a local API using Amazon Alexa

时间秒杀一切 提交于 2019-12-20 14:43:12
问题 I intend to build a set of skills for Amazon Alexa that will integrate with a custom software suite that runs on a RaspberryPi in my home. I am struggling to figure out how I can make the Echo / Dot itself make an API call to the raspberry pi directly - without going through the internet, as the target device will have nothing more then an intranet connection - it will be able to receive commands from devices on the local network, but is not accessible via the world. From what I have read,

run bash script in raspberry pi via IFTTT

主宰稳场 提交于 2019-12-20 03:07:45
问题 I have a raspberry pi running Alexa (amazon echo) that can instantly push a trigger to IFTTT, for an example I say "Alexa, trigger email to blablabla" and I immediately receive an email. My Goal I want to execute a bash script on the same raspberry pi with voice command (by Alexa) via IFTTT. Is there any IFTTT recipe that can instantly push a trigger to my raspberry pi? (so that I can instantly run a bash script) (Note: Dropbox doesn't support raspberry pi, though there is an uploader