Quick Start
Custom ID Recognizer
For simple pattern-based detection, usecreateCustomIdRecognizer:
Available PII Types for Custom Patterns
Extending RegexRecognizer
For more control, extend theRegexRecognizer class:
Built-in Recognizers
Rehydra includes these recognizers by default:Secrets Recognizers (opt-in)
These are registered automatically whensecrets: { enabled: true } is set:
See the Secrets Detection guide for full configuration options.
Recognizer Registry
Manage recognizers through the registry:Create a New Registry
For complete control, create a custom registry:Disabling Built-in Recognizers
To disable specific built-in recognizers:Pattern Best Practices
Use word boundaries
Use word boundaries
Prevent matching substrings:
Be specific
Be specific
Avoid overly broad patterns:
Add validation
Add validation
Validate matches for accuracy:
Consider performance
Consider performance
Complex patterns can slow detection:
Testing Recognizers
Next Steps
PII Types
All supported PII types
API Reference
Complete API documentation