How to setup a valid Redirect URL to receive an Access Token

24 views
Skip to first unread message

dcdan...@gmail.com

unread,
May 25, 2016, 1:02:05 PM5/25/16
to Imgur
Hopefully a simple question. How do you define a redirect URL to receive an access token?


I assumed any url would do i.e such as http://seattle.mariners.mlb.com as a redirect url. According to your documentation on how to obtain access tokens, the redirect url is used to retrieve the token. I used my client id and was taken to the page to accept, but was not redirect to a url to retrieve the token. The redirect url in my preference was setup to be 'https://my.yahoo.com' but I was not redirect to this page, but got an error page.


"
Requesting an access token is fairly straightforward: point a browser (pop-up, or full page redirect if needed) to a URL and include a set of query string parameters.


https://api.imgur.com/oauth2/authorize?client_id=YOUR_CLIENT_ID&response_type=REQUESTED_RESPONSE_TYPE&state=APPLICATION_STATE


The user will now be able to enter their password and accept that they'd like to use your application. Once this happens, they will be redirected to your redirect URL (that you entered during registration) with the access token. You can now send the access token in the headers to access their account information." Imgur website

Thanks

dcdan...@gmail.com

unread,
May 25, 2016, 1:24:53 PM5/25/16
to Imgur
Figured it out; needed to specify the parameters for respond_type.
Reply all
Reply to author
Forward
0 new messages