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)
PLC | PLV |
---|---|
0 | 0 |
1 | 1 |
2 | 2 |
3 | 3 |
4 | 4 |
5 | 5 |
6 | 6 |
7 | 7 |
8 | 8 |
9 | 9 |
A | 10 |
B | 11 |
C | 12 |
D | 13 |
E | 14 |
F | 15 |
G | 16 |
H | 17 |
J | 18 |
K | 19 |
L | 20 |
M | 21 |
N | 22 |
P | 23 |
Q | 24 |
R | 25 |
T | 26 |
U | 27 |
V | 28 |
W | 29 |
X | 30 |
Y | 31 |
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:
Remainder | Check Character |
---|---|
0 | Y |
1 | X |
2 | W |
3 | T |
4 | L |
5 | K |
6 | J |
7 | H |
8 | F |
9 | B |
10 | A |
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.