Building server side components that can integrate SharePoint and Facebook have some requirements that you must solve before the integration of other components such as web parts can begin. Some of the major issues that must be solved are where do I store the Application Key/Secret and how can you maintain user authorization per page.
Here is what the flow looks like with the DevCow Facebook web parts.
First Request to SharePoint page with Facebook web parts
This case may occur when the user logs into a site for the first time or if the users session in Facebook has expired.
- Step1: The user accesses a SharePoint site that has DevCow Facebook web parts on the page.
- Step2: User clicks on Login link for the configured web part
- Step3: New page opens that redirects to Facebook.com login page
- Step4: User enters credentials and logs into Facebook Application
- Step5: Facebook.com redirects to configured web page with DevCow ReceiverFacebookPart web part on page
- Step6: DevCow ReceiverFacebookPart web part stores SessionKey and UserId in User Profile field
- Step7: Login Window closes and original page refreshes with details of user.
Now when the user returns the page will be render with Facebook information and the user will not need to enter their credentials every time they access the page. With this model, the system will be responsible for keeping the users information secure and not allowing someone to access the information without their permission.