Setting up Google Actions for Assistant

Thanks. How do you add more devices? Did you unlink all devices before add it again?

Yes, I unlink the Hassio Device in the GA ā€œHome controlā€ section and then re-add it

Add

base_url: xxx.duckdns.org

and forward 443 to 8123 IP of your hassio

mine

http:
  # Uncomment this to add a password (recommended!)
  api_password: !secret api_password
  ssl_certificate: /ssl/fullchain.pem
  ssl_key: /ssl/privkey.pem
  base_url: !secret base_url

yes and unfortunately all rooms are gone, each time

I just unlink and relink 2 times. So far it worked

I have 98. I do not think there is a limit

yes, no problem here just this:

google_assistant:
  project_id: hassio-xxxxb
  client_id: xxxx
  access_token: xxxx
  exposed_domains:
    - switch
    - light
    - script
    - media_player
    - scene

Hi!

I was struggling with this one for a while and i was really close to ask this community for help. I noticed when i looked at the error from the webpage (invalid client id error) that the client-id was not the same as i use now. The solution was to press ā€œtest draftā€ once again on the google action page. Took a while for me to figure this out, and it may help other out there.

1 Like

I get an error when adding my ā€œdeviceā€ in Google Assistant:

Google

  1. Thatā€™s an error.

The server encountered an error and could not complete your request.

If the problem persist, please report your problem and mention this error message and the query that caused it. Thatā€™s all we know.

Any suggestions on what to check next? I donā€™t see any requests in Home Assistantā€™s log.

edit: Got past this now. I created new client_id and access_token as explained in documentation. The first ones were 256 chars long, maybe thatā€™s too long.

I just set this up, works like a charm.

I donā€™t have any problem,just wanted to give a huge thanks to @PhilK for this awesome integration! I struggle trying all sort of thing (emulated hue, with android emulator, emulated google home, ā€¦) and this is the first one working straight out of the box :+1:

1 Like

Anyone know why Iā€™d be getting a ā€œ403: Forbiddenā€ when I click the [test] My App Name link in the Google Assistant app? It opens a browser, directs me to assistant.google.com, which then redirects to https://[myhass]/api/google_assistant/auth with a huge URL including a very long base64 encoded state GET variable.

I wonder if my nginx reverse proxy might be blocking the request for being too long?

1 Like

And just as soon as I post this, I find the issue. For anyone who runs into a similar issue: Make sure that if you have split horizon DNS or similar that you are hitting your HASS instance from the outside. Public DNS will push the same URL externally via my external IP whereas inside my network it is local.

This was stopping ouath2 from working. When I disabled wifi and went externally via 4G it worked for me. Something to consider if your implementation is as complex as mine.

Sorry to all but IĀ“m very noobie to all of these, I donĀ“t know if I misunderstood anything on the instructions, but how can I know which is my client_id, and my access token?

You just randomly generate one for each and put them in the config, youā€™ll later have to enter it in your developer console

tks very much where I can generate?

For example use this command line:

cat /dev/urandom|fold -w 120|head -n 1|base64 -w 0|tr -dc '0-9A-Za-z'|cut -c -80

If youā€™re not under Linux, you could also use this website:

http://www.unit-conversion.info/texttools/random-string-generator/
Just change Length to 80 and click Generate

2 Likes

Even after that changed Iā€™m still stuck with this infinite redirect bug. I do appreciate your help so far!

Edit: Something happened, it worked-ish!

Edit: It only works when I have no exposed domains. But when I expose one it will not comply!

1 Like

I am still facing this annoying problem. I tried relink the account whole days and it wasnā€™t successful. I took a rest and tried again just now. Suddenly it was successful even though not all entities are added. Then I unlink the account and relink again. No l devices were added. I tried few dozen times and still unsuccessful. This makes it hard to work on.

1 Like

you think is possible to enquire and get as response sensor values?

Hi, can somebody help?

Iā€™ve got all the way to the end of the setup, configured everything, Https ready, ports open, but when I add the [test] My App in Google Assistant, it redirects, I see HASS redirection, but then I repeatedly get a message:

Couldn't update the setting. Check your connection

Help anyone?