muesli / beehive

A flexible event/agent & automation system with lots of bees 🐝
GNU Affero General Public License v3.0
6.32k stars 325 forks source link

Attempt to fix Facebook auth scopes (#264) #346

Closed pbek closed 4 years ago

pbek commented 4 years ago

Follow up from #345.

Have you tried authing with Facebook with the new app scope?

I now have setup my own build and docker deployment process so I can test on my server. After the painful configuration at https://developers.facebook.com (and successifuly receiving an auth token) I'm one step further.

ERRO[0993] [Facebook 2]: Error: [message:(#200) If posting to a group, requires app being installed in the group, and \
          either publish_to_groups permission with user token, or both pages_read_engagement \
          and pages_manage_posts permission with page token; If posting to a page, \
          requires both pages_read_engagement and pages_manage_posts as an admin with \
          sufficient administrative permission] [type:OAuthException] [code:200] [subcode:0] 

So yes, the scopes are working.

pbek commented 4 years ago

@muesli, is the Facebook Hive capable of posting to a Facebook page? Because that's what I'm trying to achieve. 😀

pbek commented 4 years ago

It seems like pages are a different thing, you need a page access token, https://developers.facebook.com/docs/pages/publishing.

muesli commented 4 years ago

I must admit I've kinda stopped using Facebook personally, but have so far only used it to post on my personal page - which Facebook now doesn't permit anymore.

Posting to pages via the API should still be doable, though. We may or may not have to adapt to their newer API versions.

pbek commented 4 years ago

Facebook posting was always kind of flaky (back a few years ago when I wrote my own publishing integration) since access tokens seem to expire from time to time...

muesli commented 4 years ago

Thank you, @pbek!