Rails omniauth - twitter requesting authorization of the application every time a user logs in

In Railscast: http://railscasts.com/episodes/241-simple-omniauth Ryan uses omniauth to log in. In the video, when he presses the login button, the first time Twitter asks the user if they want to allow the Ryan application. The second time the login button is pressed, it automatically registers the user. In my application, the user is forced to allow my application each time. If the user logged in to Twitter and already allowed the application, should it not "just work"?

EDIT: My application currently has read, write, and direct message permissions. I also use omniauth-twitter (0.0.6).

+5
source share
7 answers

Ok, so a new version has been released for this version. Please use 0.0.7

https://rubygems.org/gems/omniauth-twitter/versions/0.0.7

Thanks @fosrias

Cheers, Arun

+2
source

Adding an answer without rails.

Just remember to check the Twitter settings for your application to check the box "Allow this application to log in using Twitter." Otherwise, Twitter always redirects you to the login page instead of authentication.

I spend 45 minutes troubleshooting rails before finally checking twitter settings, hope this saves a little time.

+20

- twitter oauth gem:

EDIT: .

, oauth . , Devise, ( oauth Twitter):

config.omniauth :twitter, 'consumer_key' , 'consumer_secret', :client_options => {:authorize_path => '/oauth/authenticate'}
+3

"/auth/twitter?x_auth_access_type=read"
+1

, , , . , .

0

, " ", " " , , "" . , , . , , /.

, @toptwetcom , ( API ) , dev, :

If you go to https://twitter.com/settings/applications , you will see that you have granted read, write, and direct message permission to your application. In addition, if you exit your application and register via Twitter, it should β€œjust work” (if you are already logged in to Twitter).

Also be sure to read @JasonLogsdon's answer .

0
source

All Articles