try { // if(!empty($UserCode)){ $url = ''; $client = new \SoapClient($url); $userLogin = new \stdClass(); $userLogin->UserCode = ...