Added InvalidApiResponseException and upgraded response validation