Error codes

Responses and error-handling

HTTPS Error

Every request processed through the SingleView APIs will have a response among the following:

✔️ Successful ❌ Unsuccessful ⚠️ Error

HTTP StatusDescriptionHandling
200Success
400Bad requestSpot the invalid parameters from the message and retry by entering valid details
401UnauthorizedRefresh session ID and try again
500Internal/server errorRetry later
504Time-outRetry later

MW Errors

These middleware error are designed to pinpoint issues in the API integration layer before they reach the main application logic.

{
  "correlationId": "2163bbf3-c6e1-4c0b-aac3-3b1b06552388",
  "bankCode": "",
  "errorCode": "MW-401",
  "errorMessage": "Authentication token has expired. Please re-authenticate.",
  "timeStamp": "2025-02-28T07:35:25.981+03:00"
}

Description

JSON TagDescriptionData Type
correlationIdUnique correlation identity parameter for each response of invalid access tokenString
bankCodeUnique bank identification codeAlphanumeric
errorCodeCode representing the error encounteredString
errorMessageMessage explaining the details about the error encounteredString
timeStampDate and time of the errorDate

Error Codes

errorCode

errorMessage

MW-400

Error occurs when one or more inputs in the header are missing:

  • `Required header 'Authorization' not specified
  • Required header 'CompanyId' not specified
  • Required header 'SVReferenceId' not specified
  • Required header 'Device' not specified
  • Required header 'DateTimeStamp' not specified

Error occurs when a mandatory field is missing the request body:

  • Required fields are missing in request body: Field Name

MW-401

This error occurs when authentication token is expired or an active token doesn't match the CompanyId mentioned in the header:

  • Authentication token has expired. Please re-authenticate.
  • Access denied. Token is not authorized for the specified CompanyId.

Error occurs if payload and signature doesn't match:

  • Signature and message does not match.

MW-403

Error occurs when a user tries to access a service that they does not have a subscription:

  • Unauthorized to access this service. Please contact singleview support team.

MW-404

Resource Not Found

MW-405

Requested Method not allowed

MW-406

Not acceptable

MW-415

Unsupported Media Type

MW-429

Too many requests received

MW-500

Technical error

MW-503

Service Unavailable

MW-504

Gateway Timeout

Certificate Error

This error occurs when there is an issue with TLS handshake.

{
  "error": "Client certificate and private key are required",
  "message": "Ensure that the request includes the client certificate issued by Singleview along with the corresponding private key."
}