Twitter::statusesUserTimeline
Returns a collection of the most recent Tweets posted by the user indicated by the screen_name or user_id parameters.
User timelines belonging to protected users may only be requested when the authenticated user either "owns" the timeline or is an approved follower of the owner. The timeline returned is the equivalent of the one seen when you view a user's profile on twitter.com. This method can only return up to 3,200 of a user's most recent Tweets. Native retweets of other statuses by the user is included in this total, regardless of whether include_rts is set to false when requesting this resource.
Signature
public function statusesUserTimeline([string[optional]
$userId = NULL,
[string[optional]
$screenName = NULL,
[string[optional]
$sinceId = NULL,
[int[optional]
$count = NULL,
[string[optional]
$maxId = NULL,
[bool[optional]
$trimUser = NULL,
[bool[optional]
$excludeReplies = NULL,
[bool[optional]
$contributorDetails = NULL,
[bool[optional]
$includeRts = NULL]]]]]]]]] )
Parameters
$userId
— object- The ID of the user for whom to return results for. Helpful for disambiguating when a valid user ID is also a valid screen name.
$screenName
— object- The screen name of the user for whom to return results for. Helpful for disambiguating when a valid screen name is also a user ID.
$sinceId
— object- Returns results with an ID greater than (that is, more recent than) the specified ID. There are limits to the number of Tweets which can be accessed through the API. If the limit of Tweets has occured since the since_id, the since_id will be forced to the oldest ID available.
$count
— object- Specifies the number of tweets to try and retrieve, up to a maximum of 200 per distinct request. The value of count is best thought of as a limit to the number of tweets to return because suspended or deleted content is removed after the count has been applied. We include retweets in the count, even if include_rts is not supplied.
$maxId
— object- Returns results with an ID less than (that is, older than) or equal to the specified ID.
$trimUser
— object- When set to true, each tweet returned in a timeline will include a user object including only the status authors numerical ID. Omit this parameter to receive the complete user object.
$excludeReplies
— object- This parameter will prevent replies from appearing in the returned timeline. Using exclude_replies with the count parameter will mean you will receive up-to count tweets — this is because the count parameter retrieves that many tweets before filtering out retweets and replies.
$contributorDetails
— object- This parameter enhances the contributors element of the status response to include the screen_name of the contributor. By default only the user_id of the contributor is included.
$includeRts
— object- When set to false, the timeline will strip any native retweets (though they will still count toward both the maximal length of the timeline and the slice selected by the count parameter). Note: If you're using the trim_user parameter in conjunction with include_rts, the retweets will still contain a full user object.
Returns
- array