Request fields in Python Facebook SDK

前端 未结 1 1791
悲&欢浪女
悲&欢浪女 2020-12-19 19:11

This is the way I am currently fetching the /me object:

self.facebook_user = facebook.GraphAPI(access_token).get_object(\'me\')

But

相关标签:
1条回答
  • 2020-12-19 20:13

    You can pass in extra query parameters using **args:

    graph = facebook.GraphAPI(access_token)
    profile = graph.get_object('me')
    args = {'fields' : 'id,name,email', }
    profile = graph.get_object('me', **args)
    
    0 讨论(0)
提交回复
热议问题