FB.ApiClient

Description

Allows you to make calls to the Facebook REST API from within JavaScript.

Constructor

ApiClient(String apiKey)

Construct the API object.

Methods

auth_getAppPublicKey(String target_app_key,  Object onRequestCompleted)

Client side call to auth.getAppPublicKey.

callMethod(String method,  Object parameters,  Object executeUnit)

Calls the specified Facebook API method with given parameters, or queues it on the Sequencer.

connect_getUnconnectedFriendsCount(Object onRequestCompleted)

Returns the number of friends who have pending accounts on a Connect site.

events_get(String uid,  Array eids,  Number startTime,  Number endTime,  String rsvpStatus,  Object onRequestCompleted)

Client side call to events.get.

events_getMembers(Number eid,  Object onRequestCompleted)

Client side call to events.getMembers.

fbml_refreshImgSrc(String url,  Object onRequestCompleted)

Client side call to fbml.refreshImgSrc.

fbml_refreshRefUrl(String url,  Object onRequestCompleted)

Client side call to fbml.refreshRefUrl.

fbml_setRefHandle(String handle,  String fbml,  Object onRequestCompleted)
feed_getAppFriendStories(Object onRequestCompleted)

Return a list of all application stories recently published by the user's friends.

feed_publishUserAction(Number template_bundle_id,  Object template_data,  Array target_ids,  String body_general,  Number story_size,  String user_message,  Object onRequestCompleted)

This is a recommended - use FB.Connect.streamPublish instead.

fql_query(String query,  Object onRequestCompleted)

Make an FQL query directly from the client.

friends_areFriends(Array uids1,  Array uids2,  Object onRequestCompleted)
friends_get(String flid,  Object onRequestCompleted)

Return a array of friend ids for the currently logged in user.

friends_getAppUsers(Object onRequestCompleted)
friends_getLists(Object onRequestCompleted)
get_session()

Get session information for the currently logged in user.

get_sessionWaitable()

Retrieves the FB:Waitable for the session object.

groups_get(String uid,  Array gids,  Object onRequestCompleted)
groups_getMembers(Number gid,  Object onRequestCompleted)
intl_uploadNativeStrings(Array native_strings,  Object onRequestCompleted)
notifications_get(Object onRequestCompleted)
notifications_send(Array to_ids,  String notification,  Object onRequestCompleted)
notifications_sendEmail(Array recipients,  String subject,  String text,  String fbml,  Object onRequestCompleted)
pages_getInfo(Array fields,  Array page_ids,  String uid,  Object onRequestCompleted)

Client side call to pages.getInfo.

pages_isAdmin(Number page_id,  Object onRequestCompleted)

Client side call to pages.isAdmin.

pages_isAppAdded(Number page_id,  Object onRequestCompleted)

Client side call to pages.isAppAdded.

pages_isFan(Number page_id,  String uid,  Object onRequestCompleted)

Client side call to pages.isFan.

photos_addTag(String pid,  String tag_uid,  String tag_text,  Number x,  Number y,  Object tags,  Object onRequestCompleted)

Client side call to photos.addTag.

photos_createAlbum(String name,  String location,  String description,  Object onRequestCompleted)

Client side call to photos.createAlbum.

photos_get(Object subj_id,  Object aid,  Array pids,  Object onRequestCompleted)

Client side call to photos.get.

photos_getAlbums(String uid,  Array aids,  Object onRequestCompleted)

Client side call to photos.getAlbums.

photos_getTags(Array pids,  Object onRequestCompleted)

Client side call to photos.getTags.

privacy_canSee(Array uids,  Array whats,  Object onRequestCompleted)
profile_getFBML(String uid,  Object onRequestCompleted)
profile_setFBML(String uid,  String profile,  String profile_action,  String mobile_profile,  String profile_main,  Object onRequestCompleted)
requireLogin(Function callback)

This method is deprecated - use FB.Connect.requireSession instead.

revokeAuthorization(String uid,  Object onRequestCompleted)
sessionIsExpired(SessionRecord record)

Determine if a particular session is expired yet.

set_session(SessionRecord value)

Sets the current session information.

stream_get(Array source_ids,  Number start_time,  Number end_time,  Number limit,  String filter_key,  Object onRequestCompleted)

Gets the stream on behalf of a user using a set of users.

stream_getComments(String post_id,  Object onRequestCompleted)

Gets the full comments given a post_id from stream.get or the stream FQL table.

stream_getFilters(Object onRequestCompleted)

Gets the filters (with relevant filter keys for stream.get) for the current user.

users_getInfo(Array uids,  Array fields,  Object onRequestCompleted)

Client side call to users.getInfo.

users_hasAppPermission(String ext_perm,  Object onRequestCompleted)

Client side call to users.hasAppPermission.

users_isAppAdded(Object onRequestCompleted)

Client side call to users.isAppAdded.

users_isAppUser(Object onRequestCompleted)

Determine if the user has authorized this application.

users_setStatus(String status,  Boolean clear,  Boolean status_includes_verb,  Object onRequestCompleted)

The preferred way to update the user's status is via FB.Connect.streamPublish.