I basically collect responses from a Google Form and put them into a Google Spreadsheet . It has timestamp , name and email column . I would like to add all these emails(they all are google account emails) into my Google Group(where I am the owner, note that I have a normal Gmail account). People cannot directly join my group , they can only join on invite .
I want to write a Google App Script code for adding members into my Google Group from the Spreadsheet. It is compulsory to use a normal Gmail account.
I tried to do it with the Admin SDK directory API for Google App Script , but it was not working. As I think , it is only for Google Workspace accounts.
Any help will be appreciated
Admin SDK Directory API as documented here does not contain an endpoint to have this done using a Gmail.com account. On the other hand, the Advanced Admin SDK Directory Service has an endpoint to do it and is described here but as mentioned at the top of the page a Google Workspace account/domain is required:
Taking the above into consideration it can be confirmed that as of the date of this response adding members to a Google Group using Google Apps Script and a Gmail.com account is NOT possible.
As an option, you may want to submit a Feature Request here