How to get "code" for Access Token?

I have been looking at: and I see that in order to get an access token, I must have a code, “The code you received.” However I don’t know how to get this “code”. I have entered in the url on google chrome: I don’t see any “code” after I login. How can I get this “code”?

You have posted this before. You think you’re going to get a different answer now?

I have not posted this before. This is a different question. I am looking for the “code”, not the client id/secret. The previous post you are referring to is unrelated to this one.

According to the 1st link I posted, it says:
"This will require the user to log in with their SmartThings account credentials, choose a Location, and select what devices may be accessed by the third party.

The authorization code expires 24 hours after issue."

However, I don’t see the “code” after I do that.

If you are going to be learning OAuth, I would suggest looking at resources outside of the smartthings docs that might provide better tutorials for this topic. It is a pretty widely used method for authorization.
With the OAuth2 Authorization Code Flow, the code is sent as a query parameter to the redirect_uri if the request is authorized.

1 Like