{
  "openapi": "3.1.0",
  "info": {
    "title": "IBAN & SWIFT/BIC Validator API",
    "version": "1.0.0",
    "description": "Validate IBANs with the mod-97 checksum and parse SWIFT/BIC codes into bank, country, location and branch.\n\nValidate International Bank Account Numbers (IBAN) with the ISO 7064 mod-97 checksum and per-country length rules, and validate SWIFT/BIC codes — breaking each down into bank, country, location, and branch components.",
    "contact": {
      "name": "Data and APIs",
      "url": "https://dataandapis.com/contact"
    },
    "termsOfService": "https://dataandapis.com/terms-of-service",
    "license": {
      "name": "Data and APIs Terms of Service",
      "url": "https://dataandapis.com/terms-of-service"
    },
    "x-logo": {
      "url": "https://dataandapis.com/images/iban-swift.webp"
    }
  },
  "externalDocs": {
    "description": "Documentation, live tester and pricing",
    "url": "https://dataandapis.com/apis/iban-swift-validator"
  },
  "servers": [
    {
      "url": "https://api-iban-swift.dataandapis.com"
    }
  ],
  "tags": [
    {
      "name": "Finance",
      "description": "IBAN & SWIFT/BIC Validator API belongs to the Finance category of the Data and APIs catalog."
    }
  ],
  "paths": {
    "/v1/iban": {
      "get": {
        "operationId": "validateIban",
        "summary": "Validate IBAN",
        "description": "Validate IBAN endpoint of the IBAN & SWIFT/BIC Validator API. Costs 1 token per call.",
        "externalDocs": {
          "url": "https://dataandapis.com/apis/iban-swift-validator/validate-iban"
        },
        "parameters": [
          {
            "name": "iban",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            },
            "example": "GB82 WEST 1234 5698 7654 32"
          }
        ],
        "responses": {
          "200": {
            "description": "Successful response",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object"
                },
                "example": {
                  "iban": "GB82WEST12345698765432",
                  "valid": true,
                  "country_code": "GB",
                  "check_digits": "82",
                  "bban": "WEST12345698765432",
                  "length": 22,
                  "expected_length": 22,
                  "errors": []
                }
              }
            }
          },
          "401": {
            "description": "Missing or invalid API key"
          },
          "402": {
            "description": "Subscription past due; the response carries a payment_url"
          },
          "429": {
            "description": "Monthly token allowance exhausted"
          }
        },
        "security": [
          {
            "ApiKey": []
          }
        ]
      }
    },
    "/v1/swift": {
      "get": {
        "operationId": "validateSwiftBic",
        "summary": "Validate SWIFT/BIC",
        "description": "Validate SWIFT/BIC endpoint of the IBAN & SWIFT/BIC Validator API. Costs 1 token per call.",
        "externalDocs": {
          "url": "https://dataandapis.com/apis/iban-swift-validator/validate-swift-bic"
        },
        "parameters": [
          {
            "name": "bic",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            },
            "example": "DEUTDEFF500"
          }
        ],
        "responses": {
          "200": {
            "description": "Successful response",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object"
                },
                "example": {
                  "bic": "DEUTDEFF500",
                  "valid": true,
                  "bank_code": "DEUT",
                  "country_code": "DE",
                  "location_code": "FF",
                  "branch_code": "500",
                  "type": "branch",
                  "errors": []
                }
              }
            }
          },
          "401": {
            "description": "Missing or invalid API key"
          },
          "402": {
            "description": "Subscription past due; the response carries a payment_url"
          },
          "429": {
            "description": "Monthly token allowance exhausted"
          }
        },
        "security": [
          {
            "ApiKey": []
          }
        ]
      }
    }
  },
  "components": {
    "securitySchemes": {
      "ApiKey": {
        "type": "apiKey",
        "in": "header",
        "name": "X-Api-Key",
        "description": "Create a free key at https://dataandapis.com/sign-up. 500 tokens a month on the Free plan; this API costs 1 token per call."
      }
    }
  },
  "security": [
    {
      "ApiKey": []
    }
  ]
}