Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6715091
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 26, 20262026-05-26T08:34:21+00:00 2026-05-26T08:34:21+00:00

I am attempting to access the twitter streaming api, however I want to limit

  • 0

I am attempting to access the twitter streaming api, however I want to limit the number of replies I get, I tried using the count parameter:

https://user:pass@stream.twitter.com/1/statuses/sample.json?count=100

But I got the error:

Parameter count not allowed in role statusSpritzer 

Can anyone explain why this isn’t allowed?

The code I am trying to use is this:

$url = "https://user:pass@stream.twitter.com/1/statuses/sample.json";
$fp = fopen($url,"r");

while($data = fgets($fp)){
    $decode = json_decode($data);               
    for($i = 0; $i < count($decode); $i++){         
        echo $decode->$i;
    }       
}

But takes too long to process due to the number of tweets returned, so I am trying to limit the number..

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-26T08:34:22+00:00Added an answer on May 26, 2026 at 8:34 am

    Try changing sample.json to user_timeline.json

    https://user:pass@stream.twitter.com/1/statuses/user_timeline.json?count=100

    More info can be found here:
    https://dev.twitter.com/docs/api/1/get/statuses/user_timeline

    EDIT: It looks like this is not allowed on the Spritzer access level. Count can only be used on the Gardenhose access level.

    QUOTE:

    Note that the count parameter is not allowed elsewhere, including track, sample and on the default access role.

    from https://dev.twitter.com/docs/streaming-api/methods#count

    So while statuses/sample allows the count parameter, it does not allow it with the default access level of Spritzer.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am attempting to access a web service using SOAP through Perl and am
I'm attempting to use the Twitter API with the DotNetOpenAuth library. I have a
While attempting to access a test portal, I'm encountering the following problem while using
I'm attempting to access an API for a task management system (Nozbe to be
I am attempting to access a user's friends work and education history using the
I am attempting to access the Google Search Appliance API: http://code.google.com/apis/searchappliance/documentation/612/gdata/acapi_protocol.html In order to
I am attempting to use Python 3 to interface with the Twitter API to
I am attempting to access a queue and receiving an access denied error. The
Am interoping a c++ dll and am attempting to access it's functions. Below is
We have a scenario where some .NET code is attempting to access the current

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.