Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

smartthings invalid_request when authorizing integration #140126

Open
BottlecapDave opened this issue Mar 8, 2025 · 31 comments
Open

smartthings invalid_request when authorizing integration #140126

BottlecapDave opened this issue Mar 8, 2025 · 31 comments

Comments

@BottlecapDave
Copy link
Contributor

The problem

I'm trying to authorize smartthings with my home assistant instance, but when navigating back to nabucasa I'm getting "invalid_request". In the header it has the description "Unable+to+find+any+configurations+for+app"

What version of Home Assistant Core has the issue?

2025.3.1

What was the last working version of Home Assistant Core?

2025.2.0

What type of installation are you running?

Home Assistant OS

Integration causing the issue

smartthings

Link to integration documentation on our website

https://www.home-assistant.io/integrations/smartthings/

Diagnostics information

No response

Example YAML snippet

Anything in the logs that might be useful for us?

Additional information

No response

@home-assistant
Copy link

home-assistant bot commented Mar 8, 2025

Hey there @joostlek, mind taking a look at this issue as it has been labeled with an integration (smartthings) you are listed as a code owner for? Thanks!

Code owner commands

Code owners of smartthings can trigger bot actions by commenting:

  • @home-assistant close Closes the issue.
  • @home-assistant rename Awesome new title Renames the issue.
  • @home-assistant reopen Reopen the issue.
  • @home-assistant unassign smartthings Removes the current integration label and assignees on the issue, add the integration domain after the command.
  • @home-assistant add-label needs-more-information Add a label (needs-more-information, problem in dependency, problem in custom component) to the issue.
  • @home-assistant remove-label needs-more-information Remove a label (needs-more-information, problem in dependency, problem in custom component) on the issue.

(message by CodeOwnersMention)


smartthings documentation
smartthings source
(message by IssueLinks)

@joostlek
Copy link
Member

joostlek commented Mar 8, 2025

I have no clue how this happens, this is the second report so far and a ton of people already migrated, so my advice for now is to just wait and try again later

@franillanes
Copy link

Same problem here!
I noticed that it's trying to use https://account-link.nabucasa.com/ to authorize it and I don't use Home Assistant Cloud.
I'm using a Cloudfare Tunnel instead, but for some reason it doesn't use it.

@brhahlen
Copy link

brhahlen commented Mar 9, 2025

I have this same issue.
It redirects me to nabu-casa, which I don't use.

@joostlek
Copy link
Member

joostlek commented Mar 9, 2025

You don't need to have Home Assistant Cloud, it uses account linking

@cedarearthy
Copy link

Same problem here, when I try to setup the integration it also gives me the same invalid_request error on nabu casa even though I don't have a subscription

@DriesSchulten
Copy link

Since the HA update I run into exactly the same issue; my HA is available over the internet over a custom domain. I've tried to authorize it through that domain; also tried with the only internal domain but exactly the same error appears.

@tobevers
Copy link

Having the same issue. I'm using Cloudflare, rather than Nabu Casa. I've attached the error message I'm seeing. I've removed the integration, rebooted, reinstalled it, then it works for a few days before stopping and giving me the same error message again.

Image

@joostlek
Copy link
Member

@tobevers Do you run multiple instances of Home Assistant?

@tobevers
Copy link

@tobevers Do you run multiple instances of Home Assistant?

Yes, 2 instances. I have one Home Assistant install at work and one at home. I've had to reinstall SmartThings on both in the past 2 weeks. The one at work is continuing to work. The one at home has stopped working again with the error message I screenshotted and shared.

@joostlek
Copy link
Member

Are they connected to the same location? Or does every instance individually connect to their own location?

@tobevers
Copy link

Are they connected to the same location? Or does every instance individually connect to their own location?

The two instances of Home Assistant are completely separate. Concerning SmartThings, that's the only connection they have. I have a home door lock and my work door lock both in SmartThings using my work email address for SmartThings. I've signed into the SmartThings HA Integration in both HA instances using that email address. Does that answer your question?

@joostlek
Copy link
Member

In SmartThings you can have multiple locations, so is each lock in its own location?

@tobevers
Copy link

In SmartThings you can have multiple locations, so is each lock in its own location?

No, both are listed in the same location, but different rooms.

@joostlek
Copy link
Member

Check, thanks

@joostlek
Copy link
Member

@BottlecapDave Do you maybe have your location id? That would help finding the issue

@BottlecapDave
Copy link
Contributor Author

The location I'm trying to connect to is called "Home". I'm not sure where I can the location id from.

@joostlek
Copy link
Member

https://my.smartthings.com/advanced/devices there's a page in the sidebar here for locations

@DriesSchulten
Copy link

DriesSchulten commented Mar 12, 2025

I figured what was causing this and managed to fix it; I had to install the SmartThings app; go to settings; linked services; unlink Home Assistant. After that I just re-added the integration in HA and it went through the flow correctly resulting into a working integration again.

Based on the error in the URL it was SmartThings not finding the HA integration with the provided UUID. I don't use the Smartthings app (maybe originally once?) and reinstalled it to see if there was anything related to HA causing issues. I couldn't find / unlink this integration through https://my.smartthings.com; only in the app.

@joostlek
Copy link
Member

That should not be needed though, that an unrelated app from before 2025.2

@franillanes
Copy link

I figured what was causing this and managed to fix it; I had to install the SmartThings app; go to settings; linked services; unlink Home Assistant. After that I just re-added the integration in HA and it went through the flow correctly resulting into a working integration again.

Based on the error in the URL it was SmartThings not finding the HA integration with the provided UUID. I don't use the Smartthings app (maybe originally once?) and reinstalled it to see if there was anything related to HA causing issues. I couldn't find / unlink this integration through https://my.smartthings.com; only in the app.

I just tried it and now it works for me too!!

@tobevers
Copy link

That should not be needed though, that an unrelated app from before 2025.2

It also doesn't work long-term. I've done that a number of times to get it working again, but it will stop again after a few days.

@joostlek
Copy link
Member

@tobevers check #140312. that is your issue

@tobevers
Copy link

@tobevers check #140312. that is your issue

Ah, good to know. That explains why one keeps working and the other one keeps stopping. Thanks for the update. I'll move the other one to a new SmartThings account. Probably the way I should have set it up in the first place. Your work on this integration and your technical support are very much appreciated!

@joostlek
Copy link
Member

You can use a separate location btw.

But it's something I'm looking to fix

@BottlecapDave
Copy link
Contributor Author

I've just tried removing the old home assistant link in the Samsung app and Ive successfully added the integration so that must have been it.

@joostlek
Copy link
Member

@BottlecapDave do you name still have the location id so we can find out what went wrong?

@BottlecapDave
Copy link
Contributor Author

I stupidly wasnt thinking when I removed the original link, so I don't have the original location id. I can give you the new one that worked, but I don't think that's going to be much use to you.

@joostlek
Copy link
Member

Oh you created a whole new location in SmartThings?

@BottlecapDave
Copy link
Contributor Author

I didn't, I just followed the instructions around unlinking HA from the app and re-adding. The id of the location I had issues with is 0b41f997-15e6-499c-9d0a-e7e335753450

@joostlek
Copy link
Member

Okay so I checked with the ST team and apparently it can happen that this happens and that removing the HomeAssistant entry in the SmartThings app can work. I can open a PR for the documentation when I have time (when anyone else feel like doing it, feel free to help out :) )

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

7 participants