PHPackages                             webhook-notifier/webhook-notifier - 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. [API Development](/categories/api)
4. /
5. webhook-notifier/webhook-notifier

ActiveShopware-platform-plugin[API Development](/categories/api)

webhook-notifier/webhook-notifier
=================================

Shopware 6 plugin: sends webhooks for order lifecycle and customer created events with retry

1.0.0(4mo ago)00MITPHP

Since Feb 9Pushed 1mo agoCompare

[ Source](https://github.com/medinaahmeti/WebhookNotifier)[ Packagist](https://packagist.org/packages/webhook-notifier/webhook-notifier)[ RSS](/packages/webhook-notifier-webhook-notifier/feed)WikiDiscussions main Synced 1w ago

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

Webhook Notifier (Shopware 6)\[6.7\]
====================================

[](#webhook-notifier-shopware-667)

What it does
------------

[](#what-it-does)

- Sends webhooks for:
    - `order.lifecycle.state_changed` (order / order\_transaction / order\_delivery transitions)
    - `customer.created` (customer insert, payload contains `customerIds`)
- Stores deliveries in DB and retries failures.
- Optional HMAC signing headers:
    - `X-Sw-Webhook-Timestamp`
    - `X-Sw-Webhook-Signature` = HMAC\_SHA256("{timestamp}.{body}", secret)

Admin
-----

[](#admin)

Settings → Webhook Notifier

- Save config
- "Send test webhook" button (calls `/api/_action/webhook-notifier/test`)
- List data from `webhook_notifier_event`

Migrations
----------

[](#migrations)

Creates table `webhook_notifier_event`

Scheduled tasks
---------------

[](#scheduled-tasks)

Ensure scheduled tasks / message queue is running in your environment.

### Run scheduled tasks (manual)

[](#run-scheduled-tasks-manual)

```
ddev ssh
bin/console scheduled-task:run-single webhook_notifier.deliver_webhook_events -vv
bin/console messenger:consume async -vv --time-limit=60
```

CLI command
-----------

[](#cli-command)

Count retrying and pending records in webhook table in a time interval

```
bin/console webhook-notifier:deliver -vv
```

### Message queue (Messenger)

[](#message-queue-messenger)

Webhook events are stored in DB and also dispatched to Symfony Messenger for immediate delivery.

### How it works

[](#how-it-works)

- Subscriber creates a `webhook_notifier_event` row (`status=pending`)
- Subscriber dispatches a `WebhookEventMessage(id)` to Messenger
- `WebhookEventMessageHandler` delivers it (and schedules delayed retries via `DelayStamp`)

### How to test

[](#how-to-test)

1. Create a receiver (recommended: webhook.site) and copy your URL.
2. Admin → Settings → Webhook Notifier:
    - enabled = true
    - url = your webhook.site URL
    - Save
3. Trigger an event:
    - Storefront: register a new customer (triggers `customer.created`)
    - OR Admin: change order/transaction/delivery state (triggers `order.lifecycle.state_changed`)
4. Run the consumer:

```
ddev ssh
bin/console messenger:consume async -vv --time-limit=60
```

### Flow Builder: email on customer registration

[](#flow-builder-email-on-customer-registration)

1. Run migrations:

    - `bin/console database:migrate WebhookNotifier --all`
    - created by: `bin/console database:create-migration  -p WebhookNotifier --name AddCustomerRegisteredAdminMailTemplate`
2. Create flow: Admin → Settings → Flow Builder → Create flow
    Trigger: **webhook\_notifier.customer.registered**
    Action: **Send email**

Install
-------

[](#install)

1. Copy into `custom/plugins/WebhookNotifier`
2. `bin/console plugin:refresh`
3. `bin/console plugin:install --activate WebhookNotifier`
4. `bin/console cache:clear`
5. Build admin: `bin/build-administration.sh` (or your normal admin build)
6. Configure in Admin
7. bin/console database:migrate WebhookNotifier --all

Testing Webhook / Manual QA
---------------------------

[](#testing-webhook--manual-qa)

### Webhook receiver (pick one)

[](#webhook-receiver-pick-one)

You need a URL that accepts `POST`:

**Option A (recommended): webhook.site**

1. Open webhook.site
2. Copy your unique URL: `https://webhook.site/`
3. Paste into **Settings → Webhook Notifier → Webhook URL**
4. Save config
5. Use “Send test webhook” or trigger storefront events (below)

**Option B: local receiver + tunnel**Run a local webhook catcher and expose it via ngrok/cloudflared, then use the public HTTPS URL as the webhook URL.

---

### Test button (Admin) — manual test cases

[](#test-button-admin--manual-test-cases)

The “Send test webhook” button calls:

- `POST /api/_action/webhook-notifier/test`

#### 1) Happy path (2xx)

[](#1-happy-path-2xx)

- Config:
    - enabled = true
    - url = valid receiver URL
- Action: click “Send test webhook”
- Expect:
    - Admin shows success notification
    - Receiver gets one request with:
        - header `X-Sw-Webhook-Event: webhook.test`
        - JSON body: ```
            {
              "event": "webhook.test",
              "occurredAt": "...",
              "data": { "message": "Hello from Shopware Webhook Notifier" }
            }
            ```

#### 2) Disabled plugin → 400

[](#2-disabled-plugin--400)

- Config: enabled = false
- Action: click “Send test webhook”
- Expect: Admin error “Plugin is disabled” (HTTP 400)

#### 3) Empty URL → 400

[](#3-empty-url--400)

- Config: enabled = true, url empty
- Action: click “Send test webhook”
- Expect: Admin error “Webhook URL is empty” (HTTP 400)

#### 4) Receiver returns non-2xx → shows error

[](#4-receiver-returns-non-2xx--shows-error)

- Config: enabled = true, url points to an endpoint returning 404/500
- Action: click “Send test webhook”
- Expect: Admin shows error like `HTTP 404` / `HTTP 500`

#### 5) Unreachable/timeout → shows error

[](#5-unreachabletimeout--shows-error)

- Config: enabled = true, url points to an unreachable host
- Action: click “Send test webhook”
- Expect: Admin shows error (request fails; controller returns ok=false)

#### 6) HMAC headers disabled when secret empty

[](#6-hmac-headers-disabled-when-secret-empty)

- Config: secret empty
- Action: click “Send test webhook”
- Expect:
    - Receiver does NOT get `X-Sw-Webhook-Timestamp` / `X-Sw-Webhook-Signature`

#### 7) HMAC headers enabled when secret set

[](#7-hmac-headers-enabled-when-secret-set)

- Config: secret set to a non-empty value
- Action: click “Send test webhook”
- Expect:
    - Receiver gets:
        - `X-Sw-Webhook-Timestamp: `
        - `X-Sw-Webhook-Signature: `
    - Signature is computed as:
        - `HMAC_SHA256("{timestamp}.{rawBody}", secret)`

---

### Simulate webhook events from the Storefront (no API calls needed)

[](#simulate-webhook-events-from-the-storefront-no-api-calls-needed)

#### A) Trigger `customer.created` from storefront

[](#a-trigger-customercreated-from-storefront)

1. Ensure plugin is enabled and webhook URL is set.
2. In Storefront, register a **new customer**:
    - Storefront → Account → Register
3. Expect:
    - A webhook event is queued with event name `customer.created`
    - Receiver gets a POST with payload containing:
        - `event: "customer.created"`
        - `data.customerIds: [ ... ]`

Notes:

- Updating an existing customer should NOT trigger `customer.created` (insert only).

#### B) Trigger `order.lifecycle.state_changed` from storefront + admin action

[](#b-trigger-orderlifecyclestate_changed-from-storefront--admin-action)

1. In Storefront, place an order:
    - Add product to cart → Checkout → Place order
2. Then in Admin, change the state of:
    - the order, the transaction, or the delivery
    - (e.g. set payment status, delivery status, etc.)
3. Expect:
    - Webhook event queued with:
        - `event: "order.lifecycle.state_changed"`
        - `data.entity` in `order` / `order_transaction` / `order_delivery`
        - transition details (fromStateId/toStateId/transition/entityId)

---

###  Health Score

32

—

LowBetter than 70% of packages

Maintenance84

Actively maintained with recent releases

Popularity0

Limited adoption so far

Community6

Small or concentrated contributor base

Maturity34

Early-stage or recently created project

 Bus Factor1

Top contributor holds 100% 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

Unknown

Total

1

Last Release

120d ago

### Community

Maintainers

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

---

Top Contributors

[![medinaahmeti](https://avatars.githubusercontent.com/u/25962930?v=4)](https://github.com/medinaahmeti "medinaahmeti (4 commits)")

### Embed Badge

![Health badge](/badges/webhook-notifier-webhook-notifier/health.svg)

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

###  Alternatives

[shopware/storefront

Storefront for Shopware

684.4M207](/packages/shopware-storefront)[shopware/production

177202.8k](/packages/shopware-production)[frosh/tools

Provides some basic things for managing the Shopware Installation

83783.3k2](/packages/frosh-tools)[shopware/administration

Administration frontend for the Shopware Core

414.2M104](/packages/shopware-administration)[shopware/elasticsearch

Elasticsearch for Shopware

143.8M15](/packages/shopware-elasticsearch)[adyen/adyen-shopware6

Official Shopware 6 Plugin to connect to Payment Service Provider Adyen

24115.8k](/packages/adyen-adyen-shopware6)

PHPackages © 2026

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