You need to sign in to do that
Don't have an account?

Is it possible to integrate salesforce apex with google calendar ?
hello,
is it possible to integrate using salesforce apex code with google calendar ?
i want to create from apex a simple event on google calendar.
i read about the google calendar api but i can't understand how to do it in apex.
is it possible ? can someone give me a simple example ?
The basic flow is:
1) Authenticate with Google's OAuth service to get a token. This can be done with a popup.
2) Request the data you need access to.
To complete the first step, you'll have to create a Google API account that has a client secret/key pair that is enabled for at minimum calendar access (using whatever permissions you desire). From there, you can use the standard popup/login/authorize flow as documented on Google Developer (https://developers.google.com/accounts/docs/OAuth2).
Once you have an OAuth2 token, you can call the Google Calendar API. This will require setting up a Remote Access point in salesforce.com. Once you allow salesforce.com to connect out, you can use the JSON class to create requests, and parse responses, through the Google Calendar API.
Even this simple description doesn't do justice to the quantity of code you'll have to write, but it is well-documented if you'd like to take a shot at doing this.
All Answers
The basic flow is:
1) Authenticate with Google's OAuth service to get a token. This can be done with a popup.
2) Request the data you need access to.
To complete the first step, you'll have to create a Google API account that has a client secret/key pair that is enabled for at minimum calendar access (using whatever permissions you desire). From there, you can use the standard popup/login/authorize flow as documented on Google Developer (https://developers.google.com/accounts/docs/OAuth2).
Once you have an OAuth2 token, you can call the Google Calendar API. This will require setting up a Remote Access point in salesforce.com. Once you allow salesforce.com to connect out, you can use the JSON class to create requests, and parse responses, through the Google Calendar API.
Even this simple description doesn't do justice to the quantity of code you'll have to write, but it is well-documented if you'd like to take a shot at doing this.
Hi,
Thank you for your reply. It will help for me. But you provided a link not working. Can you please
send any links? I have searched in google sales force provided tool kit
http://wiki.developerforce.com/page/Google_Calendar_API Is it write way?
Thank you
Sorry, the forum added some characters to my link. The link above should work for the first bullet point.
It looks like the code provided in the link you posted should work as well. I wasn't aware such an article existed; it should still be trivial to implement anyways.
Hi,
Thanks for your reply. Can you share any sample code for getting token?
Thank you.
Hi ,
Thank you for your quick reply. It will help for my requirement.
Thank you
i have same requirement
i am creating an event in google calender to use salesforce apex