SmartThings Community

Oauth Error for Obtaining Access Code 500

(Mathew Heard) #21

@tryagain I am also on the NA-02 region, perhaps thats the reason…

BTW I bumped this thread after posting a new thread a few weeks before (OAuth Internal Error).

(Erobertshaw) #22

After following the tutorial: I ran into the same 500 error problem

Adding an input device got me past the 500 error (editing the preferences in the code to include an actual input).

I then hit a second error “no devices” error. I solved this by calling my input “devices” (Even when selecting devices).

preferences {
 section ("Allow external service to control these things...") {
  input "devices", "capability.switch", multiple: true, required: false

Let me know if this helps anyone else, it could have just been someone fixed the server…

Update It would appear the device name doesn’t matter. Its the required flag that was changed to false that allowed me to proceed.

OAuth Internal Error
(Mathew Heard) #23

@erobertshaw I am not certain, but the input we have already has required: false. And its already been configured from a mobile device to connect sensors.

As of today the issue still happens. I have also started seeing the error when logging in via the regular login (although the login still occurs).

(Jay Baker) #24

I am getting this as of today. I get the 500 error.
I have tried both the
and the

shards. My app is on the na02 shard.

I tried the example ruby app and I also tried my own app (non-ruby).


If this is temporarily broken I sure would like to know so I don’t waste a bunch of time.

( #25

Same problem here. I have tried all of the proposed solutions. Has anyone got it working yet?

(Doug Beard) #26

I began having this problem about two days ago. I thought I was doing something wrong, since I was in development. The more I’ve investigated, the more I’ve realized ST is broken. I’m very frustrated by the amount of hours I’ve dumped into this with no resolution.

I also rebuilt the app to get new clientId and secret, etc with no luck.

(Ben Dixon) #27

I know this is an old thread, but has anybody resolved this? I’m familiar with this process and I’ve been trying for two days and get the 500 error. I don’t have any solution to even try at this point. I’m using the actual region URL, my redirect URI matches in both steps, I’ve used every single browser available to me. Same result.

(Victor) #28

I had the same 500 error and I was able to make it work doing this:
Get your Client_id and access the website for authorization using any browser:

It will ask you to grant permission.
Once you click in authorize you will be redirected to http://localhost/?code=xxxxxx

Now is the trick part. If you try to create you access_token using any browser it didn’t work and I always got the 500 error. But using curl or powershell invoke-webrequest it worked fine:

Invoke-WebRequest “

I believe there are some cookie being set that is breaking the communication and causing the 500.

All the guids in these links is just for reference.