PHPackages                             synolia/sylius-gdpr-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. [Utility &amp; Helpers](/categories/utility)
4. /
5. synolia/sylius-gdpr-plugin

ActiveSylius-plugin[Utility &amp; Helpers](/categories/utility)

synolia/sylius-gdpr-plugin
==========================

Synolia sylius GDPR plugin.

v2.0.0(1y ago)20148.1k—1.5%10[1 issues](https://github.com/synolia/SyliusGDPRPlugin/issues)EUPL-1.2PHPPHP ^8.2CI passing

Since Jul 13Pushed 1y ago11 watchersCompare

[ Source](https://github.com/synolia/SyliusGDPRPlugin)[ Packagist](https://packagist.org/packages/synolia/sylius-gdpr-plugin)[ RSS](/packages/synolia-sylius-gdpr-plugin/feed)WikiDiscussions main Synced 1mo ago

READMEChangelog (10)Dependencies (24)Versions (16)Used By (0)

[![License](https://camo.githubusercontent.com/6915efddd2b3616c07afd37cda2035aa41f7a10bab3f963eb81c8e309fcd2f3e/68747470733a2f2f62616467656e2e6e65742f6769746875622f6c6963656e73652f73796e6f6c69612f53796c69757347445052506c7567696e)](https://github.com/synolia/SyliusGDPRPlugin/blob/master/LICENSE)[![CI - Analysis](https://github.com/synolia/SyliusGDPRPlugin/actions/workflows/analysis.yaml/badge.svg?branch=master)](https://github.com/synolia/SyliusGDPRPlugin/actions/workflows/analysis.yaml)[![CI - Sylius](https://github.com/synolia/SyliusGDPRPlugin/actions/workflows/sylius.yaml/badge.svg?branch=master)](https://github.com/synolia/SyliusGDPRPlugin/actions/workflows/sylius.yaml)[![Version](https://camo.githubusercontent.com/bb1517395a32db78ecdf93d21c9f87c9f15e5e1839cb61488ff9972fc31ff536/68747470733a2f2f62616467656e2e6e65742f6769746875622f7461672f73796e6f6c69612f53796c69757347445052506c7567696e3f6c6162656c3d56657273696f6e)](https://packagist.org/packages/synolia/sylius-gdpr-plugin)[![Total Downloads](https://camo.githubusercontent.com/7f305569c9f4b68478a800740867a4f29fa594844111d21072bf91cc919dee1d/68747470733a2f2f706f7365722e707567782e6f72672f73796e6f6c69612f73796c6975732d676470722d706c7567696e2f646f776e6c6f616473)](https://packagist.org/packages/synolia/sylius-gdpr-plugin)

 [ ![](https://camo.githubusercontent.com/1567208cc7c8ec53cf6e2af4f54449a9bb3ab0dee7916998de4e3ce9b7f79015/68747470733a2f2f64656d6f2e73796c6975732e636f6d2f6173736574732f73686f702f696d672f6c6f676f2e706e67) ](https://sylius.com)

Sylius GDPR Plugin
==================

[](#sylius-gdpr-plugin)

[![Capture](/etc/capture.png "Capture")](/etc/capture.png)

Features
--------

[](#features)

- Anonymize customer with the GDPR section in the admin customer show.
- Export customer data with the GDPR section in the admin customer show.

[Click to see the anonymization configuration](ANONYMIZE_CONFIGURATION.md).

[Click to see the export data configuration](EXPORT_CONFIGURATION.md).

- Anonymize any entity with command for example :

```
php bin/console synolia:gdpr:anonymize --entity='Sylius\Component\Core\Model\Customer' --id=1
```

Use --help to get more informations

Requirements
------------

[](#requirements)

VersionPHP^8.2Sylius^2.0Installation
------------

[](#installation)

1. Add the bundle and dependencies in your composer.json :

    ```
    composer require synolia/sylius-gdpr-plugin --no-scripts
    ```
2. Create required config in `config/packages/gdpr.yaml` file:

    ```
    imports:
        - { resource: "@SynoliaSyliusGDPRPlugin/Resources/config/app/config.yaml" }
    ```
3. Create routing in `config/routes/gdpr.yaml` file:

    ```
    synolia_gdpr:
        resource: "@SynoliaSyliusGDPRPlugin/Resources/config/routes.yaml"
        prefix: '/%sylius_admin.path_name%'
    ```
4. Process translations

    ```
    php bin/console translation:extract en SynoliaSyliusGDPRPlugin --dump-messages
    php bin/console translation:extract fr SynoliaSyliusGDPRPlugin --dump-messages
    ```
5. Clear cache

    ```
    php bin/console cache:clear
    ```

Add anonymization configuration
-------------------------------

[](#add-anonymization-configuration)

```
synolia_sylius_gdpr:
   disable_default_mappings: false # False by default
   anonymization:
       mappings:
           paths:
               - # Your\Paths\To\Mappings\Directory
```

Example of configuration

```
Sylius\Component\Core\Model\Address: # Your class path
  properties:
     firstName:
        faker: text # let's see => https://fakerphp.github.io/formatters/
        args: [20] # The associated faker arguments
        prefix: 'anonymized-'
     lastName:
        value: 'Fake lastName'
        prefix: 'anonymized-'
```

`value` can be null, an array, an int, a string and an [expression language](https://symfony.com/doc/current/reference/formats/expression_language.html)

Example of configuration with dynamic value

```
Sylius\Component\Core\Model\Customer:
   properties:
      firstName:
          value: '@="some-arbitrary-text..." ~ object.getId() ~ "...more-arbitrary-text"'
```

### Note:

[](#note)

> your expression language must starts with `@=` to be evaluated properly

> variable `object` is the current entity you are dealing with (e.g. in that case `Sylius\Component\Core\Model\Customer`)

Add form in advanced actions page
---------------------------------

[](#add-form-in-advanced-actions-page)

There's two steps to add your custom form into the page:

- Override the controller service by setting the link of your FormType in the $formsType variable

```
   Synolia\SyliusGDPRPlugin\Controller\AdvancedActionsController:
       arguments:
           $formsType:
               - 'Synolia\SyliusGDPRPlugin\Form\Type\Actions\AnonymizeCustomerNotLoggedSinceType'
       tags: ['controller.service_arguments']
```

> or use php attributes `#[AsController]` on your controller and `#[Autowire(AnonymizeCustomerNotLoggedSinceType::class)]` in your constructor for `$formsType` parameter

- Then create your form processor by implementing Synolia\\SyliusGDPRPlugin\\Processor\\AnonymizerProcessor\\AdvancedActionsFormDataProcessorInterface

[There](src/Processor/AdvancedActions/AnonymizeCustomersNotLoggedBeforeProcessor.php) a form processor example

### Events

[](#events)

- Synolia\\SyliusGDPRPlugin\\Event\\BeforeAnonymize
- Synolia\\SyliusGDPRPlugin\\Event\\AfterAnonymize
- Synolia\\SyliusGDPRPlugin\\Event\\BeforeCustomerAnonymize
- Synolia\\SyliusGDPRPlugin\\Event\\AfterCustomerAnonymize
- Synolia\\SyliusGDPRPlugin\\Event\\BeforeExportCustomerData

Development
-----------

[](#development)

See [How to contribute](CONTRIBUTING.md).

License
-------

[](#license)

This library is under the [EUPL-1.2 license](LICENSE).

Credits
-------

[](#credits)

Developed by [Synolia](https://synolia.com/).

###  Health Score

49

—

FairBetter than 95% of packages

Maintenance45

Moderate activity, may be stable

Popularity44

Moderate usage in the ecosystem

Community21

Small or concentrated contributor base

Maturity72

Established project with proven stability

 Bus Factor1

Top contributor holds 62.4% 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 ~113 days

Recently: every ~159 days

Total

13

Last Release

411d ago

Major Versions

v1.7.0 → v2.0.02025-04-02

PHP version history (4 changes)v1.0.0PHP ^7.3 || ^8.0

v1.2.0PHP ^7.4 || ^8.0

v1.4.0PHP ^8.0

v1.7.0PHP ^8.2

### Community

Maintainers

![](https://www.gravatar.com/avatar/32f47fee63643780d0758c7803bd7f2e682fb8c41e09a6f6041412b3264821c1?d=identicon)[synolia](/maintainers/synolia)

---

Top Contributors

[![oallain](https://avatars.githubusercontent.com/u/6593252?v=4)](https://github.com/oallain "oallain (68 commits)")[![jbcr](https://avatars.githubusercontent.com/u/51637606?v=4)](https://github.com/jbcr "jbcr (18 commits)")[![maxperei](https://avatars.githubusercontent.com/u/7437661?v=4)](https://github.com/maxperei "maxperei (12 commits)")[![adpeyre](https://avatars.githubusercontent.com/u/12408697?v=4)](https://github.com/adpeyre "adpeyre (4 commits)")[![GalloisLuca](https://avatars.githubusercontent.com/u/35807138?v=4)](https://github.com/GalloisLuca "GalloisLuca (3 commits)")[![dependabot[bot]](https://avatars.githubusercontent.com/in/29110?v=4)](https://github.com/dependabot[bot] "dependabot[bot] (2 commits)")[![Jibbarth](https://avatars.githubusercontent.com/u/3168281?v=4)](https://github.com/Jibbarth "Jibbarth (1 commits)")[![chadyred](https://avatars.githubusercontent.com/u/5954673?v=4)](https://github.com/chadyred "chadyred (1 commits)")

---

Tags

gdprrgpdsyliussylius-pluginsyliusgdprsylius-pluginSynoliargpd

###  Code Quality

TestsPHPUnit

Static AnalysisPHPStan, Rector

Code StylePHP\_CodeSniffer

Type Coverage Yes

### Embed Badge

![Health badge](/badges/synolia-sylius-gdpr-plugin/health.svg)

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

###  Alternatives

[sylius/refund-plugin

Plugin provides basic refunds functionality for Sylius application.

691.7M14](/packages/sylius-refund-plugin)[stefandoorn/sitemap-plugin

Sitemap Plugin for Sylius

851.0M](/packages/stefandoorn-sitemap-plugin)[monsieurbiz/sylius-rich-editor-plugin

A Rich Editor plugin for Sylius.

75380.8k6](/packages/monsieurbiz-sylius-rich-editor-plugin)[synolia/sylius-scheduler-command-plugin

Scheduler Command Plugin.

34361.5k](/packages/synolia-sylius-scheduler-command-plugin)[odiseoteam/sylius-blog-plugin

This plugin add blog capabilities to your Sylius project

37104.5k](/packages/odiseoteam-sylius-blog-plugin)[webgriffe/sylius-table-rate-shipping-plugin

Provides table rate shipping calculator.

1490.4k](/packages/webgriffe-sylius-table-rate-shipping-plugin)

PHPackages © 2026

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