# Redact SWIFT/BIC codes

> Redact SWIFT and BIC codes from payment instructions without flagging every all-caps word.

Canonical: https://bitbanger.in/entities/swift-bic
Last updated: 2026-10-27

Category: Financial data · Entity type: `financial.swift_bic`

A BIC is eight or eleven characters of unremarkable capitals, which is exactly what makes naive detection useless. Redactly requires a digit or an explicit SWIFT/BIC cue nearby.

## How Redactly detects SWIFT/BIC codes

- Matched by regex for four letters, a country code, a location code, and an optional branch code.
- Rejected unless the value contains a digit or a SWIFT/BIC cue appears within the preceding characters.
- This is what stops words like CONFIDENTIAL or PARTICULARS being redacted as banks.

## Why redact SWIFT/BIC codes?

Payment instructions pasted into support threads expose the routing path for a customer's funds.

## Example request

```bash
curl -X POST https://api.bitbanger.in/v1/redact \
  -H "X-API-Key: rdct_your_key_here" \
  -H "Content-Type: application/json" \
  -d '{"text": "Intermediary bank BIC DEUTDEFFXXX, charges SHA.", "style": "replace"}'
```

## FAQ

**Does Redactly redact SWIFT/BIC codes automatically?**

Yes. Send text to the API and every detected type is redacted, including SWIFT/BIC codes. To redact only this type, pass the value financial.swift_bic in the entities filter. No training or configuration is required.

**What happens to SWIFT/BIC codes after redaction?**

With style set to replace, each match becomes [financial.swift_bic] — 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

- [IBANs](https://bitbanger.in/entities/iban) — Redact International Bank Account Numbers with mod-97 validation across all SEPA countries.
- [Bank account numbers](https://bitbanger.in/entities/bank-account) — Redact domestic bank account numbers that carry no checksum and no fixed format.
- [Credit card numbers](https://bitbanger.in/entities/credit-card) — Redact card numbers from text and JSON with Luhn validation, so only real card numbers are flagged and order IDs are left alone.

Try it on your own text: https://bitbanger.in/entities/swift-bic
