google-calendar-api - Google calendar id length and event id length
问题描述
I try to search the default google calendar ID length and event ID length, but not able to find the information, I need to store the calendar ID and event ID in mysql, so the size is required.
I will not provide my own ID when add events/calendars, I am looking for the ID as :
If you do not specify an ID, it will be automatically generated by the server.
What is the length of such calendar ID and event ID?
解决方案
回答:
日历 ID 不可写,由服务器生成。可以按照事件创建文档中的规定生成事件 ID。
更多信息:
根据有关事件的文档:插入:
id
string
:事件的不透明标识符。在创建新的单个或重复事件时,您可以指定它们的 ID。提供的 ID 必须遵循以下规则:
- ID 中允许的字符是 base32hex 编码中使用的字符,即小写字母 av 和数字 0-9,请参阅RFC2938中的第 3.1.2 节
- ID 的长度必须介于 5 到 1024 个字符之间
- 每个日历的 ID 必须是唯一的由于系统的全球分布特性,我们不能保证在事件创建时会检测到 ID 冲突。为了最大限度地降低冲突风险,我们建议使用已建立的 UUID 算法,例如RFC4122中描述的算法。如果不指定ID,则由服务器自动生成。
请注意, the
icalUID
和 theid
不相同,在事件创建时只应提供其中一个。它们语义上的一个区别是,在重复事件中,一个事件的所有出现都有不同id
的 s,而它们都共享相同icalUID
的 s。
至于日历 ID,从日历资源页面可以看到,它id
是不可写的。
推荐阅读
- html - 为什么我的“gif”文件在我的 HTML 文档上没有动画
- python - 从 Python 列表中将唯一项添加到 .txt 文件
- permissions - 如何限制某些 Informix 用户的权限
- vb.net - 在 IF 语句中使用调用方法 vb.net
- laravel - 如何预先填写用户在 Laravel 7 中输入的表单数据
- discord - 如何创建一个只在您的频道中播放本地音频文件的 Discord 机器人?
- c++ - 在解决 C++ 问题中的继承问题时需要帮助
- linux - Puppeteer newPage() 冻结/从不解决也不拒绝 Ubuntu 服务器
- ruby - Mac M1 - Cocoapods 不工作 (Flutter) verify_minimum_git_version
- swift - 如何伪造 Alamofire 请求进行单元测试?