igor-noskov/logging-soap-client

Decorator that allows you to log SOAP requests and responses. PSR-3 compatible.

Installs: 14

Dependents: 0

Suggesters: 0

Security: 0

Stars: 0

Watchers: 1

Forks: 0

Open Issues: 0

pkg:composer/igor-noskov/logging-soap-client

1.0.0 2019-11-22 15:48 UTC

This package is auto-updated.

Last update: 2025-12-23 05:13:56 UTC


README

Decorator that allows you to log SOAP requests and responses. PSR-3 compatible. You can use it, for example, with Monolog.

License

Requirements

  • PHP 7.1 or higher
  • Composer for installation

Installation

composer require "igor-noskov/logging-soap-client"

Usage

You can use it like this:

<?php

use IgorNoskov\LoggingSoapClient\LoggingSoapClient;
use Psr\Log\LoggerInterface;

class Foo
{
    public function doSomething(string $wsdl, LoggerInterface $logger)
    {
        $soapClient = new LoggingSoapClient(new SoapClient($wsdl, ['trace' => true]), $logger);

        // do something useful
    }
}