stdnum.nl.bsn

BSN (Burgerservicenummer, the Dutch national identification number).

The BSN is a number with up to 9 digits (the leading 0’s are commonly left out) which is used as the Dutch national identification number.

>>> is_valid('111222333')
True
>>> is_valid('111252333')
False
>>> compact('1234.56.782')
'123456782'
>>> format('111222333')
'1112.22.333'
stdnum.nl.bsn.checksum(number)

Calculate the checksum over the number. A valid number should have a check digit of 0.

stdnum.nl.bsn.compact(number)

Convert the number to the minimal representation. This strips the number of any valid separators and removes surrounding whitespace.

stdnum.nl.bsn.format(number)

Reformat the passed number to the standard format.

stdnum.nl.bsn.is_valid(number)

Checks to see if the number provided is a valid BSN. This checks the length and whether the check digit is correct.

Previous topic

stdnum.mt.vat

Next topic

stdnum.nl.btw