I'm doing a small app juggling with calendars and I'd love to send invitations to my user's contacts.
I'm wondering, is there a way (even complicated, I don't mind) which would allow me to know whether a particular contact uses Google Calendar or not, so I could send them plain e-mail invitation or full-featured Google Calendar invitation (which they are familiar with and can respond to them with one click from Gmail)?
Input: Contact's e-mail address. (e.g. steve.jobs#apple.com, my.mom#gmail.com, ...)
Output: Boolean information "does this contact use Google Calendar?"
subtask: Boolean information "does this contact even use Google apps?"
It's more or less possible to solve the subtask. Google uses two domains that directly yell at programmer "we are from Google!!!", that's gmail.com and googlemail.com (second one used in UK and Germany due to some legal restrictions). In Python, it's this simple:
def uses_google(email):
return email.endswith(('gmail.com', 'googlemail.com'))
Well, then there are Google Apps. Anyone can run them on his own domain. This should (as far as OpenID is properly installed) solve answer to this question: How to detect if an email is a Google Account?
But what about the usage of Google Calendar?
And is it even necessary to solve such problem? What happens if I send invitations to e-mails without any connection to Google Calendar? Something tells me it wouldn't be nice (maybe only notice "Honza sent you invitation, start using Google Calendar if you'd like to respond"). As a user of the Calendar I know when someone sends invitation to me on wrong e-mail, I can't even respond to it.
A lot of questions here, but I'll take a crack at this.
First off, using Google's mail service doesn't guarantee that the owner use other Google services. Yes, you can assume they have access and they'll be able to accept an invitation, but it doesn't mean they use it as their calendar.
As for somehow gleaning information about Google services used based on a non-Google email address, this does not seem possible. This information is private between the customer and Google, and also borders on proprietary to Google I imagine.
Related
I was wondering if it's possible to utilize the Instagram API with Python in order to gather info on follower account status to seek trends/activity/etc. for my platform. Basically I want to see what brands, etc. users engage with by using the API to see where the accounts who are part of my network go, what they click like on, where they leave a comment/what type of feedback they give/interact across brands. The accounts will consent to this of course, but is this even possible with the API anyways? I have seen services offer this for a fee, so I assumed it's possible somehow.
I assume that when a user leaves a comment it is stored in some database that you can then use the API to see if it matches with some ID or such -- if not then maybe there is a way to do this indirectly, i.e., some kind of background service that can see if a comment/ID matches a username without having to use the API itself. Basically I'm interested if this is feasible/simple -- I'm not too savvy!
This is meant for business and non-business/personal accounts -- also just for the fun of it too.
I have peeked at the API but it does not mention this, and no amount of searching narrows it down.
I know Facebook made some changes with their graph API which basically makes this a dead end on their platform without some possible hackaround if that is even theoretically possible.
I'm doing some research, where I have a facebook app, that asks for some permissions on the users facebook to get some basic information.
I can see that my app has about 600 users, and I'd like to query them, to see some patterns in the users. i.e. how many friends do they have, how long messages do they post in updates etc.
My question is: Do I have to copy the data when the user first visits my app and grants access to his information, or can I query it as long as the user hasn't "removed" my app.
I hope the second option will be true, since I have a lot of considerations about "copying" user data, and storing it in a database - primarily ethical but also related to security issues, compliance, resources so on and so forth.
the programming language is not important, but if anyone needs to exemplify, lets say it's python.
NO. You don't have to copy the data.
You can query Facebook as long as you have a valid access token regardless of whether the user is online or offline.
However, the only thing you need to take care of is handling of expired access token, because in that case the user will need to re-authorize your application for you to get the access_token.
I'm writing a command line script to subscribe every account on our Google domain (Apps for Education and Business) to a single academic schedule calendar. There doesn't seem to be an easy way to force this, so I'm using Calendar API V2 and the python API client to grab all the accounts and individually subscribe them to the calendar. The API responds differently depending on whether the user was already subscribed to the calendar, however the documentation doesn't seem to indicate any way to check whether someone is already subscribed to a calendar without changing the state of the subscription.
https://developers.google.com/google-apps/calendar/v2/developers_guide_python#ManagingSubscriptions
I need a non-destructive way to find out who is already subscribed to the calendar so we can make a list and roll-back should we decide to cancel this whole calendar endeavour.
Right now the best way I can think of doing this is to do perform the change and record which ones were already subscribed, but I'd really rather see if theres a side-effect free way of doing this before I unleash it on the production domain.
Any ideas?
You can retrieve a list of all the calendars in a user's list. Note that this includes hidden calendars that the user will not see in their UI:
https://developers.google.com/google-apps/calendar/v2/developers_guide_python#RetrievingCalendars
feed = calendar_client.GetAllCalendarsFeed()
print feed.title.text
for i, a_calendar in enumerate(feed.entry):
print '\t%s. %s' % (i, a_calendar.title.text,)
I'm developing a Google App Engine-app where one can fill out an online-form and based on how you fill it out a calendar post in a specific Google Calendar is created. What I'm wondering about is authorization in this type of situation where I want this form to be 100% publicly available and require no login whatsover to create the calendar post.
Using OAuth2 I have gotten the actual form and post-creation to work as I want but only when I'm signed in.
This is what I'm doing now, I have:
One registered app, let's call it form-app(.appspot.com)
One Google account, let's call it form-app-admin(#gmail.com) This account owns the Google Calendar that the posts are going in.
One API Project owned by form-app-admin
I have used these and the google-api-python-client library (with its oauth2decorator) as in the Google App Engine-example so when I'm logged in as form-app-admin and surf onto form-app.appspot.com everything works exactly as I want it to but if I am not logged in as form-app-admin, naturally, it doesn't.
So what I would like to do is to kind of grant this permission to write to form-app-admin's primary calendar to the actual app rather than the user currently using the app. Or is there a better way?
The only premises is that anyone (logged into gmail or not) should be able to fill out the form and thus creating a post in some google calendar.
Naturally I would be very thankful if anyone happened to have the appropriate python code to achieve this but primarily I want help figuring out how to go about this since I have very little experience with auth-related stuff.
Thank you for your time!
/Tottish
What you want is the App Identity API. That page shows examples of how to use the API to assert identity to Google APIs.
I have a simple 'Buy Now' Google Checkout button on my Django site (very simple; no basket or anything more fancy). What I want is for Google to send a notification to a URL on my server once a new order has been processed. The notification should tell me the customer's email address and name (preferably as simple POST params). Then I can take this info and set up a user account, send out a confirmation email, etc.
This sounds simple. However, all I can find by way of documentation on Google's site is a dense and impenetrable thicket of competing versions, protocols, and APIs with no clear tutorials or example code. It is a nightmare.
Furthermore, I can see no obvious way of testing out the functionality. I continually see references to a 'sandbox', but I can find no concrete information on what this is or how to set it up. The URL 'sandbox.google.com' returns a 503 error.
Can anybody give me a pointer?
Thanks in advance.
Tom
Take a look at how Satchmo handles notifications in: payment.modules.google