Which Ruby gems support the Facebook API? - ruby-on-rails

I have a rails application using the Facebook API. I've seen several different Ruby gems for integrating with Facebook, but they look dated.
Is it best to write low-level calls myself? Is there a decent and current gem available?
Have any of these gems changed recently?
I'm beginning a new project -- which gem should I use as of September, 2012?

The Koala Gem is the way to go.
These Railscasts from July will tell you all you need to know about interacting with the Social Graph in Ruby and in Rails (both are paid episodes):
#361: Facebook Graph API: Learn how to use the Facebook Graph API with the Koala gem to fetch data from Facebook and post content through a user. Here I delve into permissions, error handling, and more.
#363: Facebook Open Graph: This episode builds on last week's episodes and shows how to integrate Facebook further through the Open Graph protocol. You will also learn how to tunnel your local server and move Facebook communication into a background process.

Having used it quite recently, I'd suggest Koala too. Pretty well documented, goes through the changes in api pretty smoothly, still maintained, and arsduo is a pretty cool guy.

According to this link,
With Facebook’s Graph API and the creation of the Open Graph protocol, it is now easier then ever before to read and write data from and to the “social graph”.
...
The following are proven to work with Ruby 1.9.x and Rails 3.0.0.
Gems
Cardinal Blue’s rest-graph
miniFB
FBGraph
Koala
Mogli
Plugins - Facebooker2
Middlewares
OmniAuth
rack-facebook

I would suggest either mogli or koala.

One known to have an active user base is facebooker2. The documentation is not really sufficient right now but its mailing list is very active, you get responses pretty quickly.

I've dug into the Koala deeply for my project, and I found it to be well written, solid code that has full test coverage. The main author, Alex Koppel, definitely knows what he's doing and he cares about the developer community. I needed to make a few improvements, which was easy thanks to the good architecture of the gem, and Alex was helpful in merging the changes into the master branch. Highly recommended.

The oauth2 from Intridea supports Facebook's Graph API.
Blog Post: http://intridea.com/2010/4/22/oauth2-gem-just-in-time-for-facebook-graph?blog=company
On github: http://github.com/intridea/oauth2

The sample source of Heroku's facebook application was used mogli,but now is koala.It is the best and great gem.Have a good group -- koala-users

Related

Twitter bot with Rails

I am trying to create a Twitter bot with Ruby on Rails but I just dont find any useful information on this manner...
Is it posible?
I tried with the GEM twibot but it is deprecated it is not longer useful.
Does Rails have a method for trigger events when (for example) a twit is posted?
Anyone have worked with something like this?
Any tutorial?
Any information at all that is in current use, I mean that does work today with the Twitter API (Many of the stuff I googled does not work now)?
Thank you very much.
Twitter itself is running on Rails, and it has a REST API. You could easily write your own solution with ActiveResource
You can get started with the ActiveResource videos on Railscasts
rails per se does not have any support for twitter. it's just an mvc-web-framework. but there are a lot of ruby gems for twitter. my favorite is this https://github.com/jnunemaker/twitter but you can find a lot more here https://www.ruby-toolbox.com/categories/api_clients.html

Facebook Canvas App on Rails 3.1

I'm trying to create a Facebook canvas app that allow users to write a custom Wall post and tag some friends. I'm familiar with stand alone rails apps, but I'm having a hard time grasping API interactions.
I've came across with a few gems (Facebooker2, Koala and fb_graph) and the Heroku integration that provide a easier way to use the GraphAPI, but I wasn't able to find updated examples on how to integrate them with a rails app from scratch. So far, the only one that I've found was this sample from fb_graph.
It seems that this type of application is pretty common of Facebook, so I was expecting to find more info on the community. Is there a better way to start developing for Facebook using Rails or should I just pick one of those gems and stick with it until I grasp the concepts?
I was able to create an Facebook canvas app using the fb_graph sample. Probably there are better solutions to handle Facebook authorization inside canvas, but the sample is a great start. Here is my project, a Music Quiz inside Facebook: https://github.com/luizbranco/MusicQuiz
I built my first Facebook app from scratch using Koala. Their wiki on Github is absolutely fantastic and everything is well explained.

Rails 3 and Facebook share

in my app I want to have the "Share" Facebook thing in the items with a pre-defined message, so the user clicks in "Share" and gets redirected to the Allow/Deny page and after allowing, the pre-defined message is automatically posted in the user's facebook wall. What's the best gem for my problem(I am sure there is one :p)?
Thanks!
P.S: I looked at the facebooker gem but it seems out-of-date and I have to use the latest Rails 3.
Take a look at some related questions. Is fb_graph or Koala gem better than facebooker2? and Which Facebook Ruby API
I'm currently using a custom solution for our facebook integration but I have been looking moving to a gem and these seem to be the main choices:
koala
fb_graph
facebooker2
So far I agree with David from the "Which Facebook Ruby API" post and am leaning towards fb_graph because of its simplicity. It should handle your requirements without any problems, just take a look at the sample app.
koala seems to a better choice, as the remaining gems are outdated. Either they support the old facebook API or are not in active development.
I am successfully using koala with rails 3.
https://github.com/arsduo/koala

Is fb_graph or Koala ruby gem better than facebooker2, using the facebook graph?

Is the fb_graph gem better?
It seems to be newer, but the facebooker has a lot more people using.
http://github.com/nsanta/fbgraph
http://github.com/mmangino/facebooker
Update:
I looked into koala, and it seems it is a good choice as well.
http://github.com/arsduo/koala
I also figure out that fb_graph is different than fbgraph. This is the right one:
http://github.com/nov/fb_graph
And there is a new facebooker, that uses that Open Graph API, but it doesnt look as mature as the others:
http://github.com/wallace/facebooker2
I've been using Koala and have been very happy. It's very low level - meaning no abstractions that try to do stuff for you. The graph API is very straightforward, so this the best approach.
I ended up using Koala. It seems to be the best choice now. Facebooker2 is still very early stage, and Koala does a great job wrapping everything.
Don't get confused! Facebooker is for the old FB API!
The original Facebooker gem was split into two pieces for the new api - Facebooker2 for front-end helpers/auth and Mogli for back-end open graph api calls. Both are managed by the same person who did the original Facebooker gem - mike mangino - who does a great job of supporting both. Mogli is most directly comparable to Koala.
So far, I'm a big fan of koala, but I've not tried fb_graph. I did post a comparison of a few facebook gems here: http://jeffdeville.com/minifb-vs-koala-vs-mogli-facebook-graph-api-r

Recommended twitter gem for ruby-on-rails

I've found a couple of different twitter gem (for ruby-on-rails) out there:
http://twitter4r.rubyforge.org/
http://twitter.rubyforge.org/
But I'm wondering if someone can rate them and provide a recommendation of either one or a new one.
Thanks
Use twitter. It's actively maintained.
I've used both twitter4r and twitter (outside of Rails though) and over time seem to have stuck with the latter since I find it easy to use and well documented.
Grackle http://github.com/hayesdavis/grackle is pretty good. It's very clean, actively developed and well documented. It supports both Basic and OAuth authentication.

Resources