stdnum.se.vat

VAT (Moms, Mervärdesskatt, Swedish VAT number).

The Momsregistreringsnummer is used for VAT (Moms, Mervärdesskatt) purposes and consists of 12 digits of which the last two should be 01. The first 10 digits should have a valid Luhn checksum.

>>> compact('SE 123456789701')
'123456789701'
>>> is_valid('123456789701')
True
>>> is_valid('123456789101')  # invalid check digits
False
stdnum.se.vat.compact(number)

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

stdnum.se.vat.is_valid(number)

Checks to see if the number provided is a valid VAT number. This checks the length, formatting and check digit.

Previous topic

stdnum.ro.cnp

Next topic

stdnum.si.ddv