0

I have simple situation: I know both (user) UID and password and I want to create API requests, such as https://graph.facebook.com/220439?access_token=....

What I don't want is to redirect user to Facebook page and prompt him to give me permission - since I know the credentials. Is there any way to obtain access_token directly? Or at least make the first OAuth request just once, receive permanent request token and then only switch it for regular access token when making API calls?

And btw, I use PHP SDK.

Pavel S.
  • 11,892
  • 18
  • 75
  • 113

1 Answers1

1

No. Facebook are quite explicit that you cannot send credentials to their API in order to perform logins etc.

Jamie Dixon
  • 53,019
  • 19
  • 125
  • 162
  • They used to have an offline_access setting for authentication but they've depricated that now. I'll double check but afaik you need to authenticate each time the token expires etc. – Jamie Dixon Apr 25 '12 at 12:08
  • "we are now allowing the option to use access_tokens with a long-lived expiration time that can be renewed each time the user revists your app " - http://developers.facebook.com/roadmap/offline-access-removal/ – Jamie Dixon Apr 25 '12 at 12:11