[.Net/C#/WinForms] User Management Application - subscribe user to corp resource calendar

170 views
Skip to first unread message

Markusr

unread,
Nov 30, 2011, 7:06:28 PM11/30/11
to google-app...@googlegroups.com
Good day,

I am writing an in-house user management application.

I am able to connect to the AppsService and get a complete list of users.

                appservice = new AppsService(aDomain, aDomainUserName, Decode(aDomainUserPwd));
                UserFeed uf = appservice.RetrieveAllUsers();
                ...

I am also able connect to the CalendarResourceService and get a list of calendar resources.

                resourceservice = new CalendarResourceService(aDomain, "google_control_demo");
                resourceservice.setUserCredentialsaDomainUserName,Decode(aDomainUserPwd));
                var rf = resourceservice.RetrieveAllCalendarResources();
                ...

I am also able to create a new user.

                var user = appservice.CreateUser(aUserName, aUserFirstName, aUserLastName, GenerateStrongPwd());

How do I subscribe the new user to a Calendar Resource (I have the calendar resourceEmail)?

(Am I doing everything in the preferred manner as well?)

-Markus

Jay Lee

unread,
Nov 30, 2011, 7:52:02 PM11/30/11
to google-app...@googlegroups.com
Hi Markus,

  The Calendar Resource API allows you to create, update and delete resource calendars but it does not deal with ACL rights to the calendar or adding the calendar to the user's list of Calendars. For those functions, you use the Calendar Data API. If you need help figuring out the API calls to share the calendar and add it to the user list, you can post in the Google Calendar API Forum.

Jay

Markusr

unread,
Nov 30, 2011, 8:15:36 PM11/30/11
to google-app...@googlegroups.com
Thanks much for your fast reply!

Bugger! I knew someone would say that.

I will go there next (hopefully this can be done from the admin's account). :)

-Markus

Robert Norris

unread,
Dec 1, 2011, 1:50:13 AM12/1/11
to google-app...@googlegroups.com
You can. Admin accounts implicitly have the equivalent of the "modify events and manage sharing" permission on all calendars in the domain.



--
You received this message because you are subscribed to the Google Groups "Google Apps Domain Information and Management APIs" group.
To view this discussion on the web visit https://groups.google.com/d/msg/google-apps-mgmt-apis/-/WSZnFeeguy8J.

To post to this group, send email to google-app...@googlegroups.com.
To unsubscribe from this group, send email to google-apps-mgmt...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/google-apps-mgmt-apis?hl=en.

Reply all
Reply to author
Forward
0 new messages