python-fints
python-fints copied to clipboard
no transactions after tan challange with get_transactions
When I tray to get the transactions from a period longer than 90 days, a TAN is needed.
When I send the TAN with send_tan the response is always an empty list.
The log after the TAN is send is in the attachment tan_send.log
Without the TAN challange everything works fine.
The relevat code looks the folloring
def get_account_transactions(self, start: datetime.date = None, end: datetime.date = None):
transactions = self.client.get_transactions(self.account, start_date=start, end_date=end)
if isinstance(transactions, NeedTANResponse):
transactions = self.tan_challenge(transactions)
for transaction in transactions:
yield transaction.data
def tan_challenge(self, res):
print("Eine TAN wird benötigt!")
print(res.challenge)
tan = input('TAN:')
return self.client.send_tan(res, tan)
I can confirm that your code works with GLS Gemeinschaftsbank ( https://hbci-pintan.gad.de/cgi-bin/hbciservlet ) and that after entering the PIN all transactions are returned.
Probably your bank does this differently