# Method: accounts.customers.provisionCloudIdentity

- [HTTP request](https://docs.cloud.google.com/channel/docs/reference/rest/v1alpha1/accounts.customers/provisionCloudIdentity#body.HTTP_TEMPLATE)
- [Path parameters](https://docs.cloud.google.com/channel/docs/reference/rest/v1alpha1/accounts.customers/provisionCloudIdentity#body.PATH_PARAMETERS)
- [Request body](https://docs.cloud.google.com/channel/docs/reference/rest/v1alpha1/accounts.customers/provisionCloudIdentity#body.request_body)
  - [JSON representation](https://docs.cloud.google.com/channel/docs/reference/rest/v1alpha1/accounts.customers/provisionCloudIdentity#body.request_body.SCHEMA_REPRESENTATION)
- [Response body](https://docs.cloud.google.com/channel/docs/reference/rest/v1alpha1/accounts.customers/provisionCloudIdentity#body.response_body)
- [Authorization scopes](https://docs.cloud.google.com/channel/docs/reference/rest/v1alpha1/accounts.customers/provisionCloudIdentity#body.aspect)
- [AdminUser](https://docs.cloud.google.com/channel/docs/reference/rest/v1alpha1/accounts.customers/provisionCloudIdentity#AdminUser)
  - [JSON representation](https://docs.cloud.google.com/channel/docs/reference/rest/v1alpha1/accounts.customers/provisionCloudIdentity#AdminUser.SCHEMA_REPRESENTATION)
- [Try it!](https://docs.cloud.google.com/channel/docs/reference/rest/v1alpha1/accounts.customers/provisionCloudIdentity#try-it)

Creates a Cloud Identity for the given customer using the customer's information, or the information provided here.

Possible error codes:

- PERMISSION_DENIED:
  - The customer doesn't belong to the reseller.
  - You are not authorized to provision cloud identity id. See <https://support.google.com/channelservices/answer/9759265>
- INVALID_ARGUMENT: Required request parameters are missing or invalid.
- NOT_FOUND: The customer was not found.
- ALREADY_EXISTS: The customer's primary email already exists. Retry after changing the customer's primary contact email.
- INTERNAL: Any non-user error related to a technical issue in the backend. Contact Cloud Channel support.
- UNKNOWN: Any non-user error related to a technical issue in the backend. Contact Cloud Channel support.

Return value: The ID of a long-running operation.

To get the results of the operation, call the operations.get method of CloudChannelOperationsService. The Operation metadata contains an instance of `OperationMetadata`.

### HTTP request

`POST https://cloudchannel.googleapis.com/v1alpha1/{customer=accounts/*/customers/*}:provisionCloudIdentity`

The URL uses [gRPC Transcoding](https://google.aip.dev/127) syntax.

### Path parameters

| Parameters ||
|---|---|
| `customer` | `string` Required. Resource name of the customer. Format: accounts/{account_id}/customers/{customer_id} |

### Request body

The request body contains data with the following structure:

| JSON representation |
|---|
| ``` { "cloudIdentityInfo": { object (`https://docs.cloud.google.com/channel/docs/reference/rest/v1alpha1/CloudIdentityInfo`) }, "user": { object (`https://docs.cloud.google.com/channel/docs/reference/rest/v1alpha1/accounts.customers/provisionCloudIdentity#AdminUser`) }, "validateOnly": boolean } ``` |

| Fields ||
|---|---|
| `cloudIdentityInfo` | ``object (`https://docs.cloud.google.com/channel/docs/reference/rest/v1alpha1/CloudIdentityInfo`)`` CloudIdentity-specific customer information. |
| `user` | ``object (`https://docs.cloud.google.com/channel/docs/reference/rest/v1alpha1/accounts.customers/provisionCloudIdentity#AdminUser`)`` Admin user information. |
| `validateOnly` | `boolean` Validate the request and preview the review, but do not post it. |

### Response body

If successful, the response body contains an instance of `https://docs.cloud.google.com/channel/docs/reference/rest/Shared.Types/ListOperationsResponse#Operation`.

### Authorization scopes

Requires the following OAuth scope:

- `https://www.googleapis.com/auth/apps.order`

For more information, see the [Authentication Overview](https://docs.cloud.google.com/docs/authentication#authorization-gcp).

## AdminUser

Information needed to create an Admin User for Google Workspace.

| JSON representation |
|---|
| ``` { "email": string, "givenName": string, "familyName": string } ``` |

| Fields ||
|---|---|
| `email` | `string` Primary email of the admin user. |
| `givenName` | `string` Given name of the admin user. |
| `familyName` | `string` Family name of the admin user. |