US documents
The United States document types in the Constaia catalogue, PDF417 (AAMVA) barcode reading on driver's licenses, Form I-9 lists, and validation of SSN, EIN and other identifiers.
The Constaia catalogue includes 31 United States-specific types (and 5 Canadian ones) on top of the universal ones,
such as the ICAO passport. You use them like any other: pass them in expect and you get a verdict with its reasons,
the extracted fields and each type's deterministic checks.
curl -s 'https://api.constaia.com/v1/document-types?country=USA&strict=true&language=en' \
| jq -r '.data[] | "\(.type)\t\(.label)"'Without strict=true the list also includes the universal types (passport, invoice…). Fields, validators and
checks for each type: GET /v1/document-types or the
full catalogue.
Which types there are
| Group | Types |
|---|---|
| Driving and identity | us_driver_license, us_state_id (50 states and DC, with PDF417), us_passport_book, us_passport_card, us_military_id, us_school_id, us_voter_registration_card, us_tribal_document, us_citizen_id_card, us_resident_citizen_id_card |
| Immigration and work | us_permanent_resident_card (Green Card), us_ead (I-766), us_foreign_passport_i551, us_i94, us_i9_form |
| Vital records and Social Security | us_birth_certificate, us_consular_birth_report, us_ssn_card |
| Health | us_medicare_card, us_health_insurance_card |
| Tax | us_w9, us_w2, us_1099_nec, us_1099_misc, us_1099_int, us_irs_ein_letter |
| Income, banking and address | us_paystub, us_bank_statement, us_utility_bill |
| Insurance and vehicles | acord_25, us_vehicle_registration |
| Canada | ca_driver_licence, ca_photo_id_card, ca_pr_card, ca_sin, ca_health_card |
Driver's licenses and state IDs: the PDF417 barcode
The back of a US driver's license or state ID (and of Canadian licences) carries a PDF417 barcode with the holder's data in the AAMVA standard. Constaia reads it on its own servers, without sending it to any AI provider and at no extra cost, and:
- fills in any missing fields from it (number, name, dates, address…);
- cross-checks it with the printed front: number, first name, last name, date of birth and expiry. The result is the
aamva_matches_visualcheck; if something doesn't match, it fails, the affected fields getvalidated: falseand the verdict becomesinvalid; - validates the license number format for the issuing state (
issuing_state) and the ZIP code (id_number_format).
For it to be read, the file must include the back: one image with both sides or a two-page PDF (still 1 credit).
The widget with sides="2" captures both sides and joins them. If only the front arrives, there is
no aamva_matches_visual and everything else works the same.
curl https://api.constaia.com/v1/analyze \
-H "Authorization: Bearer $CONSTAIA_API_KEY" \
-F file=@driver_license_both_sides.jpg \
-F 'options={"expect":["us_driver_license","us_state_id"],"checks":{"min_age_years":21},"language":"en"}'{
"document": { "type": "us_driver_license", "label": "US driver's license", "country": "USA" },
"verdict": {
"status": "valid",
"reasons": [
{ "code": "type_match", "severity": "info", "message": "The document is US driver's license." },
{ "code": "not_expired", "severity": "info", "message": "Valid until 30/07/2031." },
{ "code": "age", "severity": "info", "message": "The holder is 41 years old." },
{ "code": "i9_list", "severity": "info", "message": "Acceptable Form I-9 document: List B." }
]
},
"checks": [
{ "code": "id_number_format", "passed": true, "message": "Identifier document_number (us_dl) is valid." },
{ "code": "id_number_format", "passed": true, "message": "Identifier postal_code (us_zip) is valid." },
{ "code": "aamva_matches_visual", "passed": true, "message": "The PDF417 barcode (AAMVA v10) was read and matches the printed data." }
]
}The fields include issuing_state, document_number, first_name, middle_name, last_name, birth_date,
issue_date, expiry_date, address, postal_code, real_id_compliant, class, restrictions, endorsements,
commercial and barcode_data (the PDF417 text). Expiry is checked by default. Full guide:
Verify a US driver's license.
Form I-9: Lists A, B and C
Types that can be used for Form I-9 show their list in i9_lists (["A"], ["B"], ["C"] or ["B","C"]) in the
catalogue, and when analysed with expect they add an informational reason:
{ "code": "i9_list", "severity": "info", "message": "Acceptable Form I-9 document: List A." }| List | Types |
|---|---|
| A | us_passport_book, us_passport_card, us_permanent_resident_card, us_foreign_passport_i551, us_ead, us_i94 |
| B | us_driver_license, us_state_id, us_school_id, us_voter_registration_card, us_military_id, us_tribal_document, ca_driver_licence |
| C | us_ssn_card, us_birth_certificate, us_consular_birth_report, us_tribal_document, us_citizen_id_card, us_resident_citizen_id_card |
Constaia tags the list; whether the combination is complete (one List A document, or one from List B plus one from List C) is up to your code, and the employer remains responsible for the form. There is no E-Verify integration. Full guide: Form I-9 documents.
US identifiers
These identifiers are validated deterministically (no AI) on the types that carry them. Only the format or check digit is checked: Constaia never queries the SSA, the IRS or USCIS.
| Scheme | What it validates | Where |
|---|---|---|
us_dl | License number format for the issuing state | us_driver_license, us_state_id |
us_ssn | SSN format (valid area, group and serial) | us_ssn_card, us_w9, us_w2, 1099, us_i9_form |
us_ein | EIN format (valid IRS prefix) | us_w9, us_w2, 1099, us_irs_ein_letter |
us_uscis | USCIS number / A-Number | us_permanent_resident_card, us_ead, us_foreign_passport_i551, us_i9_form |
us_mbi | Medicare Beneficiary Identifier | us_medicare_card |
us_aba | Bank routing number (ABA) check digit | us_bank_statement |
us_zip | 5- or 9-digit ZIP code | licenses, W-9, statements, bills, EIN letter, vehicle registration |
The result goes in checks[] as id_number_format or id_number_checksum. On some types the identifier is marked as
soft (for example the SSN on a W-2 or a 1099, which is often masked): its failure gives a reason with warning and
leads to review instead of invalid. Which schemes each type has is listed in field_validators in the catalogue.
Testing
With a ck_test_ key there are no US scenarios: a US document returns the generic type and, with expect, a
review verdict with type_unknown. To see the US types for real, use a live key: the month's 150 free credits are
enough (free credits in live mode require a verified email). See Test mode.
Where data is processed
Today every document, including those from US customers, is processed and stored in the EU, and processing.region is
eu. Constaia does no biometrics and doesn't query public records (DMV, IRS, SSA, E-Verify). Notes on DPPA, CCPA,
GLBA/FCRA and biometric laws in Data residency & compliance.
Coming soon: US region
A US processing region is planned, with no date yet. Watch the changelog.
Guides
Driver's license
Age, validity and PDF417 for sign-ups and rentals.
Form I-9
List A, B and C documents and a Section 2 draft.
Contractor W-9
Collect and validate W-9s from vendors and freelancers.
Income verification
Pay stubs and bank statements in one application.
ACORD 25 certificate
Liability insurance for vendors and subcontractors.
Proof of address
Recent utility bills and bank statements.
Human review
What to do with the review verdict. Why it happens, receiving it by webhook, building a review queue, recording the decision and asking for a new photo.
Verify a US driver's license
Verify a US driver's license or state ID with the PDF417 barcode (AAMVA), each state's license number format, expiration and minimum age, with Node or Python.