There are a few questions on individual components of "Sign in with Google" floating around, but I can't find any that refer to the current API (as of July 2015).
I have a "Log In with Gmail" option in my webapp, and I'd like to retrieve:
All emails that I've ever sent and received (if possible)
A list of all my contacts
A list of all my contacts' profile pictures (and any other info that may be possible, like location, gender, age etc)
Right now, in my oAuth login I use the following scope:
['profile', 'email','https://www.googleapis.com/auth/userinfo.profile', 'https://www.google.com/m8/feeds']
Then once I have my oAuth token, I make the following API call:
https://www.google.com/m8/feeds/contacts/default/full?max-results=10000&alt=json&oauth_token={{token}}
This give me a list of contact emails and associated names, but no pictures (at least that I can find) and no other info about contacts.
I'd also like to be able to download all of the user's sent/received emails, I understand that I have to do this via IMAP but I can only find NodeJS implementations that require a username and passwords. Is it possible to do using an oAuth token?
Ideally I'd like to do this all with the one oAuth call, as I'm building an email analysis tool.
Gmail provides an HTTP API you can use to access all of a user's sent and received emails.
The Contacts API is basically only information the user has manually entered for the contact. Most users aren't going to be entering age and gender and contacts will only have locations if the user treats it like a traditional address book.
If you want to get something more like a social profile you might want to check out the Google+ people.list API. You will have to find a way to correlate between contacts and Google+ profiles but Google+ profiles are more likely to have photos demographics data.
Related
Context
Sign-up form and one of the fields is Instagram account
When the user will finish sing up, there's a link to the person's Insta account
(No integrations)
Goal
I want to make sure the user can only sign up with his own Instagram,
much like e-mail verification
My thoughts
I took a look at the Instagram API documentation and didn't find an option for it. Any thoughts about how to do that?
There would be an option to use the Insta auth basic, allow the user to sign-up via Instagram. Although this seems to be a proper overkill and it's getting deprecated anyways.
I tried to use the googleapi#27 to get the profile information but it gave me only following fields.
{
emailAddress: 'jainshravan321#gmail.com',
messagesTotal: 2122,
threadsTotal: 2111,
historyId: '116715'
}
I tried above with this(https://developers.google.com/gmail/api/quickstart/nodejs?authuser=1) example. I need all of the fields like firstname, lastname, email address, contact number & all of the fields available in user's profile. So do you know any way by which i will be getting all of the fields of user's profile using googleapi under node js.
Users: getProfile
Gets the current user's Gmail profile.
A users gmail profile consists of
{
"emailAddress": string,
"messagesTotal": integer,
"threadsTotal": integer,
"historyId": unsigned long
}
The information you are looking for its not part of the Gmail api. The gmail api is a mail system it is not a user profile system. You should try looking into the People api or the google+ api.
People api is basically linked to google contacts so if the user has not filled in this information you wont get it back. Google+ api is linked to the google plus social media site. If the user has not set the information public for example phone number you will not be able to see it.
There is no really good way of getting this information back.
Update: after a big of googling it looks like the call for people and google+ is the same endpoint now. But the data comes from Google+ and contacts combined.
I have 1700 users who have registered to DocuSign using the company domain. These users are not part of the account. I am looking for an API to get more information on these users such as when they last logged in. I see there is an API available for getting users that are part of the ACCOUNT.
Users: List
GET /v2/accounts/{accountId}/users
As people who directly registered with my company domain email address don't have an account, I am not able to use this API. Let me know if there is any other API to get this information.
There's no API that will give you this information. I'd suggest that you contact DocuSign support (or ask your DocuSign Sales Rep, if you've been working with one) for assistance -- it may be possible for them to provide this type of information for you.
The facebook chat api is a power tool. From a purely technically point of view, it definitely does more than its predecessor of private messages in the Graph API.
This brings up a question of where Facebook is drawing the line of abuse of its chat api.
So here's how I'm planning to use the Facebook chat api for my app.
The app is an event planning app that lets users invite their friends to an event. Other than sending SMS, and emails to notify the guests, the most reliable way is to send invitations through the list of facebook friends. And let's face it, sometimes you may not have the person's phone number in your contact book, and you definitely don't remember most of their emails, so facebook is your only source for reaching them.
So I need a solution to send invitations to the guests. Here are my requirements and conditions:
The guest is a facebook friend of the user
There's no way of obtaining the guest's email (unless the user enters it) or phone number (ie. sms is not an option)
Each guest must receive a link that is unique to him/her
No one else should be able to obtain this link (ie. the message shouldn't be seen publicly)
It must not require the user's interaction to send these invitations (imagine having the user confirm a facebook post 10 times for the 10 facebook friends he's inviting). The invitation must be sent automatically.
Here's the obstacle. Facebook had revoked the functionality to send private message recently (I was able to have my facebook friends send me private messages via an app just over a month ago, not anymore). However, I discover that I could do so using Facebook Chat API.
This seems to be a grey area, my app is using the chat api for the sole purpose of helping the users notify their friends of their event invitation. There's no intention of abuse (such as mass messaging everyone of the user's friends with a link to my APP/website). Is Facebook going to hunt me down and revoke my App's privilege to use Facebook's API?
Can anyone shed some light on whether my intended usage of the API is an abuse or is it legitimate? If it is not legitimate, what are your suggestions.
I'd recommend using core functionality wherever possible here. For example, you could utilise the Facebook 'Event' object and the Graph API to create invite-only events and to invite individual friends of your app's users. This would deliver the same functionality without the need for nonce-based invite URLs and possible misuse of the Chat API. Take a look at https://developers.facebook.com/docs/reference/api/event/#invited for details.
I am a bit shaky on how to use the venues API in forusquare. My main question is related to OAuth. I want to be able to do venue searches on the server side of the system, and i need the server to login into foursquare automatically. It says on the website that foursquare doesn't require user authentication to use some of the venue functions, however whenever i try to do a call to: venues/categories without specifying an oath_token I get a permission error.
How can i do venue calls without having to use a user login?
Thanks in advance.
It would help if you had given the exact url you are trying to call, but in general:
The userless requests to Foursquare still require the client id and client secret that you get when you register the OAuth Consumer in foursquare.
Using the id + secret you can access Venue API endpoints without authenticating with a user.
So if I got to the Venues Categories endpoint you can see that it does not require and acting user and thus accessing:
https://api.foursquare.com/v2/venues/categories?client_id={0}&client_secret={1}&v={2}
Will get the categories list.
In that example, replace {0} with your client id, {1} with your client secret and {2} with whatever version date you feel comfortable with, today would be 20111218
More can be found here https://developer.foursquare.com/overview/auth#userless
you can use https://developer.foursquare.com/docs/explore#req=/venues/categories and in the view box use /venues/categories to see a list of all of the venue codes to use. then simply use:
https://api.foursquare.com/v2/venues/search?ll="+ ll+"&radius=10000&limit=50&categoryId="+catID+"&client_secret=xxx&client_id=xxx
in your call to load the url based upon ll which is long and lat and it will create a response of json object to parse. The App/Web site does not need to be authorized for such a search, and the limit goes to 5000 calls per hour, and you can increase this by emailing Foursquare with the application information and screen image of the app showing you credit Foursquare with the info, like a Foursquare button, etc. - Hope this helps.
Visit https://foursquare.com/developers/apps to get your API keys. Once you click "Create A New App", your Client ID and Client Secret should be visible.
Once you have your keys, try plugging them into this search:
https://api.foursquare.com/v2/venues/search?near=seattle,wa&query=coffee&v=20150214&m=foursquare&client_secret=xxx&client_id=xxx