Validation suite tests for error responses
The validation suite tests your integration against a number of error demo_result values. Your integration should return the appropriate error responses to these tests.
The following error demo_result values are used:
ERROR_INVALID_CREDENTIALSERROR_ANY_PROVIDER_MESSAGEERROR_CONNECTION_TO_PROVIDERUHJWO_RWFG_FRJUKY_ZKBC_MQQKBQor any other random letter and underscore string
Depending on the error demo_result value, this determines which error response is expected.
The associated error response type for these errors are as follows:
ERROR_INVALID_CREDENTIALS→INVALID_CREDENTIALSERROR_ANY_PROVIDER_MESSAGE→PROVIDER_MESSAGEERROR_CONNECTION_TO_PROVIDER→PROVIDER_CONNECTIONUHJWO_RWFG_FRJUKY_ZKBC_MQQKBQ→UNSUPPORTED_DEMO_RESULT
Note that if the demo_result value is a random string, you should use the UNSUPPORTED_DEMO_RESULT error type response.
The response should be in the following format, with the error type set to the associated type to the error demo_result value.
Note
Despite being error responses, response codes should always be 200.
The following example response would be a valid response to the demo_result value of ERROR_ANY_PROVIDER_MESSAGE.
{
"errors": [
{
"type": "PROVIDER_MESSAGE",
"message": "API is not available at this time. Please try again later."
}
],
"warnings": []
}