omniauth

Missing client_id with Devise and Facebook-Omniauth

梦想与她 提交于 2019-12-10 22:15:18
问题 Here is my initializers/devise.rb code for Facebook: require "omniauth-facebook" config.omniauth :facebook, "app_key", "app_secret" And I have added: devise :omniauthable into the model I want to be able to use Facebook with. When I click on this link: <%= link_to "Sign in with Facebook", user_omniauth_authorize_path(:facebook) %> I get: An OAuthException with message: "message": "Missing client_id parameter.", Notice that the app_key and app_secret are the ones that I can see on my Facebook

Gathering a user's news feed with Koala (Ruby)

China☆狼群 提交于 2019-12-10 21:41:17
问题 I want to pull in a user's newsfeed after they have authenticated. I am using the Koala gem but if I call get_connection('me', 'feed') it only returns the last three posts on my wall. I want the last ~100 posts (or since post 1234567) that would show up on the user's home page. 回答1: You can get all posts during a certain time period using FQL. Here is an example that should get you started: @feed = Koala::Facebook::API.new(current_user.token) to = Time.now.to_i yest = 1.day.ago.to_i @feed.fql

OmniAuth + Devise - Facebook provider - OAuthException 191

我们两清 提交于 2019-12-10 19:37:31
问题 Problem I'm getting the following error: "error": { "message": "Invalid redirect_uri: Given URL is not allowed by the Application configuration.", "type": "OAuthException", "code": 191 } It is very known and I found many different solutions to adress it and unfortunatelly any of them worked for me. I'm trying to make it run locally in the localhost:3000 , but can't make it work. My configuration is a common configuration: config/initializers/devise.rb config.omniauth :facebook,

Unicorn and omniauth-facebook - uninitialized constant OmniAuth

佐手、 提交于 2019-12-10 17:41:34
问题 So I am trying to get omniauth-facebook to work in my production env. It works fine locally on my machine using POW. My prod env is ubuntu with nginx/unicorn and code is Rails 3.2.13, the errors from unicorn are: E, [2013-05-20T15:51:13.900829 #8737] ERROR -- : uninitialized constant OmniAuth (NameError) /home/web/apps/****/releases/20130520041958/config/initializers/omniauth.rb:1:in `<top (required)>' So from what I could find I try adding require 'omniauth/facebook' above the configure

Cannot getting devise omniauthable working

久未见 提交于 2019-12-10 16:59:50
问题 I need to access google APIs, I'm trying to make users log in with their google account using Devise 2.1.1 and Omniauth (using the gem google_oauth2 since OAuth2 is the reccomended one from google docs). Unfortunatly I cannot get it working, this is the routes.rb TestApp::Application.routes.draw do root :to => 'Landing#index' devise_for :users, :controllers => { :omniauth_callbacks => "users/omniauth_callbacks" } devise_scope :user do get 'sign_in', :to => 'users/sessions#new', :as => :new

Devise Oauth Twitter: OAuth::Unauthorized Forbidden 403

自古美人都是妖i 提交于 2019-12-10 16:14:21
问题 I am trying to implement Oauth Twitter using Devise. I have created app on twitter I have set callback url to: http://localhost:3000 I have added this to config\initializers\devise.rb config.omniauth :twitter, "key", "key secret" Sign in with Twitter automatically appears at this route: /users/sign_up/ But on clicking it I get this error key and key secret are correct I also tried deleting and creating new app. I cannot get it fixed Help would be greatly appreciated Here it says that https

Devise Omniauth - setup & defining strategies

痴心易碎 提交于 2019-12-10 13:54:14
问题 I tried asking this question - and didn't find any help. http://stackoverflow.com/questions/33493369/rails-devise-omniauth-problems-with-setup I gave up trying to solve the problem and made an entirely new app with nothing else in it so that I could try to reduce the scope for other errors interfering. In my new app, I now get an error when I click on the new registration/new user link. I have followed the rails casts tutorials (having tried about 20 others) to get this setup. 1.5 years in

Make local development work with Facebook/Google APIs

谁都会走 提交于 2019-12-10 11:48:55
问题 I'm working on implementing omniauth into a Rails project. My problem is that the authentication providers - Twitter, Google, Facebook etc all require me to create an application with a url that limits authentication requests from anywhere other than the url. I need to be able to to test locally but also run code in production, but Facebook for example doesn't allow 2 domains and doesn't allow localhost anyhow. So what are my options? 回答1: At work, we have multiple applications setup for the

Omniauth + Google + Faraday + Behind the proxy = how setup proxy?

夙愿已清 提交于 2019-12-10 11:21:33
问题 My production server is Ubuntu 12 . I'm using Devise + OmniAuth to handle the Google authentication. But when Google returns a control to my application I get an error "Network is unreachable" . I assume it's because of server is behind the proxy. Here's error description: ------------------------------- Request: ------------------------------- * URL : http://efiling.uipv.org/users/auth/google_oauth2/callback?state=f4eaca9fbed2a77c0baac50cdbdccab7eee671179bb8fc43&code=4

OmniAuth / Rails - You have a nil object when you didn't expect it

北城余情 提交于 2019-12-10 10:32:25
问题 I'm getting the following error in my Rails application and I have no idea how to go about debugging or fixing it: NoMethodError in AuthenticationsController#create You have a nil object when you didn't expect it! You might have expected an instance of ActiveRecord::Base. The error occurred while evaluating nil.[] Rails.root: /Users/phil/Sites/travlrapp.com Application Trace | Framework Trace | Full Trace app/controllers/authentications_controller.rb:15:in `create' The controller is this: