Resolve errors
Smart Scanner uses HTTP response status codes to indicate the success or failure of your API requests. In general, there are three status code ranges you can expect:
2xx
success status codes confirm that your request worked as expected.4xx
error status codes indicate an error caused by the data provided (invalid request, invalid API key).5xx
error status codes are rare and indicate a problem on Smart Scanner’s server side.
You might have to deal with errors at some point when making API requests to Smart Scanner. Below is a list of possible errors that can be returned, along with additional information about how to resolve them.
Resolve a 400 error: Bad request
This error can result from any one of the following issues in your code:
- A required field or parameter is missing from the HTTP request.
- The value of the docType field is invalid.
- One or more fields in the request contain only whitespace.
- The request contains one or more unexpected parameters.
- The content field contains a file with an unsupported file type (currently, we support only JPEG and PDF).
- No supported financial information can be found in the document.
To fix these errors:
- Check the message field of the exception and adjust your request accordingly.
- Check our API documentation to see the number and valid values for required items.
- Check the quality of the file.
Resolve a 401 error: Invalid credentials
This error indicates that the API key you're using is either expired or invalid.
To fix this error please contact us.
Resolve a 5XX error: Server errors
Bankify monitors these errors to make them as rare as possible, but integrations should be able to handle them if they arise.