2

The current behavior of the list version of /badges/{id} is to return the users that have been awarded any of the badges in the list.

An alternative is to have the API to return the list of the users that have been awarded all badges in the list.

I can see how both could be useful. In fact, if I was to write an app to screen for potential SO users to solicit for biz opportunities, I'd like to be able to do both types of queries.

However, the usefulness of the current implementation is bit limited by the fact that determining which badge from the list particular used got, requires additional request.

2 Answers 2

0

The flip-side of that is that an "and" equivalent would require multiple requests to get all of the users who received one of a set of badges.

It just so happens that the "or" behavior was easier - and probably more performant, though don't hold me to that - to implement, and unless there's a compelling reason to change it its going to stay that way.

1
  • "the 'or' behavior was easier" - that's as good a reason as any other I guess... :-) Jun 3, 2010 at 22:57
0

You could make it so that the /badges/{id} list included which badges from the requested list the user has so that the caller is able to do either OR or AND as they wish. Not sure whether that's going to be any harder, of course...

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .