(Recommended) To use a script to create a service account, go to Create a Google Workspace service account.
You need to create a service account when you’re setting up Google Workspace Migrate. If you don’t use a script, follow these steps to manually create a service account.
Steps to create the service accountStep 1: Use the Google Cloud to turn on APIs
- Go to Google Cloud and sign in as a Google Workspace super administrator. If this is your first time signing in to the console, agree to the Terms of Service.
- Click IAM & AdminManage Resources. You might have to click Menu first.
- At the top, click Create Project.
- Enter a project name and click Create.
- Check the box next to your new project.
- Click APIs & ServicesLibrary. You might have to click Menu first.
- For each API you require (below), click the API name and then Enable.
Tip: If you can't find the API, specify the API name in the search box.
- Admin SDK
- Contacts API
- Google Workspace Migrate API
- Gmail API
- Google Calendar API
- Google Drive API
- Groups Migration API
- Groups Settings API
- Google Sheets API
- Tasks API
- Repeat steps 7, as required.
(Optional) Enable APIs using the command line
You can enable the APIs using the gcloud command-line tool.
- In a browser window, open the Cloud Shell Editor.
- In the gcloud command-line tool, enter:
gcloud services enable admin.googleapis.com contacts.googleapis.com \
migrate.googleapis.com gmail.googleapis.com calendar-json.googleapis.com \
drive.googleapis.com groupsmigration.googleapis.com \
groupssettings.googleapis.com sheets.googleapis.com tasks.googleapis.com
For details, go to gcloud services enable.
- In Google Cloud, click IAM & AdminService Accounts. You might have to click Menu first.
- Click Create Service Account.
- For Service account name, enter a name.
The service account ID is completed automatically.
- (Optional) To add your own description to the service account, click Service account description and enter a description.
- Click Create and Continue.
- Service account and user permissions are not required for Google Workspace Migrate.
Click Done to skip these steps.
- Select the email address of the service account that you created.
- At the top, click KeysAdd KeyCreate new key.
- Make sure the key type is set to JSON and click Create.
You'll get a message that the service account JSON key file has been created and downloaded to your computer. Make a note of the name of this file because you’ll need it later.
- Click Close.
What happens next?
It can take up to 24 hours to create service accounts. If you lose the name of the key file, repeat these steps to create a new one.
You must be signed in as a super administrator for this task.
On the Admin console Home page, go to SecurityAPI controls.
Click Manage Domain Wide Delegation.
Click Add new and enter your service account client ID.
You can find the ID (also known as the Unique ID) in the JSON file that you downloaded when you created the service account or in Google Cloud (click IAM & AdminService accountsthe name of your service account).
Note: Make sure you use the service account client ID, not the OAuth Web client ID.
- Click OAuth scopes and enter the following list of scopes, separated by commas (you can copy the list):
- Click Authorize.
Point to the new client ID, click View details, and make sure every scope is listed.
If a scope is not listed, click Edit, enter the missing scope, and click Authorize. You can't edit the client ID.
If you get an error, the client ID might not be registered with Google or there could be duplicate or unsupported scopes. Google Workspace Migrate should be available for use within an hour, but might take up to 24 hours.