Question

I am working on an ASP.NET MVC project and I am trying to get it integrated with facebook by using facebook connect API. Now, I am having a small problem in imagining how the conceptual layout would be. I am using the repository model in MVC, I have my own DB. I want to be able to fetch user’s information from FB, and maybe store their fb_uid in my database (is that legal anyway?) I also want to be able to post stories into user’s mini feed. I have a model class called User; this class has to be filled with data from both my internal DB, and FB database. I have repository classes to communicate with the database, and I don’t really know where/which part should communicate with FB? I thought of using the FBDeveloperToolkit, but from what I have read in this forum, the toolkit is a bit out of date! I don’t know if I should use XFBML and pure javascript functions? And if yes, how can pull the data back to my DB, for example user’s fb_uid? And does that mean I will be directly calling the API functions from my presentation layer?

Can anyone please help me in this?

Thanks!

Was it helpful?

Solution

I would suggest a FacebookService layer that implements a subset of functionality you need from the Facebook API. In the DDD world it's called an Anti-Corruption Layer.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top