Request for https://homegraph.googleapis.com/v1/devices:reportStateAndNotification failed: 403

The problem is that it works, so we will have little luck getting the code owners to look for a problem (that isn’t in their code). I followed the instructions accurately on my old build and I had errors. Followed the identical process on a new build and I have zero errors. My installation had a gremlin, not the Google Assistant code as such. So thats my/our problem to solve. If this thread had many many more complaints it might get attention. I suppose a long standing deployment of HA can acquire cobwebs that trigger a fault like this. Good luck.

PS. I did try a supervisor snapshot restore on a fresh install, that was no good - it just imported the bug to the new build.

You can add me to the list of complaints.

Have you guys who are having issues created a service account key like the documentation states and added it to your config?

yes indeed.

The cloud dashboard should show you the errors on google’s end, you’ll want to check there to see what’s being thrown.

hey guys,

the problem is solved here :slight_smile:

I have the same error 404 and i have already the agent_user_id define in my automation, but not the good one…i previously put the admin one (create by the system) and its the user one that is needed…lol

Now, good buy the 404 error, even when i automate the syncing.

enjoy

1 Like

I did all of this, none of my devices are showing up in my Google Home App

I ran into the same issue. I tried several things which did not help:

  • Disable and re-enable Homegraph API
  • Restart home assistant
  • Recreate project

What finally helped to fix the errors was to first unlink my Project in the Google Home app (Android) and then relink the Project again. Relinking without unlinking did not help!

Hope this helps.

hello @Anders_Karlstrom,

thanks for this solution, i lost my mind today to unlink/relink my “test” account in google assistant…

What is really strange is i succeed, it works for 2 hours and then i can syncing anymore…

Then i read your POST, and go to the API Homegraph page with your link, and surprise, the Homegraph API wasnt active anymore!!! but i activated 2 hours before…dont understand how the Homegraph API can desactivated by itself??

Thanks

I have exactly the same problem for more than month now.
50% for both servises.

It like every second request to homeassistant API is throwing empty or error response. I even tried to keep one light only in my configuration for GA - still same 50% error rate on Google side - nothing helps. This is super suspicious.

I run HA core as separate container, and it is updated to latest version every week, now it is 0.108.3. I do not really think that rebuilding HA would help, but I might try this as well - since it helped you @Milster

I have also tried everything:

  • As part of my last HA install (as it breaks completely every 4-6mths) I imported only the config;
  • I unlinked+relinked - and everything previous to that;
  • I Recreated project on GCP and Actions - and everything previous to that.

No luck whatsoever. Next time I get to reinstall I will do it from scratch including confs.
Till then will have to live with 50% errors and a huge error log.
Any news are appreciated, otherwise count me on the list of complains…

1 Like

Actually, I finally got time to deep a little more into this issue.
I was able to find the problem with 50% of errors in GraphAPI. For some unknown reason I had two accounts in .storage/google_assistant file. One of the account is mine ID from HA, the other account was causing the errors all the time during the request, since routine was reporting states for each of these accounts.
So solution is either modify the file, or delete it and reling your account. 50% of errors are gone.

I still have other problem with Google Actions not reaching my HA api. But that is different story - a lot of “failed with code: BACKEND_FAILURE” in StackDriver logger. Hopefully I will be able to solve this too.

3 Likes

That could have been the case for me. As I reinstalled from scratch the problem was gone. I guess the file you mentioned came with the config restore I did previous. Thanks.

I had this error too. Upon checking i realized that my service account was created under a different project. So i deleted the service account key and created another one under the home assistant project. Replaced the file in config.yaml. unlinked and relinked test app. Enabled homegraph api again. No more errors.

1 Like

Finally got rid of them! I had this issue too. Did my setup following the instructions about a couple of weeks ago (so that means I used a service account). I got thousands of Request for https://homegraph.googleapis.com/v1/devices:reportStateAndNotification failed: 404 as well as 403’s each day in my log. Enabling HomeGraph API in Google Cloud Console got rid of the 403’s, but the 404’s remained. In Cloud Console I could see that it had done 130.000 requests in the past week, almost exactly 50% of which were failed.

Now this evening, I tried to set report_state: false in my google_assistant config. No more errors! Tried to open the lights screen on a Nest Hub an turning the lights off using a Zigbee switch, and after around 3 seconds the state updated on the Nest Hub. I then disabled HomeGraph API in Cloud Console and restarted Home Assistant; still no errors and still working. Sweet!

1 Like

Well, that’s not really a fix then is it? You simply disable the report state (which is why the API is needed in the first place). Obviously the errors won’t show up after that, since there is no call anymore.

404:s mean we are reporting entities that was never exposed to google in a sync request. Re-sync your entities.

2 Likes

I re-synced and the errors continue. Looks like this is not it.

I get this error too and no data shows up in homegraph api screen so i dont think any requests are getting through

getting data now shows 50% error rate.

how can you tell if its even working?

I just had this error and apparently elupus is right.
I re-synced my devices and the message stopped.