简体   繁体   English

如何通过电子邮件用户名身份验证创建Google Calendar事件?

[英]How to create Google Calendar event by email-username authentication?

I need to create google calendar events from my application, based on logged user. 我需要根据登录用户从应用程序创建Google日历事件。 For each user I have email/password of the gmail account. 对于每个用户,我都有gmail帐户的电子邮件/密码。 From my searches, every guide is for creating events to just one gmail account like here: OAuth 2.0 Google API access but this is not my case. 从我的搜索中,每条指南都是针对仅向一个gmail帐户创建事件的,例如: OAuth 2.0 Google API访问,但这不是我的情况。 Has anyone ever faced this issue? 有没有人遇到过这个问题?

You can not use Login and password to access a users Google calendar account. 您不能使用登录名和密码来访问用户的Google日历帐户。 This is called client login and was shut down by google may 2015 . 这称为客户端登录,并已于2015年5月Google关闭。

You have a few options. 您有几种选择。 First you can add an event to a calendar you own personally then add the different users as attendees using their email address they will get an email and be able to click the email and add it to their personal google calendar account. 首先,您可以将事件添加到您自己的日历中,然后使用他们的电子邮件地址将不同的用户添加为参与者,他们将收到一封电子邮件,并能够单击该电子邮件并将其添加到其个人Google日历帐户中。

Switch to Oauth2 you do not need to be storing a users login and password to their Google account you cant use it for anything. 切换到Oauth2,您无需将用户的登录名和密码存储到其Google帐户中,因此您不能将其用于任何用途。

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

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