Drupal is a registered trademark of Dries Buytaert
Protected Pages 3.0.0 Major update available for module protected_pages (3.0.0). Commerce Core 3.3.8 Minor update available for module commerce (3.3.8). Search API HTML Element Filter 1.0.7 Minor update available for module search_api_html_element_filter (1.0.7). Layout Builder Reorder 2.0.1 Minor update available for module layout_builder_reorder (2.0.1). Ban 1.1.0 Minor update available for module ban (1.1.0). Field Formatter Range 2.0.0 Major update available for module field_formatter_range (2.0.0). Field Formatter Range 8.x-1.8 Minor update available for module field_formatter_range (8.x-1.8). UI Patterns (SDC in Drupal UI) 2.0.18 Minor update available for module ui_patterns (2.0.18). Search API Solr 4.3.11 Module search_api_solr updated after 14 months of inactivity (4.3.11). Provus Mega Menu Module provus_mega_menu crossed 1,000 active installs.

This module provides a configurable system for managing and sending emails. It allows site administrators to define and customize system emails, such as those for user registration or password resets, using a configuration entity. The module also offers a service for sending emails from any entity that implements a specific interface, aiming to replace the traditional hook_mail() system.

Provides a config entity for system emails, and a service for mailing any entity which implements the interface.

This project is intended as a testing ground for replacing hook_mail() in core: see https://www.drupal.org/node/1346036 for details.

Overview

This module's mail message entity type is intended for system emails, that is, emails where the text is initially defined in code, possibly configurable, and may be processed to have tokens replaced. Examples include user registration and password reset, content subscription emails, Commerce order emails, moderation notification emails, event reminder emails, and so on.

A mail message entity can define which mail backend to use, to override the site setting, and which mail processor plugin to use. The processor plugin does the equivalent work of hook_mail(): replaces tokens, and so on.

Modules using this system define their emails as default config entities. The 'group' property on mail message entities allows the creation of an admin list that only shows the mail message entities for a particular group, which modules defining messages can use to create an admin UI for editing their own emails. The Mail Example submodule provides an example of doing this.

Activity

Total releases
1
First release
Dec 2025
Latest release
7 months ago
Releases (12 mo)
1 ▲ from 0
Maintenance
Slowing

Releases

Version Type Release date
8.x-1.2 Stable Dec 8, 2025