Modaltrans uses conventional HTTP response codes to indicate the success or failure of an API request. In general:Codes in the 2xx range indicate success.
4xx errors indicate client-side issues where the request made by the client is incorrect or cannot be fulfilled by the server. These errors suggest that the problem lies with the client’s request, such as incorrect syntax, invalid authentication, or lack of necessary permissions.
Codes in the 5xx range indicate an error with Modaltrans’ servers.
Error Responses
In the event of an error during any process, the system will provide an error response in JSON format. This response includes a JSON object that outlines the errors encountered. Below is an example of the structure of such an error response:Error codes#
This section provides an overview of common error codes you might encounter when using the API. For each error code listed, you'll find its probable cause and suggested solutions.500 - Internal Server Error
Cause : The reason for a 400 response is typically due to malformed request syntax, invalid request message framing, or deceptive request routing.
Ensure that the request syntax is correct according to the API specifications.
Ensure that all fields in the request are of the correct data types as specified in the API documentation.
Modified at 2024-09-09 13:27:45