Operator-Specific Parameter Validation#
In addition to general data type validation, some API endpoints may require operator-specific validations for certain parameters. These validations are performed to ensure that the provided data meets the operator's requirements. If a validation error occurs, the API will respond with details about the specific validation issue.Please note that you can find the expected operator-specific regex patterns in the "Operators" section of this documentation. Ensure that your requests adhere to these patterns to avoid validation errors and ensure smooth processing of your requests.
Regex Validation Example#
In cases where a parameter must match a specific regex pattern, the API response will follow this format:{
"success": false,
"message": "REGEX_NOT_MATCH",
"data": {
"regex": "^\\d{5,15}$",
"value": "123"
}
}
In this example, the API is expecting the "value" to match the regular expression pattern "^\d{5,15}$," which means it should consist of digits (0-9) and have a length between 5 and 15 characters. The "value" provided in the request, in this case, is "123," which does not match the expected pattern. As a result, the API responds with a "REGEX_NOT_MATCH" error message, including details about the expected regex pattern ("regex") and the provided value ("value").Please ensure that your requests meet the operator-specific validation requirements to avoid validation errors and ensure smooth processing of your requests.