PHPackages                             fab/messenger - 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. fab/messenger

ActiveTypo3-cms-extension[Mail &amp; Notifications](/categories/mail)

fab/messenger
=============

Send emails to a bunch of people. A message is wrapped in a template / layout that a BE user can freely edit in a BE module.

6.0.0(3mo ago)52.2k↓50%9[2 issues](https://github.com/fabarea/messenger/issues)1GPL-2.0-or-laterPHP

Since Aug 30Pushed 2mo ago1 watchersCompare

[ Source](https://github.com/fabarea/messenger)[ Packagist](https://packagist.org/packages/fab/messenger)[ Docs](https://github.com/fabarea/messenger)[ RSS](/packages/fab-messenger/feed)WikiDiscussions develop Synced 1mo ago

READMEChangelogDependencies (3)Versions (26)Used By (1)

Messenger Extension
===================

[](#messenger-extension)

Messenger Extension is a TYPO3 extension for listing recipients in a flexible way and send them emails to them. The extension basically contains:

- A email is composed by two parts: a message template and a possible layout. The layout will wrap the template. This can be useful if the message must be surrounded by a footer / header containing a logo or some default text.
- Messenger will send **multi-parted email** which contains a HTML version next to a plain text within the same email.
- Body message can be written in **Markdown syntax**alongside with **Fluid View Helper** which will be be rendered when sending the email.
- Messages can be queued and scheduled for mass mailing. In this case, emails are sent via a scheduler task or a CLI command.

[![https://raw.github.com/fabarea/messenger/master/Documentation/Screenshot.png](https://camo.githubusercontent.com/28a11ab1c16807da6a593489d56449fea50a35b3ddc1564b4e57ae6ebcce43df/68747470733a2f2f7261772e6769746875622e636f6d2f666162617265612f6d657373656e6765722f6d61737465722f446f63756d656e746174696f6e2f53637265656e73686f742e706e67)](https://camo.githubusercontent.com/28a11ab1c16807da6a593489d56449fea50a35b3ddc1564b4e57ae6ebcce43df/68747470733a2f2f7261772e6769746875622e636f6d2f666162617265612f6d657373656e6765722f6d61737465722f446f63756d656e746174696f6e2f53637265656e73686f742e706e67)

Project info and releases
-------------------------

[](#project-info-and-releases)

Development version:

```
composer require fab/messenger
```

Flash info about latest development or release

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

[](#installation)

Extension have self-explanatory settings in the Extension Manager. For a particular context you could configure to have all emails redirected to a configured email for testing purposes and for not "leaking" messages outside your dev environment.

Message composing
-----------------

[](#message-composing)

When composing content, you can take full advantage of the Fluid syntax and make use of View Helper within your messages. Markers should be defined as follows {first\_name} and will be processed when rendering the email.

Note, you can use a double curly bracket {{text}} to have the marker interpreted as HTML. This would be the equivalent to &lt;f:format.raw&gt;{text}&lt;/f:format.raw&gt; in Fluid.

You may want to add prefix to all URLs with a domain (absolute URLs) which is required to have the links clickable. Otherwise, links will be relative to nothing and this will simply not work correctly for the end user.

``config.absRefPrefix = https://domain.tld/``

Retrieve sent messages
----------------------

[](#retrieve-sent-messages)

It could be handy to show sent messages or messages from the queue on the FE. We can achieve that knowing the UUID of the message. In newsletter we often have see links like ""

[``](#id1)[`](#id3)

\# Display a sent message [https://domain.tld/?type=1556100596&amp;uuid=a7760851-2349-4b5c-bc9e-ae43eecc01a9](https://domain.tld/?type=1556100596&uuid=a7760851-2349-4b5c-bc9e-ae43eecc01a9)

\# Display a message to be sent in the queue [https://domain.tld/?type=1556100596&amp;uuid=a7760851-2349-4b5c-bc9e-ae43eecc01a9&amp;source=queue](https://domain.tld/?type=1556100596&uuid=a7760851-2349-4b5c-bc9e-ae43eecc01a9&source=queue)[``](#id5)[`](#id7)

This can be used in a HTML content element in TYPO3 to generate a link to show the content that was sent to the User in the browser.

``If this email is not shown correctly click here.``

Message API
-----------

[](#message-api)

Usage:

```
$templateIdentifier = 1; // uid
$layoutIdentifier = 1; // uid
$recipients = array('john@doe.com' => 'John Doe');
$markers = array(
  'first_name' => 'John',
  'last_name' => 'Doe',
);
$languageIdentifier = 0; // sys_language_uid
$pathToFile = 'some-path-to-file'; // @todo replace me with FAL identifier

/** @var \Fab\Messenger\Domain\Model\Message $message */
$message = GeneralUtility::makeInstance(Fab\Messenger\Domain\Model\Message:class);

# Minimum required to be set
$message->setMessageTemplate($templateIdentifier)
        ->setTo($recipients);

# Additional setter
$message->assign('foo', $bar)
        ->setLanguage($languageIdentifier)
        ->addAttachment($pathToFile)
        ->setMessageLayout($layoutIdentifier);

# Send the email...
$isSent = $message->send();
```

Queue
-----

[](#queue)

Messenger has the feature to queue up emails. This is advised as soon as sending many emails at once.

```
/** @var \Fab\Messenger\Domain\Model\Message $message */
$message = GeneralUtility::makeInstance('Fab\Messenger\Domain\Model\Message');
$message->
        ... // same as in the example above
        ->enqueue();
```

Configuration
-------------

[](#configuration)

Following configuration should be configured. The default sender name:

```
$GLOBALS['TYPO3_CONF_VARS']['MAIL']['defaultMailFromName'] = 'John Doe';
$GLOBALS['TYPO3_CONF_VARS']['MAIL']['defaultMailFromAddress'] = 'john@doe.com';
```

Whenever Application Context is in Development, there is the possibility to define a default target recipient which is convenient for sending unwanted emails to real people.

```
$GLOBALS['TYPO3_CONF_VARS']['MAIL']['development']['recipients'] = 'fabien@omic.ch';
```

Tool to send emails to Frontend Users
-------------------------------------

[](#tool-to-send-emails-to-frontend-users)

Messenger makes it possible to send bulk messages to a selection / group of users. There is BE module to see the state of the queue and the messages waiting to be sent. Consider setting up the scheduler task to properly send the emails as messages are put into a queue and are sent by patch.

You have the possibility to configure a list of possible senders (the contact person displayed as "from"). They could be retrieved from three different sources

- The currently logged-in BE User if the email address is defined.
- The PHP global configuration defaultMailFromName and defaultMailFromAddress
- User TSConfig:

    ```
    options.messenger {

        senders {
            0 {
                name = My Name
                email = test@example.tld
            }
        }
    }
    ```

CLI
---

[](#cli)

Messenger provides two commands.

Send messages and remove them from the queue by batch of 100 messages:

```
./vendor/bin/typo3 messenger:dequeue
```

Sent messages older than 100 days will be removed:

```
./vendor/bin/typo3 messenger:cleanUp
```

Fluid templates
---------------

[](#fluid-templates)

More of Fluid's power can be used if the template is stored in external files. In such a case layouts can be used. They have to be stored in a folder called "Layouts", placed in the same folder as the template itself.

For example, if the template is located at "EXT:foo/Resource/Private/Templates/Mail/Bar.html" it may refer to layouts located in "EXT:foo/Resource/Private/Templates/Mail/Layouts".

Furthermore, it is possible to choose "Fluid only" as a templating engine when defining a message template. In such a case the Markdown interpreter will not run. This means that the Fluid template can be written more freely.

Sponsors
--------

[](#sponsors)

- [Ecodev](https://www.ecodev.ch/) Ingénierie du développement durable – CMS – application web – bases de données – Webdesign
- [Gebrüderheitz](https://gebruederheitz.de/) – Agentur für Webkommunikation
- [Cobweb](https://www.cobweb.ch/) Agence web spécialisée dans le conseil web, le webdesign et la réalisation de sites internet

###  Health Score

51

—

FairBetter than 96% of packages

Maintenance74

Regular maintenance activity

Popularity26

Limited adoption so far

Community20

Small or concentrated contributor base

Maturity73

Established project with proven stability

 Bus Factor1

Top contributor holds 74% 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 ~215 days

Recently: every ~333 days

Total

17

Last Release

99d ago

Major Versions

1.0.2 → 2.0.02019-05-01

2.3.0 → 3.0.02021-10-19

3.0.2 → 4.0.22022-06-14

4.1.0 → 5.0.02025-11-27

5.0.0 → 6.0.02026-02-09

### Community

Maintainers

![](https://www.gravatar.com/avatar/9df52765d70098f094d02c41a2fda5b108b30ba7e58383dd79c5eda0f286dd21?d=identicon)[fudriot](/maintainers/fudriot)

---

Top Contributors

[![fabarea](https://avatars.githubusercontent.com/u/620730?v=4)](https://github.com/fabarea "fabarea (245 commits)")[![compaoreh338](https://avatars.githubusercontent.com/u/131278191?v=4)](https://github.com/compaoreh338 "compaoreh338 (66 commits)")[![stissot](https://avatars.githubusercontent.com/u/869941?v=4)](https://github.com/stissot "stissot (7 commits)")[![PowerKiKi](https://avatars.githubusercontent.com/u/72603?v=4)](https://github.com/PowerKiKi "PowerKiKi (7 commits)")[![Lebeau09](https://avatars.githubusercontent.com/u/162180980?v=4)](https://github.com/Lebeau09 "Lebeau09 (2 commits)")[![fudriot](https://avatars.githubusercontent.com/u/9142147?v=4)](https://github.com/fudriot "fudriot (2 commits)")[![stat1x](https://avatars.githubusercontent.com/u/11523234?v=4)](https://github.com/stat1x "stat1x (1 commits)")[![claudiusheitz](https://avatars.githubusercontent.com/u/1027097?v=4)](https://github.com/claudiusheitz "claudiusheitz (1 commits)")

---

Tags

emailTYPO3 CMSnewslettermailingemail queue

###  Code Quality

Static AnalysisRector

### Embed Badge

![Health badge](/badges/fab-messenger/health.svg)

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

###  Alternatives

[putyourlightson/craft-campaign

Send and manage email campaigns, contacts and mailing lists.

6435.0k1](/packages/putyourlightson-craft-campaign)[hocza/sendy

Sendy API implementation for Laravel

71195.5k](/packages/hocza-sendy)[ecomailcz/ecomail

Ecomail.cz API Wrapper

17383.8k4](/packages/ecomailcz-ecomail)[phplist/core

The core module of phpList, the world's most popular open source newsletter manager

885.2k3](/packages/phplist-core)[mediaessenz/mail

Powerful newsletter system for TYPO3

119.1k2](/packages/mediaessenz-mail)

PHPackages © 2026

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