Hot answers tagged

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. ...
Brock Adams's user avatar
  • 12.8k
5 votes

StackPrinter: The Stack Exchange Printer Suite

status-completedI asked this as a question, but apparently the convention is to report bugs/feature requests in the announcement thread. It appears, that the MathJax extension mhchem is currently not ...
Martin - マーチン's user avatar
4 votes

StackPrinter: The Stack Exchange Printer Suite

The default bookmarklet javascript has problems when used with mathoverflow. Because annoyingly mathoverflow ends with a .net instead of a .com. I made some changes so that it could also work with ...
Jose Capco's user avatar
4 votes

StackPrinter: The Stack Exchange Printer Suite

Here is a small script (stackprinter) which uses Stack Printer from the command-line: #!/bin/sh type wkhtmltopdf || { echo >&2 "wkhtmltopdf command is required. Aborting."; exit 1; } :...
kenorb's user avatar
  • 163
4 votes
Accepted

Get the Authenticated User's email?

The API does not provide any method to determine a user's email address and it is unlikely to do so in the future. This would be a risk to both the user's privacy and his/her trust in Stack Exchange. ...
Brock Adams's user avatar
  • 12.8k
3 votes
Accepted

The /questions endpoint only returns around 30,000 items where 400,000 are expected

This looks like a bug in the API. The response wrapper object has a field has_more to indicate if there are more records beyond the page you fetched. For unknown reasons has_more returns false when it ...
rene's user avatar
  • 2,275
3 votes

How to deal with the "Too Many Requests" error coming as HTML?

It sounds like you've either got a bug which is in fact making more requests than you think it is, or you're on a network where there's some other source of high-frequency requests. You're not ...
Tim Stone's user avatar
  • 4,706
3 votes
Accepted

What is the difference between accepted and is_accepted?

If the answer is the accepted answer, is_accepted is true and anyone can see it. accepted is set to true only if the currently authenticated user is the one who has accepted the answer. For instance,...
Brock Adams's user avatar
  • 12.8k
3 votes
Accepted

How to get up_vote_count and down_vote_count for a user?

You need to use a filter that returns those properties. The default filter does not. Also, the API is at version 2.2. You should use that unless you've a very good reason not to. So try, for example:...
Brock Adams's user avatar
  • 12.8k
3 votes
Accepted

Descriptions of tag-based badges are incorrect

This seems to have been silently/magically fixed in the last 7 months (Date of Nicos Karalis' comment). Descriptions seem correct now. I had verified that they weren't correct when I upvoted this ...
Brock Adams's user avatar
  • 12.8k
3 votes

Stack Exchange API in Chrome extension

I've built an extension that uses StackExchange API using OAuth2 flow. I did not use the JS SDK and did it manually instead. Here is how I did it: function auth(sendResponse) { const scope = '...
mmohammad's user avatar
  • 141
3 votes

Why is "body" missing from certain inbox items?

The documentation was updated sometime in the last 2 years and the API docs (version 2.2) now state that the property may be absent:
Brock Adams's user avatar
  • 12.8k
2 votes

Get favorited tags of user

UPDATE: The feature appears to be present in the, so far, undocumented API version 2.3. See captncraig's answer on this page. After all these years, it looks like this might never get implemented. ...
Brock Adams's user avatar
  • 12.8k
2 votes

StackImpact - What's your impact?

Hmm… a couple of bugs in this: It doesn't seem to be accounted for that accepting your own answer doesn't earn any rep. Selecting a Sunday will make it load the previous week, instead of the one that ...
Nissa's user avatar
  • 121
2 votes

Stack.PHP - Powerful and Extensive Library for Accessing the Stack Exchange API - Including Full Support for v2.0.

bug support @Nathan Osman, I have been trying to get authentication working with your library (which is very useful BTW). However, whenever I use the explicit flow I end up with an error on the stack ...
Zack Hodari's user avatar
2 votes

I Cannot Perform Oauth

The authentication process is described in the API docs: http://api.stackexchange.com/docs/authentication.
Adam Lear's user avatar
  • 358
2 votes
Accepted

Add the 'people reached' count to the API?

Until the feature request is approved (unlikely, and a similar request has no developer love either), you can get this number in one of 3 ways: You can get slightly stale data with this SEDE query (...
Brock Adams's user avatar
  • 12.8k
2 votes

Application Key and AccessToken are not working for Stack Exchange API?

In my particular case, I somehow managed to append % character to the end of the access_token. There should be no % character at the end of the access_token.
Gajus's user avatar
  • 163
1 vote

Main Stack Exchange network site API

You are not missing something. 'Stack Exchange' is not a site in terms of Questions and Answers. It has the sole purpose of offering users (not API consumers) a common place across all network sites. ...
rene's user avatar
  • 2,275
1 vote
Accepted

How can I the question detail page and add comments like the Stack Exchange app?

Can we get the list of data when clicking on the specific question and display the question detail page like the Stack Exchange app? Sure: use the /questions/{ids} method and apply the appropriate ...
Glorfindel's user avatar
  • 6,517
1 vote
Accepted

After which time span can my vote no longer change?

It's no different in the API than it is for the main site. From the FAQ: you may change your vote within a five minute window from the time of the first vote you cast on that post. Note that after ...
Glorfindel's user avatar
  • 6,517
1 vote
Accepted

Do my users need to be logged in, for quota?

Your app can just give them the link, and they don't need to be logged in. The quota is a function of your API key (mainly). Register your app and use a key and that will give you a 10K quota. See:...
Brock Adams's user avatar
  • 12.8k
1 vote

access_token not present in /oauth/access_token response

Unpack response content with $response->getBody()->getContents(). use GuzzleHttp\Client; Route::get('/approve', function () { header('Location: https://stackexchange.com/oauth?client_id=12345&...
ajthinking's user avatar
1 vote
Accepted

Authentication uses # instead of `?`?

Refer to the generic URI syntax, it is perfectly valid to have a fragment (The optional part of a URL that starts with an octothorpe #) without a preceding query (The optional part of a URL that ...
Brock Adams's user avatar
  • 12.8k
1 vote

The `top_questions` field shows outdated information?

Although this can be annoying or confusing, there is no bug. Take a look at your Stack Exchange accounts page. Currently it shows: (Click for larger image) 10 questions, here on Stack Apps, and 1 ...
Brock Adams's user avatar
  • 12.8k
1 vote

Get favorited tags of user

Good news! The (yet undocumented) api version 2.3 has this feature. https://api.stackexchange.com/2.3/users/{id}/tag-preferences?access_token=...&key=...&site=StackOverflow.com will give you ...
captncraig's user avatar

Only top scored, non community-wiki answers of a minimum length are eligible