Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 3280308
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 17, 20262026-05-17T19:41:23+00:00 2026-05-17T19:41:23+00:00

I have been searching to figure out how exactly to use the oauthable module

  • 0

I have been searching to figure out how exactly to use the oauthable module in the Devise gem for Rails 3. I have come across a couple of questions on here that seem correct, but I was unable to get the implementation working. My end goal is to have both Twitter and Facebook authentication through Devise in my Rails 3 application. Right now I am struggling with what I thought was the “example” in the warden strategy list. I have got this far.

Inside of my devise initalizer I have the following blocks of code in, what I believe, the appropriate places.

manager.oauth(:twitter) do |twitter|
  twitter.consumer_secret = '[secret]'
  twitter.consumer_key  = '[key]'
  twitter.options :site => 'http://twitter.com'
end
manager.default_strategies(:scope => :user).unshift :twitter_oauth        

Warden::OAuth::access_token_user_finder(:twitter) do |access_token|
  User.find_or_create_by(:token => access_token.token, :secret => access_token.secret).tap do |user|
     user ||= User.create!(:access_token => access_token.token, :secret => access_token.secret)
  end
end

I have placed a link on one of my views but all I am getting is an error, OAuth 401 Unauthorized, is this something from Twitter or am I completely missing a step?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-17T19:41:24+00:00Added an answer on May 17, 2026 at 7:41 pm

    Have you seen OmniAuth for Twitter, FB and other social network authentication integration into devise?

    The last two railscast episodes show off an integration.

    OmniSocial is another solution built on top of the two.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have been searching for the past through days, trying to figure out how
I have been searching around and I cannot figure out how to sumarise the
I have been searching for days trying to figure out how to add dialog
I have been searching on this for hours and can not figure out the
I have been searching for an answer and trying out stuff for days now
I've been searching for hours to try and figure this out, and it seems
I have been doing a lot of searching and still can't seem to figure
I have been trying to figure out how to do this and it seems
I have been trying to figure out driving directions using user input and it
So I have been searching the internet for hours now and I can't figure

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.