An asynchronous SOAP client build on top of Guzzle. The SoapClient
implements meng-tian/php-async-soap.
PHP 7.1 --enablelibxml --enable-soap
composer require meng-tian/async-soap-guzzle
use GuzzleHttp\Client;
use Meng\AsyncSoap\Guzzle\Factory;
use Laminas\Diactoros\RequestFactory;
use Laminas\Diactoros\StreamFactory;
$factory = new Factory();
$client = $factory->create(new Client(), new StreamFactory(), new RequestFactory(), 'http://www.webservicex.net/Statistics.asmx?WSDL');
// async call
$promise = $client->callAsync('GetStatistics', [['X' => [1,2,3]]]);
$result = $promise->wait();
// sync call
$result = $client->call('GetStatistics', [['X' => [1,2,3]]]);
// magic method
$promise = $client->GetStatistics(['X' => [1,2,3]]);
$result = $promise->wait();
This library is released under MIT license.