Omniauth doesn't return Facebook Checkins? - ruby-on-rails

After authenticating with Omniauth/facebook, checkins dont seem to be included inside the data hash I am receiving from request.env["omniauth.auth"], I have authorized for checkins and can see them fine when hitting the url with my access code..
Anybody have any ideas?

Look at: https://github.com/nsanta/fbgraph instead. Omniauth isn't really intended for scraping all the possible facebook data, just for authenticating.

Related

omniauth-facebook and fb_graph not working together

I am developing a rails 3.2 application and am authenticating using omniauth-facebook. This part has been giving me no problems. I get the request.env['omniauth.hash'] successfully and I extract the Oauth token as such.
auth_hash = request.env['omniauth.hash']
token = auth_hash['credentials']['token']
Afterwards I try to hit Facebook's Open Graph using fb_graph as such:
user = FbGraph::User.me(token)
However when I do this, my user is not loaded. I just get a blank user and it seems like facebook is not accepting my token as a valid token for some reason. Am I doing something wrong? Is the token I have not the one I need to make Facebook Open Graph requests? Help is much appreciated!
Try user = FbGraph::User.me(token).fetch

how to share fixed data on facebook if used omniauth for authentication

I have used omniauth for authentication of user in rails. i just want to create a button on my site which when clicked should post to logged in users facebook profile a certain fixed data.
i have tried facebook_share gem but unable to specify the predefine text. kindly help me in this
thanks in advance
In place of facebook_share the better way is to use facebook api. link explains all
https://github.com/aayushkhandelwal11/training-assignment/blob/master/facebookshare.txt

OAuth, Twitter and Indentity - who am I?

Once authenticated to Twitter via OAuth I did not see a good call to get your username.
How is this supposed to work? I'd like to pull back things like Twitter username, firstname, lastname, etc... basic profile stuff. Should the OAuth handshake give me my username?
Try this:
https://dev.twitter.com/docs/api/1/get/account/verify_credentials
It'll show you all information (you'ld normally get of any other user) of the OAuth-authenticated-account =)!
First, Twitter includes the screen_name parameter in the access token response. Second, you can call http://api.twitter.com/1/account/verify_credentials.json to get the full profile which will also include the name (JSON key 'name'). Twitter does not provide email addresses.
Have you tried any of these libraries? I've tried just about all of the php ones and all that I tried had examples on how to get the user data.

twitter connect and rails

I am reading this tutorial: http://blog.dhavalparikh.co.in/2009/06/step-by-step-twitter-oauth-integration-with-rails/
OK, first redirect to twitter connect page. When I allow the connection, twitter redirect to https://twitter.com/oauth/authorize with a code for connect but this must redirect to a action which connect and create a new user in my db.
SO which could be the problem? How i must config the twitter application callback url and app url for localhost.
please i need this answer
Thanks in advance
This doesn't really answer your question but is a nicer way to do this.
Omniauth is a nice gem for rails that makes it very easy to offer twitter, facebook etc. login.
A good intro to this was created by Ryan Bates of Railscasts.
The problem is: Twitter send the token information via post. SO i receive the token by params.
Also there is a problem with oauth 0.4.
I am using oauth 0.3.4 because work in the correct form when twitter try redirect to callback url.

OmniAuth to extract full profile data from LinkedIn

I'm loving the ease of OmniAuth, but I'm having a hard time connecting the dots on making additional api calls after I receive the token back.
I'll use LinkedIn as an example, but it's not LinkedIn that's the issue, more so my lack of understanding on how to make subsequent calls after I have authenticated.
I can make the request to LinkedIn and authenticate just fine.
Then I get the hash back and it's completely populated.
Now I would like to call LinkedIn back and get my complete profile data or maybe a list of contacts. How do I do this? Will I need the oauth gem after all?
I'd prefer to avoid app specific gems because I will have to make the same requests to twitter and facebook.
Omniauth is designed for authentification only.
Marcel Falliere is right. Omniauth is just for authentication.
You can have a look at this plugin, it could solve your problem.
https://github.com/pengwynn/linkedin
I think I just found out the answer to it.
after completion of oauth process with service provider(fb, twitter) omniauth saves the user. here it passes a hash to the user object and the content of hash are here https://github.com/intridea/omniauth/wiki/Auth-Hash-Schema these credentials part can be used to request further request( infact u will have to save these in your user object).

Resources