# SWIFT/BIC Validator API
> SWIFT/BIC business-identifier-code validation and parsing as an API, computed locally and deterministically. The validate endpoint checks that a code follows the ISO 9362 BIC structure — four letters for the institution, a two-letter ISO country code, a two-character location code and an optional three-character branch code, eight or eleven characters in total — ignoring spaces and upper-casing the input, and confirms the country code is a recognised one; DEUTDEFF (Deutsche Bank, Frankfurt) is a valid eight-character head-office BIC and DEUTDEFF500 a valid eleven-character branch BIC. The parse endpoint breaks a BIC into its institution, country, location and branch components, reports whether it is a head office or a branch (branch XXX or none means the head office), and reads the status from the location code’s second character — 0 for a test/non-SWIFT code, 1 for a passive participant and 2 for reverse billing. A BIC carries no checksum, so this is structural validation. Everything is computed locally and deterministically, so it is instant and private. Ideal for fintech, banking, payment, KYC, treasury and accounting app developers, SWIFT-code and bank-identifier tools, and onboarding flows. Pure local computation — no key, no third-party service, instant. Live, nothing stored. 2 endpoints. This validates and parses a BIC; for IBAN account-number validation use an IBAN API.

## Authentication
All requests require your oanor API key in the `x-oanor-key` header. Get one at https://www.oanor.com/developer/keys.

```bash
curl -H "x-oanor-key: oanor_live_…" "https://api.oanor.com/bic-api/..."
```

## Pricing
- **Free** (Free) — 4,050 calls/Mo, 2 req/s
- **Starter** ($6/Mo) — 40,500 calls/Mo, 6 req/s
- **Pro** ($17/Mo) — 192,000 calls/Mo, 15 req/s
- **Mega** ($51/Mo) — 1,145,000 calls/Mo, 40 req/s

## Endpoints

### BIC

#### `GET /v1/parse` — Parse a BIC into parts

**Parameters:**
- `bic` (query, required, string) — SWIFT/BIC code Example: `DEUTDEFF500`

**Example:**
```bash
curl -H "x-oanor-key: $KEY" \
  "https://api.oanor.com/bic-api/v1/parse?bic=DEUTDEFF500"
```

**Response:**
```json
{
    "data": {
        "note": "BIC breakdown. The second location character flags status: '0' test/non-SWIFT, '1' passive, '2' reverse-billing. Branch 'XXX' or none means the head office.",
        "inputs": {
            "bic": "DEUTDEFF500"
        },
        "office": "branch",
        "passive": false,
        "connected": true,
        "normalized": "DEUTDEFF500",
        "branch_code": "500",
        "is_test_bic": false,
        "country_code": "DE",
        "location_code": "FF",
        "reverse_billing": false,
        "institution_code": "DEUT"
    },
    "meta": {
        "timestamp": "2026-06-05T19:50:13.625Z",
        "request_id": "4439642d-2c06-4724-a536-f055213b0187"
    },
    "status": "ok",
    "message": "Parse BIC",
    "success": true
}
```

#### `GET /v1/validate` — Validate a BIC

**Parameters:**
- `bic` (query, required, string) — SWIFT/BIC code (8 or 11 chars) Example: `DEUTDEFF`

**Example:**
```bash
curl -H "x-oanor-key: $KEY" \
  "https://api.oanor.com/bic-api/v1/validate?bic=DEUTDEFF"
```

**Response:**
```json
{
    "data": {
        "note": "A BIC is 4 letters (institution) + 2 letters (ISO country) + 2 (location) + optional 3 (branch). DEUTDEFF (Deutsche Bank Frankfurt) is a valid 8-character BIC.",
        "type": "BIC8 (head office)",
        "valid": true,
        "inputs": {
            "bic": "DEUTDEFF"
        },
        "length": 8,
        "normalized": "DEUTDEFF",
        "country_recognized": true,
        "structurally_valid": true
    },
    "meta": {
        "timestamp": "2026-06-05T19:50:13.730Z",
        "request_id": "9597a60b-3350-4ad3-8b2d-a8a2a7d1e64a"
    },
    "status": "ok",
    "message": "Validate BIC",
    "success": true
}
```

### Meta

#### `GET /v1/meta` — Spec

**Example:**
```bash
curl -H "x-oanor-key: $KEY" \
  "https://api.oanor.com/bic-api/v1/meta"
```

**Response:**
```json
{
    "data": {
        "notes": "Spaces are ignored, input is upper-cased. Structural/format validation (a BIC has no checksum). For IBAN account-number validation use an IBAN API.",
        "service": "bic-api",
        "endpoints": {
            "GET /v1/meta": "This document.",
            "GET /v1/parse": "Break a BIC into its institution, country, location and branch parts.",
            "GET /v1/validate": "Validate a BIC's structure and country code."
        },
        "description": "SWIFT/BIC code validation and structural parsing (institution, country, location, branch)."
    },
    "meta": {
        "timestamp": "2026-06-05T19:50:13.847Z",
        "request_id": "a19b0ad3-cdd1-4489-9152-51f42345111b"
    },
    "status": "ok",
    "message": "Meta",
    "success": true
}
```


---
Marketplace page: https://www.oanor.com/api/bic-api
OpenAPI spec: https://www.oanor.com/api/bic-api/openapi.json
