- [HTTP request](https://docs.cloud.google.com/chronicle/docs/reference/rest/v1alpha/projects.locations.instances/generateSoarAuthJwt#body.HTTP_TEMPLATE)
- [Path parameters](https://docs.cloud.google.com/chronicle/docs/reference/rest/v1alpha/projects.locations.instances/generateSoarAuthJwt#body.PATH_PARAMETERS)
- [Request body](https://docs.cloud.google.com/chronicle/docs/reference/rest/v1alpha/projects.locations.instances/generateSoarAuthJwt#body.request_body)
  - [JSON representation](https://docs.cloud.google.com/chronicle/docs/reference/rest/v1alpha/projects.locations.instances/generateSoarAuthJwt#body.request_body.SCHEMA_REPRESENTATION)
- [Response body](https://docs.cloud.google.com/chronicle/docs/reference/rest/v1alpha/projects.locations.instances/generateSoarAuthJwt#body.response_body)
  - [JSON representation](https://docs.cloud.google.com/chronicle/docs/reference/rest/v1alpha/projects.locations.instances/generateSoarAuthJwt#body.GenerateSoarAuthJwtResponse.SCHEMA_REPRESENTATION)
- [Authorization scopes](https://docs.cloud.google.com/chronicle/docs/reference/rest/v1alpha/projects.locations.instances/generateSoarAuthJwt#body.aspect)
- [IAM Permissions](https://docs.cloud.google.com/chronicle/docs/reference/rest/v1alpha/projects.locations.instances/generateSoarAuthJwt#body.aspect_1)
- [SoarJwtType](https://docs.cloud.google.com/chronicle/docs/reference/rest/v1alpha/projects.locations.instances/generateSoarAuthJwt#SoarJwtType)

**Full name**: projects.locations.instances.generateSoarAuthJwt

instances.generateSoarAuthJwt signs a jwt in order to proceed with jwt exchange based authenticate with soar. This API also signs a jwt containing the details of the user assigned scopes.

### HTTP request

`POST https://{endpoint}/v1alpha/{name}:generateSoarAuthJwt`

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 name of the chronicle instance to retrieve a report for. Format: `projects/{projectId}/locations/{location}/instances/{instance}` |

### Request body

The request body contains data with the following structure:

| JSON representation |
|---|
| ``` { "soarJwtType": enum (`https://docs.cloud.google.com/chronicle/docs/reference/rest/v1alpha/projects.locations.instances/generateSoarAuthJwt#SoarJwtType`) } ``` |

| Fields ||
|---|---|
| `soarJwtType` | ``enum (`https://docs.cloud.google.com/chronicle/docs/reference/rest/v1alpha/projects.locations.instances/generateSoarAuthJwt#SoarJwtType`)`` Optional. The type of jwt to generate. If not provided, the default value of soarJwtType is USER_CLAIMS_JWT. |

### Response body

Response with a signed jwt.

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

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

| Fields ||
|---|---|
| `signedJwt` | `string` The signed jwt, that can be used to procced with jwt exchange based authentication protocol with Chronicle SOAR. |

### 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.instances.generateSoarAuthJwt`

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

## SoarJwtType

The type of jwt to generate. When set to USER_CLAIMS_AND_SCOPES_JWT, the jwt will contain the user's claims and data access scopes assigned to the user. Otherwise, the jwt will contain the user's claims.

| Enums ||
|---|---|
| `SOAR_JWT_TYPE_UNSPECIFIED` | The default value. |
| `USER_CLAIMS_JWT` | JWT for claims. |
| `USER_CLAIMS_AND_SCOPES_JWT` | JWT for claims \& data access scopes. |