PHPackages                             php-solution/notification - 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. [Mail &amp; Notifications](/categories/mail)
4. /
5. php-solution/notification

ActiveLibrary[Mail &amp; Notifications](/categories/mail)

php-solution/notification
=========================

Library for create notify functionality

v0.1(9y ago)12.7k1MITPHPPHP &gt;=7.1

Since Mar 30Pushed 9y ago1 watchersCompare

[ Source](https://github.com/php-solution/notification-lib)[ Packagist](https://packagist.org/packages/php-solution/notification)[ RSS](/packages/php-solution-notification/feed)WikiDiscussions master Synced 2mo ago

READMEChangelogDependencies (2)Versions (2)Used By (1)

Notification component
======================

[](#notification-component)

Notification component helps developer to create functionality for send notification system.

Concept
-------

[](#concept)

### Parts of logic:

[](#parts-of-logic)

- Context
- Manager
- Extension
- Type
- Rule
- Notifier

### Main Flow:

[](#main-flow)

1. Client create Context and set some parameter for notification, specify Type of notification(string name or object) and send this info to Manager

```
$type = new NotificationType();
$context = new Context(['parameter' => 'parameter value']);
$notificationManager->notifyType($type, $context);

```

or

```
$context = new Context(['parameter' => 'parameter value']);
$notificationManager->notifyType(NotificationType::getName(), $context);

```

2. Manager prepare Type and Context via Extension(if Extension is specified for Manager)
3. Type build Rule/Rules(some simple info for Notifier)
4. Notifier accept Rule(parameters) and send real notification. For example: Email Notifier accept parameters(Rule) for email sending(from, to, cc,text) and send via smtp mail

### Manager

[](#manager)

This is a service for send notification, has 2 public methods for send notification:

- notify(string $name, Context $context = null) - will get Type from TypeRegistry
- notifyType(TypeInterface $type, Context $context = null) - use accepted Type

### Extension

[](#extension)

Implements functionality for prepare Type, Context info before build Rules

### Context

[](#context)

Some value object of parameters for Type

### Type

[](#type)

Rule builder

### Rule

[](#rule)

Some value object of parameters for Notifier

### Notifier

[](#notifier)

Implements functionality for real notification sending

Installing
----------

[](#installing)

1. Add to your composer.json

```
    "require": {
        ...
        "php-solution/notification": "dev-master",
        ...
    }

```

2. run:

```
    composer update php-solution/notification

```

Examples:
---------

[](#examples)

- basic usage: [link](/examples/basic_usage.php)
- use Symfony context configurator extension, for resolve context parameters [link](/examples/sf_context_configurator.php)
- use Symfony Event dispatcher extension [link](/examples/sf_event_dispatcher.php)

###  Health Score

25

—

LowBetter than 37% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity17

Limited adoption so far

Community6

Small or concentrated contributor base

Maturity48

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

3334d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/49381ba2a061a148b9a6f7b5e80663f17d44f15047bbc5f1f38d13429de60487?d=identicon)[olesav](/maintainers/olesav)

### Embed Badge

![Health badge](/badges/php-solution-notification/health.svg)

```
[![Health](https://phpackages.com/badges/php-solution-notification/health.svg)](https://phpackages.com/packages/php-solution-notification)
```

###  Alternatives

[tijsverkoyen/css-to-inline-styles

CssToInlineStyles is a class that enables you to convert HTML-pages/files into HTML-pages/files with inline styles. This is very useful when you're sending emails.

5.8k505.3M227](/packages/tijsverkoyen-css-to-inline-styles)[minishlink/web-push

Web Push library for PHP

1.9k12.0M53](/packages/minishlink-web-push)[laravel-notification-channels/twilio

Provides Twilio notification channel for Laravel

2587.7M12](/packages/laravel-notification-channels-twilio)[spatie/url-signer

Generate a url with an expiration date and signature to prevent unauthorized access

4422.3M16](/packages/spatie-url-signer)[mattketmo/email-checker

Throwaway email detection library

2742.0M5](/packages/mattketmo-email-checker)[laravel-notification-channels/discord

Laravel notification driver for Discord.

2371.3M11](/packages/laravel-notification-channels-discord)

PHPackages © 2026

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