stdnum.us.atin

ATIN (U.S. Adoption Taxpayer Identification Number).

An Adoption Taxpayer Identification Number (ATIN) is a temporary nine-digit number issued by the United States IRS for a child for whom the adopting parents cannot obtain a Social Security Number.

>>> validate('123-45-6789')
'123456789'
>>> validate('1234-56789')  # dash in the wrong place
Traceback (most recent call last):
    ...
InvalidFormat: ...
>>> format('123456789')
'123-45-6789'
Traceback (most recent call last):
    ...
InvalidFormat: ...
stdnum.us.atin.compact(number)

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

stdnum.us.atin.format(number)

Reformat the passed number to the standard format.

stdnum.us.atin.is_valid(number)

Checks to see if the number provided is a valid ATIN. This checks the length and formatting if it is present.

stdnum.us.atin.validate(number)

Checks to see if the number provided is a valid ATIN. This checks the length and formatting if it is present.

Previous topic

stdnum.sm.coe

Next topic

stdnum.us.ein