omniauth

Ruby on Rails, LinkedIn:Module error

爱⌒轻易说出口 提交于 2019-12-23 18:27:24
问题 Has any one come across this error? NoMethodError (undefined method `new' for LinkedIn:Module) I think it's related to omniauth and linkedin. Here's my Gemfile: gem 'omniauth' gem 'linkedin', :git => "git://github.com/redbeard-tech/linkedin.git", :branch => 'jsapi' I'm using: ruby 1.8.7 (2010-01-10 patchlevel 249) rails 3.0.5 What might be the reason for it? 回答1: Check what version of omniauth you are using. We recently ran into this and it was from our dev environment having omniauth 0.3.x

rails5 api + devise_token_auth: no access-token and uid returns after login successfully via omniauth2

帅比萌擦擦* 提交于 2019-12-23 17:50:46
问题 I am using devise_token_auth for omniauth2 login with weibo and qq. Yes, I am trying to use rails5 api feature! After setup and using omniauth test_mode, I seems like login successfully but not login info( access_token, expiry, client and uid ) return in the header of response. Here is model, I apply candidate rather than user as authentication resource. #app/models/candidate.rb class Candidate < ApplicationRecord devise :database_authenticatable, :trackable, :omniauthable include

rails5 api + devise_token_auth: no access-token and uid returns after login successfully via omniauth2

走远了吗. 提交于 2019-12-23 17:42:01
问题 I am using devise_token_auth for omniauth2 login with weibo and qq. Yes, I am trying to use rails5 api feature! After setup and using omniauth test_mode, I seems like login successfully but not login info( access_token, expiry, client and uid ) return in the header of response. Here is model, I apply candidate rather than user as authentication resource. #app/models/candidate.rb class Candidate < ApplicationRecord devise :database_authenticatable, :trackable, :omniauthable include

Omniauth-Facebook callback does not get initialised in Rails Mountable Engine

巧了我就是萌 提交于 2019-12-23 06:56:58
问题 I'm developing a mountable engine (called SimpleUser) which uses Devise, OmniAuth and OmniAuth-Facebook. First I made a test app with the gems about and every worked fine. Next, I started building the engine from scratch, using the code of the test app as an example. Everything is almost done, except for the connection with Facebook (it uses the Javascript popup). When I click in "log in" the FB popup is displayed, I grant the app, it redirects to the route specified (see routes), but throws

How to use OmniAuth only for authorization from different Apis without authentication in Ruby on Rails

时光总嘲笑我的痴心妄想 提交于 2019-12-23 01:15:13
问题 I want to use OmniAuth to retrieve user access_token and secret from facebook , twitter and google at the same time. I'm using Devise for authentication , and I want to know how to request keys when the user is signed in and store them in a database to use them later . 回答1: Add in gem file gem 'devise' gem 'omniauth' gem 'omniauth-twitter' gem 'omniauth-facebook' gem 'omniauth-linkedin' Generate migrations and models rails generate devise:install rails generate devise user rails g migration

Faraday::Error::ConnectionFailed Omniauth Facebook

China☆狼群 提交于 2019-12-22 23:14:26
问题 I am getting error in rails - Faraday::Error::ConnectionFailed. I am trying RailsCast Omniauth Episode. It's working fine with Twitter. But when I give http://localhost:3000/auth/facebook it's giving error. I have also see question, but problem not solved. Settings on developer.facebook.com Site URL: http://localhost:3000/ Site Domain: localhost I am using windows. I have also read question. Thanks! 回答1: I have solved this problem. This problem might be for windows users only. Use this, 1

Faraday::Error::ConnectionFailed Omniauth Facebook

旧街凉风 提交于 2019-12-22 23:13:30
问题 I am getting error in rails - Faraday::Error::ConnectionFailed. I am trying RailsCast Omniauth Episode. It's working fine with Twitter. But when I give http://localhost:3000/auth/facebook it's giving error. I have also see question, but problem not solved. Settings on developer.facebook.com Site URL: http://localhost:3000/ Site Domain: localhost I am using windows. I have also read question. Thanks! 回答1: I have solved this problem. This problem might be for windows users only. Use this, 1

instagram api - cryptic response; not sure if working and unable to test omniauth with this

不羁的心 提交于 2019-12-22 18:24:20
问题 I am working on an rails app that has as the requirement logging in with omniuth to instagram. This would be my first time using instagrams OAuth endpoint and it is unclear whether it is working (and not clear to project manager either). I'm using their cURL implementation with the following (will reset it in future) but getting "No matching code found" error which would seem to be the logical first setp. curl \-F 'client_id=4658fa17d45244c88dd13c73949a57d7' \ -F 'client_secret

omniauth behind proxy

回眸只為那壹抹淺笑 提交于 2019-12-22 09:39:11
问题 I have a small app using omniauth and I'm testing it with LinkedIn provider (omniauth-linkedin). Unfortunately my test environment is behind a proxy. So I need to access linkedin through a proxy. How do I set the proxy address so the request to linkedin will succeed? It does not seem to be obeying the http_proxy settings. 回答1: I figured it out, I think.. ue OmniAuth::Builder do provider :linkedin, "KEY", "SECRET", {:client_options => { :proxy =>\ ENV["HTTP_PROXY"] || ENV["http_proxy"] }} end

Devise/Omniauth failure: How to debug it?

最后都变了- 提交于 2019-12-22 03:21:06
问题 After trying to "log in with Google", I'm seeing this error in the logs: Processing by Users::OmniauthCallbacksController#failure as HTML I can see all the data from google being sent through the URL (in the logs), including user email and name. So what could go wrong? My callbacks aren't even being executed. I only get redirected to the sign_in page of my site. And I'm pretty sure everything is configured correctly, because this was working fine some weeks ago. I don't think I changed