Skip to content

barisbalic/modulus

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

6 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

THIS PROJECT IS NOWHERE NEAR READY FOR USE, COME BACK LATER.

Modulus

Modulus allows you to validate bank account numbers (UK ones specifically), using the MOD10, MOD11 and Double Alternative check algorithms and data freely provided by VocaLink, see related links below for more information.

The data is imported into Redis with the commands provided, and can be updated with files from VocaLink in their existing format. All you have to do is download them and run the import scripts, you should always import both the weighting and substitute tables when updating your data.

Caveats:

  • Just because an account is valid doesn't mean that it is in use.
  • If an account belongs to a financial institution not listed by VocaLink it is assumed to be valid as per their specification.
  • An account that cannot be found will raise a SortcodeNotFound exception, which you can handle as you wish.

Installation

Add this line to your application's Gemfile:

gem 'modulus'

And then execute:

$ bundle

Or install it yourself as:

$ gem install modulus

Usage

valid = Modulus.check('######', '########')

Commandline Interface (for imports)

modulus
  -r  --redis [host:port]
  -w  --weight-table [file]
  -s  --substitute-table [file]

Related Links

Contributing

  1. Fork it
  2. Create your feature branch (git checkout -b my-new-feature)
  3. Commit your changes (git commit -am 'Added some feature')
  4. Push to the branch (git push origin my-new-feature)
  5. Create new Pull Request

About

Modulus checking for UK bank accounts.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages