Which Ruby gems support the Facebook API?

12,857

Solution 1

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.

Solution 2

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.

Solution 3

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

Solution 4

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.

Solution 5

I would suggest either mogli or koala.

Share:
12,857

Related videos on Youtube

Kevin Bedell
Author by

Kevin Bedell

About me: Boston-based I build engineering teams and software products. Github http://www.kbedell.com/ @kbedell on Twitter Linkedin profile

Updated on July 24, 2020

Comments

  • Kevin Bedell
    Kevin Bedell almost 4 years

    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?

    • Nathan Taylor
      Nathan Taylor over 13 years
      Consider rephrasing the title to this question so it doesn't seem so subjective.
  • BF4
    BF4 over 11 years
    I'd like to add that though the gem is pretty easy to use, the open graph protocol is a little weird. it might be worth play with the dev tools on facebook's site to see how to relate objects together. Also, just requests can be so simple just read in the json, e.g. graph.facebook.com/zuck and read developers.facebook.com/docs/opengraph/tutorial (and fun, you can create a ruby facebook app on heroku directly from fb! see devcenter.heroku.com/articles/facebook-ruby and developers.facebook.com/blog/post/558 )