Cloud Data Loss Prevention (DLP) API logo

Cloud Data Loss Prevention (DLP) API

Cloud Data Loss Prevention (DLP) API

Google Cloud DLP (Data Loss Prevention) API scans and de-identifies sensitive data — detects PII (national IDs, credit cards, emails) and performs masking, encryption, or format-preserving encryption.

Visit site ↗Health checked 9h ago
Use it when

Built-in 150+ infoTypes (credit cards, SSN, national IDs by country)

Watch for

Charged by bytes processed — costly for large datasets

First check

POST /v2/projects/{projectId}/content:inspect to scan for PII; POST /content:deidentify to de-identify.

Auth
CORS
No
HTTPS
Yes
Signup
?
Latency
44 ms
Protocol
REST
Pricing

Uptime · 30-day window

Probes: 1Uptime: 100%Avg latency: 44ms
01

About this API

DLP is GCP's privacy-protection tool. The core problem it solves: "Where is sensitive data in my systems, and how do I handle it?" Built-in infoType detectors cover common PII by country: US SSN, credit cards (issuer-detected), email, phone, Chinese national ID, UK NHS number, etc. Can scan text, tables, images (with auto-OCR), or directly scan BigQuery tables / GCS buckets at scale, producing reports of "which columns have what PII". De-identification methods are flexible — simple mask (XXX-XX-1234), replace (with fake data), encryption (reversible with KMS key), format-preserving encryption (preserves length and format, ideal for database migration). Essential for compliance (GDPR, HIPAA, PCI) and data-governance scenarios.

02

What you can build

  • 1Scan logs/databases to find PII
  • 2De-identify production data for dev/test environments
  • 3Auto-detect PII in BigQuery tables
  • 4Chatbot input filtering
03

Strengths & limitations

Strengths

  • Built-in 150+ infoTypes (credit cards, SSN, national IDs by country)
  • Multiple de-identification methods (mask, replace, encrypt, tokenize)
  • Direct scan of BigQuery / Cloud Storage / Datastore

Limitations

  • Charged by bytes processed — costly for large datasets
  • Custom infoTypes require regex or custom-trained models
04

Example request

Generic template — replace <endpoint> with the real path from the docs.
curl https://google.com/<endpoint>
05

Getting started

POST /v2/projects/{projectId}/content:inspect to scan for PII; POST /content:deidentify to de-identify.

06

FAQ

Can it detect Chinese national IDs?+

Yes. CHINA_RESIDENT_ID_NUMBER is a built-in infoType with high accuracy (checksum validation).

When to use format-preserving encryption?+

Database-migration scenarios — encrypted data preserves original length and format (e.g. credit card remains 16 digits), so downstream schemas don't change.

07

Technical details

CORS: NoHTTPS: YesSignup: ?Open source: No
Auth type
unknown
Pricing
unknown
Protocols
REST
SDKs
python, javascript, go, java
Response time
44 ms
Last health check
5/12/2026, 7:37:31 AM
08

Tags

09

More from Google