Home Assistant and Smartthings New Integration Error / "error":{"code":"UnexpectedError","message":"A non-recoverable error condition occurred.","details":[]}}

Tags: #<Tag:0x00007f739a89ced8>

New installation of homeassistant, followed directions to integrate with smartthings, created the API key with the permissions as described, and using the nabu casa for webhook.

I click add smartthings integration, it shows me to confirm the callback url which is https://hooks.nabu.casa/“LONG String omitted here”
I click submit, then paste the access token (with no additional space before or after) and click submit,
The it prompts me to select location, with only one option “Home” and click submit

The next step is “Authorize Home Assistant” and I click the link to “OPEN WEBSITE”
I’m prompted to login to Samsung (if I’m not already logged in in another tab, which I tried also)

And in the new tab it immediately fails with the error:
{“requestId”:"LONG STRING OMITTED HERE,“error”:{“code”:“UnexpectedError”,“message”:“A non-recoverable error condition occurred.”,“details”:[]}}

I’ve tried to do this about a dozen times, rebooting, confirming the webhook wasn’t there , creating a new access token, etc but still fails same error. I noticed a script exists to delete smartthings keys on homeassistant, but I’m running homeassistant os so I’m not clear what the process would be ?

running 4.13 on a VM

Any suggestions to get this working would be greatly appreciated
One additional detail, I noticed the url from the “OPEN WEBSITE” button in Homeassistant
starts with the url :
https://account.smartthings.com/login?redirect=https%3A%2F%2Fstrongman-regional.api.smartthings.com%2F%3FappId%3D

Followed by a number with dashes in the same exact format as the samsung personal access token
(but it’s not the same number, maybe an older credential?) I tried changing it to be the same and submitting that url request but it didn’t help…

Thanks,
Rob

2 Likes

In my case i solved modifiyng the url.

https://strongman-regional.api.smartthings.com/?appId=[MY_APP_ID]&appType=ENDPOINTAPP&language=en&clientOS=web&theme=smartthings

i remove the “theme” parameter

https://strongman-regional.api.smartthings.com/?appId=[MY_APP_ID]&appType=ENDPOINTAPP&language=en&clientOS=web

and i got the integration.

15 Likes

@samuelecarpene this fixed it for me. Thank you! For anyone else who comes upon this, also wanted to link to the related GitHub issue: https://github.com/home-assistant/core/issues/40771

2 Likes

Thank you for fast response!
This fixed the issue for me also, thank you!

For others having same issue:
The next step is “Authorize Home Assistant” you will see a link in home assistant to : “OPEN WEBSITE”

Don’t click the link, instead right click and copy, then paste to notepad,

delete the last part of the URL:
%26theme%3Dsmartthings

Now copy the new link and paste it into a new tab and Samsung will confirm your permissions correctly now.

1 Like

OMG - Thank you. This was Driving me crazy!!!

Fixed my integration now. Thx

This also solved may issue thanks for the post.

Thanks! Problem solved.

Awesome, I have spent the last 3 days trying to figure this out. My next step was to rebuild HA. I tell my students that it is always something simple. In this case it was just removing the “theme” parameter. Thank you @samuelecarpene

OMG!! You have just cured literally weeks of me not being able to figure this out, it was driving me insane. Thank you so much

Works fine! thanks man!

Thanks a ton, this helped! I started with my own https then switched over to Nabu Casa - apparently the url never updated and so I went ahead and tried to readd the integration. Thought I messed something up even more!

Ran into the same issue trying to set up a Sensi thermostat. The suggested fix of removing part of the link solved the issue… Many thanks!

Thank you so much, that fixed it for me

Worked for me to, thanks!