Drupal is a registered trademark of Dries Buytaert
Drupal 10.6.14 Update released for Drupal core (10.6.14)! Drupal 11.3.16 Update released for Drupal core (11.3.16)! OAuth2 Client 4.2.0 Minor update available for module oauth2_client (4.2.0). OAuth2 Client 4.1.5 Minor update available for module oauth2_client (4.1.5). CKeditor Details Accordion 2.1.1 Minor update available for module ckeditor_details (2.1.1). Schema Markup Generator using AI 1.0.2 Minor update available for module ai_schema_markup_generator (1.0.2). DSFR for Drupal 1.6.2 Minor update available for theme dsfr4drupal (1.6.2). DSFR for Drupal 1.6.1 Minor update available for theme dsfr4drupal (1.6.1). Field Defaults 2.1.1 Module field_defaults updated after 15 months of inactivity (2.1.1). Provus Mega Menu Module provus_mega_menu crossed 1,000 active installs.

The CAP standard is used worldwide to communicate consistent, timely safety information in a way that many applications and devices can consume.

This module allows a Drupal website to act as a CAP alert publisher (CAP V1.2 Message Producer). It does not provide the ability to consume/ingest CAP alerts from other sources (CAP V1.2 Message Consumer).

It aims to provide a 1:1 mapping of the CAP standard to Drupal content types, fields and taxonomy, so that publishers can fully utilize the functionality of the CAP standard entirely from within Drupal.

All alerts published by this module are treated as being CAP v1.2 compliant. No support for versions 1.0 and 1.1 is planned at this stage, but I'm open to feedback on if this would be useful.

The CAP standard supports XML, RSS, Atom and EDXL-DE feed formats. This module currently only provides the XML feed format, but support for the other formats is planned.

It allows information to be distributed and consumed by a wide variety of systems, including emergency alerting systems, SMS, emails, pagers, weather alerting systems, digital road signs and more.

AI Development Declaration

This module was written with the assistance of AI agents. The module maintainer reviews and takes full responsibility for all the work done by AI.

Understanding the CAP standard

It is strongly advised to read the CAP documentation before using this module:
https://docs.oasis-open.org/emergency/cap/v1.2/CAP-v1.2-os.html

Official home of the CAP standard: https://cap.alert-hub.org/

There are important restrictions to be aware of around what certain agencies may publish. This module cannot verify if the user has the necessary authority to publish certain types of alerts e.g. weather, law enforcement, emergency services etc.

Never publish alerts for domains you are not authorised to publish in! Doing so can result in confusion, delay, conflicting information and potentially serious and even deadly consequences for the public. If you are unsure, please contact your local emergency services or relevant authority before publishing any alerts.

It is the responsibility of the publisher to ensure they are authorised to publish their alerts.

Installation

  1. Install the module with `composer require drupal/cap_alerts`
  2. Enable the `cap_alerts` module via the UI or with `drush pm:enable -y cap_alerts`.
  3. Install and enable the `migrate`, `migrate_plus`, and `migrate_tools` modules if not already installed. These are required to import the CAP-controlled terms and can be removed once done.
  4. Run `drush migrate:import --group="cap_terms" -y` to import the cap-controlled terms.
  5. Visit `/admin/config/services/cap-alerts` to configure your CAP feed settings. You MUST do this before any of your alerts are consumed by external services, as these settings change the output of the CAP feed!.
  6. Publish your first CAP Alert by going to `Content` > `Add content` > `CAP Alert Message`.
  7. Visit `/api/alerts` to view your CAP feed, or `/api/alerts/test` to view the test feed (requires 'Access CAP alerts test feed' permission or the Administrator role).

The module will create several new entity types:

  • Content Type: `CAP Alert Message`
  • Paragraph types: `CAP Alert - *`
  • Taxonomy Vocabularies: `CAP Alert - *`.

Do NOT change the terms in the CAP taxonomy vocabularies, as they are controlled by the CAP standard and may be updated in future releases of this module. Using any terms other than what is included will result in your alerts being non-compliant with the CAP standard and potentially rejected by consuming systems! (They shouldn't be, but they might).

More information

See the README.md file for more information.

Activity

Total releases
1
First release
Jul 2026
Latest release
12 hours ago
Releases (12 mo)
1 ▲ from 0
Maintenance
Active

Releases

Version Type Release date
1.0.0-alpha1 Pre-release Jul 24, 2026