# Method: organizations.locations.reports.createIaCValidationReport

- [HTTP request](https://docs.cloud.google.com/security-command-center/docs/reference/securityposture/rest/v1/organizations.locations.reports/createIaCValidationReport#body.HTTP_TEMPLATE)
- [Path parameters](https://docs.cloud.google.com/security-command-center/docs/reference/securityposture/rest/v1/organizations.locations.reports/createIaCValidationReport#body.PATH_PARAMETERS)
- [Request body](https://docs.cloud.google.com/security-command-center/docs/reference/securityposture/rest/v1/organizations.locations.reports/createIaCValidationReport#body.request_body)
  - [JSON representation](https://docs.cloud.google.com/security-command-center/docs/reference/securityposture/rest/v1/organizations.locations.reports/createIaCValidationReport#body.request_body.SCHEMA_REPRESENTATION)
- [Response body](https://docs.cloud.google.com/security-command-center/docs/reference/securityposture/rest/v1/organizations.locations.reports/createIaCValidationReport#body.response_body)
- [Authorization scopes](https://docs.cloud.google.com/security-command-center/docs/reference/securityposture/rest/v1/organizations.locations.reports/createIaCValidationReport#body.aspect)
- [IAM Permissions](https://docs.cloud.google.com/security-command-center/docs/reference/securityposture/rest/v1/organizations.locations.reports/createIaCValidationReport#body.aspect_1)
- [IaC](https://docs.cloud.google.com/security-command-center/docs/reference/securityposture/rest/v1/organizations.locations.reports/createIaCValidationReport#IaC)
  - [JSON representation](https://docs.cloud.google.com/security-command-center/docs/reference/securityposture/rest/v1/organizations.locations.reports/createIaCValidationReport#IaC.SCHEMA_REPRESENTATION)

Validates a specified infrastructure-as-code (IaC) configuration, and creates a `https://docs.cloud.google.com/security-command-center/docs/reference/securityposture/rest/v1/organizations.locations.reports#Report` with the validation results.

Only Terraform configurations are supported. Only modified assets are validated.

### HTTP request

`POST https://securityposture.googleapis.com/v1/{parent=organizations/*/locations/*}/reports:createIaCValidationReport`

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

### Path parameters

| Parameters ||
|---|---|
| `parent` | `string` Required. The parent resource name, in the format `organizations/{organization}/locations/global`. |

### Request body

The request body contains data with the following structure:

| JSON representation |
|---|
| ``` { "iac": { object (`https://docs.cloud.google.com/security-command-center/docs/reference/securityposture/rest/v1/organizations.locations.reports/createIaCValidationReport#IaC`) } } ``` |

| Fields ||
|---|---|
| `iac` | ``object (`https://docs.cloud.google.com/security-command-center/docs/reference/securityposture/rest/v1/organizations.locations.reports/createIaCValidationReport#IaC`)`` Required. The infrastructure-as-code (IaC) configuration to validate. |

### Response body

If successful, the response body contains an instance of `https://docs.cloud.google.com/security-command-center/docs/reference/securityposture/rest/v1/organizations.locations.operations#Operation`.

### Authorization scopes

Requires the following OAuth scope:

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

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 `parent` resource:

- `securityposture.reports.create`

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

## IaC

Details of an infrastructure-as-code (IaC) configuration.

| JSON representation |
|---|
| ``` { // Union field `source` can be only one of the following: "tfPlan": string // End of list of possible types for union field `source`. } ``` |

| Fields ||
|---|---|
| Union field `source`. The IaC configuration to validate. `source` can be only one of the following: ||
| `tfPlan` | `string (https://developers.google.com/discovery/v1/type-format format)` Optional. A Terraform plan file, formatted as a stringified JSON object. To learn how to generate a Terraform plan file in JSON format, see [JSON output format](https://developer.hashicorp.com/terraform/internals/json-format) in the Terraform documentation. A base64-encoded string. |