Skip to main content
3 of 4
library tag is for announcing libraries, not discussing them
Kevin Montrose
  • 18.7k
  • 6
  • 35
  • 62

How to filter getAnswersForUser by tag?

I'm using Stackexchange java client lib I wanted to get a little more statistics but the following snippet returns only 30 answers.

  • Do I need to to register for an API key, or just use AnswersForUserRequestConfiguration?
  • How can I filter answers by a tag?

INFO: No API key provided, request limit will be restricted.

List<Answer> answers = StackAppClient.getAnswersForUser(241590);
    long votes=0;
    for ( Answer a : answers ) {
        votes += a.getUpVoteCount();
         System.err.println("answer:" + a);
    }
    System.err.println("votes:" + votes);

EDIT:

I think I shouldn't try to use getQuestionsForTag("java") which would return 50k+ answers and check whether I provided an answer to this question.

stacker
  • 123
  • 5