Validations and Checks

Validations and Checks #

You may want to implement these checks in your software to ensure that Medicare cards, provider numbers and DVA file numbers are correctly entered prior to submitting requests to the API.

Medicare Card Validation #

The following algorithm is applied to check that a Medicare card is valid.

Medicare Check Digit Routine:

  • (Digit 1) +
  • (Digit2*3)+
  • (Digit3*7)+
  • (Digit4*9)+
  • (Digit 5) +
  • (Digit6*3)+
  • (Digit7*7)+
  • (Digit 8 * 9)
  • Divide the total by 10
  • The remainder is the Check Digit.

Note: The check digit becomes the 9th digit in the Medicare Card number. The 10th digit is the Medicare Card issue number and must not be zero.

Provider Number Validation #

A practitioner may have one or more provider numbers, usually one for each location they work in. Facilities also have provider numbers.

A Provider Number is comprised of:

  • A Provider Stem - a 6-digit number, unique to the provider
  • 1 Practice Location Character which has a corresponding Practice Location Value (PLV)
  • 1 Check Character (see algorithm below)

The Practice Location Character indicates the order of the practices that a provider has been registered at. Each Practice Location Character is allocated a Practice Location Value (PLV) that is used in the Provider Check Digit Routine. (note that the characters I, O and S are never used as PLCs)

PLCPLV
00
11
22
33
44
55
66
77
88
99
A10
B11
C12
D13
E14
F15
G16
H17
J18
K19
L20
M21
N22
P23
Q24
R25
T26
U27
V28
W29
X30
Y31

The algorithm used for the Provider Check Digit is:

  • (digit 1 * 3) +
  • (digit 2 * 5) +
  • (digit 3 * 8) +
  • (digit 4 * 4) +
  • (digit 5 * 2) +
  • (digit 6) +
  • (PLV * 6)
  • Divide the result by 11 The remainder is allocated an alpha that is the provider check character (See table below for details). The check characters for the resultant remainder are as follows:
RemainderCheck Character
0Y
1X
2W
3T
4L
5K
6J
7H
8F
9B
10A

DVA File Number Validation #

The DVA file number is 3 to 9 Characters in total.

  • The first character is the state code (an alphabetic character) - N, V, Q, W, S or T for the appropriate state/territory. Australian Capital Territory is included in New South Wales (N) and Northern Territory with South Australia (S).
  • The next characters are the war code of 1-3 characters followed by the digits of the file number, which together have a maximum length of 7
  • For dependents of veterans, the last character is always an alphabetic character. The alphabetic code is generated in the order by which the cards are issued. For example A, B, C, D etc.