Facebook Graph

FREE
By community
Updated 5 months ago
Social
-/10
Popularity Score
-
Latency
-
Success Rate

Facebook Graph API Documentation

Facebook Graph API. (For demo purposes only). You can also use FQL using the "fql" parameter. You need to create an app in https://developers.facebook.com/apps to get this to work (check the Readme section)

View API Details
GETFriends
GETfql
GETMe
GETFriends
Authorization:

Please check the README section to see how you will set up your apps in https://developers.facebook.com/apps

Header Parameters
X-RapidAPI-HostSTRING
REQUIRED
X-RapidAPI-KeySTRING
REQUIRED
AuthorizationOAUTH2
REQUIREDPlease check the README section to see how you will set up your apps in https://developers.facebook.com/apps
Code Snippet
unirest.get("https://mashape-community-facebook-graph.p.rapidapi.com/me/friends")
.header("X-RapidAPI-Host", "mashape-community-facebook-graph.p.rapidapi.com")
.header("X-RapidAPI-Key", "SIGN-UP-FOR-KEY")
.header("Authorization", "")
.end(function (result) {
  console.log(result.status, result.headers, result.body);
});
Sample Response
General
Request URL: https://mashape-community-facebook-graph.p.rapidapi.com/me/friends
Request Method: GET
Response Headers
Response Body

Install SDK for NodeJS

Installing

To utilize unirest for node.js install the the npm module:

$ npm install unirest

After installing the npm package you can now start simplifying requests like so:

var unirest = require('unirest');

Creating Request

unirest.get("https://mashape-community-facebook-graph.p.rapidapi.com/me/friends")
.header("X-RapidAPI-Host", "mashape-community-facebook-graph.p.rapidapi.com")
.header("X-RapidAPI-Key", "SIGN-UP-FOR-KEY")
.header("Authorization", "")
.end(function (result) {
  console.log(result.status, result.headers, result.body);
});
OAuth2 Authentication
Client ID
Client Secret
OAuth2 Authentication