---
title: "POST /v2/{+parent}/contentPolicies"
method: POST
path: "/v2/{+parent}/contentPolicies"
tags: ["projects"]
---

# POST /v2/{+parent}/contentPolicies

`POST /v2/{+parent}/contentPolicies`

Create a ContentPolicy.

## Path parameters

- `parent` string, required

## Request body

- GooglePrivacyDlpV2CreateContentPolicyRequest — Request message for CreateContentPolicy.
  - `contentPolicy` GooglePrivacyDlpV2ContentPolicy — A policy to apply to content based on its inspection findings.
    - `displayName` string — Optional. Display name (max 63 chars)
    - `inputTooLarge` GooglePrivacyDlpV2PolicyAction — A possible action to take when applying a content policy.
      - `returnVerdict` 'CONTENT_POLICY_VERDICT_UNSPECIFIED' | 'ALLOW' | 'BLOCK' — Optional. If set, the verdict will be returned to the user.
    - `rules` GooglePrivacyDlpV2PolicyRule[] — Required. Policies to apply, based on the findings returned by inspection. The first rule to match applies.
      - `conditions` GooglePrivacyDlpV2PolicyCondition[] — Optional. Conditions that must match for this rule to apply. All conditions must match (`AND`). For `OR` conditions, use multiple rules.
        - `infoTypeCondition` GooglePrivacyDlpV2InfoTypeCondition — A info type based condition.
          - `infoTypes` GooglePrivacyDlpV2InfoTypes — Info types to match.
            - `infoTypeNames` string[] — Required. A list of info types to match.
          - `anyInfoType` GoogleProtobufEmpty — A generic empty message that you can re-use to avoid defining duplicated empty messages in your APIs. A typical example is to use it as the request or the response type of an API method. For instance: service Foo { rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty); }
      - `action` GooglePrivacyDlpV2PolicyAction — A possible action to take when applying a content policy.
        - `returnVerdict` 'CONTENT_POLICY_VERDICT_UNSPECIFIED' | 'ALLOW' | 'BLOCK' — Optional. If set, the verdict will be returned to the user.
      - `returnVerdict` 'CONTENT_POLICY_VERDICT_UNSPECIFIED' | 'ALLOW' | 'BLOCK' — If set, the verdict will be returned to the user. Deprecated: Use `action` instead.
    - `defaultAction` GooglePrivacyDlpV2PolicyAction — A possible action to take when applying a content policy.
      - `returnVerdict` 'CONTENT_POLICY_VERDICT_UNSPECIFIED' | 'ALLOW' | 'BLOCK' — Optional. If set, the verdict will be returned to the user.
    - `errors` GooglePrivacyDlpV2Error[] — Output only. A stream of errors encountered when the policy was applied. Output only field. Will return the last 100 errors. Whenever the policy is modified this list will be cleared.
      - `timestamps` string[] — The times the error occurred. List includes the oldest timestamp and the last 9 timestamps.
      - `details` GoogleRpcStatus — The `Status` type defines a logical error model that is suitable for different programming environments, including REST APIs and RPC APIs. It is used by [gRPC](https://github.com/grpc). Each `Status` message contains three pieces of data: error code, error message, and error details. You can find out more about this error model and how to work with it in the [API Design Guide](https://cloud.google.com/apis/design/errors).
        - `code` integer — The status code, which should be an enum value of google.rpc.Code.
        - `message` string — A developer-facing error message, which should be in English. Any user-facing error message should be localized and sent in the google.rpc.Status.details field, or localized by the client.
        - `details` object[] — A list of messages that carry the error details. There is a common set of message types for APIs to use.
      - `extraInfo` 'ERROR_INFO_UNSPECIFIED' | 'IMAGE_SCAN_UNAVAILABLE_IN_REGION' | 'FILE_STORE_CLUSTER_UNSUPPORTED' — Additional information about the error.
    - `inspectTemplate` GooglePrivacyDlpV2InspectTemplate — The inspectTemplate contains a configuration (set of types of sensitive data to be detected) to be used anywhere you otherwise would normally specify InspectConfig. See https://cloud.google.com/sensitive-data-protection/docs/concepts-templates to learn more.
      - `description` string — Short description (max 256 chars).
      - `name` string — Output only. The template name. The template will have one of the following formats: `projects/PROJECT_ID/inspectTemplates/TEMPLATE_ID` OR `organizations/ORGANIZATION_ID/inspectTemplates/TEMPLATE_ID`;
      - `createTime` string, google-datetime — Output only. The creation timestamp of an inspectTemplate.
      - `displayName` string — Display name (max 256 chars).
      - `updateTime` string, google-datetime — Output only. The last update timestamp of an inspectTemplate.
      - `inspectConfig` GooglePrivacyDlpV2InspectConfig — Configuration description of the scanning process. When used with redactContent only info_types and min_likelihood are currently used.
        - `minLikelihood` 'LIKELIHOOD_UNSPECIFIED' | 'VERY_UNLIKELY' | 'UNLIKELY' | 'POSSIBLE' | 'LIKELY' | 'VERY_LIKELY' — Only returns findings equal to or above this threshold. The default is POSSIBLE. In general, the highest likelihood setting yields the fewest findings in results and the lowest chance of a false positive. For more information, see [Match likelihood](https://cloud.google.com/sensitive-data-protection/docs/likelihood).
        - `limits` GooglePrivacyDlpV2FindingLimits — Configuration to control the number of findings returned for inspection. This is not used for de-identification or data profiling. When redacting sensitive data from images, finding limits don't apply. They can cause unexpected or inconsistent results, where only some data is redacted. Don't include finding limits in RedactImage requests. Otherwise, Cloud DLP returns an error.
          - `maxFindingsPerRequest` integer — Max number of findings that are returned per request or job. If you set this field in an InspectContentRequest, the resulting maximum value is the value that you set or 3,000, whichever is lower. This value isn't a hard limit. If an inspection reaches this limit, the inspection ends gradually, not abruptly. Therefore, the actual number of findings that Cloud DLP returns can be multiple times higher than this value.
          - `maxFindingsPerItem` integer — Max number of findings that are returned for each item scanned. When set within an InspectContentRequest, this field is ignored. This value isn't a hard limit. If the number of findings for an item reaches this limit, the inspection of that item ends gradually, not abruptly. Therefore, the actual number of findings that Cloud DLP returns for the item can be multiple times higher than this value.
          - `maxFindingsPerInfoType` GooglePrivacyDlpV2InfoTypeLimit[] — Configuration of findings limit given for specified infoTypes.
            - `infoType` GooglePrivacyDlpV2InfoType — Type of information detected by the API.
              - …
            - `maxFindings` integer — Max findings limit for the given infoType.
        - `minLikelihoodPerInfoType` GooglePrivacyDlpV2InfoTypeLikelihood[] — Minimum likelihood per infotype. For each infotype, a user can specify a minimum likelihood. The system only returns a finding if its likelihood is above this threshold. If this field is not set, the system uses the InspectConfig min_likelihood.
          - `infoType` GooglePrivacyDlpV2InfoType — Type of information detected by the API.
            - `name` string — Name of the information type. Either a name of your choosing when creating a CustomInfoType, or one of the names listed at https://cloud.google.com/sensitive-data-protection/docs/infotypes-reference when specifying a built-in type. When sending Cloud DLP results to Data Catalog, infoType names should conform to the pattern `[A-Za-z0-9$_-]{1,64}`.
            - `sensitivityScore` GooglePrivacyDlpV2SensitivityScore — Score is calculated from of all elements in the data profile. A higher level means the data is more sensitive.
              - …
            - `version` string — Optional version name for this InfoType.
          - `minLikelihood` 'LIKELIHOOD_UNSPECIFIED' | 'VERY_UNLIKELY' | 'UNLIKELY' | 'POSSIBLE' | 'LIKELY' | 'VERY_LIKELY' — Only returns findings equal to or above this threshold. This field is required or else the configuration fails.
        - `customInfoTypes` GooglePrivacyDlpV2CustomInfoType[] — CustomInfoTypes provided by the user. See https://cloud.google.com/sensitive-data-protection/docs/creating-custom-infotypes to learn more.
          - `sensitivityScore` GooglePrivacyDlpV2SensitivityScore — Score is calculated from of all elements in the data profile. A higher level means the data is more sensitive.
            - `score` 'SENSITIVITY_SCORE_UNSPECIFIED' | 'SENSITIVITY_LOW' | 'SENSITIVITY_UNKNOWN' | 'SENSITIVITY_MODERATE' | 'SENSITIVITY_HIGH' — The sensitivity score applied to the resource.
          - `detectionRules` GooglePrivacyDlpV2DetectionRule[] — Set of detection rules to apply to all findings of this CustomInfoType. Rules are applied in the order that they are specified. Only supported for the `dictionary`, `regex`, and `stored_type` CustomInfoTypes.
            - `hotwordRule` GooglePrivacyDlpV2HotwordRule — The rule that adjusts the likelihood of findings within a certain proximity of hotwords.
              - …
          - `storedType` GooglePrivacyDlpV2StoredType — A reference to a StoredInfoType to use with scanning.
            - `name` string — Resource name of the requested `StoredInfoType`, for example `organizations/433245324/storedInfoTypes/432452342` or `projects/project-id/storedInfoTypes/432452342`.
            - `createTime` string, google-datetime — Timestamp indicating when the version of the `StoredInfoType` used for inspection was created. Output-only field, populated by the system.
          - `metadataKeyValueExpression` GooglePrivacyDlpV2MetadataKeyValueExpression — Configuration for a custom infoType that detects key-value pairs in the metadata matching the specified regular expressions.
            - `valueRegex` string — The regular expression for the value. Value should be non-empty.
            - `keyRegex` string — The regular expression for the key. Key should be non-empty.
          - `exclusionType` 'EXCLUSION_TYPE_UNSPECIFIED' | 'EXCLUSION_TYPE_EXCLUDE' — If set to EXCLUSION_TYPE_EXCLUDE this infoType will not cause a finding to be returned. It still can be used for rules matching. Only supported for the `dictionary`, `regex`, and `stored_type` CustomInfoTypes.
          - `fileLabelInfoType` GooglePrivacyDlpV2FileLabelInfoType — Configuration for a custom infoType that detects file labels.
            - `googleDriveLabel` GooglePrivacyDlpV2GoogleDriveLabel — Google Drive labels published by Google.
              - …
            - `sensitivityLabel` GooglePrivacyDlpV2SensitivityLabel — Sensitivity labels published by Microsoft.
              - …
          - `likelihood` 'LIKELIHOOD_UNSPECIFIED' | 'VERY_UNLIKELY' | 'UNLIKELY' | 'POSSIBLE' | 'LIKELY' | 'VERY_LIKELY' — Likelihood to return for this CustomInfoType. This base value can be altered by a detection rule if the finding meets the criteria specified by the rule. Defaults to `VERY_LIKELY` if not specified.
          - `infoType` GooglePrivacyDlpV2InfoType — Type of information detected by the API.
            - `name` string — Name of the information type. Either a name of your choosing when creating a CustomInfoType, or one of the names listed at https://cloud.google.com/sensitive-data-protection/docs/infotypes-reference when specifying a built-in type. When sending Cloud DLP results to Data Catalog, infoType names should conform to the pattern `[A-Za-z0-9$_-]{1,64}`.
            - `sensitivityScore` GooglePrivacyDlpV2SensitivityScore — Score is calculated from of all elements in the data profile. A higher level means the data is more sensitive.
              - …
            - `version` string — Optional version name for this InfoType.
          - `dictionary` GooglePrivacyDlpV2Dictionary — Custom information type based on a dictionary of words or phrases. This can be used to match sensitive information specific to the data, such as a list of employee IDs or job titles. Dictionary words are case-insensitive and all characters other than letters and digits in the unicode [Basic Multilingual Plane](https://en.wikipedia.org/wiki/Plane_%28Unicode%29#Basic_Multilingual_Plane) will be replaced with whitespace when scanning for matches, so the dictionary phrase "Sam Johnson" will match all three phrases "sam johnson", "Sam, Johnson", and "Sam (Johnson)". Additionally, the characters surrounding any match must be of a different type than the adjacent characters within the word, so letters must be next to non-letters and digits next to non-digits. For example, the dictionary word "jen" will match the first three letters of the text "jen123" but will return no matches for "jennifer". Dictionary words containing a large number of characters that are not letters or digits may result in unexpected findings because such characters are treated as whitespace. The [limits](https://cloud.google.com/sensitive-data-protection/limits) page contains details about the size limits of dictionaries. For dictionaries that do not fit within these constraints, consider using `LargeCustomDictionaryConfig` in the `StoredInfoType` API.
            - `wordList` GooglePrivacyDlpV2WordList — Message defining a list of words or phrases to search for in the data.
              - …
            - `cloudStoragePath` GooglePrivacyDlpV2CloudStoragePath — Message representing a single file or path in Cloud Storage.
              - …
          - `regex` GooglePrivacyDlpV2Regex — Message defining a custom regular expression.
            - `pattern` string — Pattern defining the regular expression. Its syntax (https://github.com/google/re2/wiki/Syntax) can be found under the google/re2 repository on GitHub.
            - `groupIndexes` integer[] — The index of the submatch to extract as findings. When not specified, the entire match is returned. No more than 3 may be included.
          - `surrogateType` GooglePrivacyDlpV2SurrogateType — Message for detecting output from deidentification transformations such as [`CryptoReplaceFfxFpeConfig`](https://cloud.google.com/sensitive-data-protection/docs/reference/rest/v2/organizations.deidentifyTemplates#cryptoreplaceffxfpeconfig). These types of transformations are those that perform pseudonymization, thereby producing a "surrogate" as output. This should be used in conjunction with a field on the transformation such as `surrogate_info_type`. This CustomInfoType does not support the use of `detection_rules`.
        - `ruleSet` GooglePrivacyDlpV2InspectionRuleSet[] — Set of rules to apply to the findings for this InspectConfig. Exclusion rules, contained in the set are executed in the end, other rules are executed in the order they are specified for each info type. Not supported for the `metadata_key_value_expression` CustomInfoType.
          - `infoTypes` GooglePrivacyDlpV2InfoType[] — List of infoTypes this rule set is applied to.
            - `name` string — Name of the information type. Either a name of your choosing when creating a CustomInfoType, or one of the names listed at https://cloud.google.com/sensitive-data-protection/docs/infotypes-reference when specifying a built-in type. When sending Cloud DLP results to Data Catalog, infoType names should conform to the pattern `[A-Za-z0-9$_-]{1,64}`.
            - `sensitivityScore` GooglePrivacyDlpV2SensitivityScore — Score is calculated from of all elements in the data profile. A higher level means the data is more sensitive.
              - …
            - `version` string — Optional version name for this InfoType.
          - `rules` GooglePrivacyDlpV2InspectionRule[] — Set of rules to be applied to infoTypes. The rules are applied in order.
            - `exclusionRule` GooglePrivacyDlpV2ExclusionRule — The rule that specifies conditions when findings of infoTypes specified in `InspectionRuleSet` are removed from results.
              - …
            - `hotwordRule` GooglePrivacyDlpV2HotwordRule — The rule that adjusts the likelihood of findings within a certain proximity of hotwords.
              - …
            - `adjustmentRule` GooglePrivacyDlpV2AdjustmentRule — Rule that specifies conditions when a certain infoType's finding details should be adjusted.
              - …
        - `contentOptions` string[] — Deprecated and unused.
        - `includeQuote` boolean — When true, a contextual quote from the data that triggered a finding is included in the response; see Finding.quote. This is not used for data profiling.
        - `excludeInfoTypes` boolean — When true, excludes type information of the findings. This is not used for data profiling.
        - `infoTypes` GooglePrivacyDlpV2InfoType[] — Restricts what info_types to look for. The values must correspond to InfoType values returned by ListInfoTypes or listed at https://cloud.google.com/sensitive-data-protection/docs/infotypes-reference. When no InfoTypes or CustomInfoTypes are specified in a request, the system may automatically choose a default list of detectors to run, which may change over time. If you need precise control and predictability as to what detectors are run you should specify specific InfoTypes listed in the reference, otherwise a default list will be used, which may change over time.
          - `name` string — Name of the information type. Either a name of your choosing when creating a CustomInfoType, or one of the names listed at https://cloud.google.com/sensitive-data-protection/docs/infotypes-reference when specifying a built-in type. When sending Cloud DLP results to Data Catalog, infoType names should conform to the pattern `[A-Za-z0-9$_-]{1,64}`.
          - `sensitivityScore` GooglePrivacyDlpV2SensitivityScore — Score is calculated from of all elements in the data profile. A higher level means the data is more sensitive.
            - `score` 'SENSITIVITY_SCORE_UNSPECIFIED' | 'SENSITIVITY_LOW' | 'SENSITIVITY_UNKNOWN' | 'SENSITIVITY_MODERATE' | 'SENSITIVITY_HIGH' — The sensitivity score applied to the resource.
          - `version` string — Optional version name for this InfoType.
      - `allowLimitedAvailabilityInfoTypes` boolean — Optional. Enables the use of [limited-availability built-in infoTypes](https://docs.cloud.google.com/sensitive-data-protection/docs/infotypes-reference#limited-availability-infotypes) in inspect_config. These infoTypes are supported only in specific regions and can cause scanning errors if used elsewhere.
    - `failedToScanSupportedFileType` GooglePrivacyDlpV2PolicyAction — A possible action to take when applying a content policy.
      - `returnVerdict` 'CONTENT_POLICY_VERDICT_UNSPECIFIED' | 'ALLOW' | 'BLOCK' — Optional. If set, the verdict will be returned to the user.
    - `createTime` string, google-datetime — Output only. The creation timestamp of a contentPolicy; output-only field.
    - `loggingConfigs` GooglePrivacyDlpV2LoggingConfig[] — Optional. Log the actions taken by the content policy to external systems.
      - `logToBigQuery` GooglePrivacyDlpV2LogToBigQuery — Configuration for logging content policy actions to BigQuery.
        - `projectId` string — Required. The ID of the project containing the BigQuery table to write to.
        - `datasetId` string — Required. The ID of the dataset containing the BigQuery table to write to.
        - `tableId` string — Required. The ID of the BigQuery table to write to.
    - `unsupportedFileType` GooglePrivacyDlpV2PolicyAction — A possible action to take when applying a content policy.
      - `returnVerdict` 'CONTENT_POLICY_VERDICT_UNSPECIFIED' | 'ALLOW' | 'BLOCK' — Optional. If set, the verdict will be returned to the user.
    - `inspectConfig` GooglePrivacyDlpV2InspectConfig — Configuration description of the scanning process. When used with redactContent only info_types and min_likelihood are currently used.
      - `minLikelihood` 'LIKELIHOOD_UNSPECIFIED' | 'VERY_UNLIKELY' | 'UNLIKELY' | 'POSSIBLE' | 'LIKELY' | 'VERY_LIKELY' — Only returns findings equal to or above this threshold. The default is POSSIBLE. In general, the highest likelihood setting yields the fewest findings in results and the lowest chance of a false positive. For more information, see [Match likelihood](https://cloud.google.com/sensitive-data-protection/docs/likelihood).
      - `limits` GooglePrivacyDlpV2FindingLimits — Configuration to control the number of findings returned for inspection. This is not used for de-identification or data profiling. When redacting sensitive data from images, finding limits don't apply. They can cause unexpected or inconsistent results, where only some data is redacted. Don't include finding limits in RedactImage requests. Otherwise, Cloud DLP returns an error.
        - `maxFindingsPerRequest` integer — Max number of findings that are returned per request or job. If you set this field in an InspectContentRequest, the resulting maximum value is the value that you set or 3,000, whichever is lower. This value isn't a hard limit. If an inspection reaches this limit, the inspection ends gradually, not abruptly. Therefore, the actual number of findings that Cloud DLP returns can be multiple times higher than this value.
        - `maxFindingsPerItem` integer — Max number of findings that are returned for each item scanned. When set within an InspectContentRequest, this field is ignored. This value isn't a hard limit. If the number of findings for an item reaches this limit, the inspection of that item ends gradually, not abruptly. Therefore, the actual number of findings that Cloud DLP returns for the item can be multiple times higher than this value.
        - `maxFindingsPerInfoType` GooglePrivacyDlpV2InfoTypeLimit[] — Configuration of findings limit given for specified infoTypes.
          - `infoType` GooglePrivacyDlpV2InfoType — Type of information detected by the API.
            - `name` string — Name of the information type. Either a name of your choosing when creating a CustomInfoType, or one of the names listed at https://cloud.google.com/sensitive-data-protection/docs/infotypes-reference when specifying a built-in type. When sending Cloud DLP results to Data Catalog, infoType names should conform to the pattern `[A-Za-z0-9$_-]{1,64}`.
            - `sensitivityScore` GooglePrivacyDlpV2SensitivityScore — Score is calculated from of all elements in the data profile. A higher level means the data is more sensitive.
              - …
            - `version` string — Optional version name for this InfoType.
          - `maxFindings` integer — Max findings limit for the given infoType.
      - `minLikelihoodPerInfoType` GooglePrivacyDlpV2InfoTypeLikelihood[] — Minimum likelihood per infotype. For each infotype, a user can specify a minimum likelihood. The system only returns a finding if its likelihood is above this threshold. If this field is not set, the system uses the InspectConfig min_likelihood.
        - `infoType` GooglePrivacyDlpV2InfoType — Type of information detected by the API.
          - `name` string — Name of the information type. Either a name of your choosing when creating a CustomInfoType, or one of the names listed at https://cloud.google.com/sensitive-data-protection/docs/infotypes-reference when specifying a built-in type. When sending Cloud DLP results to Data Catalog, infoType names should conform to the pattern `[A-Za-z0-9$_-]{1,64}`.
          - `sensitivityScore` GooglePrivacyDlpV2SensitivityScore — Score is calculated from of all elements in the data profile. A higher level means the data is more sensitive.
            - `score` 'SENSITIVITY_SCORE_UNSPECIFIED' | 'SENSITIVITY_LOW' | 'SENSITIVITY_UNKNOWN' | 'SENSITIVITY_MODERATE' | 'SENSITIVITY_HIGH' — The sensitivity score applied to the resource.
          - `version` string — Optional version name for this InfoType.
        - `minLikelihood` 'LIKELIHOOD_UNSPECIFIED' | 'VERY_UNLIKELY' | 'UNLIKELY' | 'POSSIBLE' | 'LIKELY' | 'VERY_LIKELY' — Only returns findings equal to or above this threshold. This field is required or else the configuration fails.
      - `customInfoTypes` GooglePrivacyDlpV2CustomInfoType[] — CustomInfoTypes provided by the user. See https://cloud.google.com/sensitive-data-protection/docs/creating-custom-infotypes to learn more.
        - `sensitivityScore` GooglePrivacyDlpV2SensitivityScore — Score is calculated from of all elements in the data profile. A higher level means the data is more sensitive.
          - `score` 'SENSITIVITY_SCORE_UNSPECIFIED' | 'SENSITIVITY_LOW' | 'SENSITIVITY_UNKNOWN' | 'SENSITIVITY_MODERATE' | 'SENSITIVITY_HIGH' — The sensitivity score applied to the resource.
        - `detectionRules` GooglePrivacyDlpV2DetectionRule[] — Set of detection rules to apply to all findings of this CustomInfoType. Rules are applied in the order that they are specified. Only supported for the `dictionary`, `regex`, and `stored_type` CustomInfoTypes.
          - `hotwordRule` GooglePrivacyDlpV2HotwordRule — The rule that adjusts the likelihood of findings within a certain proximity of hotwords.
            - `hotwordRegex` GooglePrivacyDlpV2Regex — Message defining a custom regular expression.
              - …
            - `likelihoodAdjustment` GooglePrivacyDlpV2LikelihoodAdjustment — Message for specifying an adjustment to the likelihood of a finding as part of a detection rule.
              - …
            - `proximity` GooglePrivacyDlpV2Proximity — Message for specifying a window around a finding to apply a detection rule.
              - …
        - `storedType` GooglePrivacyDlpV2StoredType — A reference to a StoredInfoType to use with scanning.
          - `name` string — Resource name of the requested `StoredInfoType`, for example `organizations/433245324/storedInfoTypes/432452342` or `projects/project-id/storedInfoTypes/432452342`.
          - `createTime` string, google-datetime — Timestamp indicating when the version of the `StoredInfoType` used for inspection was created. Output-only field, populated by the system.
        - `metadataKeyValueExpression` GooglePrivacyDlpV2MetadataKeyValueExpression — Configuration for a custom infoType that detects key-value pairs in the metadata matching the specified regular expressions.
          - `valueRegex` string — The regular expression for the value. Value should be non-empty.
          - `keyRegex` string — The regular expression for the key. Key should be non-empty.
        - `exclusionType` 'EXCLUSION_TYPE_UNSPECIFIED' | 'EXCLUSION_TYPE_EXCLUDE' — If set to EXCLUSION_TYPE_EXCLUDE this infoType will not cause a finding to be returned. It still can be used for rules matching. Only supported for the `dictionary`, `regex`, and `stored_type` CustomInfoTypes.
        - `fileLabelInfoType` GooglePrivacyDlpV2FileLabelInfoType — Configuration for a custom infoType that detects file labels.
          - `googleDriveLabel` GooglePrivacyDlpV2GoogleDriveLabel — Google Drive labels published by Google.
            - `labelFieldsToMatch` GooglePrivacyDlpV2LabelField[] — The field values of the Google Drive label to match.
              - …
            - `labelId` string — The [label ID](https://developers.google.com/workspace/drive/labels/guides/overview) of the Google Drive label.
          - `sensitivityLabel` GooglePrivacyDlpV2SensitivityLabel — Sensitivity labels published by Microsoft.
            - `guid` string — The GUID of the sensitivity label.
        - `likelihood` 'LIKELIHOOD_UNSPECIFIED' | 'VERY_UNLIKELY' | 'UNLIKELY' | 'POSSIBLE' | 'LIKELY' | 'VERY_LIKELY' — Likelihood to return for this CustomInfoType. This base value can be altered by a detection rule if the finding meets the criteria specified by the rule. Defaults to `VERY_LIKELY` if not specified.
        - `infoType` GooglePrivacyDlpV2InfoType — Type of information detected by the API.
          - `name` string — Name of the information type. Either a name of your choosing when creating a CustomInfoType, or one of the names listed at https://cloud.google.com/sensitive-data-protection/docs/infotypes-reference when specifying a built-in type. When sending Cloud DLP results to Data Catalog, infoType names should conform to the pattern `[A-Za-z0-9$_-]{1,64}`.
          - `sensitivityScore` GooglePrivacyDlpV2SensitivityScore — Score is calculated from of all elements in the data profile. A higher level means the data is more sensitive.
            - `score` 'SENSITIVITY_SCORE_UNSPECIFIED' | 'SENSITIVITY_LOW' | 'SENSITIVITY_UNKNOWN' | 'SENSITIVITY_MODERATE' | 'SENSITIVITY_HIGH' — The sensitivity score applied to the resource.
          - `version` string — Optional version name for this InfoType.
        - `dictionary` GooglePrivacyDlpV2Dictionary — Custom information type based on a dictionary of words or phrases. This can be used to match sensitive information specific to the data, such as a list of employee IDs or job titles. Dictionary words are case-insensitive and all characters other than letters and digits in the unicode [Basic Multilingual Plane](https://en.wikipedia.org/wiki/Plane_%28Unicode%29#Basic_Multilingual_Plane) will be replaced with whitespace when scanning for matches, so the dictionary phrase "Sam Johnson" will match all three phrases "sam johnson", "Sam, Johnson", and "Sam (Johnson)". Additionally, the characters surrounding any match must be of a different type than the adjacent characters within the word, so letters must be next to non-letters and digits next to non-digits. For example, the dictionary word "jen" will match the first three letters of the text "jen123" but will return no matches for "jennifer". Dictionary words containing a large number of characters that are not letters or digits may result in unexpected findings because such characters are treated as whitespace. The [limits](https://cloud.google.com/sensitive-data-protection/limits) page contains details about the size limits of dictionaries. For dictionaries that do not fit within these constraints, consider using `LargeCustomDictionaryConfig` in the `StoredInfoType` API.
          - `wordList` GooglePrivacyDlpV2WordList — Message defining a list of words or phrases to search for in the data.
            - `words` string[] — Words or phrases defining the dictionary. The dictionary must contain at least one phrase and every phrase must contain at least 2 characters that are letters or digits. [required]
          - `cloudStoragePath` GooglePrivacyDlpV2CloudStoragePath — Message representing a single file or path in Cloud Storage.
            - `path` string — A URL representing a file or path (no wildcards) in Cloud Storage. Example: `gs://[BUCKET_NAME]/dictionary.txt`
        - `regex` GooglePrivacyDlpV2Regex — Message defining a custom regular expression.
          - `pattern` string — Pattern defining the regular expression. Its syntax (https://github.com/google/re2/wiki/Syntax) can be found under the google/re2 repository on GitHub.
          - `groupIndexes` integer[] — The index of the submatch to extract as findings. When not specified, the entire match is returned. No more than 3 may be included.
        - `surrogateType` GooglePrivacyDlpV2SurrogateType — Message for detecting output from deidentification transformations such as [`CryptoReplaceFfxFpeConfig`](https://cloud.google.com/sensitive-data-protection/docs/reference/rest/v2/organizations.deidentifyTemplates#cryptoreplaceffxfpeconfig). These types of transformations are those that perform pseudonymization, thereby producing a "surrogate" as output. This should be used in conjunction with a field on the transformation such as `surrogate_info_type`. This CustomInfoType does not support the use of `detection_rules`.
      - `ruleSet` GooglePrivacyDlpV2InspectionRuleSet[] — Set of rules to apply to the findings for this InspectConfig. Exclusion rules, contained in the set are executed in the end, other rules are executed in the order they are specified for each info type. Not supported for the `metadata_key_value_expression` CustomInfoType.
        - `infoTypes` GooglePrivacyDlpV2InfoType[] — List of infoTypes this rule set is applied to.
          - `name` string — Name of the information type. Either a name of your choosing when creating a CustomInfoType, or one of the names listed at https://cloud.google.com/sensitive-data-protection/docs/infotypes-reference when specifying a built-in type. When sending Cloud DLP results to Data Catalog, infoType names should conform to the pattern `[A-Za-z0-9$_-]{1,64}`.
          - `sensitivityScore` GooglePrivacyDlpV2SensitivityScore — Score is calculated from of all elements in the data profile. A higher level means the data is more sensitive.
            - `score` 'SENSITIVITY_SCORE_UNSPECIFIED' | 'SENSITIVITY_LOW' | 'SENSITIVITY_UNKNOWN' | 'SENSITIVITY_MODERATE' | 'SENSITIVITY_HIGH' — The sensitivity score applied to the resource.
          - `version` string — Optional version name for this InfoType.
        - `rules` GooglePrivacyDlpV2InspectionRule[] — Set of rules to be applied to infoTypes. The rules are applied in order.
          - `exclusionRule` GooglePrivacyDlpV2ExclusionRule — The rule that specifies conditions when findings of infoTypes specified in `InspectionRuleSet` are removed from results.
            - `dictionary` GooglePrivacyDlpV2Dictionary — Custom information type based on a dictionary of words or phrases. This can be used to match sensitive information specific to the data, such as a list of employee IDs or job titles. Dictionary words are case-insensitive and all characters other than letters and digits in the unicode [Basic Multilingual Plane](https://en.wikipedia.org/wiki/Plane_%28Unicode%29#Basic_Multilingual_Plane) will be replaced with whitespace when scanning for matches, so the dictionary phrase "Sam Johnson" will match all three phrases "sam johnson", "Sam, Johnson", and "Sam (Johnson)". Additionally, the characters surrounding any match must be of a different type than the adjacent characters within the word, so letters must be next to non-letters and digits next to non-digits. For example, the dictionary word "jen" will match the first three letters of the text "jen123" but will return no matches for "jennifer". Dictionary words containing a large number of characters that are not letters or digits may result in unexpected findings because such characters are treated as whitespace. The [limits](https://cloud.google.com/sensitive-data-protection/limits) page contains details about the size limits of dictionaries. For dictionaries that do not fit within these constraints, consider using `LargeCustomDictionaryConfig` in the `StoredInfoType` API.
              - …
            - `regex` GooglePrivacyDlpV2Regex — Message defining a custom regular expression.
              - …
            - `excludeInfoTypes` GooglePrivacyDlpV2ExcludeInfoTypes — List of excluded infoTypes.
              - …
            - `excludeByHotword` GooglePrivacyDlpV2ExcludeByHotword — The rule to exclude findings based on a hotword. For record inspection of tables, column names are considered hotwords. An example of this is to exclude a finding if it belongs to a BigQuery column that matches a specific pattern.
              - …
            - `matchingType` 'MATCHING_TYPE_UNSPECIFIED' | 'MATCHING_TYPE_FULL_MATCH' | 'MATCHING_TYPE_PARTIAL_MATCH' | 'MATCHING_TYPE_INVERSE_MATCH' | 'MATCHING_TYPE_RULE_SPECIFIC' — How the rule is applied, see MatchingType documentation for details.
            - `excludeByImageFindings` GooglePrivacyDlpV2ExcludeByImageFindings — The rule to exclude image findings based on spatial relationships with other image findings. For example, exclude an image finding if it overlaps with another image finding. This rule is silently ignored if the content being inspected is not an image.
              - …
          - `hotwordRule` GooglePrivacyDlpV2HotwordRule — The rule that adjusts the likelihood of findings within a certain proximity of hotwords.
            - `hotwordRegex` GooglePrivacyDlpV2Regex — Message defining a custom regular expression.
              - …
            - `likelihoodAdjustment` GooglePrivacyDlpV2LikelihoodAdjustment — Message for specifying an adjustment to the likelihood of a finding as part of a detection rule.
              - …
            - `proximity` GooglePrivacyDlpV2Proximity — Message for specifying a window around a finding to apply a detection rule.
              - …
          - `adjustmentRule` GooglePrivacyDlpV2AdjustmentRule — Rule that specifies conditions when a certain infoType's finding details should be adjusted.
            - `adjustByMatchingInfoTypes` GooglePrivacyDlpV2AdjustByMatchingInfoTypes — AdjustmentRule condition for matching infoTypes.
              - …
            - `adjustByImageFindings` GooglePrivacyDlpV2AdjustByImageFindings — AdjustmentRule condition for image findings. This rule is silently ignored if the content being inspected is not an image.
              - …
            - `likelihoodAdjustment` GooglePrivacyDlpV2LikelihoodAdjustment — Message for specifying an adjustment to the likelihood of a finding as part of a detection rule.
              - …
      - `contentOptions` string[] — Deprecated and unused.
      - `includeQuote` boolean — When true, a contextual quote from the data that triggered a finding is included in the response; see Finding.quote. This is not used for data profiling.
      - `excludeInfoTypes` boolean — When true, excludes type information of the findings. This is not used for data profiling.
      - `infoTypes` GooglePrivacyDlpV2InfoType[] — Restricts what info_types to look for. The values must correspond to InfoType values returned by ListInfoTypes or listed at https://cloud.google.com/sensitive-data-protection/docs/infotypes-reference. When no InfoTypes or CustomInfoTypes are specified in a request, the system may automatically choose a default list of detectors to run, which may change over time. If you need precise control and predictability as to what detectors are run you should specify specific InfoTypes listed in the reference, otherwise a default list will be used, which may change over time.
        - `name` string — Name of the information type. Either a name of your choosing when creating a CustomInfoType, or one of the names listed at https://cloud.google.com/sensitive-data-protection/docs/infotypes-reference when specifying a built-in type. When sending Cloud DLP results to Data Catalog, infoType names should conform to the pattern `[A-Za-z0-9$_-]{1,64}`.
        - `sensitivityScore` GooglePrivacyDlpV2SensitivityScore — Score is calculated from of all elements in the data profile. A higher level means the data is more sensitive.
          - `score` 'SENSITIVITY_SCORE_UNSPECIFIED' | 'SENSITIVITY_LOW' | 'SENSITIVITY_UNKNOWN' | 'SENSITIVITY_MODERATE' | 'SENSITIVITY_HIGH' — The sensitivity score applied to the resource.
        - `version` string — Optional version name for this InfoType.
    - `updateTime` string, google-datetime — Output only. The last update timestamp of a contentPolicy; output-only field.
    - `name` string — Output only. Resource name of the policy.
  - `contentPolicyId` string — Optional. The content policy ID can contain uppercase and lowercase letters, numbers, and hyphens; that is, it must match the regular expression: `[a-zA-Z\d-_]+`. The maximum length is 100 characters. If empty, the system will generate a random id.

## Response `200`

Successful response

---

[API](https://skmtc.net/google/apis/dlp.md) · [All operations](https://skmtc.net/google/apis/dlp/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/google/dlp/versions/98ced13f7159/schema)
