laravel-soap: Server was unable to process request. Object reference not set to an instance of an object.

Hello, i use laravel 5.6 running under PHP 7.2.3 and i’ve got the following error exception generated by laravel-soap library: SoapFault | Arguments | Server was unable to process request. —> Object reference not set to an instance of an object.

Here is my code:

$this->soapWrapper->add('Piraeus', function ($service){

      $service
      ->wsdl('https://paycenter.piraeusbank.gr/services/tickets/issuer.asmx?WSDL')
      ->trace(true);

});

$params = array(

      //HIDING PARAMETERS VALUE WITH ASTERISK FOR SECURITY REASONS

      'Request' => array(

        'Username'          => "*******",
        'Password'          => md5('*******'),
        'MerchantId'        => *******,
        'PosId'             => *******,
        'AcquirerId'        => *******,
        'MerchantReference' => '*******',
        'RequestType'       => '*******',
        'ExpirePreauth'     => *******,
        'Amount'            => *******,
        'CurrencyCode'      => *******,
        'Installments'      => *******,
        'Bnpl'              => *******,
        'Parameters'        => '*******'

      )

);

$result = $this->soapWrapper->call(

      'Piraeus.IssueNewTicket',
      ['Request' => $params]

);

var_dump($result);

About this issue

Most upvoted comments

@devateminent Check this 😉

public function myFun() {

    $soapWrapper = new \Artisaninweb\SoapWrapper\SoapWrapper;

    $client = $soapWrapper->add('Domain', function ($service) {

      $service
      ->wsdl('https://domains.livedns.co.il/API/DomainsAPI.asmx?WSDL')
      ->trace(true);

    });

    $params = [

      'DomainName' => 'greetingsfromgreece.com' // :) 

    ];

    $response = $soapWrapper->call(

      'Domain.Whois',
      ['op' => $params]

    );

    var_dump($response);

  }