Kernel 8.0 APIs Banner
Office of Information and Technology (OIT) Banner
[skip navigation]

$$CHKDGT^XUSNPI(): Validate NPI Format

Reference Type: Controlled Subscription, Category: National Provider Identifier (NPI), ICR#: 4532

Description

The $$CHKDGT^XUSNPI extrinsic function validates the format of a National Provider Identifier (NPI) number. It checks the following:

NOTE: This API was released with Kernel Patch XU*8.0*410.

Format

  $$CHKDGT^XUSNPI(xusnpi)

Input Parameters

xusnpi:

(required) The 10-digit National Provider Identifier (NPI) number to validate. No default.

Output

returns:

Returns:

  • 1—If check digit is valid. The NPI number must be 10-digits long

  • 0—If check digit is not valid.

Examples

Example 1

The following example shows the result when checking a valid NPI:

>W $$CHKDGT^XUSNPI(1234567893)
1

Example 2

The following example shows the result when checking an invalid NPI (not 10 digits):

>W $$CHKDGT^XUSNPI(123456789)
0

Example 3

The following example shows the result when checking an invalid NPI (invalid digit):

>W $$CHKDGT^XUSNPI(1234567892)
0