PHPackages                             pledg/sylius-payment-plugin - 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. [Payment Processing](/categories/payments)
4. /
5. pledg/sylius-payment-plugin

ActiveSylius-plugin[Payment Processing](/categories/payments)

pledg/sylius-payment-plugin
===========================

Payment Gateway Plugin using PledgBySofinco (Sylius 2.x)

3.0.1(2w ago)311.5k2[8 PRs](https://github.com/pledgcorporate/ecard-sylius/pulls)MITPHPPHP ^8.2CI failing

Since Jan 7Pushed 2w ago11 watchersCompare

[ Source](https://github.com/pledgcorporate/ecard-sylius)[ Packagist](https://packagist.org/packages/pledg/sylius-payment-plugin)[ RSS](/packages/pledg-sylius-payment-plugin/feed)WikiDiscussions main Synced today

READMEChangelog (8)Dependencies (65)Versions (41)Used By (0)

Sylius Payment Gateway Plugin using Pledg
=========================================

[](#sylius-payment-gateway-plugin-using-pledg)

Installation
------------

[](#installation)

1. Install the package (beware of which version of our plugin supports your version of Sylius)

```
    composer require pledg/sylius-payment-plugin
```

2. Import routes in one of your routing file or create a new one (like `config/routes/pledg_sylius_payment.yaml`)

```
    pledg_sylius_payment:
        resource: "@PledgSyliusPaymentPlugin/Resources/config/routing.yml"
        prefix: /pledg
```

3. If your Sylius version is &lt;1.14.0:

- Sandbox and production environment

    By default, plugin uses sandbox mode. You can configure it by specify the mode in your configuration files. For example if you only want to disable the sandbox mode for the production environment you just have to create a `config/packages/prod/pledg_sylius_payment_plugin.yaml` file with :

    ```
        pledg_sylius_payment:
            sandbox: false
    ```
- Add assets

    ```
    mkdir -p templates/bundles/SyliusAdminBundle/
    mkdir -p templates/bundles/SyliusShopBundle/
    cp -R vendor/pledg/sylius-payment-plugin/tests/Application/templates/bundles/SyliusAdminBundle/* templates/bundles/SyliusAdminBundle/
    cp -R vendor/pledg/sylius-payment-plugin/tests/Application/templates/bundles/SyliusShopBundle/* templates/bundles/SyliusShopBundle/
    ```
- Add state machine configuration

    Import the configuration in `_sylius.yaml` or your `pledg_sylius_payment_plugin.yaml` file :

    ```
    imports:
    - { resource: "@PledgSyliusPaymentPlugin/Resources/config/state_machine.yaml" }
    ```

4. Clear your cache in order to see translations

```
    bin/console c:c
```

Create your payment method
--------------------------

[](#create-your-payment-method)

Now you can use the plugin and create your first Pledg Payment method :

1. Select the PledgBySofinco Type
2. Fill all required fields (specially with your merchant id, secret and restricted countries). Don't forget to activate the method on your channel.

Pledg allows to use a payment method without a signature but the plugin does not allow it. So even in sandbox mode, the secret is required and exchanges will be signed.

How the plugin works ?
----------------------

[](#how-the-plugin-works-)

We use Payum and the Sylius payment workflow in order to redirect on the Pledg payment page. Pledg uses all the parameters already filled in order to avoid you to refill them again. If all mandatory parameters are filled, you just need to fill your banking information. Otherwise, you could potentially fill in your address and your phone number.

All parameters in this url are in a signature parameter corresponding to a JSON Web Token encoding with the HS256 algorithm.

The plugin reuses Payum in order to retrieve the result of the payment process.

We also have a webhook route for 2 types of Pledg notifications (Standard and Transfer mode). This 2 types are also signed : the first with a custom signature and the second with a JWT.

All the details (parameters, redirection url, pledg result, pledg errors, pledg notifications) are stored in the payment entity.

How to contribute ?
-------------------

[](#how-to-contribute-)

You just have to :

1. Retrieve the package
2. Launch `make env && make create-project` to create a new Sylius project
3. Launch `make install` to install the database
4. Launch `make deploy_pledg_plugin` to install the plugin in the container
5. Make a PR and check if the CI is green. Do not forget to upgrade the version number in the CHANGELOG.md and in the Pledg\\SyliusPaymentPlugin\\RedirectUrl\\ParamBuilder.php file.

The plugin does not (yet) use behat. To compensate this, we wrote unit tests with PHPUnit in a [classical way](https://github.com/testdouble/contributing-tests/wiki/Detroit-school-TDD).

###  Health Score

59

—

FairBetter than 98% of packages

Maintenance96

Actively maintained with recent releases

Popularity28

Limited adoption so far

Community20

Small or concentrated contributor base

Maturity78

Established project with proven stability

 Bus Factor1

Top contributor holds 81.9% of commits — single point of failure

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

Every ~82 days

Recently: every ~159 days

Total

25

Last Release

19d ago

Major Versions

1.1.8 → 2.0.02023-01-31

2.1.0 → 3.0.02026-06-08

PHP version history (5 changes)1.0.0PHP ^7.3

1.1.2PHP ^7.3 | ^8,0

2.0.0PHP ^7.4 | ^8,0

2.0.3PHP ^7.4 | ^8.0

3.0.0PHP ^8.2

### Community

Maintainers

![](https://www.gravatar.com/avatar/87753cd4cfb70aeebb290110913472804bec74011c0cd6b2b0c633dffe87ac16?d=identicon)[Pledg](/maintainers/Pledg)

![](https://avatars.githubusercontent.com/u/937901?v=4)[Fabien Salles](/maintainers/FabienSalles)[@FabienSalles](https://github.com/FabienSalles)

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

![](https://www.gravatar.com/avatar/18c9aaf735d2b4738922ac647b7316d24359f30ce8084609e4f7be5ebbab7e19?d=identicon)[etiennegaschet\_pledg](/maintainers/etiennegaschet_pledg)

---

Top Contributors

[![FabienSalles](https://avatars.githubusercontent.com/u/937901?v=4)](https://github.com/FabienSalles "FabienSalles (104 commits)")[![etiennegaschet](https://avatars.githubusercontent.com/u/4664325?v=4)](https://github.com/etiennegaschet "etiennegaschet (11 commits)")[![Kvn91](https://avatars.githubusercontent.com/u/5636731?v=4)](https://github.com/Kvn91 "Kvn91 (9 commits)")[![pledg-elefranc](https://avatars.githubusercontent.com/u/90066709?v=4)](https://github.com/pledg-elefranc "pledg-elefranc (2 commits)")[![benlienart](https://avatars.githubusercontent.com/u/7664692?v=4)](https://github.com/benlienart "benlienart (1 commits)")

---

Tags

syliuspaymentsylius-pluginpledg

###  Code Quality

TestsPHPUnit

Static AnalysisPHPStan

Type Coverage Yes

### Embed Badge

![Health badge](/badges/pledg-sylius-payment-plugin/health.svg)

```
[![Health](https://phpackages.com/badges/pledg-sylius-payment-plugin/health.svg)](https://phpackages.com/packages/pledg-sylius-payment-plugin)
```

###  Alternatives

[sylius/invoicing-plugin

Invoicing plugin for Sylius.

891.1M2](/packages/sylius-invoicing-plugin)[sylius/paypal-plugin

PayPal plugin for Sylius.

461.5M7](/packages/sylius-paypal-plugin)

PHPackages © 2026

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