Open afieyudha opened 4 years ago
i have issue when use header with auth and get this messages ARERR [149] A user name must be supplied in the control record
this is my code
` $namespace = 'http://remedy-sit.telkomsigma.co.id/arsys/WSDL/public/10.210.30.74/HPD_IncidentInterface_WS?WSDL'; $name = 'AuthenticationInfo'; $data = array('userName' => 'xxx', 'password' => 'xxx', 'authentication'=>'', 'locale'=>'', 'timeZone'=>'');
$this->soapWrapper->add('CreateSession', function ($service) use ($namespace,$name,$data){ $service ->wsdl('http://remedy-sit.telkomsigma.co.id/arsys/WSDL/public/10.210.30.74/HPD_IncidentInterface_WS?WSDL') ->trace(true) ->header($namespace,$name,$data) ->options([ 'user_agent' => 'PHPSoapClient', // Add this as options 'userName' => 'xxx', 'password' => 'xxx' ]); }); $response = $this->soapWrapper->call('CreateSession.HelpDesk_Query_Service', [ 'Incident_Number' => 'INC000000012600', ]); var_dump($response); exit;`
Your options are wrong, remove them and it should work. see https://www.php.net/manual/en/soapclient.soapclient.php
@afieyudha did you solve this problem ? facing it now.
i have issue when use header with auth and get this messages ARERR [149] A user name must be supplied in the control record
this is my code
` $namespace = 'http://remedy-sit.telkomsigma.co.id/arsys/WSDL/public/10.210.30.74/HPD_IncidentInterface_WS?WSDL'; $name = 'AuthenticationInfo'; $data = array('userName' => 'xxx', 'password' => 'xxx', 'authentication'=>'', 'locale'=>'', 'timeZone'=>'');