Hi all,
So I know a lot of people have run into the issue of getting an event feed
of a secondary calendar, and what seems to fix the problem is use the
calendar ID plus the secret magic cookie in 'private-MAGICCOOKIE'. I am
trying to avoid having to ask my user to go into the calendar settings to
retrieve the cookie for me, after all isn't that the point of having an
API?
client = gdata.calendar.client.CalendarClient(APP_NAME)
client.auth_token = gdata.gauth.ae_load('access_token')
calendars = client.GetOwnCalendarsFeed();
for i, c in enumerate(calendars.entry):
calendar_id = c.id.text # The [email protected] id
number.
if calendar_id in desired_calendars:
query = gdata.calendar.client.CalendarEventQuery()
query.user = calendar_id
events = client.GetCalendarEventFeed(q=query)
When I do this and loop through the returned events from my calendar, I get
events for my default calendar (even though calendar_id I use is of a
secondary calendar).
Thanks for your help!
-Patrick
--
You received this message because you are subscribed to the Google
Groups "Google Calendar Data API" group.
To post to this group, send email to
[email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://code.google.com/apis/calendar/community/forum.html