Menu Search Sign up

Graph API Explorer

What is Graph API Explorer?

A tool from facebook for facebook app developers to explore how to use Graph API to build their facebook app.

How to access Graph API Explorer?

https://developers.facebook.com/tools/explorer

Use Graph API Explorer to get page access token for your app

  1. Login to Graph API Explorer
  2. In Graph API Explorer, at the top-right corner, switch the "application: [?]" from "Graph API Explorer" to your app
  3. In the "Access Token:" line, there is a textbox and a dropdown list box. In the dropdown list box, select your app below "PageAccess Tokens"
  4. In the same dropdown list box, select "Request publish_pages", which will open a pop-up window asking the facebook user (which is yourself) to permit your app to be able to "publish as pages you manage". Just click ok.
  5. In the "Access Token:" textbox, the page access token will be displayed. This is a short-lived token.
  6. To make the page access token a long-lived one, click the little "i" icon in the "Accesstoken:" textbox. This will open the pop-up window "Access Token Info". In that window, click "Open in Access Token Tool", which will open the page "Access Token Debugger"
  7. In the "Access Token Debugger" page, click "Extend Access Token". This will prompt you to type in your facebook user password again, then the new long-lived page access token (that will never expire) will be displayed.

Use Graph API Explorer to get user access token for your app

  1. Login to Graph API Explorer
  2. In Graph API Explorer, at the top-right corner, switch the "application: [?]" from "Graph API Explorer" to your app
  3. In the "Access Token:" line, there is a textbox and a dropdown list box. In the dropdown list box, select "Get User Access Token". This will open a pop-up window "Select Permissions".
  4. In the pop-up window "Select Permissions", select "publish_actions", "manage_pages", and "publish_pages" for you to be able to post to pages (as user as well as page) and groups.
  5. Then click "Get Access Token"
  6. In the "Access Token:" textbox, the user access token will be displayed. This is a short-lived token.
  7. To make the user access token a long-lived one, click the little "i" icon in the "Accesstoken:" textbox. This will open the pop-up window "Access Token Info". In that window, click "Open in Access Token Tool", which will open the page "Access Token Debugger"
  8. In the "Access Token Debugger" page, click "Extend Access Token". This will prompt you to type in your facebook user password again, then the new long-lived page access token (that will never expire) will be displayed.