我遇到了 Google 脚本。浏览了他们的 API 并浏览了他们的一些教程。第一个教程创建一个脚本来创建文档并发送电子邮件。如果我将其他人添加到该电子邮件列表中,他们将无法立即查看它。即使我向他们发送了链接,他们也必须请求许可才能查看。
有没有办法在脚本中对此进行编码,以授予通过电子邮件发送链接的人员查看和编辑的权限?
此外,通过 API 并向人们发送电子邮件,他们表明可以使用抄送和密件抄送。 API 示例未展示如何执行此操作。这是我一直在查看的内容:https://developers.google.com/apps-script/defaultservices
谢谢。
最佳答案
Is there a way to have this coded in the script to give rights to the people that are being emailed the link to view and edit?
Document.addEditor()
, Document.addEditors()
, Document.addViewer()
和 Document.addViewers()
让您将权限分配给其他人。
Also, going through the API and emailing people, they show that cc and bcc can be used.
看看MailApp.sendMail(recipient, subject, body, options)
,了解码成选项
的“高级参数”的描述。选项对象可能包含 cc
和 bcc
成员。
关于javascript - Google 脚本共享权,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/14134207/