Property | Type | Description | |
---|---|---|---|
$added | to save making the friends.get api call, this will get prepopulated on canvas pages | ||
$api_key | |||
$friends_list | |||
$secret | |||
$session_key |
Method | Description | |
---|---|---|
__construct ( $api_key, $secret, string $session_key = null ) | Create the client. | |
auth_getSession ( string $auth_token ) : assoc | Returns the session information available after current user logs in. | |
call_method ( $method, $params ) | * UTILITY FUNCTIONS | |
convert_simplexml_to_array ( $sxml ) | ||
events_get ( integer $uid, array $eids, integer $start_time, integer $end_time, string $rsvp_status ) : array | Returns events according to the filters specified. | |
events_getMembers ( integer $eid ) : assoc | Returns membership list data associated with an event | |
fbml_refreshImgSrc ( $url ) | ||
fbml_refreshRefUrl ( $url ) | ||
fbml_setRefHandle ( $handle, $fbml ) | ||
feed_publishActionOfUser ( $title, $body, $image_1 = null, $image_1_link = null, $image_2 = null, $image_2_link = null, $image_3 = null, $image_3_link = null, $image_4 = null, $image_4_link = null, $priority = 1 ) | ||
feed_publishStoryToUser ( $title, $body, $image_1 = null, $image_1_link = null, $image_2 = null, $image_2_link = null, $image_3 = null, $image_3_link = null, $image_4 = null, $image_4_link = null, $priority = 1 ) | ||
fql_query ( string $query ) : generalized | Makes an FQL query. This is a generalized way of accessing all the data in the API, as an alternative to most of the other method calls. More info at http://developers.facebook.com/documentation.php?v=1.0&doc=fql | |
friends_areFriends ( $uids1, $uids2 ) : array | Returns whether or not pairs of users are friends. | |
friends_get ( ) : array | Returns the friends of the current session user. | |
friends_getAppUsers ( ) : array | Returns the friends of the session user, who are also users of the calling application. | |
groups_get ( integer $uid, array $gids ) : array | Returns groups according to the filters specified. | |
groups_getMembers ( integer $gid ) : assoc | Returns the membership list of a group | |
notifications_get ( ) : assoc | Returns the outstanding notifications for the session user. | |
notifications_send ( $to_ids, $markup, $no_email ) : string | Sends an email notification to the specified user. | |
notifications_sendRequest ( array $to_ids, string $type, string $content, string $image, boolean $invite ) : string | Sends a request to the specified user (e.g. "you have 1 event invitation") | |
photos_get ( integer $subj_id, integer $aid, array $pids ) : array | Returns photos according to the filters specified. | |
photos_getAlbums ( integer $uid, array $aids ) | Returns the albums created by the given user. | |
photos_getTags ( string $pids ) : array | Returns the tags on all photos specified. | |
post_request ( $method, $params ) | ||
profile_getFBML ( $uid ) | ||
profile_setFBML ( string $markup, $uid = null ) : array | Sets the FBML for the profile of the user attached to this session | |
users_getInfo ( array $uids, array $fields ) : array | Returns the requested info fields for the requested set of users | |
users_getLoggedInUser ( ) : integer | Returns the user corresponding to the current session object. | |
users_isAppAdded ( ) : boolean | Returns whether or not the user corresponding to the current session object has the app installed |
public __construct ( $api_key, $secret, string $session_key = null ) | ||
$session_key | string | if you haven't gotten a session key yet, leave this as null and then set it later by just directly accessing the $session_key member variable. |
public auth_getSession ( string $auth_token ) : assoc | ||
$auth_token | string | the token returned by auth_createToken or passed back to your callback_url. |
return | assoc | array containing session_key, uid |
public static convert_simplexml_to_array ( $sxml ) |
public events_get ( integer $uid, array $eids, integer $start_time, integer $end_time, string $rsvp_status ) : array | ||
$uid | integer | Optional: User associated with events. A null parameter will default to the session user. |
$eids | array | Optional: Filter by these event ids. A null parameter will get all events for the user. |
$start_time | integer | Optional: Filter with this UTC as lower bound. A null or zero parameter indicates no lower bound. |
$end_time | integer | Optional: Filter with this UTC as upper bound. A null or zero parameter indicates no upper bound. |
$rsvp_status | string | Optional: Only show events where the given uid has this rsvp status. This only works if you have specified a value for $uid. Values are as in events.getMembers. Null indicates to ignore rsvp status when filtering. |
return | array | of events |
public events_getMembers ( integer $eid ) : assoc | ||
$eid | integer | : event id |
return | assoc | array of four membership lists, with keys 'attending', 'unsure', 'declined', and 'not_replied' |
public feed_publishActionOfUser ( $title, $body, $image_1 = null, $image_1_link = null, $image_2 = null, $image_2_link = null, $image_3 = null, $image_3_link = null, $image_4 = null, $image_4_link = null, $priority = 1 ) |
public feed_publishStoryToUser ( $title, $body, $image_1 = null, $image_1_link = null, $image_2 = null, $image_2_link = null, $image_3 = null, $image_3_link = null, $image_4 = null, $image_4_link = null, $priority = 1 ) |
public friends_areFriends ( $uids1, $uids2 ) : array | ||
return | array | of uid pairs with bool, true if pair are friends, e.g. array( 0 => array('uid1' => id_1, 'uid2' => id_A, 'are_friends' => 1), 1 => array('uid1' => id_2, 'uid2' => id_B, 'are_friends' => 0) ...) |
public friends_get ( ) : array | ||
return | array | of friends |
public friends_getAppUsers ( ) : array | ||
return | array | of friends |
public groups_getMembers ( integer $gid ) : assoc | ||
$gid | integer | : Group id |
return | assoc | array of four membership lists, with keys 'members', 'admins', 'officers', and 'not_replied' |
public notifications_get ( ) : assoc | ||
return | assoc | array of notification count objects for 'messages', 'pokes' and 'shares', a uid list of 'friend_requests', a gid list of 'group_invites', and an eid list of 'event_invites' |
public notifications_send ( $to_ids, $markup, $no_email ) : string | ||
return | string | url which you should send the logged in user to to finalize the message. |
public notifications_sendRequest ( array $to_ids, string $type, string $content, string $image, boolean $invite ) : string | ||
$to_ids | array | user ids to receive the request (must be friends with sender, capped at 10) |
$type | string | type of request, e.g. "event" (as in "You have an event invitation.") |
$content | string | fbml content of the request. really stripped down fbml - just
text/names/links. also, use the special tag |
$image | string | url of an image to show beside the request |
$invite | boolean | whether to call it an "invitation" or a "request" |
return | string | url which you should send the logged in user to to finalize the message. |
public photos_get ( integer $subj_id, integer $aid, array $pids ) : array | ||
$subj_id | integer | Optional: Filter by uid of user tagged in the photos. |
$aid | integer | Optional: Filter by an album, as returned by photos_getAlbums. |
$pids | array | Optional: Restrict to a list of pids Note that at least one of these parameters needs to be specified, or an error is returned. |
return | array | of photo objects. |
public photos_getAlbums ( integer $uid, array $aids ) | ||
$uid | integer | Optional: the uid of the user whose albums you want. A null value will return the albums of the session user. |
$aids | array | Optional: a list of aids to restrict the query. Note that at least one of the (uid, aids) parameters must be specified. |
public photos_getTags ( string $pids ) : array | ||
$pids | string | : a list of pids to query |
return | array | of photo tag objects, with include pid, subject uid, and two floating-point numbers (xcoord, ycoord) for tag pixel location |
public profile_setFBML ( string $markup, $uid = null ) : array | ||
$markup | string | The FBML that describes the profile presence of this app for the user |
return | array | A list of strings describing any compile errors for the submitted FBML |
public users_getLoggedInUser ( ) : integer | ||
return | integer | uid |
public users_isAppAdded ( ) : boolean | ||
return | boolean |
public $added |