raise Error when api status code is 400