Is this even possible?

Tags: #<Tag:0x00007f3267b679c0>

Totally new to Home Automation and have just started using HA and node red. What I’m trying to achieve is the following.

From Google Nest Mini “Hey google, Search youtube for Pink Flloyd” this is then sent to Node red and this can then be filtered and actioned?

I would say, no and maybe.

No if you use the built-in google/alexa api stuff. Maybe if you write your own api endpoint software.

I’ve manually set up my own alexa endpoint using the 100 step process of creating the endpoint and everything. However, I didn’t write my own script in the AWS section…I just copied someone else’s.

To summarize, what is going on is Home Assistant knows how to respond to Google/Alexa query for “what smart devices do you have?”.

These devices all must follow an API. For example, if it’s a binary_sensor, it must be able to report if it is on or off. If it is a light, it has to know how to convert the google/alexa ‘on’ or ‘off’ command to whatever commands home assistant uses. This is kind of what the script is doing for you.

Your voice commands to google/alexa go to their own private server. From there, they are analyzed. It will figure out what you’ve said. Then from the list of devices it knows about (from the discovery query) can figure out what to do with the command. If it doesn’t know, it will reply with the canned “Sorry, I don’t know how to do that, maybe you need a new skill” type thing.

In the current list of available domains for google, found here:

you can see what domains are supported and what info they get passed. We can’t really modify the info passed…that stuff is parsed from google and is what is sent to us. By the time we see the request, it will send us only the relevant info.

I think the closest you can get is with:

  • media_player (on/off/set volume (via set volume)/source (via set input source)/control playback)

If you created a media_player device in node red, you could register it to google. Now when you say “hey google, play pink floyd on <my node red media_player>”, it might be able to send you this command…maybe. However, I’m worried that ‘set input source’ is nothing more than ‘change to hdmi1’ rather than ‘change to youtube’ at this time.