I can ask Alexa what the living room thermostat temperature is set to and I will receive the set temperature.
Is there any way I can then get Alexa to set an input_number in HA with the thermostat number?
I can ask Alexa what the living room thermostat mode is and it will reply “Auto” or “Heat” or “Cool”.
Is there any way I can then get Alexa to set an input_text in HA with the thermostat mode?
@ Didgeridrew I can easily tell Alexa to set the temperature as well as the mode via HA. What I would like to do is find out what the current settings are on my Nest Thermostat (mode and set temperature).
I can ask Alexa what temperature my Nest thermostat is set to, and get a reply. I can also look at a Home Assistant dashboard and see what temperature the thermostat is set to.
The first is handled by an Alexa skill, the second by a Home Assistant integration - my thermostat is not exposed to Alexa.
Alexa will control HA devices that are exposed to it, but I don’t think it passes data back to HA. So the answer is no.
I can control my Velux skylights from HA but don’t want to open them if the Nest mode is set to heat or cool.
I’d like to know what the temperature is currently set for before readjusting it via HA.
With Alexa I have controlled items in HA but just didn’t know if there was some way to get what is right now only a spoken response (mode, temperature) as a trigger to set something in HA. The question was really is if there is a way to make this info somehow useable.
You can test the Modes and temperature attributes of the thermostat in HA to determine what you want to do with skylight, you do not need input numbers for that. You can just create a script that does the tests.
If you want the voice command to be blocked due to the thermostat, I suggest you create a template cover which itself blocks the commands under cirtain corcumstances. I did that with blinds that cannot be controlled if the window is open.
If Alexa does not have a voice command to get the setpoint of the thermostat, you can create a script with text to speech to say the set mode (the script does need to know what smart speaker to use). You can trigger that script from alexa, and it will speak out whatever you put in the script.
@Edwin_D this is the part I don’t understand. Alexa knows the Nest mode and temperature but as far as I know it is not exposed to HA. I’m not sure how I can get this information from Alexa to HA to use.
You could use the Google SDK integration in HA.
If you send a command via this, the response can then be used within HA.
eg. I use the following using the SDK via Node Red:
“what is the temperature on thermostat?”,
“what is the humidity on thermostat?”,
“what is the thermostat set to?”,
then the response can be parsed to get the required information.
Not sure if that’d help your task…?
EDIT - I found the “custom” version of this integration is needed for this to work…
Thanks @mikep99. What is the “custom” version of the integration? I’ve tried twice to set up the google SDK and neither time got it working. I just remember going through an awful lot of steps for nothing. IF I could get that working, I’d have no need to try to get the info from Alexa.
I didn’t realize that this was just the communication part (there was another google integration that I had tried to set up). I do have this set up already BUT I do have a question for you. How do you parse the google response in HA?
I use Node Red so its different to HAs Automation.
You can write the response out as a variable in HA then use that.
You should have something similar to the below in your trace: