facebook permissions - checking and rerequesting

In my app I am requesting the “publish_actions” permission only the first time and not every time the user wants to share on FB. 

However, when requesting permissions from our users they can now decide to decline, and not grant them or revoke them from the facebook settings page. 

“People can also revoke permissions granted to your app in Facebook’s interface at any time after they have logged in. It is important that your app regularly checks which permissions have been granted, especially when launching on a new platform.”

(https://developers.facebook.com/docs/facebook-login/permissions/v2.2#checking)

This is why facebook added the ability to check the permissions the user has granted and denied for your app (in order to detect when to ask for the permissions and when not to). 

This raises a few questions:

  1. when a user denied the app access, the listener of the showDialog function received the respones with the field isError = true, however there was not explanation what was wrong. I expected something like:

{
“error”: {
“message”: “(#200) The user hasn’t authorized the application
to perform this action”,
“type”: “OAuthException”,
“code”: 200
}
}

(https://developers.facebook.com/docs/facebook-login/permissions/v2.2#handling)

  1. Is there a way to check the user’s permissions with the facebook library?

  2. Is there a way to rerequest the permissions in case they were revoked? According to facebook, simply asking for the permissions will not work without additional info:

If someone has declined a permission for your app, the login dialog won’t let your app re-request the permission unless you pass auth_type=rerequest along with your request.

Thanks

Bump as having similar issues.

@stanga.games, can I get you to file a bug report with this?  Make sure to include a sample app (you might make the existing facebook app have the issues you are talking about).  Make sure to include any assets needed to run the sample along with the build.settings and config.lua and put it in a .zip file (no other format please). and use the Report a bug Link at the top of the page.

You will get an email with a Case ID #.  Please post it back here as a reference.

Rob

I filed a bug report: Case ID #: 38891.

Thanks!

Bump as having similar issues.

@stanga.games, can I get you to file a bug report with this?  Make sure to include a sample app (you might make the existing facebook app have the issues you are talking about).  Make sure to include any assets needed to run the sample along with the build.settings and config.lua and put it in a .zip file (no other format please). and use the Report a bug Link at the top of the page.

You will get an email with a Case ID #.  Please post it back here as a reference.

Rob

I filed a bug report: Case ID #: 38891.

Thanks!

I see facebook v4 plugin will fix some of the issues explained above - but the documentation doesn’t say if the plugin will allow to re-request a revoked permission. 

According to facebook, simply asking for the permissions will not work without additional info:

“If someone has declined a permission for your app, the login dialog won’t let your app re-request the permission unless you pass auth_type=rerequest along with your request.

The notes on the bug report hint that all you have to do is re-request the permission and it should work.  It also says that if you revoke “public_profile”, you might run into problems. The bug has not been closed yet, because there are some other permission features (settings screens) that are still being worked on.

I will forward this on to the assigned Engineer so he can look into your findings.

Rob

I see facebook v4 plugin will fix some of the issues explained above - but the documentation doesn’t say if the plugin will allow to re-request a revoked permission. 

According to facebook, simply asking for the permissions will not work without additional info:

“If someone has declined a permission for your app, the login dialog won’t let your app re-request the permission unless you pass auth_type=rerequest along with your request.

The notes on the bug report hint that all you have to do is re-request the permission and it should work.  It also says that if you revoke “public_profile”, you might run into problems. The bug has not been closed yet, because there are some other permission features (settings screens) that are still being worked on.

I will forward this on to the assigned Engineer so he can look into your findings.

Rob