stdnum.isrc

ISRC (International Standard Recording Code).

The ISRC is an international standard code (ISO 3901) for uniquely identifying sound recordings and music video recordings.

More information:

>>> validate('US-SKG-19-12345')
'USSKG1912345'
>>> validate('XX-SKG-19-12345')
Traceback (most recent call last):
    ...
InvalidComponent: ...
stdnum.isrc.compact(number)

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

stdnum.isrc.format(number, separator='-')

Reformat the number to the standard presentation format.

stdnum.isrc.is_valid(number)

Check if the number provided is a valid ISRC.

stdnum.isrc.validate(number)

Check if the number provided is a valid ISRC. This checks the length, the alphabet, and the country code but does not check if the registrant code is known.