每次我受邀参加日历活动时都会进行 Webhook
我有一个 Google Workspace 电子邮件地址,每次有人邀请我的地址参加活动时,我都希望获得一个网络钩子。这可能吗?
查看了 Google Calendar API 上的推送通知页面,但找不到我要查找的内容: https://developers.google.com/calendar/api/guides/push
我总是可以解析收到的邀请电子邮件,但想知道是否有办法设置网络钩子,
谢谢
I have a Google Workspace Email address, and I'd like to get a webhook every time someone invites my address to an event. Is this possible?
Had a look at the Push notifications page on the Google Calendar API but I could not find what I was looking for: https://developers.google.com/calendar/api/guides/push
I can always parse the invitation email I receive but wondering if there's a way to set up a webhook
thanks
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
要请求推送通知,您需要为您想要观看的每个资源设置一个通知通道。
首先,您需要一个端点来接收通知,您可以使用 Google Apps 脚本来执行此操作,如下所述 此处。
获得有效网址后,您只需使用 Google Calendar API 作为高级服务 Google Apps 脚本内(这是使用 Google Apps 脚本的示例,但这可以用任何语言或使用纯 HTTP 请求重现):
之后,您可以转到端点并检查一切是否按预期进行。
To request push notifications, you need to set up a notification channel for each resource you want to watch.
First of all you need an endpoint to receive the notification, you can use Google Apps Script for doing so as described here.
After having a valid URL, you only need to use Google Calendar API as an Advanced Service inside Google Apps Script (this is an example using Google Apps Script, but this can be reproducible in any language or using pure HTTP request):
After that, you can go to your endpoint and check if everything is going as expected.