所有旧问题已过期3-8年。需要有关Google Calendar API V3的帮助。
我看到了如何设置所选日历的共享权限,但是我们要将要共享的电子邮件放在哪里?
答案 0 :(得分:0)
所以我想您想与电子邮件共享日历,这是我在python中的工作代码:
#ACL INSERT add partecipant to a calendar
def update_calendar_by_adding_partecipant_to_a_calendar():
id = "mail@gmail.com"
url = "https://www.googleapis.com/calendar/v3/calendars/"+ id +"/acl"
payload = {
"role": "reader",
"scope": [{
"type": "user",
"value": "mail@gmail.com"
}]
}
response = requests.request("POST", url, headers=headers, data=json.dumps(payload))
json_response = response.text
json_share=json.loads(json_response)
print(json_share)