Fairly new to Home Assistant, however im having a lot of trouble with this installation, I am getting sent on a wild goose chase for the subscriber_id when I look at the logs, the file google is apparently looking for is never correct:
Error Codes:
Configuration error: Subscription misconfigured. Expected topic name to match ‘projects/sdm-[a-z]+/topics/.*’ but was 'projects/XXXXXXXX/topics/XXXXX’.
1:26:55 AM – Nest (ERROR)
Configuration error: Subscription misconfigured. Expected subscriber_id to match ‘projects/./subscriptions/.’ but was 'projects/sdm-prod/topics/enterprise-XXXXXXXXXXXXXXXXXXXXXXX
1:30:06 AM – Nest (ERROR)
Configuration error: Subscription misconfigured. Expected subscriber_id to match ‘projects/./subscriptions/.’ but was 'projects/XXXXXXXX/topics/XXXX’
1:34:28 AM – Nest (ERROR)
Configuration error: Subscription misconfigured. Expected topic name to match ‘projects/sdm-[a-z]+/topics/.*’ but was 'projects/XXXXXX/topics/XXXX’XX.
1:36:35 AM – Nest (ERROR)
Pretty sure I’ve tried every combination, can anyone help?
FYI, I have used:
projects/XXXX/subscriptions/XXXXX
in the .yaml file and after restarting I still get the error report quoting
FYI, try and use backquotes around your code so it appears as ‘code’. The </> button on the bar will add single quotes around inline words/phrases/sentences or triple quotes around a block of text, or your can just type them. The triple quotes need to be on a line before the block by themselves and on a line by themselves after the block to end the ‘code’…
Inline code: Configuration error: Subscription misconfigured. Expected topic name to match 'projects/sdm-[a-z]+/topics/.*' but was 'projects/XXXXXXXX/topics/XXXXX' …and then the sentence can continue.
Block code:
1:34:28 AM – Nest (ERROR)
Configuration error: Subscription misconfigured. Expected topic name to match 'projects/sdm-[a-z]+/topics/.*' but was 'projects/XXXXXX/topics/XXXXX.
What do we mean when under the OAuth Error 400: redirect_uri_mismatch when it says, “[… it] must use a publicly known hostname, though your Home Assistant ports do not need to be exposed to the internet”? Below that it says something about using a hosts file to temporarily assign a public hostname…
Using port forwarding on my firewall, I have it working. When I close that external port, it stops working after a few days. Delete the integration, open the port, add it again, close the port, its good until it stops, rinse and repeat. I’ve obviously misunderstood something here!
If I don’t want to expose my whole HA to the Internet, can I just somehow make my external “public hostname” accessible from inside my network (i.e., block external traffic to that port through the firewall) and have it continue working non-stop?
Correct you don’t need to expose anything., As you’ve said.
The part where it stops working: is that due to needing reauthorization? See discussions atelier in the thread about the oauth consent screen and making sure it’s not set to Testing.
Thanks for the hint on the testing. With over 1200 posts in this thread it’s hard to get through everything.
I see that in testing mode the token only lasts for a week. So, if I simply change it to production mode, the expectation is that I can disable my external access forever (once its properly setup in the first place)? Am I understanding that correctly?
To be honest, the best thing to do is start at the beginning of the instructions and make sure you have followed them exactly. I’ve followed this forum since near the start, and almost everyone who has had a problem resolved it my ensuring they have followed the instructions.
From what I can see you have two types of error there. One to do with topic and one to do with subscription. The subscription id is stored in your config.yaml, but I’m pretty sure (from memory) that topic is entered against the subscription on the google console somewhere. So if you have put something with topic in it in your config.yaml, then you’ve entered it in the wrong place.
I would suspect that when you get the topic error, you have the subscription id right, and when it reaches across to google, it is telling you that you have the topic configured wrong there. I’m sure Allen can confirm if that is right or wrong.
You’re good to go! You don’t need to expose anything on the internet at all (unless that is the only way your browser can access your public dns name because you don’t have hairpin nat or something)
Yep, exactly right. This is spelled out in detail in the instructions and it’s subtle and easy to get wrong. Likely they have a separate cloud pubsub topic configured instead of the sdm topic.
I took your advice and found my error, which was this:
The Topic name should match the topic name in your project in the Device Access Console and typically looks like projects/sdm-prod/topics/EXAMPLE . The SDM topic names do not show up by default so make sure to Enter topic manually .
I’d created different topic names.
Don’t suppose that’s a Lembeh Cuttlefish in your avatar? I lived there for close to 15 years pre pandemic.
I have my system set up this way with a single credential but a prod and test auth callback urls in the allow list configured in the consent screen. It all works fine.
Close, but not quite. It is a Komodo cuttlefish, from an absolutely amazing trip in 2019. We are booked for Lembeh later this year, not sure it will happen though. Staying at Dive into Lembeh. Stayed a KBR twice before, brilliant diving.
I have it open for other reasons: using the companion apps, webhooks from smarts things, etc.
Definitely don’t need to externally for Nest integration at all. You just need a public domain name, but it doesn’t have to be open to access from the internet.
Once you set your app status as ‘In production,’ your app will be available to anyone with a Google Account. Depending on how you configure your OAuth screen, you may have to submit your app for verification"
For some reason, the integration now only sees one of my two Nest thermostats. When I get to the authorization screen, it shows me both of them and they’re both set to be allowed for the application, but Home Assistant only sees one of the two.
Hi, check out discussion for workarounds for this bug on the Google side https://github.com/home-assistant/core/issues/46412 that make it appear again. For me, restarting the thermostat did the trick, and for others changing something in the nest / home app makes it work.