Skip to content

[altabanka-rs] new auth flow and data API#1082

Open
flater1c wants to merge 1 commit into
zenmoney:masterfrom
flater1c:altabanka-rs-new-auth-flow
Open

[altabanka-rs] new auth flow and data API#1082
flater1c wants to merge 1 commit into
zenmoney:masterfrom
flater1c:altabanka-rs-new-auth-flow

Conversation

@flater1c

@flater1c flater1c commented Jun 24, 2026

Copy link
Copy Markdown

What

Updates the altabanka-rs plugin to the bank's new internet banking platform. The previous altabanka.24x7.rs HTML-scraping flow no longer works because the bank migrated to online.altabanka.rs (Holos) with a JSON API and a different login method.

Changes

  • Auth: login via username + one-time code (OTP) generated in the mobile app (no password anymore). Token obtained from GetEnvironmentVariables and sent as X-Holos-RequestToken. UserInteractionError is thrown when running in background.
  • Accounts: DataService.svc/GetAllAccountBalance.
  • Account operations: DataService.svc/GetTransactionalAccountTurnover (card rows excluded, they are taken from card turnover).
  • Card operations: DataService.svc/GetCardTurnover — provides the real transaction date and the original-currency amount; queried per currency. Foreign purchases keep the domestic RSD sum plus an original-currency invoice.
  • Pending authorizations: DataService.svc/GetTransactionalAccountReservedFunds imported as hold.
  • Plugin restructured to the fetchApi / api / parsers / converters / models layout; codeRequired set to true.
  • Tests reworked to JSON fixtures.

Testing

yarn test altabanka-rs passes (lint + types + 31 unit tests). Verified live against a real account via yarn start altabanka-rs: accounts, RSD/foreign card operations with real dates, refunds and pending authorizations.

Issue #1079

@flater1c flater1c changed the title altabanka-rs: new online.altabanka.rs auth flow and data API [altabanka-rs] new auth flow and data API Jun 24, 2026
Migrate from the retired altabanka.24x7.rs HTML scraping to the new
online.altabanka.rs (Holos) JSON API:

- Login via username + one-time code (OTP) from the mobile app;
  UserInteractionError when running in background.
- Accounts from GetAllAccountBalance; account operations from
  GetTransactionalAccountTurnover (card rows excluded).
- Card operations from GetCardTurnover (real transaction date,
  original-currency invoice, per-currency queries).
- Pending authorizations from GetTransactionalAccountReservedFunds as hold.
- Tests updated to JSON fixtures.
@flater1c

Copy link
Copy Markdown
Author

Hello @skvav, may I ask you for a review please?
Thanks in advance

@dufflink

Copy link
Copy Markdown

@skvav
Please, review the pull request 🙏

@katrinio

Copy link
Copy Markdown

Hey! I just noticed this PR for the Alta Banka plugin fix. I was so desperate I almost started learning TypeScript myself 😄

The implementation looks really solid, and it covers a lot. I’m really looking forward to seeing it merged!

@skvav Since the current plugin is broken after the bank update, could you please take a look when you have a chance? I think it would help get the fix merged sooner.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants