When making API calls to the MassPay service, you may encounter error messages in the response indicating that something has gone wrong. These error messages are accompanied by HTTP status codes that indicate the type of error that has occurred. Here's what each of these status codes means and what you should do if you encounter them:
Error number | Error title | Error description | What should I do? |
---|---|---|---|
400 | Bad Request | This error message indicates that the request you made to the API was malformed or invalid. This could be due to missing required parameters, parameters that were not formatted correctly, or invalid data in the parameters. | When you receive a 400 error message, you should check your request and ensure that all required parameters are included and that they are formatted correctly. |
401 | Unauthorized | This error message indicates that your request was either invalid or that you did not have the proper authorization to access the requested resource. The server needs authentication, but the given credentials were either incomplete or incorrect. | When you receive a 401 error message, you should check your authentication credentials and ensure that they are correct, up-to-date, and properly formatted. Additionally, verify that you have the necessary permissions or privileges to access the requested resource. |
403 | Forbiden | This error message indicates that the request you made was valid, but you do not have permission to access the requested resource. This could be due to invalid credentials or insufficient permissions. | When you receive a 403 error message, you should check your authentication credentials and ensure that you have the necessary permissions to access the requested resource. |
404 | Not found | This error message indicates that the resource you requested could not be found. This could be due to an incorrect URL or a resource that no longer exists. | When you receive a 404 error message, you should check the URL and ensure that it is correct. |
405 | Method Not Allowed | This error message indicates that REST API method you used in your request is not supported for the requested resource. | When you receive a 405 error message, you should check the HTTP method used in your request and ensure that it is supported for the requested resource. |
500 | Gateway Time-out | This error message indicates that while processing the request, the server experienced an unexpected condition. It implies that the server was unable to process the request because of an internal error or malfunction. | When you receive a 500 error message, retry the request after a short interval. If the error persists, contact the server administrator or support team. |
504 | Gateway Time-out | This error message indicates that the server processing your request did not receive a timely response from an upstream server it needed to complete the request. | When you receive a 504 error message, you should try your request again later. |
In general, when you encounter error messages in MassPay API calls, it's important to carefully review the error message and associated status code to determine the cause of the error. From there, you can take appropriate steps to resolve the issue, which may include checking your request or reviewing documentation.
In case of any problem you can contact us at [email protected]. We are here to help you!