Error codes

Error Response Format

When an error occurs, the API returns a structured JSON response:

{
  "statusCode": <integer>,  // HTTP status code (e.g., 400, 401, 500)
  "timestamp": "<ISO 8601>",  // Timestamp of the error occurrence
  "path": "<string>",  // API endpoint where the error occurred
  "message": "<string | array>"  // Error description (string for general errors, array for validation errors)
}

Example Responses

400 Bad Request

{
  "statusCode": 400,
  "timestamp": "2025-02-25T09:28:36.278Z",
  "path": "/v1/sub-wallet/create",
  "message": "Bad Request Exception"
}

422 Validation Error (Multiple Issues)

{
  "statusCode": 422,
  "timestamp": "2025-02-25T09:28:36.278Z",
  "path": "/v1/sub-wallet/create",
  "message": [
    "sub-walletId is required",
    "currency must be a valid ISO code",
    "amount must be a positive number"
  ]
}


Error codeStatusMeaning
400Bad request
401UnAuthorized
403Forbidden
404Not FoundResource not found. The url/data requested does not exist.
422UnProcessable Entity
429Too Many Requests
5XXServer Error