Get status of users with streaming api


I have created a class which will get the status of the user using StatusListener. I want to configure for multiple users.

    ConfigurationBuilder cb = new ConfigurationBuilder();
    cb.setOAuthAccessToken("bbb"); // user access token
    cb.setOAuthAccessTokenSecret("bbb"); // user access token secret
	StatusListener listener = new StatusListener() {

		public void onException(Exception arg0) {
			// TODO Auto-generated method stub

		public void onStatus(Status status) {
			// TODO

		public void onDeletionNotice(StatusDeletionNotice arg0) {
			// TODO Auto-generated method stub

		public void onScrubGeo(long arg0, long arg1) {
			// TODO Auto-generated method stub

		public void onTrackLimitationNotice(int arg0) {
			// TODO Auto-generated method stub

	TwitterStreamFactory factory = new TwitterStreamFactory(;
	twitterStream = factory.getInstance();

How can i configure multiple users i.e give access tokens in configuration so that i get there status updates ?


Are you trying to use User Streams? Site Streams is the multi-user version of User Streams. You can read about it here: [node:6346]