Four Square Pages

Returns user details for a page. Will return error if user specified is not a page.

Figure 1a. Instantiate Pages
$pages = eden('foursquare')->pages($_SESSION['oauth_token']);
Figure 1b. Usage: Retrieve the Page's Venues.
$pages
	->setLocation('[LONGTITUDE]', '[LATITUDE]')		//optional
    ->setRadius('[INTEGER]')						//optional
    ->setOffset('[INTEGER]')						//optional
    ->setLimit('[INTEGER]')							//optional
    ->getVenue('[PAGE_ID]');
Figure 1c. Usage: Retrieve Pages Matching the Search Term.
$pages
	->setTwitter('[TWITTER_ACCOUNT]')		//optional
    ->setFacebookId('[FACEBOOK_ID]')		//optional
    ->search('YOUR SEARCH HERE');
Figure 1d. Pages Methods
Method Arguments Returns Description
$pages->setTwitter($twitter);
  1. string
Eden_Foursquare_Pages Set twitter account
$pages->setFacebookId($fbId);
  1. string
Eden_Foursquare_Pages Set twitter account
$pages->setFields($fields);
  1. string
Eden_Foursquare_Pages Specifies which fields to return. May be one or more of totalCheckins, newCheckins, uniqueVisitors, sharing, genders, ages, hours,
$pages->setEndTime($endTime);
  1. string
  2. - YYYY-MM-DD
Eden_Foursquare_Pages The end of the time range to retrieve stats for (seconds since epoch). If omitted, the current time is assumed.
$pages->setLocation($longtitude, $latitude);
  1. int|float
  2. int|float
Eden_Foursquare_Pages Set location by setting longtitide and latitude
$pages->setRadius($radius);
  1. integer
Eden_Foursquare_Pages Radius in meters, up to approximately 2000 meters.
$pages->setLimit($limit);
  1. integer
Eden_Foursquare_Pages The number of venues to return. Defaults to 20, max of 100.
$pages->setOffset($offset);
  1. integer
Eden_Foursquare_Pages The offset of which venues to return. Defaults to 0.
$pages->search($name);
  1. string
  2. - A search term to be applied against page names.
array Returns a list of pages matching the search term.
$pages->getTimeSeries($pageId, $startAt);
  1. string
  2. - The page whose venues to get timeseries data for
  3. string
  4. - The start of the time range to retrieve stats for
array Get daily venue stats for venues managed by a page over a time range.
$pages->getVenue($pageId);
  1. string
  2. - The page id for which venues are being requested.
array Allows you to get the page's venues.

© 2012 Openovate Labs. All rights reserved.