本文介绍了使用Admin SDK通过Apps脚本更新组设置的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

保持简单-我正在使用Google Apps Script Admin SDK目录服务批量创建组:

Keeping it simple - I'm using Google Apps Script Admin SDK Directory Service to bulk create groups:

AdminDirectory.Groups.insert({"email": group1@test.test});

在此之后,我一直在尝试使用以下方法更新网上论坛权限:

Following this I have been attempting to update the groups permissions using the following:

AdminDirectory.Groups.update({
                             "whoCanJoin": "CAN_REQUEST_TO_JOIN",
                             "whoCanViewMembership": "ALL_IN_DOMAIN_CAN_VIEW",
                             "whoCanViewGroup": "ALL_IN_DOMAIN_CAN_VIEW",
                             "whoCanInvite": "ALL_MANAGERS_CAN_INVITE",
                             "allowExternalMembers": "false",
                             "whoCanPostMessage": "ALL_IN_DOMAIN_CAN_POST",
                             "allowWebPosting": "true"
                             },
                             "group1@test.test");

我得出的结论是,我真正需要的是对Group Settings API的访问权限.我可以使用Apps脚本吗?

I've come to the conclusion that what I really need is access to the Group Settings API. Can I do this with Apps Script?

推荐答案

是的,如果您无法从内置的Googles ,或高级服务,您始终可以通过网址提取服务访问其他任何可访问的API: https://developers.google.com/apps-script/guides/services/external

Yes, if you can't find what you want from Googles built in services, or the Advanced services, you can always access any other accessible API via the URL fetch service: https://developers.google.com/apps-script/guides/services/external

这篇关于使用Admin SDK通过Apps脚本更新组设置的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

10-14 17:04