PIIGuard / Detectors
IBAN
Detects International Bank Account Numbers using MOD-97 checksum validation (ISO 7064). Covers 80+ country formats. Always confidence 1.0 — MOD-97 is mathematically rigorous.
Endpoint: POST /v1/pii/detect/iban
Validation & Confidence
Country code (2 letters) + check digits (MOD-97) + country-specific BBAN structure.
Always 1.0. Severity: high.
Example
from instructeer.guards import PIIGuard
# api_key = os.environ["INSTRUCTEER_API_KEY"]
pii = PIIGuard(api_key="rg_your_key")
result = pii.detect_iban("Transfer to IBAN GB82 WEST 1234 5698 7654 32")// Response
{
"entity_type": "IBAN_CODE",
"value": "GB82 WEST 1234 5698 7654 32",
"severity": "high",
"confidence": 1.0,
"extra": { "normalized": "GB82WEST12345698765432", "country": "GB" }
}Notes
- Formatting: Spaces between groups are handled. Both formatted (GB82 WEST ...) and compact (GB82WEST...) are detected.
- Checksum failure: A structurally matching string that fails MOD-97 is not returned.