Skip to content

Commit

Permalink
Add example in README for CA
Browse files Browse the repository at this point in the history
  • Loading branch information
Vinay P committed Oct 18, 2018
1 parent cb4f9aa commit f945229
Showing 1 changed file with 18 additions and 0 deletions.
18 changes: 18 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -505,6 +505,7 @@ iban.branch_code # => "7507"
iban.account_number # => "1211203"
iban.iban # => "SE2680000000075071211203"

# Australia
iban = Ibandit::IBAN.new(
country_code: 'AU',
branch_code: '123-456', # 6 digit BSB number
Expand All @@ -519,6 +520,23 @@ iban.branch_code # => "123456"
iban.account_number # => "123456789"
iban.iban # => nil

# Canada
iban = Ibandit::IBAN.new(
country_code: 'CA',
bank_code: '0036', # 4 Financial Institution number
branch_code: '00063', # 5 digit Branch Transit number
account_number: '0123456' # 7 to 12 digits
)
iban.pseudo_iban # => "CAZZ003600063000000123456"
iban.iban # => nil

iban = Ibandit::IBAN.new('CAZZ003600063000000123456')
iban.country_code # => "CA"
iban.bank_code # => "0036"
iban.branch_code # => "00063"
iban.account_number # => "000000123456"
iban.iban # => nil

# New Zealand
iban = Ibandit::IBAN.new(
country_code: 'NZ',
Expand Down

0 comments on commit f945229

Please sign in to comment.