Zum Inhalt springen 
API-Dokumentation

API-Referenz

API zur IBAN-Prüfung und Bankabfrage. RESTful-Architektur mit JSON-Antworten.

Basis-URL https://test.ibansource.com/api/v1

Authentifizierung

Senden Sie Ihren API-Schlüssel auf eine der folgenden Weisen:

Methode Verwendung
X-API-Key X-API-Key: ibsrc_live_xxx
Bearer Token Authorization: Bearer ibsrc_live_xxx
Query Param ?api_key=ibsrc_live_xxx

IBAN-Prüfung

POST /api/v1/iban/validate IBAN-Prüfung

Prüft eine einzelne IBAN und gibt die Bankdaten zurück.

Parameter
iban erforderlich — Die zu prüfende IBAN
Beispiel (cURL)
curl -X POST https://test.ibansource.com/api/v1/iban/validate \
  -H "X-API-Key: ibsrc_live_xxx" \
  -H "Content-Type: application/json" \
  -d '{"iban": "TR330006100519786457841326"}'

Sammelprüfung von IBANs

POST /api/v1/iban/batch Sammelprüfung von IBANs

Prüft mehrere IBANs in einer Anfrage (max. 50).

Parameter
ibans erforderlich — Array von IBANs
Beispiel (JavaScript)
const response = await fetch('https://test.ibansource.com/api/v1/iban/batch', {
  method: 'POST',
  headers: {
    'Content-Type': 'application/json',
    'X-API-Key': 'ibsrc_live_xxx'
  },
  body: JSON.stringify({
    ibans: ['TR330006100519786457841326', 'TR120006200119000006672315']
  })
});
const data = await response.json();

Banken

GET /api/v1/banks Bankenliste

Listet Finanzinstitute auf und filtert sie.

Parameter
type_slug optional — Filter nach Institutsart
search optional — Suchbegriff
page optional — Seitennummer (Standard: 1)
per_page optional — Datensätze pro Seite (Standard: 10, max.: 100)
Beispiel (PHP)
$ch = curl_init('https://test.ibansource.com/api/v1/banks?search=garanti');
curl_setopt_array($ch, [
    CURLOPT_RETURNTRANSFER => true,
    CURLOPT_HTTPHEADER => ['X-API-Key: ibsrc_live_xxx']
]);
$response = json_decode(curl_exec($ch), true);
curl_close($ch);
GET /api/v1/health Statusprüfung

Prüft den API-Status. Keine Authentifizierung erforderlich.

Antwortformat

Erfolgreiche Antwort
{
  "success": true,
  "data": { ... },
  "message": "İşlem başarılı",
  "meta": {
    "version": "1.0.0",
    "request_id": "20250101-120000-abc123",
    "timestamp": 1704106800,
    "datetime": "2025-01-01T12:00:00+03:00",
    "execution_time_ms": 12.5
  }
}
Fehlerantwort
{
  "type": "https://ibansource.com/errors/validation_error",
  "title": "Validation Error",
  "status": 422,
  "detail": "Doğrulama hatası",
  "instance": "/api/v1/iban/validate",
  "timestamp": "2025-01-01T12:00:00+03:00",
  "success": false,
  "error": {
    "code": "VALIDATION_ERROR",
    "message": "Doğrulama hatası",
    "http_status": 422,
    "details": { "iban": ["IBAN 26 karakter olmalıdır"] }
  },
  "meta": { ... }
}

Rate Limiting

Jeder Endpunkt hat sein eigenes Limit. Mit einem API-Schlüssel werden die Limits erhöht.

Endpunkt Anonym API-Schlüssel Zeitfenster
/iban/* 100 500 60 Sek.
/banks 200 1,000 1 Std.
blog 200 1,000 60 Sek.
blog_detail 60 300 60 Sek.
/banks/{slug} 60 300 60 Sek.
provinces 120 600 60 Sek.
districts 150 750 60 Sek.
Antwort-Header: X-RateLimit-Limit, X-RateLimit-Remaining, X-RateLimit-Reset

Fehlercodes

HTTP Code Beschreibung
400 BAD_REQUEST Ungültiger Parameter oder fehlendes Feld
401 UNAUTHORIZED Ungültiger oder fehlender API-Schlüssel
403 FORBIDDEN Sie haben keinen Zugriff auf diesen Endpunkt
404 RESOURCE_NOT_FOUND Die angeforderte Ressource wurde nicht gefunden
405 METHOD_NOT_ALLOWED HTTP-Methode nicht unterstützt
422 VALIDATION_ERROR Validierungsfehler (detailliert)
429 RATE_LIMIT_EXCEEDED Anfragelimit überschritten
500 INTERNAL_SERVER_ERROR Serverfehler

Codebeispiele

Python
import requests

resp = requests.post(
    "https://test.ibansource.com/api/v1/iban/validate",
    json={"iban": "TR330006100519786457841326"},
    headers={"X-API-Key": "ibsrc_live_xxx"}
)
data = resp.json()
print(data["data"])
Node.js
const res = await fetch(
  'https://test.ibansource.com/api/v1/iban/validate',
  {
    method: 'POST',
    headers: {
      'Content-Type': 'application/json',
      'X-API-Key': 'ibsrc_live_xxx'
    },
    body: JSON.stringify({
      iban: 'TR330006100519786457841326'
    })
  }
);
const data = await res.json();