Redact tax identification numbers from text, JSON, and CSV
Tax identifiers appear on almost every B2B invoice and almost never need to leave your systems. Redactly detects them from a tax cue plus the value that follows.
How Redactly detects tax identification numbers
- Detected by a context cue for TIN, EIN, VAT, or tax ID followed by the value.
- Accepts both hyphenated and plain digit forms.
- An SSN used as a tax identifier is reported as identity.ssn, which is the more specific type.
Why redact tax identification numbers?
Tax IDs are used for filing fraud and are frequently exposed in invoice PDFs sent to third parties.
Example request
curl -X POST https://api.bitbanger.in/v1/redact \
-H "X-API-Key: rdct_your_key_here" \
-H "Content-Type: application/json" \
-d '{"text": "Vendor TIN: 12-3456789, W-9 on file.", "style": "replace"}'
Every hit in the response carries entity, text, start, and end. The offsets index into the text you sent, so you can apply the redactions to your own copy of the document. The full response schema is in the API reference.
Questions
Does Redactly redact tax identification numbers automatically?
Yes. Send text to the API and every detected type is redacted, including tax identification numbers. To redact only this type, pass the value identity.tax_id in the entities filter. No training or configuration is required.
What happens to tax identification numbers after redaction?
With style set to replace, each match becomes [identity.tax_id] — the entity type in square brackets. Setting style to mask replaces every character with a block character, and remove deletes the span entirely.
Related entity types
- Social Security numbersRedact US Social Security numbers in 3-2-4 format from text, JSON, and CSV. Format-matched, with no model dependency.
- National ID numbersRedact national identity numbers such as NIN, DNI, PESEL, and similar government identifiers.
- Bank account numbersRedact domestic bank account numbers that carry no checksum and no fixed format.
Redact tax identification numbers in production
Get an API key and send your first request in a minute. Plans start at $24/month.
See pricing