Update Facebooks Status using Python

前端 未结 2 1973
我在风中等你
我在风中等你 2021-01-14 09:56

Is there an easy way to update my Facebook status (\"What\'s on your mind?\" box) using Python code ?

2条回答
  •  情书的邮戳
    2021-01-14 10:10

    Check out PyFacebook which has a tutorial, from... Facebook!

    Blatantly ripped from the documentation on that page and untested, you'd probably do something like this:

    import facebook
    fb = facebook.Facebook('YOUR_API_KEY', 'YOUR_SECRET_KEY')
    fb.auth.createToken()
    fb.login()
    fb.auth.getSession()
    fb.set_status('Checking out StackOverFlow.com')
    

提交回复
热议问题