Twitter Users

Users are at the center of everything Twitter: they follow, they favorite, and tweet & retweet.

Figure 1a. Instantiate Users
$users = eden('twitter')->users('[TWITTER_KEY]', '[TWITTER_SECRET]', $_SESSION['access_token'], $_SESSION['access_secret']);
Figure 1b. Usage: Get Contributees
$users
	->includeEntities()				//optional
	->skipStatus()					//optional
	->getContributees(123, 'openovate');
Figure 1c. Usage: Get Contributors
$users
	->includeEntities()				//optional
	->skipStatus()					//optional
	->getContributors(123, 'openovate');
Figure 1d. Usage: Get User Detail
$users
	->includeEntities()	//optional
	->getDetail('openovate');
Figure 1e. Usage: Look Up Friends
$users
	->setUserId(123)
	->setScreenName('openovate')
	->includeEntities()				//optional
	->lookupFriends();
Figure 1f. Usage: Search Users
$users
	->includeEntities()			//optional
	->setPage(1)				//optional
	->setPerpage(25)			//optional
	->search('Openovate Labs');
Figure 1g. Users Methods
Method Arguments Returns Description
$users->getAccountSettings(); none array Returns settings (including current trend, geo and sleep time information) for the authenticating user.
$users->getCredentials(); none array Returns an HTTP 200 OK response code and a representation of the requesting user if authentication was successful
$users->updateDeliveryDevice($device);
  1. string
  2. - Must be one of: sms, none.
array Sets which device Twitter delivers updates to for the authenticating user. Sending none as the device parameter will disable SMS updates.
$users->updateProfile(); none array Sets values that users are able to set under the "Account" tab of their settings page. Only the parameters specified will be updated.
$users->updateBackgroundImage($image);
  1. string
array Updates the authenticating user's profile background image. This method can also be used to enable or disable the profile background image
$users->updateProfileColor(); none array Sets values that users are able to set under the Account tab of their settings page. Only the parameters specified will be updated.
$users->updateProfileImage($image);
  1. string
array Updates the authenticating user's profile image.
$users->getBlockList(); none array Returns a collection of user objects that the authenticating user is blocking.
$users->getBlockedUserIds($stringify = false);
  1. boolean
integer Returns an array of numeric user ids the authenticating user is blocking.
$users->blockUser($id);
  1. string|integer
  2. - either the screen name or user ID
array Blocks the specified user from following the authenticating user.
$users->unblock($id);
  1. string|integer
  2. - either the screen name or user ID
array Un-blocks the user specified in the ID parameter for the authenticating user.
$users->lookupFriends(); none array Return up to 100 users worth of extended information, specified by either ID, screen name, or combination of the two.
$users->getContributees($id = NULL, $name = NULL);
  1. string|null
  2. - Twitter User Id
  3. string|null
  4. - Twitter Screen Name
array Returns an array of users that the specified user can contribute to.
$users->getContributors($id = NULL, $name = NULL);
  1. string|null
  2. - Twitter User Id
  3. string|null
  4. - Twitter Screen Name
array Returns an array of users that the specified user can contribute to.
$users->getDetail($id);
  1. int
  2. - user ID
array Returns extended information of a given user, specified by ID or screen name as per the required id parameter.
$users->search($search);
  1. string
array Runs a search for users similar to find people
$users->setName($name);
  1. string
Eden_Twitter_Users Set name
$users->setUrl($url);
  1. string
Eden_Twitter_Users Set url
$users->setDescription($description);
  1. string
Eden_Twitter_Users Set description
$users->setLocation($location);
  1. string
Eden_Twitter_Users Set location
$users->setToTile(); none Eden_Twitter_Users Set profile background image to tile
$users->disableProfileBackground(); none Eden_Twitter_Users Disable profile imaga background
$users->setBackgroundColor($background);
  1. string
Eden_Twitter_Users Set profile background color
$users->setBorderColor($border);
  1. string
Eden_Twitter_Users Set profile sibebar border color
$users->setFillColor($fill);
  1. string
Eden_Twitter_Users Set profile sibebar fill color
$users->setLinkColor($link);
  1. string
Eden_Twitter_Users Set profile link color
$users->setTextColor($textColor);
  1. string
Eden_Twitter_Users Set profile text color
$users->includeEntities(); none Eden_Twitter_Users Set include entities
$users->setUserId($id);
  1. integer
Eden_Twitter_Users Set user id
$users->setScreenName($name);
  1. string
Eden_Twitter_Users Set screen name
$users->setPage($page);
  1. integer
Eden_Twitter_Users Set page
$users->setPerpage($perPage);
  1. integer
Eden_Twitter_Users Set per page
$users->skipStatus(); none Eden_Twitter_Users Set skip status

© 2012 Openovate Labs. All rights reserved.