node-red-contrib-alexa-remote2
node-red-contrib-alexa-remote2 copied to clipboard
Authentication fail after Deploy in Node-Red
Hello,
Tks for your nice work. I get this working but having issue. Each time I hit deploy, I get "Authentication failed: "Authentication unsuccessful"" I do have to restart Node-Red to have the option localhost:3456 and then redo the name and password authentication in the browser. It work until I not adding new stuf. Do I miss something? Any help is welcome. Regards,
I get the same issue after a restart or deploy after a day or two. I set my alexa account IP to my pi's IP so I don't have to connect to the pi to do the page auth. I use the Fresh Authentication method and the service node with entitiy echo.
for me the german servers did not work/authenticate, but the american servers worked fine
I'm faced with the exact same issue. I've tried using every server listed, but no luck so far. Is there a specific one for each country ? I'm from France, so I'm not sure if this is even supposed to work.
It might have something to do with the address of my alexa thing being set to an American adress (did it to enable spotify/tidal support)
Here's a flow that seems to work well for me:
[{"id":"fac6639c.f02c1","type":"tab","label":"Alexa Voice Handler","disabled":false,"info":""},{"id":"974de7ab.103c98","type":"alexa-remote-init","z":"fac6639c.f02c1","name":"","account":"b8d86056.e5bce","option":"initialise","x":560,"y":80,"wires":[[]]},{"id":"c93167cd.80be48","type":"inject","z":"fac6639c.f02c1","name":"FlowStart","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"","crontab":"","once":true,"onceDelay":0.1,"topic":"","payload":"","payloadType":"date","x":120,"y":80,"wires":[["974de7ab.103c98"]]},{"id":"a62c6bf0.fb5cc8","type":"alexa-remote-event","z":"fac6639c.f02c1","name":"","account":"b8d86056.e5bce","event":"ws-device-activity","x":140,"y":320,"wires":[["c15cfaad.bc44f8","35bff807.72daa8"]]},{"id":"e021a31e.990f6","type":"inject","z":"fac6639c.f02c1","name":"Refresh once an hour","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"3600","crontab":"","once":true,"onceDelay":"0.1","topic":"","payload":"","payloadType":"date","x":160,"y":160,"wires":[["94b637a5.e302a8"]]},{"id":"94b637a5.e302a8","type":"alexa-remote-init","z":"fac6639c.f02c1","name":"","account":"b8d86056.e5bce","option":"refresh","x":560,"y":160,"wires":[[]]},{"id":"a25d99ad.f21158","type":"change","z":"fac6639c.f02c1","name":"extract summary","rules":[{"t":"set","p":"name","pt":"msg","to":"payload.name","tot":"msg"},{"t":"set","p":"summary","pt":"msg","to":"payload.description.summary","tot":"msg"},{"t":"set","p":"payload","pt":"msg","to":"summary","tot":"msg"}],"action":"","property":"","from":"","to":"","reg":false,"x":350,"y":420,"wires":[["3b1abb8b.dfb5a4","d508558e.a23508"]]},{"id":"35bff807.72daa8","type":"debug","z":"fac6639c.f02c1","name":"ALL","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","x":340,"y":260,"wires":[]},{"id":"c15cfaad.bc44f8","type":"switch","z":"fac6639c.f02c1","name":"Only pass SUCCESS messages","property":"payload.activityStatus","propertyType":"msg","rules":[{"t":"eq","v":"SUCCESS","vt":"str"}],"checkall":"true","repair":false,"outputs":1,"x":420,"y":320,"wires":[["b87b0099.7875e"]]},{"id":"b87b0099.7875e","type":"switch","z":"fac6639c.f02c1","name":"Filter out noise","property":"payload.description.summary","propertyType":"msg","rules":[{"t":"eq","v":"","vt":"str"},{"t":"eq","v":"alexa","vt":"str"},{"t":"else"}],"checkall":"true","repair":false,"outputs":3,"x":130,"y":420,"wires":[[],[],["a25d99ad.f21158"]]},{"id":"46ecac80.4fe934","type":"alexa-remote-routine","z":"fac6639c.f02c1","name":"Acticulate response","account":"b8d86056.e5bce","routineNode":{"type":"speak","payload":{"type":"announcement","text":{"type":"msg","value":"payload"},"devices":{"type":"msg","value":"name"}}},"x":790,"y":620,"wires":[[]]},{"id":"3b1abb8b.dfb5a4","type":"function","z":"fac6639c.f02c1","name":"Save requesting Alexa Device Name","func":"global.set('lastAlexName', msg.name);\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","x":690,"y":400,"wires":[["30857edc.bd5a52"]]},{"id":"ec9fce7.70e1c3","type":"function","z":"fac6639c.f02c1","name":"Restore requesting Alex Device Name","func":"msg.name = global.get('lastAlexName');\nreturn msg;","outputs":1,"noerr":0,"initialize":"","finalize":"","x":470,"y":620,"wires":[["46ecac80.4fe934"]]},{"id":"3f577e15.c8efa2","type":"catch","z":"fac6639c.f02c1","name":"Catch refresh error","scope":["94b637a5.e302a8"],"uncaught":false,"x":130,"y":120,"wires":[["8e74cf80.4635c"]]},{"id":"8e74cf80.4635c","type":"delay","z":"fac6639c.f02c1","name":"","pauseType":"delay","timeout":"10","timeoutUnits":"seconds","rate":"1","nbRateUnits":"1","rateUnits":"second","randomFirst":"1","randomLast":"5","randomUnits":"seconds","drop":false,"x":360,"y":120,"wires":[["974de7ab.103c98"]]},{"id":"d30770c4.762ac","type":"mqtt in","z":"fac6639c.f02c1","name":"","topic":"Alexa/VoiceResponse","qos":"2","datatype":"auto","broker":"60346d2e.382554","x":150,"y":620,"wires":[["ec9fce7.70e1c3"]]},{"id":"30857edc.bd5a52","type":"mqtt out","z":"fac6639c.f02c1","name":"Alexa/VoiceRequest","topic":"Alexa/VoiceRequest","qos":"2","retain":"false","broker":"60346d2e.382554","x":990,"y":400,"wires":[]},{"id":"c8e85257.0b72b","type":"comment","z":"fac6639c.f02c1","name":"Initialize Credentials for Alexa access","info":"","x":200,"y":40,"wires":[]},{"id":"9824fac0.fb2f98","type":"comment","z":"fac6639c.f02c1","name":"Handle Inbound Voice Requests","info":"","x":170,"y":220,"wires":[]},{"id":"b0a2adc1.2bb77","type":"comment","z":"fac6639c.f02c1","name":"Handle request for Alexa Voice Reponse","info":"","x":230,"y":560,"wires":[]},{"id":"d508558e.a23508","type":"debug","z":"fac6639c.f02c1","name":"ALL","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"true","targetType":"full","x":590,"y":480,"wires":[]},{"id":"b8d86056.e5bce","type":"alexa-remote-account","name":"","authMethod":"proxy","proxyOwnIp":"172.16.16.175","proxyPort":"3456","cookieFile":"/home/pi/.node-red/public/alexa.txt","refreshInterval":"1","alexaServiceHost":"pitangui.amazon.com","amazonPage":"amazon.com","acceptLanguage":"en-US","userAgent":"","useWsMqtt":"on","autoInit":"on"},{"id":"60346d2e.382554","type":"mqtt-broker","name":"DrBus","broker":"172.16.14.10","port":"1883","clientid":"","usetls":false,"compatmode":false,"keepalive":"60","cleansession":true,"birthTopic":"","birthQos":"0","birthPayload":"","closeTopic":"","closeQos":"0","closePayload":"","willTopic":"","willQos":"0","willPayload":""}]
Here's a flow that seems to work well for me:
Thanks for the suggestion. I tried with this flow, but unfortunately the issue persists.
Have the same issue. Tried out everything. Hope we'll find a solution. I moved my Node-red from Raspberry to a Node-Red Container but it still doesn't work.
Having the same issue with Node Red as Home Assistant Addon.
Home Assistant Supervisor: 2020.12.7 Node Red Addon: 7.2.11
I have the same problem. not sure if it matters, but I have an amazon.ca account.
Home Assistant Supervisor: 2020.12.2 Node Red Addon: 7.2.11
*Update: I stumbled onto this link: https://peyanski.com/alexa-tts-how-to/
he suggested using alexa.amazon.it as the service host. it worked for me.
one more update Since I have a Canadian account, I tried the following settings and they seem to work: Service Host: alexa.amazon.ca Page: amazon.ca Language: en-US
Thanks @nj2299 this seems to be working for me.
I have the same problem. not sure if it matters, but I have an amazon.ca account.
Home Assistant Supervisor: 2020.12.2 Node Red Addon: 7.2.11
*Update: I stumbled onto this link: https://peyanski.com/alexa-tts-how-to/
he suggested using alexa.amazon.it as the service host. it worked for me.
one more update Since I have a Canadian account, I tried the following settings and they seem to work: Service Host: alexa.amazon.ca Page: amazon.ca Language: en-US