Drupal is a registered trademark of Dries Buytaert
Release: Dynamic Entity Reference 3.2.3 Minor update available for module dynamic_entity_reference (3.2.3). Release: Charts 5.2.3 Minor update available for module charts (5.2.3). Release: amazee.ai Private AI Provider 1.3.5 Minor update available for module ai_provider_amazeeio (1.3.5). Release: Search and Replace Scanner 2.0.0-beta5 New beta version released for module scanner (2.0.0-beta5). Release: Database Info Schema 1.3.1 Minor update available for module database_info_schema (1.3.1). Release: Easy LQP 2.0.4 Minor update available for module easy_lqp (2.0.4). Usage Milestone: Media entity Twitter Module media_entity_twitter crossed 10,000 active installs. Usage Milestone: OpenAPI Module openapi crossed 10,000 active installs. Usage Milestone: Account field split Module account_field_split crossed 10,000 active installs. Module Revived: Message 8.x-1.9 Module message updated after 17 months of inactivity (8.x-1.9).

This module provides the core framework for other Cloudflare modules, managing API credentials and shared HTTP services. It allows you to configure multiple sets of Cloudflare credentials, securely stored in your settings.php file, and enables other modules to leverage these credentials for Cloudflare interactions.

The framework layer for the Cloudflare module suite, built on the standalone Cloudflare API client. It provides named credential sets, resolution of account IDs and API tokens from settings.php, a shared HTTP client factory, and the provisioning framework that the other Cloudflare modules build on.

You usually install this module because another Cloudflare module (such as the Cloudflare AI Gateway) depends on it. On its own it adds a small admin screen for managing credential sets and the services those modules use; it makes no calls to Cloudflare by itself.

Features

  • A credential set configuration entity, identified by a machine name and label only. Nothing account-specific is stored in configuration or the database.
  • Account ID and API token resolved from settings.php, keyed by the credential set's machine name ($settings['cloudflare']['credentials'][<id>]).
  • Support for multiple named credential sets, for example different tokens for different purposes or accounts.
  • A pluggable credential resolver behind an interface, so the secret source can be changed without changing callers.
  • A shared HTTP client factory that binds a base URI and default headers over Drupal core's HTTP client, with a typed exception.
  • A provisioning framework (capabilities, primitives, a reconciler and deployment appliers) that lets feature modules declare the Cloudflare resources they need and have them reconciled.

Post-Installation

This module has no standalone features beyond credential management; you install it because another Cloudflare module needs it. After enabling it:

  1. Add a credential set at Configuration > Web services > Cloudflare credentials, giving it a machine name.
  2. Add its account ID and API token to settings.php, keyed by that machine name:
    $settings['cloudflare']['credentials']['my_account'] = [
      'account_id' => 'your-account-id',
      'token' => 'your-token',
    ];

Other Cloudflare modules then reference the credential set by its machine name.

Additional Requirements

This module requires the Cloudflare API module, which Composer installs automatically. To make a credential set useful you need a Cloudflare account and an API token. Install with Composer:

composer require drupal/cloudflare_sdk

While the suite is in alpha, require it as drupal/cloudflare_sdk:^1.0@alpha (or set your project's minimum-stability to alpha) so the pre-stable releases resolve.

This module exists to support the rest of the Cloudflare suite:

Similar projects

The existing Cloudflare module integrates CDN and cache management. This module is narrower and reusable: a credential and HTTP foundation that keeps account IDs and tokens in settings.php and gives the other Cloudflare suite modules one shared credential model.

Supporting this Module

Issue reports, patches and feedback are welcome in the project's issue queue.

Community Documentation

For creating a Cloudflare API token, see Cloudflare's documentation at developers.cloudflare.com/fundamentals/api/get-started/create-token.

Activity

Tracked releases
7
Tracked since
Jun 2026
Latest release
3 weeks ago
Releases (12 mo)
7 ▲ from 0
Maintenance
Active

Release Timeline

Releases

Version Type Release date
1.0.0-alpha7 Pre-release Jul 11, 2026
1.0.0-alpha6 Pre-release Jul 11, 2026
1.0.0-alpha5 Pre-release Jul 11, 2026
1.0.0-alpha4 Pre-release Jul 10, 2026
1.0.0-alpha3 Pre-release Jul 7, 2026
1.0.0-alpha2 Pre-release Jun 21, 2026
1.0.0-alpha1 Pre-release Jun 21, 2026