Using the Graph API to get permissions granted

Finally, we can use Graph API to get the permissions that a user has granted to our application!  This should be one of the most wanted features that we want to have in the Graph API.

Quoting from Facebook’s announcement,

As part of our efforts to transition functionality from legacy REST APIs to the Graph API, we added the ability to retrieve the list of permissions users have granted your app by adding the permissions connection to the User object. Similar to other User object connections, you can query for the list of permissions granted by calling:…

That is simply and easy to remember!

Sample data returned from the Graph API is shown below,

'data' ...
    '0' ...
        'status_update' => "1"
        'photo_upload' => "1"
        'video_upload' => "1"
        'offline_access' => "1"
        'email' => "1"
        'create_note' => "1"
        'manage_pages' => "1"
        'user_birthday' => "1"

With this, we are now one more step away from the Old REST API and FQL.  Thank for Facebook team!  Keep it up!…. and most important, please keep the platform healthy!

I have to stop here…. as I need to some of my FAQ for this.  🙂


This entry was posted in Development Tips, news and tagged . Bookmark the permalink.

Leave a Reply

Your email address will not be published. Required fields are marked *