PHPackages                             codebach/soap - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. codebach/soap

ActiveLibrary

codebach/soap
=============

Build and consume SOAP and WSDL based web services

v1.0(8y ago)04MITPHPPHP &gt;=5.3.0

Since Aug 9Pushed 8y ago1 watchersCompare

[ Source](https://github.com/codebach/soap)[ Packagist](https://packagist.org/packages/codebach/soap)[ RSS](/packages/codebach-soap/feed)WikiDiscussions master Synced 3d ago

READMEChangelog (1)Dependencies (7)Versions (1)Used By (0)

Extended Version of BeSimpleSoap
================================

[](#extended-version-of-besimplesoap)

Here you go, soap lovers. A lot of new features are extended to BesimpleSoap.

### New Features (Configurations)

[](#new-features-configurations)

#### SoapClient

[](#soapclient)

- Loading wsdl locally and using different url to make request (not to local wsdl file)
- Basic Http Authentication Support

#### SoapServer

[](#soapserver)

- Document-Wrapped support
- Configurable wsdl definition name attribute
- Ws Security with signing the response
- Multiple namespace support

### Installation

[](#installation)

Tell composer to install

```
composer require codebach/soap
```

### Usage

[](#usage)

Example full configuration:

```
be_simple_soap:
    clients:
        # Wsdl file and request url same place (Basic Usage)
        FooService:
            wsdl: wsdl_service_url

        # Wsdl file and request url different place
        BarService:
            wsdl: wsdl_file_to_load
            request_url:  url_to_make_soap_requests
            basic_http_auth:
                login: login
                password: password

    services:
        # Single Namespace (Basic Usage)
        FooServer:
            namespace:     namespace
            binding:       document-wrapped # Or rpc-literal
            version:       2
            resource:      "@FooBundle/Controller/FooController.php"
            resource_type: annotation
            cache_type:    none

        # Multiple Namespace
        BarServer:
            namespace:      namespace
            binding:        document-wrapped # Or rpc-literal
            version:        2
            resource:       '@BarBundle/Controller/BarController.php'
            resource_type:  annotation
            cache_type:     none
            target_name:    ns1 # Service definition name attribute
            public_key:     public_key_to_sign_response
            private_key:    private_key_to_sign_response
            namespace_types:
              - { name: 'ns2', url: name_space2_url}
              - { name: 'ns3', url: name_space3_url}
```

#### Multiple Namespace Usage

[](#multiple-namespace-usage)

To put the ComplexType in different (e.g: configured in yaml file above), use new Annotation class `BeSimple\SoapBundle\ServiceDefinition\Annotation\Type` and new parameter `target` of `BeSimple\SoapBundle\ServiceDefinition\Annotation\ComplexType` class

Make the server configuration:

```
be_simple_soap:
    services:
        FooServer:
            namespace:      default_namespace
            binding:        document-wrapped
            version:        2
            resource:       '@FooBundle/Controller/DefaultController.php'
            resource_type:  annotation
            cache_type:     none
            target_name:    ns1
            namespace_types:
              - { name: 'ns2', url: 'foo_namespace'}
              - { name: 'ns3', url: 'bar_namespace'}
```

Add Method:

```
use FooBundle\Server\SoapRequest;
use BeSimple\SoapBundle\ServiceDefinition\Annotation as Soap;
use Symfony\Bundle\FrameworkBundle\Controller\Controller;

class DefaultController extends Controller
{
    /**
     * @Soap\Method("soapRequest")
     * @Soap\Param("request", phpType = "FooBundle\Server\SoapRequest")
     * @Soap\Result("soapResponse", phpType = "FooBundle\Server\SoapResponse")
     */
    public function soapRequestAction(SoapRequest $request)
    {
    }
}
```

Bar.php

```
use BeSimple\SoapBundle\ServiceDefinition\Annotation as Soap;

/**
 * @Soap\Alias("Bar")
 * @Soap\Type("ns3")
 */
class Bar
{
    /**
     * @var string
     *
     * @Soap\ComplexType("string")
     */
    private $value;

    /**
     * @return string
     */
    public function getValue(): string
    {
        return $this->value;
    }

    /**
     * @param string $value
     */
    public function setValue(string $value)
    {
        $this->value = $value;
    }
}
```

Foo.php

```
use BeSimple\SoapBundle\ServiceDefinition\Annotation as Soap;

/**
 * @Soap\Alias("Foo")
 * @Soap\Type("ns2")
 */
class Foo
{
    /**
     * @var Bar
     *
     * @Soap\ComplexType("FooBundle\Server\Bar", target="ns3")
     */
    private $bar;

    /**
     * @return Bar
     */
    public function getBar(): Bar
    {
        return $this->bar;
    }

    /**
     * @param Bar $bar
     */
    public function setBar(Bar $bar)
    {
        $this->bar = $bar;
    }
}
```

SoapRequest.php

```
use BeSimple\SoapBundle\ServiceDefinition\Annotation as Soap;

/**
 * @Soap\Alias("SoapRequest")
 *
 * Default namespace is ns1
 */
class SoapRequest
{
    /**
     * @var Foo
     *
     * @Soap\ComplexType("FooBundle\Server\Foo", target="ns2")
     */
    private $foo;

    /**
     * @return Foo
     */
    public function getFoo(): Foo
    {
        return $this->foo;
    }

    /**
     * @param Foo $foo
     */
    public function setFoo(Foo $foo)
    {
        $this->foo = $foo;
    }
}
```

And here is the xml output of our server:

```

```

### Components

[](#components)

BeSimpleSoap consists of five components ...

#### BeSimpleSoapBundle

[](#besimplesoapbundle)

The BeSimpleSoapBundle is a Symfony2 bundle to build WSDL and SOAP based web services. For further information see the [README](https://github.com/codebach/Soap/blob/master/src/BeSimple/SoapBundle/README.md).

#### BeSimpleSoapClient

[](#besimplesoapclient)

The BeSimpleSoapClient is a component that extends the native PHP SoapClient with further features like SwA, MTOM and WS-Security. For further information see the [README](https://github.com/codebach/Soap/blob/master/src/BeSimple/SoapClient/README.md).

#### BeSimpleSoapCommon

[](#besimplesoapcommon)

The BeSimpleSoapCommon component contains functionylity shared by both the server and client implementations. For further information see the [README](https://github.com/codebach/Soap/blob/master/src/BeSimple/SoapCommon/README.md).

#### BeSimpleSoapServer

[](#besimplesoapserver)

The BeSimpleSoapServer is a component that extends the native PHP SoapServer with further features like SwA, MTOM and WS-Security. For further information see the [README](https://github.com/codebach/Soap/blob/master/src/BeSimple/SoapServer/README.md).

#### BeSimpleSoapWsdl

[](#besimplesoapwsdl)

For further information see the [README](https://github.com/codebach/Soap/blob/master/src/BeSimple/SoapWsdl/README.md).

###  Health Score

23

—

LowBetter than 27% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity3

Limited adoption so far

Community4

Small or concentrated contributor base

Maturity56

Maturing project, gaining track record

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Unknown

Total

1

Last Release

3201d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/e8a2ce15bcc7c7b8d989838dacde2eac3ebc602fcade0a939dbdd78cc1908a7b?d=identicon)[Codebach](/maintainers/Codebach)

---

Tags

soap

### Embed Badge

![Health badge](/badges/codebach-soap/health.svg)

```
[![Health](https://phpackages.com/badges/codebach-soap/health.svg)](https://phpackages.com/packages/codebach-soap)
```

###  Alternatives

[besimple/soap

Build and consume SOAP and WSDL based web services

112560.2k2](/packages/besimple-soap)[scheb/2fa

Two-factor authentication for Symfony applications (please use scheb/2fa-bundle to install)

578630.7k1](/packages/scheb-2fa)[besimple/soap-bundle

Build and consume SOAP and WSDL based web services with Symfony2

62200.1k2](/packages/besimple-soap-bundle)[shopware/core

Shopware platform is the core for all Shopware ecommerce products.

595.2M386](/packages/shopware-core)[jolicode/gif-exception-bundle

The GhostBuster of your exception page

20596.8k](/packages/jolicode-gif-exception-bundle)[sulu/skeleton

Project template for starting your new project based on the Sulu content management system

29733.3k](/packages/sulu-skeleton)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
