- [HTTP request](https://docs.cloud.google.com/chronicle/docs/reference/rest/v1/projects.locations.instances.uniqueEntities/download#body.HTTP_TEMPLATE)
- [Path parameters](https://docs.cloud.google.com/chronicle/docs/reference/rest/v1/projects.locations.instances.uniqueEntities/download#body.PATH_PARAMETERS)
- [Query parameters](https://docs.cloud.google.com/chronicle/docs/reference/rest/v1/projects.locations.instances.uniqueEntities/download#body.QUERY_PARAMETERS)
- [Request body](https://docs.cloud.google.com/chronicle/docs/reference/rest/v1/projects.locations.instances.uniqueEntities/download#body.request_body)
- [Response body](https://docs.cloud.google.com/chronicle/docs/reference/rest/v1/projects.locations.instances.uniqueEntities/download#body.response_body)
  - [JSON representation](https://docs.cloud.google.com/chronicle/docs/reference/rest/v1/projects.locations.instances.uniqueEntities/download#body.GenerateUniqueEntityReportResponse.SCHEMA_REPRESENTATION)
- [Authorization scopes](https://docs.cloud.google.com/chronicle/docs/reference/rest/v1/projects.locations.instances.uniqueEntities/download#body.aspect)
- [IAM Permissions](https://docs.cloud.google.com/chronicle/docs/reference/rest/v1/projects.locations.instances.uniqueEntities/download#body.aspect_1)
- [LastCaseType](https://docs.cloud.google.com/chronicle/docs/reference/rest/v1/projects.locations.instances.uniqueEntities/download#LastCaseType)
- [CaseDistributionType](https://docs.cloud.google.com/chronicle/docs/reference/rest/v1/projects.locations.instances.uniqueEntities/download#CaseDistributionType)

**Full name**: projects.locations.instances.uniqueEntities.download

Generates and downloads a report for a unique entity. The report includes detailed information about the entity's history, related cases, and distribution across products or tags.

### HTTP request

`GET https://{endpoint}/v1/{name}/uniqueEntities:generateReport`

Where `{endpoint}` is one of the [supported service endpoints](https://docs.cloud.google.com/chronicle/docs/reference/rest#rest_endpoints).

### Path parameters

| Parameters ||
|---|---|
| `name` | `string` Required. The resource name of the UniqueEntity to retrieve. Format: projects/{project}/locations/{location}/instances/{instance}/uniqueEntities:generateReport |

### Query parameters

| Parameters ||
|---|---|
| `identifier` | `string` Required. Unique entity id. |
| `type` | `string` Required. Unique entity type. |
| `environment` | `string` Required. The environment in which the entity exists. |
| `lastCaseType` | ``enum (`https://docs.cloud.google.com/chronicle/docs/reference/rest/v1/projects.locations.instances.uniqueEntities/download#LastCaseType`)`` Required. The last case type. |
| `caseDistributionType` | ``enum (`https://docs.cloud.google.com/chronicle/docs/reference/rest/v1/projects.locations.instances.uniqueEntities/download#CaseDistributionType`)`` Required. The case distribution type. |

### Request body

The request body must be empty.

### Response body

Response message for uniqueEntities.download.

If successful, the response body contains data with the following structure:

| JSON representation |
|---|
| ``` { "media": { object (`https://docs.cloud.google.com/chronicle/docs/reference/rest/Shared.Types/MediaResponseInfo#Media`) } } ``` |

| Fields ||
|---|---|
| `media` | ``object (`https://docs.cloud.google.com/chronicle/docs/reference/rest/Shared.Types/MediaResponseInfo#Media`)`` Zipped file with the integration content. Includes the following folders: Actions, Connectors, Jobs, Managers, Dependencies Each folder includes json files and a python file for the script. Includes integration definition json file. Includes metadata.json file Information representing the imported data |

### Authorization scopes

Requires one of the following OAuth scopes:

- `https://www.googleapis.com/auth/cloud-platform`
- `
  https://www.googleapis.com/auth/chronicle`

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

### IAM Permissions

Requires the following [IAM](https://cloud.google.com/iam/docs) permission on the `name` resource:

- `chronicle.uniqueEntities.get`

For more information, see the [IAM documentation](https://cloud.google.com/iam/docs).

## LastCaseType

The last case type.

| Enums ||
|---|---|
| `ALL` | All case types. |
| `CLOSED` | Closed last case type. |
| `OPENED` | Opened last case type. |

## CaseDistributionType

The case distribution type.

| Enums ||
|---|---|
| `PRODUCT` | Product case distribution type. |
| `TAG` | Tag case distribution type. |