Skip to content

A unified API for looking up and validating bank account details.

License

Notifications You must be signed in to change notification settings

fohlin/unified-bank-utils

Repository files navigation

unified-bank-utils

A unified API for looking up and validating bank account details. There are a lot of initiatives in this space, and a goal of this project is to provide curated and simple-as-possible use.

Usage

Sweden (SE) is the first locale to be supported.

var BankUtils = require('unified-bank-utils');
// Get a bank account object from clearing and account numbers:
var account = BankUtils.SE.account('9252', '0782455');

// Then do stuff like
account.validateClearingNumber() // true
account.bankName // 'SBAB'
account.validateAccountNumber() // true - valid for this bank
account.isValid() // true - since both of the above are true

// You can also access some functions without going through an account object
BankUtils.SE.getBankName('5177') // 'SEB'
BankUtils.SE.getBankName('8299-0') // 'Swedbank'

Library build

Please see the dist directory for a version of this project built as a standalone library, ready for execution in the browser. Note that it adds a global object window.BankUtils, and that the file is not minimized.

Tests

npm test

Acknowledgements

These projects are currently used:

Additional resources

Related projects:

About

A unified API for looking up and validating bank account details.

Resources

License

Stars

Watchers

Forks

Packages

No packages published