Introduction
Welcome to the IBANTEST API! Our API can be used to access IBANTEST API endpoints. You can register your API key with 100 credits for free at https://www.ibantest.com.
GitHub / Composer
For PHP projects we recommend our "IBANTEST API PHP client" on GitHub.
Get last version with Composer.
$ composer require ibantest/ibantest-php
Wordpress / WooCommerce
If you want to use IBANTEST with your WooCommerce Shop, please have a look at our
IBANTEST for WooCommerce - Wordpress Plugin
Authentication
Our REST API is stateless. This means that each request has to come with some sort of authentication credentials.
IBANTEST includes two ways to authenticate with the REST API:
1. Header-Authentication
Include the API key in all API requests to the server in a header as Bearer-Token:
Header key | Header value |
---|---|
Authorization | Bearer YOUR_API_KEY |
2. Authentication with GET parameter
You can also just put the token as parameter to your api request like this:
https://api.ibantest.com/v1/validate_iban/<iban>'?token=YOUR_API_KEY
Response format
The IBANTEST REST API supports json, xml and html for response format. You can use the "Accept" header for specify the format:
Header key | Header value |
---|---|
Accept | application/json |
Accept | application/xml |
Accept | text/html |
It's also possible to use the "format" parameter for GET requests to specify the response format.
https://api.ibantest.com/v1/validate_iban/<iban>?token=YOUR_API_KEY&format=xml
The format parameter accepts "json", "xml" or "html" as value.
The default response format is JSON. Successful requests will return a 200 OK HTTP status.
Endpoints
Validate IBAN
curl -X GET \
https://api.ibantest.com/v1/validate_iban/<iban> \
-H 'authorization: Bearer YOUR_API_KEY'
<?php
$curl = curl_init();
curl_setopt_array($curl, array(
CURLOPT_URL => "https://api.ibantest.com/v1/validate_iban/<iban>",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => array(
"authorization: Bearer YOUR_API_KEY"
),
));
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
var settings = {
"async": true,
"crossDomain": true,
"url": "https://api.ibantest.com/v1/validate_iban/<iban>",
"method": "GET",
"headers": {
"authorization": "Bearer YOUR_API_KEY"
}
}
$.ajax(settings).done(function (response) {
console.log(response);
});
The above command returns JSON structured like this:
{
"valid": true,
"checks": {
"ibanLength": true,
"ibanChecksum": true,
"ibanSyntaxVerify": true,
"bankAccountSyntaxVerify": true,
"bankExistVerify": true
},
"ibanData": {
"iban": "DE02600501010002034304",
"ibanExt": "DE02 6005 0101 0002 0343 04",
"countryCode": "DE",
"checksum": "02",
"bankCode": "60050101",
"account": "0002034304",
"bban": "600501010002034304",
"nationalChecksum": "",
"length": 22
},
"bankData": {
"bankCode": 60050101,
"bic": "SOLADEST600",
"description": "Landesbank Baden-Württemberg/Baden-Württembergische Bank",
"descriptionShort": "LBBW/BW-Bank Stuttgart",
"address": "",
"zip": "70144",
"city": "Stuttgart",
"state": "",
"countryCode": "DE",
"phone": "",
"fax": "",
"mail": "",
"website": "",
"pan": "56100"
},
"countryData": {
"isoCode": "DE",
"name": "Germany",
"isSepa": true,
"isOfficialSwiftMember": true,
"isEUMember": true,
"currencyCode": "EUR",
"centralBankName": "Deutsche Bundesbank",
"centralBankURL": "http://www.bundesbank.de/"
}
}
This endpoint validates and verifies the accuracy of an IBAN. It provides details of the tests carried out and their results as well as much information from this IBAN such as account number, bank code and checksum. In addition, all bank information such as BIC, bank name or address will be returned.
HTTP Request
https://api.ibantest.com/v1/validate_iban/<iban>
URL Parameters
Parameter | Description |
---|---|
IBAN | The IBAN you want to verify |
Response Values
Parameter | Type | Description | |
---|---|---|---|
valid | - | string | returns "true" if all checks were successful. Otherwise, 'false'. |
checks | - | object | all executed checks |
ibanLength | boolean | checks whether the IBAN length is correct | |
ibanChecksum | boolean | checks whether the IBAN checksum is correct | |
ibanSyntaxVerify | boolean | checks whether the IBAN syntax is correct | |
bankAccountSyntaxVerify | boolean | checks whether the bank account syntax is correct | |
bankExistVerify | boolean | checks whether the bank exists | |
ibanData | - | object | iban data |
iban | string | validated IBAN (machine format) | |
ibanExt | string | validated IBAN (human readable format) | |
countryCode | string | ISO country code | |
checksum | string | IBAN checksum | |
bankCode | string | domestic bank code | |
account | string | national bank account number | |
bban | string | Basic Bank Account Number | |
length | string | IBAN length for this country | |
bankData | - | object | bank data |
bankCode | string | domestic bank code | |
bic | string | BIC or SWIFT Code | |
description | string | bank name | |
descriptionShort | string | bank name (short) | |
address | string | address | |
zip | string | ZIP or Postal Code | |
city | string | city | |
state | string | state | |
countryCode | string | ISO country code | |
phone | string | phone number | |
fax | string | fax number | |
string | email address | ||
website | string | website | |
pan | string | Primary Account Number | |
countryData | - | object | bank data |
isoCode | string | ISO country code | |
name | string | country name | |
isSepa | boolean | whether the country is part of SEPA | |
isOfficialSwiftMember | boolean | whether the country is official Swift member | |
isEUMember | boolean | whether the country is member of EU | |
currencyCode | string | ISO currency code | |
centralBankName | string | name of the central bank | |
centralBankURL | string | url of the central bank |
Calculate IBAN
curl -X GET \
https://api.ibantest.com/v1/calculate_iban/<country_code>/<bank_code>/<account> \
-H 'authorization: Bearer YOUR_API_KEY'
<?php
$curl = curl_init();
curl_setopt_array($curl, array(
CURLOPT_URL => "https://api.ibantest.com/v1/calculate_iban/<country_code>/<bank_code>/<account>",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => array(
"authorization: Bearer YOUR_API_KEY"
),
));
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
var settings = {
"async": true,
"crossDomain": true,
"url": "https://api.ibantest.com/v1/calculate_iban/<country_code>/<bank_code>/<account>",
"method": "GET",
"headers": {
"authorization": "Bearer YOUR_API_KEY"
}
}
$.ajax(settings).done(function (response) {
console.log(response);
});
The above command returns JSON structured like this:
{
"valid": true,
"checks": {
"ibanLength": true,
"ibanChecksum": true,
"ibanSyntaxVerify": true,
"bankAccountSyntaxVerify": true,
"bankExistVerify": true
},
"ibanData": {
"iban": "DE02600501010002034304",
"ibanExt": "DE02 6005 0101 0002 0343 04",
"countryCode": "DE",
"checksum": "02",
"bankCode": "60050101",
"account": "0002034304",
"bban": "600501010002034304",
"nationalChecksum": "",
"length": 22
},
"bankData": {
"bankCode": 60050101,
"bic": "SOLADEST600",
"description": "Landesbank Baden-Württemberg/Baden-Württembergische Bank",
"descriptionShort": "LBBW/BW-Bank Stuttgart",
"address": "",
"zip": "70144",
"city": "Stuttgart",
"state": "",
"countryCode": "DE",
"phone": "",
"fax": "",
"mail": "",
"website": "",
"pan": "56100"
},
"countryData": {
"isoCode": "DE",
"name": "Germany",
"isSepa": true,
"isOfficialSwiftMember": true,
"isEUMember": true,
"currencyCode": "EUR",
"centralBankName": "Deutsche Bundesbank",
"centralBankURL": "http://www.bundesbank.de/"
}
}
This endpoint calculates the IBAN and BIC on the basis of the account number, bank code and country. It provides details of the tests carried out and their results as well as much information from this IBAN such as account number, bank code and checksum. In addition, all bank information such as BIC, bank name or address will be returned.
HTTP Request
for Germany and Austria:
https://api.ibantest.com/v1/calculate_iban/<country_code>/<bank_code>/<account>
for Belgium:
https://api.ibantest.com/v1/calculate_iban/BE/<bank_code>/<account>/<checkDigits>
URL Parameters
Parameter | Description |
---|---|
country_code | Two letter ISO country code (like DE, AT...) |
bank_code | Domestic bank code of the bank |
account | Domestic account number |
checkDigits | check digits of account (only for Belgium) |
Response Values
Response Values
Parameter | Type | Description | |
---|---|---|---|
valid | - | string | returns "true" if all checks were successful. Otherwise, 'false'. |
checks | - | object | all executed checks |
ibanLength | boolean | checks whether the IBAN length is correct | |
ibanChecksum | boolean | checks whether the IBAN checksum is correct | |
ibanSyntaxVerify | boolean | checks whether the IBAN syntax is correct | |
bankAccountSyntaxVerify | boolean | checks whether the bank account syntax is correct | |
bankExistVerify | boolean | checks whether the bank exists | |
ibanData | - | object | iban data |
iban | string | validated IBAN (machine format) | |
ibanExt | string | validated IBAN (human readable format) | |
countryCode | string | ISO country code | |
checksum | string | IBAN checksum | |
bankCode | string | domestic bank code | |
account | string | national bank account number | |
bban | string | Basic Bank Account Number | |
length | string | IBAN length for this country | |
bankData | - | object | bank data |
bankCode | string | domestic bank code | |
bic | string | BIC or SWIFT Code | |
description | string | bank name | |
descriptionShort | string | bank name (short) | |
address | string | address | |
zip | string | ZIP or Postal Code | |
city | string | city | |
state | string | state | |
countryCode | string | ISO country code | |
phone | string | phone number | |
fax | string | fax number | |
string | email address | ||
website | string | website | |
pan | string | Primary Account Number | |
countryData | - | object | bank data |
isoCode | string | ISO country code | |
name | string | country name | |
isSepa | boolean | whether the country is part of SEPA | |
isOfficialSwiftMember | boolean | whether the country is official Swift member | |
isEUMember | boolean | whether the country is member of EU | |
currencyCode | string | ISO currency code | |
centralBankName | string | name of the central bank | |
centralBankURL | string | url of the central bank |
Validate BIC / SWIFT Code
curl -X GET \
https://api.ibantest.com/v1/validate_bic/<bic> \
-H 'authorization: Bearer YOUR_API_KEY'
<?php
$curl = curl_init();
curl_setopt_array($curl, array(
CURLOPT_URL => "https://api.ibantest.com/v1/validate_bic/<bic>",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => array(
"authorization: Bearer YOUR_API_KEY"
),
));
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
var settings = {
"async": true,
"crossDomain": true,
"url": "https://api.ibantest.com/v1/validate_bic/<bic>",
"method": "GET",
"headers": {
"authorization": "Bearer YOUR_API_KEY"
}
}
$.ajax(settings).done(function (response) {
console.log(response);
});
The above command returns JSON structured like this:
[
{
"bankCode": 10020500,
"bic": "BFSWDE33BER",
"description": "Bank für Sozialwirtschaft",
"descriptionShort": "Bank für Sozialwirtschaft",
"address": "",
"zip": "10178",
"city": "Berlin",
"state": "",
"countryCode": "DE",
"phone": "",
"fax": "",
"mail": "",
"website": "",
"pan": "25013"
},
{
"bankCode": 10020510,
"bic": "BFSWDE33BER",
"description": "Bank für Sozialwirtschaft",
"descriptionShort": "Sozialbank Berlin",
"address": "",
"zip": "10178",
"city": "Berlin",
"state": "",
"countryCode": "DE",
"phone": "",
"fax": "",
"mail": "",
"website": "",
"pan": ""
},
{
"bankCode": 10020520,
"bic": "BFSWDE33BER",
"description": "Bank für Sozialwirtschaft",
"descriptionShort": "Sozialbank Berlin",
"address": "",
"zip": "10178",
"city": "Berlin",
"state": "",
"countryCode": "DE",
"phone": "",
"fax": "",
"mail": "",
"website": "",
"pan": ""
}
]
This endpoint retuns all bank information such as BIC, bank name or address.
HTTP Request
https://api.ibantest.com/v1/validate_bic/<bic>
or
https://api.ibantest.com/v1/validate_swiftcode/<bic>
URL Parameters
Parameter | Description |
---|---|
bic | BIC or SWIFT Code of the bank |
Response Values
Parameter | Type | Description |
---|---|---|
bankCode | string | domestic bank code |
bic | string | BIC or SWIFT Code |
description | string | bank name |
descriptionShort | string | bank name (short) |
address | string | address |
zip | string | ZIP or Postal Code |
city | string | city |
state | string | state |
countryCode | string | ISO country code |
phone | string | phone number |
fax | string | fax number |
string | email address | |
website | string | website |
pan | string | Primary Account Number |
Find Bank
curl -X GET \
https://api.ibantest.com/v1/find_bank/<country_code>/<bank_code> \
-H 'authorization: Bearer YOUR_API_KEY'
<?php
$curl = curl_init();
curl_setopt_array($curl, array(
CURLOPT_URL => "https://api.ibantest.com/v1/find_bank/<country_code>/<bank_code>",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => array(
"authorization: Bearer YOUR_API_KEY"
),
));
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
var settings = {
"async": true,
"crossDomain": true,
"url": "https://api.ibantest.com/v1/find_bank/<country_code>/<bank_code>",
"method": "GET",
"headers": {
"authorization": "Bearer YOUR_API_KEY"
}
}
$.ajax(settings).done(function (response) {
console.log(response);
});
The above command returns JSON structured like this:
[
{
"bankCode": 16010111,
"bic": "ESSEDE5F160",
"description": "SEB",
"descriptionShort": "SEB Potsdam",
"address": "",
"zip": "14467",
"city": "Potsdam",
"state": "",
"countryCode": "DE",
"phone": "",
"fax": "",
"mail": "",
"website": "",
"pan": "25927"
}
]
This endpoint retuns all bank information such as BIC, bank name or address.
HTTP Request
https://api.ibantest.com/v1/find_bank/<country_code>/<bank_code>
URL Parameters
Parameter | Description |
---|---|
country_code | Two letter ISO country code (like DE, AT, CH...) |
bank_code | Domestic bank code of the bank |
Response Values
Parameter | Type | Description |
---|---|---|
bankCode | string | domestic bank code |
bic | string | BIC or SWIFT Code |
description | string | bank name |
descriptionShort | string | bank name (short) |
address | string | address |
zip | string | ZIP or Postal Code |
city | string | city |
state | string | state |
countryCode | string | ISO country code |
phone | string | phone number |
fax | string | fax number |
string | email address | |
website | string | website |
pan | string | Primary Account Number |
Errors
The IBANTEST API uses the following error codes:
Error Code | Meaning |
---|---|
400 | Bad Request -- Your request is invalid. |
401 | Unauthorized -- Your API key is wrong. |
403 | Forbidden -- The kitten requested is hidden for administrators only. |
404 | Not Found -- The specified kitten could not be found. |
405 | Method Not Allowed -- You tried to access a kitten with an invalid method. |
406 | Not Acceptable -- You requested a format that isn't json. |
410 | Gone -- The kitten requested has been removed from our servers. |
418 | I'm a teapot. |
429 | Too Many Requests -- You're requesting too many kittens! Slow down! |
500 | Internal Server Error -- We had a problem with our server. Try again later. |
503 | Service Unavailable -- We're temporarily offline for maintenance. Please try again later. |