Skip to content


Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

This branch is 256 commits ahead, 3 commits behind mojodna:master

Failed to load latest commit information.
bin display warnings and require rubygems
examples removed unused assignment
lib Adding usage example.
script bumped version to 0.2.99
tasks Updated deployment info to be 0.2.6
test Renaming Typhoeus RequestProxy file.
website 0.3.5 release
History.txt OAuth::RequestProxy::Typhoeus
License.txt Changes from merged in
Manifest.txt Improve error handling for imperfect authorization headers.
README.rdoc cleaning up Rakefile
Rakefile we should use loops!
oauth.gemspec 0.3.6 release
setup.rb First commit


Ruby OAuth GEM


This is a RubyGem for implementing both OAuth clients and servers in Ruby applications.

See the OAuth specs


sudo gem install oauth

You can also install it from the oauth rubyforge project

The source code is now hosted on the OAuth GitHub Project

The basics

This is a ruby library which is intended to be used in creating Ruby Consumer and Service Provider applications. It is NOT a Rails plugin, but could easily be used for the foundation for such a Rails plugin.

As a matter of fact it has been pulled out from an OAuth Rails Plugin which now requires this GEM.

Demonstration of usage

Create a new consumer instance by passing it a configuration hash:

@consumer ="key","secret", :site => "https://agree2")

Start the process by requesting a token

@request_token = @consumer.get_request_token
session[:request_token] = @request_token
redirect_to @request_token.authorize_url

When user returns create an access_token

@access_token = @request_token.get_access_token
@photos = @access_token.get('/photos.xml')

For more detailed instructions I have written this OAuth Client Tutorial and “How to turn your rails site into an OAuth Provider ” .

Finally be sure to check out the OAuth RDoc Manual .

Documentation Wiki

There is some documentation on the Google Code project for the “OAuth Rails Plugin” :


How to submit patches

Read the “8 steps for fixing other people's code”

The source code is now hosted on the OAuth GitHub Project

To submit a patch, please fork the oauth project and create a patch with tests. Once you're happy with it send a pull request and post a message to the google group.


This code is free to use under the terms of the MIT license.


Comments are welcome. Send an email to “Pelle Braendgaard” email via the OAuth Ruby mailing list

Something went wrong with that request. Please try again.