Download the PHP package setono/sylius-abandoned-cart-plugin without Composer

On this page you can find all versions of the php package setono/sylius-abandoned-cart-plugin. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package sylius-abandoned-cart-plugin

Abandoned cart plugin for Sylius

Latest Stable Version Total Downloads License PHP Version Require build codecov Mutation testing badge

Recover lost sales on autopilot. This plugin spots shopping carts your customers leave behind, then emails them a friendly reminder with a one-click link back to their cart — and a compliant unsubscribe link. Everything is tracked in the admin panel so you can see exactly which carts were notified, recovered, or opted out.

Features

How it works

The plugin runs as a small pipeline, driven by two commands you schedule on a cron:

  1. Detectcreate-notifications finds carts that have been idle for idle_threshold minutes and creates a Notification for each (initial state: pending).
  2. Processprocess-notifications runs every pending notification through the eligibility checks, sends the email, and transitions it to sent (or ineligible if a check fails).
  3. Recover — the email contains a recovery link (restores the cart and tracks the click) and an unsubscribe link (records the opt-out so the customer is never emailed again).

Each notification moves through a state machine:

Requirements

Package Version
PHP 8.2+
Sylius ^2.0
Symfony 6.4 or 7.4

Using Sylius 1.x? This branch (3.x) targets Sylius 2. For Sylius 1.x support, use the 2.x branch.

Installation

1. Require the plugin

2. Register the bundle

Add the plugin to config/bundles.php before SyliusGridBundle — otherwise you'll get a non-existent parameter "setono_sylius_abandoned_cart.model.notification.class" error, because the grid configuration references parameters the plugin registers.

3. Import the routes

This registers the admin grid routes (under /admin/abandoned-cart) and the shop routes for cart recovery and unsubscribe.

4. Configure the salt

The unsubscribe links are signed with a SHA-256 hash. Set a secret salt and change it in production — anyone who knows it could forge unsubscribe links.

5. Install assets

6. Update your database schema

7. Schedule the commands

The plugin needs create-notifications and process-notifications to run regularly. A typical crontab:

Commands

Command What it does
setono:sylius-abandoned-cart:create-notifications Finds idle carts and creates notifications. Supports --dry-run to preview.
setono:sylius-abandoned-cart:process-notifications Runs eligibility checks and sends the emails.
setono:sylius-abandoned-cart:prune-notifications Deletes notifications older than prune_older_than.

Preview which carts would be picked up, without persisting anything:

Configuration reference

Customization

Add a custom eligibility rule

Implement NotificationEligibilityCheckerInterface and return an EligibilityCheck. With Symfony autoconfiguration enabled (the default), the plugin discovers and registers your checker automatically — no service config needed.

If you've disabled autoconfiguration, tag the service manually with setono_sylius_abandoned_cart.notification_eligibility_checker.

Customize which carts are considered "idle"

The idle-cart query is dispatched as a QueryBuilderForIdleCartsCreated event before it runs, so you can add your own constraints. The cart root alias is o:

Override the email template

Copy the template into your app and edit it — Symfony's template overriding does the rest:

Override translations

Override any string by redefining its key (under the setono_sylius_abandoned_cart.* prefix) in your app's translations/messages.<locale>.yml.

Contributing

A full Sylius test application lives in tests/Application for functional tests and manual testing. See CLAUDE.md for architecture notes and developer conventions.

License

This plugin is released under the MIT License.


All versions of sylius-abandoned-cart-plugin with dependencies

PHP Build Version
Package Version
Requires php Version >=8.2
ext-hash Version *
doctrine/orm Version ^2.0 || ^3.0
doctrine/persistence Version ^2.5 || ^3.0
knplabs/knp-menu Version ^3.3
ocramius/doctrine-batch-utils Version ^2.4
psr/event-dispatcher Version ^1.0
psr/log Version ^1.1 || ^2.0 || ^3.0
setono/composite-compiler-pass Version ^1.2
setono/doctrine-orm-trait Version ^1.2
sylius/channel Version ^2.0
sylius/core Version ^2.0
sylius/core-bundle Version ^2.0
sylius/mailer-bundle Version ^2.0
sylius/order Version ^2.0
sylius/resource-bundle Version ^1.12
sylius/ui-bundle Version ^2.0
symfony/config Version ^6.4 || ^7.4
symfony/console Version ^6.4 || ^7.4
symfony/dependency-injection Version ^6.4 || ^7.4
symfony/event-dispatcher Version ^6.4 || ^7.4
symfony/form Version ^6.4 || ^7.4
symfony/http-foundation Version ^6.4 || ^7.4
symfony/routing Version ^6.4 || ^7.4
symfony/validator Version ^6.4 || ^7.4
symfony/workflow Version ^6.4 || ^7.4
twig/twig Version ^3.0
webmozart/assert Version ^1.12
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package setono/sylius-abandoned-cart-plugin contains the following files

Loading the files please wait ...