PII Detection
Scans for personally identifiable information
API Field:pii_enabledOverview
PII (Personally Identifiable Information) Detection identifies sensitive personal data that could be used to identify, contact, or locate an individual. This scanner helps organizations maintain data privacy compliance and prevent accidental exposure of sensitive information through AI interactions.
What It Detects
- Social Security Numbers (SSN)
- Email addresses
- Phone numbers (various formats)
- Credit card numbers
- Physical addresses
- Date of birth
- Driver's license numbers
- Passport numbers
- Bank account numbers
Why It Matters
Handling PII incorrectly can result in identity theft, privacy violations, regulatory fines (GDPR, CCPA), and loss of customer trust. AI systems must not inadvertently store, process, or expose PII.
Technical Details
Risk Score Range
0.0 - 1.0 (High risk: > 0.5)
Confidence Level
Typically 0.90 - 0.99
Processing Time
< 50ms per scan
Common Use Cases
Detection Examples
Explicit SSN disclosure - high-risk PII that requires immediate protection.
Multiple PII elements: email address and physical address.
Payment card information - requires PCI DSS compliance.
API Usage
Enable this scanner in your API request by setting pii_enabled to true in your API key settings, or include it in your request:
curl -X POST https://benguard.io/api/v1/scan \
-H "X-API-Key: ben_your_api_key_here" \
-H "Content-Type: application/json" \
-d '{
"prompt": "Your user input here"
}'The scanner settings are configured per API key in your dashboard under Settings → Scanner Configuration.
Response Format
When this scanner detects a threat, the response will include:
{
"is_valid": false,
"status": "threat_detected",
"risk_score": 0.98,
"threat_types": ["pii"],
"details": {
"results": [
{
"scanner": "pii",
"threat_detected": true,
"risk_score": 0.98,
"confidence": 0.92,
"details": {
"reason": "Explicit SSN disclosure - high-risk PII that requires immediate protection.",
"evidence": ["detected pattern in input"]
}
}
]
},
"request_id": "req_abc123"
}Best Practices
- Never store PII in conversation logs without encryption
- Implement automatic PII redaction in responses
- Use tokenization for necessary PII processing
- Establish clear data retention policies
- Train models to avoid requesting unnecessary PII
Related Scanners
Consider enabling these related scanners for comprehensive protection: