made web request redirect in apiwrapper