0

Facebook recommends that you only ask for the permissions needed when needed. I have en Django app with facebook sign in and also a function to post to facebook. At the moment I ask for both permissions on signup using django-social-auth. So in my settings I have:

FACEBOOK_EXTENDED_PERMISSIONS = ["email", "publish_stream"]
FACEBOOK_EXTRA_DATA = [("gender", "username")]

But how can this be split, so on signup I only ask for:

FACEBOOK_EXTENDED_PERMISSIONS = ["email"]

And when the user tries to post to his or her timeline I also ask for:

FACEBOOK_EXTENDED_PERMISSIONS = ["publish_stream"]
Christoffer
  • 7,436
  • 4
  • 40
  • 42
  • 1
    You cannot at the moment, unless you monkeypatch the settings the second time. How do you plan to ask for permissions the second time? – omab Feb 07 '13 at 14:36
  • @omab user click button to post, before posting I check if user has given permission to post, if not I ask for it. I reckon I will try and implement the fb js-sdk instead then, but unfortunately Django-social-auth does not support that either. – Christoffer Feb 07 '13 at 14:48
  • A workaround could be to define a second facebook backend (same keys, etc), but different permissions, you can authenticante the user again by using that backend to gain the extra permissions, and could simplify the check for user permissions. – omab Feb 07 '13 at 18:38

0 Answers0