That could be possible.
Same with me. I read that the lastVoiceCommand is not working anymore butI had no problems and it was working as before.
But when I updated to OH4 the lastVoiceCommand stoped working…
So the question now is, are there any workarounds to getting the same functionality? When I get time I’ll experiment with workarounds, but it seems unlikely.
All my devices are Sonos Ones, which means I could even jump ship to Google Home.
FYI: I raised this issue on Amazon developer forums. No response in a week so not looking promising.
I am on OH4.0.2 and also use the lastVoiceCommand channel of my Alexa devices to run rules. This stopped working the moment I upgraded to 4.0 (a week or two ago) and I found this thread. Before I got to do anything it started working again, so no problem to report here. Living in Norway.
Yeah same here, stopped working since yesterday out of the sudden (no reboot). I’m from Germany.
If it’s permanent, it would be the sadest news from Amazon. I use it with rules a lot and is the coolest thing which I don’t want to miss in my smarthome. Anyone using google home with OH? Works it similar with “custom” voice commands combined with rules?
But what I don’t understand: If Amazon wanted to stop this functionality by intention, then why is the corresponding functionality of home assistant still working? I guess there it’s called last_called_summary and I can’t see any actual discussions that it’s failing.
For the moment I changed my rules to get triggered by dummy-items which are switched by the alexa command. It works but until now I haven’t found a way that openhab knows from which echo it got the command so it can respond to the same.
Does anybody have a workaround for this?
I remembered playing with wemos and alexa at the end of 2019 then disconnected because openhab was more responsive, since last voice comand is no longer seen by openhab I tried to turn wemos back on and it works, on wemos I only have 6 commands, and they work but they are not as fast as last voice comand I’m not very experienced but I modified this a bit for my needs
from what i understand it is because belkin simulation code still works
I have OH 3.4 and the solution I have given it for now has been the following:
You can use the api: http://openhab:8080/amazonechocontrol/account1/PROXY/api/activities?startTime=&size=1&offset=1
which with size=1 returns the last command in JSON. In that command appears the serial number of the ECHO. Using a rule you extract that serial number and you know which ECHO has been used.
Through the Alexa app I created a routine (voice command: “Alexa, power”) that activates an OH item (Item power3_value_item_tts) and I use that item to trigger the “Alexa LastVoiceCommand” rule. The whole process is very fast, since when the item has changed it is because Alexa has already interpreted the command we have given it by voice:
rule “Alexa LastVoiceCommand”
when
Item potencia3_value_item_tts received command ON
then
val String alexa_LastVoiceCommand = sendHttpGetRequest(“http://192.168.1.19:8080/amazonechocontrol/account1/PROXY/api/activities?startTime=&size=1&offset=1”)
val serialNumber_alexa_LastVoiceCommand = transform(“JSONPATH”,“$.activities[0]sourceDeviceIds[0]serialNumber”,alexa_LastVoiceCommand)
logInfo("Echo, serialNumber: ",serialNumber_alexa_LastVoiceCommand)
< Enter your code here once you know which Echo you are interacting from >
potencia3_value_item_tts.postUpdate(OFF)
end
I have added the item in *.items so that it will recognize it as a switch device in the Alexa APP:
jwiseman
(Mr. Wiseman (OH 5.1.4 Stable on Pi5))
58
If this works as described, then the binding could call this url everytime it reaches back to the api and populate the correct echo with last voice command.
The only issue i see is a timing issue on how often the binding calls the api and how many echos received a command within that period. I could easily see it missing updates.
That’s exactly why we triggered a similar call whenever the websocket reported an activity. In the past the websocket did so AFTER an activity (i.e. a command) was received by Alexa. Then it only reported an equalizer/volume change at the BEGINNING of an activity (that is why I added the 15s delay prior to the query and processed all received voice commands of the last 30s (keeping track of commands that have been processed before to avoid duplicates). Now also the equalizer/volume change reports seem to be missing.
However, the app still seems to be able to detect immediately when a voice command was detected, so most probably Amazon changed the protocols.
@All: mine is on a UK account, it doesn’t work either. Just to add to the list. Additionally I also had “dumb” routines in the Alexa app but it doesn’t help.
Example: when I say “Lights” → the only thing in the Alexa routine is say “Okay” to not to trigger a stupid response of “I don’t know that one”, and OH was handling the rest of it. Yet it doesn’t work anymore for a few weeks already, indeed since around the time I did the OH4->4.0.1->4.0.2 upgrade. I’m looking forward to any solution, will try the .kar later. Thanks for looking into it!