# stdnum.me.pib

PIB (Poreski Identifikacioni Broj, Montenegro tax number).

This number consists of 8 digits.

More information:

- http://www.pretraga.crps.me:8083/

- https://www.vatify.eu/montenegro-vat-number.html

    >>> validate('02655284')
    '02655284'
    >>> validate('02655283')
    Traceback (most recent call last):
        ...
    InvalidChecksum: ...
    >>> format('02655284')
    '02655284'

stdnum.me.pib.calc_check_digit(number: str) → str

  Calculate the check digit for the number.

stdnum.me.pib.compact(number: str) → str

  Convert the number to the minimal representation.

  This strips the number of any valid separators and removes surrounding whitespace.

stdnum.me.pib.format(number: str) → str

  Reformat the number to the standard presentation format.

stdnum.me.pib.is_valid(number: str) → bool

  Check if the number is a valid Montenegro PIB number.

stdnum.me.pib.validate(number: str) → str

  Check if the number is a valid Montenegro PIB number.