简体   繁体   English

访问用户Google日历活动

[英]Access to users Google Calendar events

I have configured in my google account application following CalDAV and Google Calendar API instructions. 我已按照CalDAVGoogle Calendar API说明在我的Google帐户应用程序中进行了配置。

As result I have turned on 2 APIs for my application 结果我为我的应用程序打开了2个API

  • CalDAV API; CalDAV API;
  • Google Calendar API (GC API). Google Calendar API(GC API)。

I have created token to get access via my personal client to google calendar information. 我已创建令牌以通过我的个人客户端访问谷歌日历信息。 Using quick start guide I have loaded only my personal calendar events. 使用快速入门指南我只加载了我的个人日历活动。 I have investigated other java samples but I did not find how to load calendars of different users. 我调查了其他java 样本,但我没有找到如何加载不同用户的日历。

Is it possible to load someones calendar information via CalDAV\\GC API with java client? 是否可以通过CalDAV \\ GC API使用Java客户端加载某些日历信息? Which clients information I should have got to load clients data (accept loginName)? 我应该有哪些客户端信息来加载客户端数据(接受loginName)? Can I have a link to get more information about loading users' calendar events to view & manage its from external applications? 我是否可以通过链接获取有关加载用户日历事件的更多信息,以便从外部应用程序查看和管理它?

To get the other users Calendar Events, Note: You must be an authenticated user that has a permission to access the other calendar events. 要获取其他用户日历事件,请注意:您必须是具有访问其他日历事件权限的经过身份验证的用户。 By using this Events: list you can try here to get the other users calendar event by passing the calendarId of the other user in the calendarId parameter. 通过使用此Events: list ,你可以在这里尝试通过将得到其他用户的日历事件calendarId在其他用户的calendarId参数。

There is a Java example code here that you can follow. 这里有一个Java示例代码 ,您可以遵循。 The " primary " word here means that you will access your own calendar, just change it to the calendarId of the user to get its own calendar event. 这里的“ 主要 ”字词表示您将访问自己的日历,只需将其更改为用户的calendarId即可获取自己的日历事件。

If you want to list Google Calendar Events without the User Authentication, then this SO question can help you with that. 如果您想在没有用户身份验证的情况下列出Google日历活动,那么此SO问题可以帮助您。 It use a Service Account to access the other user calendar. 它使用服务帐户访问其他用户日历。

Hope it helps you. 希望它能帮到你。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM