{"id":"npi-validate","version":"1.0.0","description":"Validate a 10-digit US National Provider Identifier using the Luhn formula with the constant 80840 healthcare prefix.","supported_operations":["validate a national provider identifier","check an npi check digit","is this npi number valid","verify a doctor's npi","npi luhn check 80840","check digit validation for a healthcare provider id"],"unsupported_operations":["a live NPPES registry lookup for the provider name or taxonomy","enforcing the Type 1 (starts with 1) / Type 2 (starts with 2) allocation policy","accepting hyphens, spaces or a labeled \"NPI:\" form (npi is taken exactly as given)"],"semantics":["npi is taken exactly as given: no stripping of spaces/hyphens, no case folding. Length != 10 returns reason wrong_length; length 10 but not all-digit returns reason invalid_character; both leave check_digit null.","check_digit = npi[9], populated once length and charset pass, regardless of validity.","Compute the Luhn check digit of the 14-digit payload '80840' + npi[0:9] (the constant prefix concatenated left of the 9-digit identifier part, never re-derived); compare it to check_digit for reason check_digit_mismatch.","No leading-digit restriction is enforced: only the Luhn check digit is validated."],"limits":{"max_npi_bytes":20},"pricing":{"status":"unpriced","charge_usd":null},"input_schema":{"type":"object","additionalProperties":false,"required":["npi"],"properties":{"npi":{"type":"string","minLength":1,"maxLength":20}}},"output_schema":{"type":"object","additionalProperties":false,"required":["valid","reason","check_digit"],"properties":{"valid":{"type":"boolean"},"reason":{"type":["string","null"],"enum":[null,"wrong_length","invalid_character","check_digit_mismatch"]},"check_digit":{"type":["string","null"],"pattern":"^[0-9]$"}}},"examples":[{"input":{"npi":"1234567893"},"output":{"valid":true,"reason":null,"check_digit":"3"}},{"input":{"npi":"1234567892"},"output":{"valid":false,"reason":"check_digit_mismatch","check_digit":"2"}},{"input":{"npi":"123456789"},"output":{"valid":false,"reason":"wrong_length","check_digit":null}}],"execute_url":"/v1/tools/npi-validate/versions/1.0.0/execute"}