google-calendar-api

Authenticating with Google API using AccountManager

落花浮王杯 提交于 2020-01-12 07:58:08
问题 I've been struggling with this for a couple days now. I'm trying to make calls to Google Calendar using authentication via Android's AccountManager . I retrieve an auth token using the usual method: AccountManager manager = AccountManager.get(this); String authToken = manager.getAuthToken(account, AUTH_TOKEN_TYPE, true, null, null).getResult().getString(AccountManager.KEY_AUTHTOKEN); And then, with that token, I create a Calendar instance like this: HttpTransport transport = AndroidHttp

How to add “Attachment” in Google Apps Calendar using Google API version 2?

橙三吉。 提交于 2020-01-11 10:48:11
问题 I am using Google API Version 2 fo .NET to create Google Calendar Entries. How can i add "Attachment" to Google Calendar? Thanx 回答1: I was trying to find the answer to this question myself, and after looking through the XML results for various queries using the Calendar API feeds, I'm pretty sure there isn't currently a way to retrieve or update file attachments. Since calendar event file attachments is a lab feature from Google, it's not entirely surprising that they aren't yet available

Unable to refresh OAuth2 token in PHP, invalid grant

情到浓时终转凉″ 提交于 2020-01-11 09:55:14
问题 I need to make a PHP script that creates a sigle event on Google Calendar. I had no problems setting up client id, client secret, dev key and creating a new event. My only problem is with OAuth2, in particular I need to make a permanent connection and I do not want to do the authentication everytime I run the script. Actually, with this script I'm able to get a token and a refresh token, but every hour my token expires and I don't know how to refresh it. How can I edit this code to do that?

Google API: Difference between browser key and Android key?

江枫思渺然 提交于 2020-01-11 09:51:54
问题 I'm trying to use the Google Calendar API, and I've generated a browser API key that seems to work. But in the API console I also have the option to generate an Android API key. What is the difference between the two? Can I use a browser key in an Android application? 回答1: I'm not sure if it'll work to use a browser key in an Android application, but it doesn't really make sense. From the Google API docs: The Console enables you to create server, browser, Android and iOS API Keys. Once you've

Google OAuth 2.0 Service Account - Calendar API (PHP Client)

若如初见. 提交于 2020-01-11 07:11:35
问题 I have a Google Apps account. I am trying to manipulate a users Calendar within this account. I have created the Project, added the Calendar API service and created a Service Account OAuth 2.0 Client ID through the API console. I have added that generated Email address to the Calendar through the Calendar settings to share the calendar. I have followed the steps suggested to Manage the API access. The client name is the same domain that the Google Apps account is on, and the scope is "https:/

Google Calendar API v3 time zone issues

痴心易碎 提交于 2020-01-11 06:26:07
问题 Using .Net API wrapper for Google Calendar API. First get primary calendar id Get timezone of primary calendar (returns good data, e.g., "America/Los_Angeles") Create a calendar event. Set start time and end time. Set timezone. Dim eStart As New EventDateTime eStart.DateTime = _startAt eStart.TimeZone = GoogleTimeZone Dim eEnd As New EventDateTime eEnd.DateTime = _endAt entry.Start = eStart entry.End = eEnd eEnd.TimeZone = GoogleTimeZone CalService.Events.Insert(entry, calendarid).Execute()

Invalid credentials: Google API calendar

痴心易碎 提交于 2020-01-10 05:49:05
问题 I am new to using Google APIs. I followed steps to setup Google Calendar sample code in eclipse using Google client library. I deployed the code to app engine using the cmd command- mvn appengine:update (when tried to deploy through eclipse it gave me an error saying the project is not an App Engine project). Deploying through command line worked and I could launch my web application. Suddenly, after few API request calls, started getting invalid credentials error: error:401 domain:global

How to stop watch on entire channel of Google calendar events?

浪尽此生 提交于 2020-01-10 04:31:07
问题 How do I stop watching the entire channel? The API reference reproduced below requires a resourceId , seemingly implying that it only stops watching the event specific to the resourceId . For my purposes, I would think that a channelId is enough and therefore uncertain what to put for resourceId . The field is not optional. POST https://www.googleapis.com/calendar/v3/channels/stop Authorization: Bearer {auth_token_for_current_user} Content-Type: application/json { "id": "4ba78bf0-6a47-11e2

Google Calendar api v3 re-update issue

对着背影说爱祢 提交于 2020-01-10 04:04:25
问题 I'm working on google calendar and having problem with syncing data between my Calendar app on Iphone to Google Calendar. (I use google api v3) The problem is: I can update an event by code just 1 time after i created it. The next time when i try to update it, i get message code 400: bad request. We can use google calendar explore to test this (https://code.google.com/apis/explorer/#_s=calendar&_v=v3&_m=calendars.update) by creating an event then update it 2 time. Does any one meet this

Google Calendar API batch request PHP

半城伤御伤魂 提交于 2020-01-10 03:17:07
问题 i am trying to send a bunch of events via an Batch Request to Google Calendar. But i cant figur out how to do. https://developers.google.com/google-apps/calendar/batch doesnt help me. require_once 'google-api-php-client/src/Google_Client.php'; require_once 'google-api-php-client/src/contrib/Google_CalendarService.php'; $client = new Google_Client(); $client->setUseBatch(true); $batch = new Google_BatchRequest(); $uri = 'http://www.google.com/calendar/feeds/default/private/full/batch';