Skip to content
This repository


Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

[no longer maintained] Discontinued because there's an official gem: google-api-client

branch: master


No longer maintained

Google now has an official GData Ruby gem: google-api-client


gem install gdata_plus

Making requests

Start by getting the client from the authenticator (see Authentication below).

client = authenticator.client

Then make a request.

response = client.get("")

Then parse the response using your preferred XML library. I'll use Nokogiri for this example.

feed = Nokogiri::XML(response.body)
album_titles = feed.xpath("//xmlns:entry/xmlns:title/text()").collect {|i| "#{i}"}

If you need more control over the request, then you can create your own Typhoeus request and submit it to the client.

request =
client.submit request


OAuth and ClientLogin are supported. OAuth is preferred for web apps and ClientLogin is convenient for installed apps and command-line utilities.


Before using OAuth, you will need to register your domain and get a consumer key and consumer secret from Google. See the OAuth example for getting started with OAuth.

Using an existing access token

If you already have an access token and access token secret, then you can construct an OAuth authenticator as follows:
  :consumer_key => CONSUMER_KEY,
  :consumer_secret => CONSUMER_SECRET,
  :access_token => access_token,
  :access_secret => access_secret


See the ClientLogin example.

Serializing authenticators

Both the OAuth and ClientLogin authenticators can be serialized using a method like to_yaml.

Error handling


Ruby support

This project is tested against Ruby 1.8.7 and Ruby 1.9.2. There is an issue with international characters and OAuth that affects Ruby 1.8.7.


This project is actively maintained. Please submit an issue if you find any bugs or want to request a new feature. Contributions are welcome. Please run the tests with Ruby 1.9.2 and 1.8.7 before submitting a pull request:

rake test


Copyright © 2010 Brian Alexander. See LICENSE.txt for further details.

Something went wrong with that request. Please try again.