feat: Bank ueber alle Laender suchen
Unter "Deutschland" liessen sich N26 und Revolut nicht finden – und bei Revolut kann das gar nicht klappen: Die Bank vergibt deutsche IBANs, ist aber die Revolut Bank UAB in Litauen. Das Sitzland einer Bank steht nicht in der IBAN, also ist die Laenderauswahl der falsche Einstieg. Jetzt ein Suchfeld, das ohne Land ueber alle sucht; das Land ist nur noch ein optionaler Filter. Der Treffer zeigt sein Land mit an, und verbunden wird mit dem Land der BANK statt dem des Filters – sonst schluege die Autorisierung fehl, sobald ohne Land gesucht wurde. Ohne Land UND ohne Begriff wird abgelehnt: Sonst kaemen alle Banken Europas ins Formular. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
This commit is contained in:
@@ -108,10 +108,15 @@ class BankClient:
|
||||
|
||||
# --- Die vier Endpunkte -------------------------------------------------
|
||||
|
||||
def banken(self, land: str) -> list[dict]:
|
||||
"""Verfügbare Banken eines Landes – für die Auswahl beim Verbinden."""
|
||||
daten = self._anfrage("GET", f"/aspsps?country={land.upper()}")
|
||||
return daten.get("aspsps", [])
|
||||
def banken(self, land: str | None = None) -> list[dict]:
|
||||
"""Verfügbare Banken – eines Landes oder alle.
|
||||
|
||||
Ohne Land liefert die Schnittstelle die vollständige Liste. Das ist
|
||||
nötig, weil das Sitzland einer Bank nicht an der IBAN ablesbar ist:
|
||||
Revolut gibt deutsche IBANs aus, ist aber in Litauen ansässig.
|
||||
"""
|
||||
pfad = f"/aspsps?country={land.upper()}" if land else "/aspsps"
|
||||
return self._anfrage("GET", pfad).get("aspsps", [])
|
||||
|
||||
def starte_autorisierung(self, aspsp_name: str, land: str, redirect_url: str,
|
||||
state: str, tage: int, psu_type: str = "personal") -> dict:
|
||||
|
||||
Reference in New Issue
Block a user