# Create Google Workspace User

Create a Google Workspace user account and send its temporary password to the requestor by direct message

This tool creates a new user account in Google Workspace. It sets a **temporary password** that the new user must change at the first sign-in. Use it to make accounts for new hires or contractors.

> **Note:** Risotto sends the temporary password to the requestor **by direct message
> only**. The password is not in the channel, the ticket, or the tool result.
> Give the password to the new user through a secure channel.

## What this tool does

When the tool runs, it:

1. Makes sure that the email domain is a verified domain of your Google Workspace. If the Google admin who gave consent cannot read the domain list, the tool skips this check and Google makes the decision.
2. Finds a Slack or Microsoft Teams account for the requestor, to send the password privately. If it finds none, it stops and does not create the account.
3. Makes a temporary password of 16 characters.
4. Creates the user with the first name, last name, and temporary password. The user must change the password at the first sign-in. If you give an organizational unit, the tool puts the user there. If not, the user goes in the root organizational unit.
5. Sends the temporary password to the requestor by **direct message**, not to the new user.
6. Returns a confirmation that does not contain the password.

The tool does not assign a Google Workspace license. It also does not add the user to groups, set a recovery email, or add aliases.

## Prerequisites

- The [Google Workspace tools connector](https://www.tryrisotto.com/docs/integrations/google-workspace-tools) is connected. The tool runs on the connector's grant. It does not use the **Admin API** card on **Settings > Integrations > Google Workspace**.
- The connector grant includes the `https://www.googleapis.com/auth/admin.directory.user` scope. When you add this tool, Risotto adds the scope to the connector consent. An admin must click **Reconnect** on the connector and approve the scope. If your organization already uses Reset Google Workspace User Password or Set Google Workspace User Suspension, the grant has this scope.
- The Google admin who gave consent has the **User Management** admin privilege.
- The requestor can receive direct messages from Risotto in Slack or Microsoft Teams.

## Enable the tool

1. Select **Tools** in the sidebar.
2. In the **Tool groups** list, select **Google**.
3. On the **Google Workspace Create User** row, click **Enable**.

Risotto names the new tool **Create Google Workspace User**. The tool has **Approval** set to **Required** by default, so an approver must accept each new account before the tool creates it.

## Parameters

The tool has no **Restrict to Requestor Only** option, because the new user does not exist yet.

| Parameter       | Required | Description                                                                                                        |
| --------------- | -------- | ------------------------------------------------------------------------------------------------------------------ |
| `primary_email` | Yes      | The primary email address of the new user. The domain must belong to your Google Workspace.                        |
| `first_name`    | Yes      | The first name of the new user. If the requestor did not give it, the agent asks. It does not guess it.            |
| `last_name`     | Yes      | The last name of the new user. If the requestor did not give it, the agent asks. It does not guess it.             |
| `org_unit_path` | No       | The organizational unit for the new user, for example `/Contractors`. When it is empty, the user goes in the root. |

## Troubleshooting

### is not a verified Google Workspace domain for this organization

The email domain is not one of the verified domains of your Google
Workspace. The error lists the verified domains. Use an email address in one
of them.

### no reachable Slack or Microsoft Teams account was found

The tool sends the temporary password only by direct message. Make sure the
requestor can receive direct messages from Risotto, then run the tool again.
The tool does not create the account when this error occurs.

### An account with this email address already exists in Google Workspace

A user with this email address already exists. To give that user a new
password, use [Reset Google Workspace User
Password](https://www.tryrisotto.com/docs/integrations/tools/google/reset_password).

### Google rejected the request

Make sure that the email domain belongs to your Google Workspace and that
the organizational unit path exists.

### Google refused the call

The connector grant does not include the `admin.directory.user` scope, or
the admin who connected it does not have the **User Management** privilege.
Click **Reconnect** on the connector and approve the scope.

### Failed to deliver the temporary password

The tool created the account, but the direct message failed. Nobody received
the temporary password. An admin must reset the password in the Google Admin
console. Do not run the tool again, because the account already exists.

## Related

- [Google Workspace tools connector](https://www.tryrisotto.com/docs/integrations/google-workspace-tools)
- [Reset Google Workspace User Password](https://www.tryrisotto.com/docs/integrations/tools/google/reset_password)
- [Move User to OU](https://www.tryrisotto.com/docs/integrations/tools/google/move_user_to_ou)
- [Manage Google Workspace User Alias](https://www.tryrisotto.com/docs/integrations/tools/google/manage_user_alias)

Source: https://www.tryrisotto.com/docs/integrations/tools/google/create_user
