The api I'm calling returns a json object of validation errors with the HTTP code 400. I implemented the client using PHP's curl library, but on error curl_exec returns false. How can I get the response body on error?
Note that I am setting curl_setopt($curl, CURLOPT_RETURNTRANSFER, true);