-1

I'm having issues with getting saving a facebook login into my database. I'm getting the error in my browser.

Could not authenticate you from Facebook because "Invalid credentials". 

And this error is in my terminal. Any ideas? I've been browsing for 2 days and it's possible that the facebook api has changed. My only lead is that my app isn't using the client token at all.

And I don't know how to debug where user is nil or not. Any help is appreciated. Thanks.

Started GET "/users/auth/facebook/callback
code=AQCdbZAc0Nk6YS9_YNebSvNzRC9TQwWQbgolxpu2ZtNsxjP9nzECvkDGFQE71gxTTv86_ uc5mhkTzB4FBZinlDEaD0FFakDu3H-V7YmmYy_kcTRjxQTPucD-GnBlAiozDyQ3KLhnXE3nzWbcRsXwF_eFfc4kGUU8ww9Sgds906-w6lFppl4e78iudEfs9d-lhxgP_qa3_oUBfcG2fEiIYkMGYIOQIg_-9PWhgdrh_WT8qFyemN1qtkBuwE173UI-EodfrfGBTZVBBjM-U8n4rqeFX6gqgyNldMMa9gzXRVPuZ7cBEc1okzuQTgTAagz-KMmW0rNXgP81nWCVgqSPsX1O&state=c8957c4caba73271f3ed9a083412aa995afebf1ba2e63f50" for 127.0.0.1 at 2016-02-27 22:11:16 -0800
I, [2016-02-27T22:11:16.190167 #9991]  INFO -- omniauth: (facebook) Callback phase initiated.
E, [2016-02-27T22:11:16.350628 #9991] ERROR -- omniauth: (facebook) Authentication failure! invalid_credentials: OAuth2::Error, : 
{"error":{"message":"The request is invalid because the app is configured as a desktop app","type":"OAuthException","code":1,"fbtrace_id":"GWdVBeCdl0k"}}
Processing by Devise::OmniauthCallbacksController#failure as HTML
  Parameters: {"code"=>"AQCdbZAc0Nk6YS9_YNebSvNzRC9TQwWQbgolxpu2ZtNsxjP9nzECvkDGFQE71gxTTv86_uc5mhkTzB4FBZinlDEaD0FFakDu3H-V7YmmYy_kcTRjxQTPucD-GnBlAiozDyQ3KLhnXE3nzWbcRsXwF_eFfc4kGUU8ww9Sgds906-w6lFppl4e78iudEfs9d-lhxgP_qa3_oUBfcG2fEiIYkMGYIOQIg_-9PWhgdrh_WT8qFyemN1qtkBuwE173UI-EodfrfGBTZVBBjM-U8n4rqeFX6gqgyNldMMa9gzXRVPuZ7cBEc1okzuQTgTAagz-KMmW0rNXgP81nWCVgqSPsX1O", "state"=>"c8957c4caba73271f3ed9a083412aa995afebf1ba2e63f50"}
Redirected to http://localhost:3000/users/sign_in

Completed 302 Found in 211ms (ActiveRecord: 0.0ms)

Brian Lau
  • 127
  • 14
  • Is this helpful? http://stackoverflow.com/questions/16223634/how-do-you-create-test-users-for-a-facebook-app-with-type-native-desktop – Hieu Pham Feb 28 '16 at 07:28

1 Answers1

0

My guess would be
1. You used improper credentials for facebook developer api
2. The facebook login failed since you entered invalid email id or password.

sureshprasanna70
  • 1,043
  • 1
  • 10
  • 27
  • I doubled check my credentials too many times. Does it have to be in development? Maybe I need to run a test app on the local server? – Brian Lau Feb 28 '16 at 16:46