Hot answers tagged api
3
You just need to create and pass in a filter that will return favorite_count. For example, this query will return the information for this question, including
"favorite_count": 18
2
No.
Generally speaking, no ids are unique across sites.
There are some situations where they line up (like linked meta user ids to their parent site user ids), or places where an id series is shared within a site (question_id and answer_id won't collide on Stack Overflow, for example); but these are basically implementation details, unless called out in ...
2
You can actually just pass in window.location.hostname directly:
This parameter can be the full domain name (ie. "stackoverflow.com"), or a short form identified by api_site_parameter on the site object.
(emphasis mine)
Since the site does not provide the short form to you directly anywhere, going the full hostname route is probably your best bet.
...
2
You might consider looking at StacMan for inspiration, a C# client that deals with some of these questions.
Off hand it does push everything through a "Manager" (called a Client in that code) and automatically enforces backoff and simultaneous request throttling.
How many requests are OK to send simultaneously?
While there is a strict cutoff... ...
2
No, there's no API route that gives you a user's tag specific reputation information. The /users/{ids}/tags route only returns the combined count of questions and answers that a user has posted in a tag, but not the reputation information that you can get on the user profile tags tab. (Note: There's an app at Badge Status for a particular Tag in ...
1
To do this you have to use the /users/{ids}/answers path to download all of a user's answers, and then filter out the tags and/or tot-up the scores from there.
Pseudo code:
scoreByTag = [] // Empty associative array
while (more pages of results) {
1) Fetch next page of answers
2) Store results and/or update scoreByTag array
}
Display/use select ...
1
Yes, the sites path does not filter results on site_type. But the good news is, the path accepts a pagesize of 999, so you can get all the results at once.
Then you must filter the results in your app. Here's what it looks like in jQuery:
$.ajax ( {
type: 'GET',
url: ...
1
First of all, version 1.1 of the API has been deprecated for quite some time now. Users are strongly encouraged to move their applications over to version 2.1.
The URL for retrieving information about a question looks something like this:
http://api.stackexchange.com/2.1/questions/ question_id ?site= site_name
For example, to retrieve information ...
1
I imagine the API is returning a Bad Request response because the hash mark isn't properly encoded in the URL.
As Serel doesn't appear to attempt to encode the passed-in values at the moment, you should be able to get things working by calling Serel::Tag.find_by_name('c%23') instead.
1
/questions take's a semi-colon delimited list of tags in the tagged parameter. If tagged is set, questions returned will have all the passed tags (ie. it's an AND operator).
https://api.stackexchange.com/docs/questions#order=desc&sort=votes&tagged=python&filter=default&site=stackoverflow&run=true
^ for example, that query returns all ...
1
Actually this can be done with using the rss feed channel on ifttt. together with the rss feed from the Stack2rss app that transforms stackoverflow api queries to an rss feed.
like:
http://stack2rss.stackexchange.com/stackoverflow/users/{{your user id}}/questions?body=true
you should check the api for the specific query you like (respone, specific ...
1
The documentation you linked to is for API 2.x, but you're querying 1.1 which doesn't return those exact objects (and is deprecated). This API 2.1 request will return the results you were expecting:
http://api.stackexchange.com/2.1/questions/13752517/related?site=stackoverflow
Only top voted, non community-wiki answers of a minimum length are eligible