Inspecting and de-identifying PII data
To de-identify sensitive data, use Cloud DLP’s content.deidentify
method.
There are three parts to a de-identification API call:
- The data to inspect: A string or table structure (
ContentItem
object) for the API to inspect. - What to inspect for: Detection configuration information (
InspectConfig
) such as what types of data (or infoTypes) to look for, whether to filter findings that are above a certain likelihood threshold, whether to return no more than a certain number of results, and so on. Not specifying at least one infoType in anInspectConfig
argument is equivalent to specifying all built-in infoTypes. Doing so is not recommended, as it can cause decreased performance and increased cost. - What to do with the inspection findings: Configuration information (
DeidentifyConfig
) that defines how you want the sensitive data de-identified. This argument is covered in more detail in the following section.
The API returns...