Now handle more error cases. Throw malformed response exception for times when the json we get back is non-compliant with the documentation. Also provide helper methods on the response object to better identify the problem.