Managing content efficiently is crucial for creating seamless digital experiences. The Workflows and Content Moderation modules empower editors to tailor editorial processes, ensuring content moves smoothly from draft to publication.
By defining custom states like "Draft," "Ready for Review," and "Published," these core modules allow for precise control over content management. Whether you're handling complex editorial needs or simple moderation tasks, Drupal 10’s built-in tools make it easier to deliver consistent, high-quality content.
Both of these modules are part of Drupal core, so they are safe for use in production environments to create engaging digital experiences.
Keep reading to learn more about the Workflows and Content Moderation modules in Drupal.
The Workflows module introduces one or more workflows, which are structured as a series of states and transitions.
In short, the Workflows module acts like a traffic light system. It sets up different stages, each with its own rules for moving between them.
To view a list of currently configured workflows, access the Manage administration menu and navigate to “Configuration > Workflows (admin/config/workflow/Workflows).”
This configuration page displays all existing workflows and also has the option to create a new workflow.
Editors can use the Content Moderation module to attach a workflow to an entity type or bundle. Workflows Field, on the other hand, provides a field that can be incorporated into an entity type for selecting a state within a workflow.
The workflow type can also cover aspects such as default states, the initial state, and additional configuration for states, transitions, or the workflow.
In the absence of the Content Moderation module or another module that uses workflows, users will see a message during installation asking for a module that implements a workflow type.
The Content Moderation module allows editors to attach a workflow to an entity type or bundle, provided the entity type supports revisions. If bundles are supported by the entity type, it's possible to assign different workflows to each bundle. Otherwise, only one workflow per entity type is feasible.
It's important to note that while workflows provides the core mechanism, it doesn't control how it should be utilized to manage the state of an entity. Content Moderation completes this process by providing:
For example, editors can utilize workflows with nodes (entity type) and attach them to different content types (bundles) like blog_post or page. To understand how content moderation works, editors need to know about "published" and "default revisions" for content.
Without additional modules enabled, content entities within a Digital Experience Platform (DXP) support a published/unpublished state. The core Node module uses this state to determine viewing permissions for the content. For example, all site visitors can view published content, while only administrators can access unpublished content.
Content entities also support revision tracking. Drupal stores older revisions as content is revised, enabling comparison or reversion at a later point. The default revision is the one currently in the published state. The version users see this revision by default when navigating to the page.
The workflow type within Content Moderation takes control over all these core features. When defining a new state, editors can choose whether that state corresponds to a published or unpublished status. As content moves from one state to another, its published status automatically aligns with the current state.
A content state can be set as the default revision, meaning the entity will default to this state when moved. If the state is marked as "Published," it automatically becomes the default revision as well.
Organizations can integrate the Workflows and Content Moderation modules to implement content customizations and ensure the proper implementation of editorial rules.
By default, Drupal offers a basic workflow where content is either published or unpublished. But for more complex processes, it is necessary to integrate Workflows and Content Moderation.
For example, consider the following workflow implemented on a website for producing content before it's publicly available:
In the above workflow, different individuals are assigned to various stages of this process, and certain transitions necessitate approval before proceeding. For example, transitioning from copy editing to final review requires approval from a designated copy editor.
By using the Workflows and Content Moderation modules within Drupal, organizations can seamlessly execute this publishing process.
In terms of permissions, the Workflows module defines only one permission, Administer Workflows. This grants full permission to create and edit workflows.
Content Moderation, on the other hand, introduces several permissions:
Ready to transform your editorial workflows?
Contact Axelerant’s experts to learn how we can help tailor Drupal to your unique needs and help you achieve your content goals.