# Method: licenseAssignments.insert

- [HTTP request](https://developers.google.com/workspace/admin/licensing/reference/rest/v1/licenseAssignments/insert#body.HTTP_TEMPLATE)
- [Path parameters](https://developers.google.com/workspace/admin/licensing/reference/rest/v1/licenseAssignments/insert#body.PATH_PARAMETERS)
- [Request body](https://developers.google.com/workspace/admin/licensing/reference/rest/v1/licenseAssignments/insert#body.request_body)
- [Response body](https://developers.google.com/workspace/admin/licensing/reference/rest/v1/licenseAssignments/insert#body.response_body)
- [Authorization scopes](https://developers.google.com/workspace/admin/licensing/reference/rest/v1/licenseAssignments/insert#body.aspect)
- [LicenseAssignmentInsert](https://developers.google.com/workspace/admin/licensing/reference/rest/v1/licenseAssignments/insert#LicenseAssignmentInsert)
  - [JSON representation](https://developers.google.com/workspace/admin/licensing/reference/rest/v1/licenseAssignments/insert#LicenseAssignmentInsert.SCHEMA_REPRESENTATION)
- [Try it!](https://developers.google.com/workspace/admin/licensing/reference/rest/v1/licenseAssignments/insert#try-it)

Assign a license.

### HTTP request

`POST https://licensing.googleapis.com/apps/licensing/v1/product/{productId}/sku/{skuId}/user`

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

### Path parameters

| Parameters ||
|---|---|
| `productId` | `string` A product's unique identifier. For more information about products in this version of the API, see [Products and SKUs](https://developers.google.com/workspace/admin/licensing/v1/how-tos/products). |
| `skuId` | `string` A product SKU's unique identifier. For more information about available SKUs in this version of the API, see [Products and SKUs](https://developers.google.com/workspace/admin/licensing/v1/how-tos/products). |

### Request body

The request body contains an instance of `https://developers.google.com/workspace/admin/licensing/reference/rest/v1/licenseAssignments/insert#LicenseAssignmentInsert`.

### Response body

If successful, the response body contains a newly created instance of `https://developers.google.com/workspace/admin/licensing/reference/rest/v1/licenseAssignments#LicenseAssignment`.

### Authorization scopes

Requires the following OAuth scope:

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

For more information, see the [Authorization guide](https://developers.google.com/workspace/guides/configure-oauth-consent).

## LicenseAssignmentInsert

Representation of a license assignment.

| JSON representation |
|---|
| ``` { "userId": string } ``` |

| Fields ||
|---|---|
| `userId` | `string` Email id of the user |