Validation Errors

Should there be an issue with the order submission, or if you have used the validate order endpoint, then as well as the HTTP response code, the body of the response will contain an isValid boolean value and an array of validation errors describing any problems.

KEY DESCRIPTION
MESSAGE This is the description of the error message and contains guidance of how rectify it.
FIELDPATH This provides a path to where in the order submission body the error occurred.
ERRORLEVEL If the value is 0, then this is an error which stops the order from being placed.

Example validation errors:

        
{
    "isValid": false,
    "validationErrors": [
        {
            "message": "Name must contain only letters and spaces, and must start and end with a letter",
            "fieldPath": "Candidate.CurrentName.MiddleNames",
            "errorLevel": 0
        }
    ]
}
        
    

Common errors

A lot of the validation messages that you will receive are specific and descriptive to enable you to understand the issues. Below are some common, standard messages that you may come across and what they mean:

DefaultMandatoryValidationProvider

This indicates that a field that is mandatory is missing for the submission body.

Other examples of error messages relating to missing mandatory fields are:

  • BooleanMandatoryValidationProvider
  • DateMandatoryValidationProvider
  • StringArrayMandatoryValidationProvider

GenderLockedTitleValidationProvider

This indicates that the supplied title (i.e. Mr, Mrs) is gender locked and does not match the supplied gender.

To fix this you will need to change the title or gender.

EnumValidationProvider

The enum validation provides will return an error message when the value supplied does not match a value in the value set.

To fix this, review the value set for the field in question and update the value to match.

ImplicitEmailTypeValidationProvider

This indicates that the supplied value cannot is not a valid email address. To fix this, check the rules on what we will accept as a valid email address.

Other examples of similar validators include:

  • ImplicitPhoneNumberTypeValidationProvider
  • ImplicitWebUrlTypeValidationProvider
  • ImplicitPartialDateTypeValidationProvider
  • ImplicitGuidTypeValidationProvider
  • ImplicitDateTypeValidationProvider

RangeCharactersValidationProvider

This indicates that the supplied string value exceeds the maximum number or is below the minimum number of character allowed for this field.

Other examples of range validators include:

  • RangeDateValidationProvider
  • RangeElementValidationProvider
  • CombinedRangeValidationProvider

DefaultMustBeEmptyValidationProvider

This indicates that the field for which you have attempted to supply a value is read only and will not accept a value.

MaximumCheckAmountValidationProvider

This means that you have attempted to supply more than the maximum number of checks allowed of that type in a single order.

DbsIdentityDocsValidationProvider

This means that at least 1 of the following is true:

  • One or more of the identity documents supplied is not valid for this candidate
  • The combination of documents supplied does not match a valid route, as set out by the DBS
  • The supplied purpose of check or job role is not valid

JobRolesValidationProvider

This indicates that the supplied job role ID does not match a valid job role for the check type requested.