Create users using Service Account with Google Admin SDK?

一笑奈何 提交于 2019-12-04 20:07:13
omerio

You can follow the steps outlined in the following API docs page to create the service account and perform a domain wide delegation of authority, please bear in mind you need the email address of a domain administrator which the service account can act on their behalf:

https://developers.google.com/admin-sdk/directory/v1/guides/delegation

The page includes a Java example of how to instantiate a com.google.api.services.admin.directory.Directory object using the service account and private key created on the Google Developers Console. Then use the example I've provided in this answer to create the users:

Create gmail account for a domain using Google Admin SDK Directory API in Java

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!