-1

so I'm new to the Graph API, and the one thing I'm not understanding is how the auth tokens work. The test app I want to write is a simple ruby program that can make HTTP requests to facebook to do things, like perhaps post messages from a message queue I have generated. I don't want to have a front-end or anything like that. I don't see any way to just hit an endpoint with my facebook username and password and get an authorization token back. Is that not a supported functionality? How might I accomplish what I want, which is essentially automated control of my facebook account via a ruby app.

I see I can generate a token via the API Explorer, but that token is short lived.

James
  • 19
  • 1

1 Answers1

0

OAuth requires a user interaction basically. The user has to grant your app the permission to use his/her data. So it is not possible to do a non-interactive authentication, as you seem to want to perform.

If you want to post as a Page for example, it is possible to create an eternal Page Access Token (for example via Graph Explorer), which you can then store in your application, and use it to post the messages (as Page!).

See

Community
  • 1
  • 1
Tobi
  • 31,405
  • 8
  • 58
  • 90