Skip to main content
Search type Search syntax
Tags [tag]
Exact "words here"
Author user:1234
user:me (yours)
Score score:3 (3+)
score:0 (none)
Answers answers:3 (3+)
answers:0 (none)
isaccepted:yes
hasaccepted:no
inquestion:1234
Views views:250
Code code:"if (foo != bar)"
Sections title:apples
body:"apples oranges"
URL url:"*.example.com"
Saves in:saves
Status closed:yes
duplicate:no
migrated:no
wiki:no
Types is:question
is:answer
Exclude -[tag]
-apples
For more details on advanced search visit our help page
Results tagged with
Search options not deleted user 7653

For questions relating to authenticating with the Stack Exchange API using OAuth 2.0, which is an open standard for authorization. General OAuth 2.0 questions are off-topic but might find a home elsewhere in the network.

11 votes
Accepted

Unable to get access token

Refer to the Stack Exchange API, Authentication docs. It looks like you are trying to authenticate using either a server you do not control, or a local server that is not on the public internet. Cru …
Brock Adams's user avatar
11 votes

What exactly is a valid OAuth domain name for registering your app?

The OAuth Domain is either: A valid domain that you own and control, and that is hosted somewhere the client can reach. Say, for example that you owned unicorns.mil. See this answer and this answer …
Brock Adams's user avatar
9 votes
Accepted

Can the redirect_uri contain port number?

You got that error because you set the OAuth Domain like example.com:8080, not the redirect_uri. That's not how you configure non-standard ports; see below. The redirect uri, with port, feature now …
Brock Adams's user avatar
7 votes

Javascript SDK channelUrl for local development

Your value for channelUrl is nominally correct. If I set up my XAMPP server, via httpd.conf to use port 8000, then this HTML page works perfectly fine for me: <!DOCTYPE html> <html><head> <title …
Brock Adams's user avatar
5 votes
Accepted

Getting "application not configured for implicit grants" error trying to setup website

Yes, it can be annoying that the API docs, the javascript SDK, and the settings pages use the terms: "Explicit" "Implicit" "Server side" "Client side" a little interchangeably. (The first 2 are …
Brock Adams's user avatar
4 votes
Accepted

Can not request info after OAuth

Your second call must be https:. You actually got an error like: "error_id":406, "error_message":"Access token sent over non-HTTPS request, it has been invalidated", "error_name":"access_token_co …
Brock Adams's user avatar
4 votes
Accepted

Refresh expired acess token basics

Dealing with token expiration is pretty simple. When a token is/goes bad then, when you make an API call that uses the token, you will get a JSON response like this: { "error_id": 403, "error …
Brock Adams's user avatar
3 votes
Accepted

Does verifying OAuth2 `access_token` validity count towards API call quota?

Yes, calls to /access-tokens/{accessTokens} use API quota. You can see that by repeatedly running /2.2/access-tokens/XBWL0stf*YIOCl7WpJHqYA)) for example. With each call, the quota_remaining value w …
Brock Adams's user avatar
3 votes
Accepted

Is there a way to specify how long I want an access token to be valid for?

Yes, I always get 86399 too. And, no, you can't specify an interval other than no_expiry. But you can call /access-tokens/{accessTokens}/invalidateDoc at whatever interval you wish. So, for less use …
Brock Adams's user avatar
3 votes
Accepted

iOS Client for stackoverflow always throws redirect_uri not a valid uri

That error means either that you've misconfigured the app or that the authentication call is incorrect. Note that stackexchange.com/oauth/login_success is not a valid redirect_uri irregardless. You …
Brock Adams's user avatar
3 votes
Accepted

Cannot get redirect_uri to work

There have been no reported changes to the API, officially for many years, (unofficially since January). But, frankly that script's approach should have never worked. OAuth credentials are sent to: …
Brock Adams's user avatar
3 votes
Accepted

Implicit OAuth flow puts the access token in the hash?

No, you can't get the access_token in the query/search part of the URL. This would be a security leak that would allow 3rd parties to see your access_tokens on the web. Reference: OAuth2.0 Implicit …
Brock Adams's user avatar
3 votes

Find out whether a user has association bonus

Yes, you can find out if the user has received the association bonus using the API. It's a bit clunky though. However, as we discovered, "association bonus rights" are rather meaningless at the mome …
Brock Adams's user avatar
2 votes
Accepted

Same access token between different fetch_token requests

Yes, each time you invoke stackexchange.com/oauth/ you will get a fresh access token, even though old ones may still be valid. For example: Go to /me/inboxLivedoc and hit Get Token twice, recording …
Brock Adams's user avatar
2 votes
Accepted

No 'Access-Control-Allow-Origin' for oauth/access_token

The question is not clear enough. You appear to be trying to use jQuery to do explicit OAuth from a web page. If so, this is not allowed. Explicit OAuth is for servers. You are not running that c …
Brock Adams's user avatar

15 30 50 per page