facebookfacebook-javascript-sdk

Automatic FB login with no prompt


I am wanting to add some FB functionality to our MVC business site. There are certain events that result from customer activity on our site. I would like to post these events to our company timeline.

I have several working examples and tutorials but where I am having difficulty is at log in. I would like to have the system use stored credentials..web config etc. rather than prompt for login. However all the docs etc. show that the OAuth end point doesn't accept these kind of parameters?

So how can I have the system log in using stored credentials?


Solution

  • Facebook used to have an offline_access permission that is now defunct. What you can now do is trade in a short-lived token for a long-lived token (that I think lasts around 60 days) and store that on your server. Check out the details here to learn more about this process.