Include data and status code when throwing an error in HttpApi

Sometimes applications need to do their own handling based on the response's code/data.