PHPackages                             qbcloud/laravel-cloudflare - 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. [Utility &amp; Helpers](/categories/utility)
4. /
5. qbcloud/laravel-cloudflare

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

qbcloud/laravel-cloudflare
==========================

A Laravel extension package for managing Cloudflare websites and domain names.

1.0.0(2y ago)010MITPHPPHP &gt;=7.2.5

Since Jul 1Pushed 2y ago1 watchersCompare

[ Source](https://github.com/YQB520/qbcloud-laravel-cloudflare)[ Packagist](https://packagist.org/packages/qbcloud/laravel-cloudflare)[ RSS](/packages/qbcloud-laravel-cloudflare/feed)WikiDiscussions master Synced today

READMEChangelog (1)Dependencies (2)Versions (2)Used By (0)

主要用途
----

[](#主要用途)

使用Laravel 6.x 以上在Cloudflare上批量创建站点、批量删除站点、批量添加DNS记录、快速删除所有DNS记录、修改SSL类型、清除站点所有缓存内容。

用法
--

[](#用法)

```
composer require qbcloud/laravel-cloudflare
```

发布配置文件：

```
php artisan vendor:publish --provider="QbCloud\Cloudflare\Providers\CloudflareServiceProvider"
```

```
// config/cloudflare.php

return [
    'email' => 'xxx@gmail.com', // Cloudflare Username
    'global_key' => 'globalxxoo', // Cloudflare Global API Key
    'account_id' => 'bbxxkk', // Cloudflare Account ID
    'ip_address' => null // 默认记录值  用于添加DNS记录
];
```

```
use QbCloud\Cloudflare\Facades\Cloudflare;

// 批量创建站点
Cloudflare::createZones(['xxx.com','xxx.net']);

// 批量删除站点
Cloudflare::deleteZones(['xxx.com','xxx.net']);

// 清除站点所有缓存内容
Cloudflare::purgeAllCache('xxx.com');

// 批量添加DNS记录
Cloudflare::createRecords('xxx.com', ['@', 'www', 'test'], '127.0.0.1', 'A');

// 删除一条DNS记录
Cloudflare::deleteRecords('xxx.com', 'test');

// 删除所有DNS记录
Cloudflare::deleteAllRecords('xxx.com');

// 修改SSL类型
Cloudflare::updateSSLSetting('xxx.com', 'full');

// 或者
use QbCloud\Cloudflare\Cloudflare;

$cloudflare = new Cloudflare();
$cloudflare->createZones(['xxx.com','xxx.net']);
```

### 官方文档

[](#官方文档)

[Cloudflare API](https://developers.cloudflare.com/api/operations/zones-get)
[Cloudflare SDK](https://github.com/cloudflare/cloudflare-php)

###  Health Score

18

—

LowBetter than 8% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity5

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity35

Early-stage or recently created project

 Bus Factor1

Top contributor holds 100% 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

Unknown

Total

1

Last Release

732d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/76191566?v=4)[YQB520](/maintainers/YQB520)[@YQB520](https://github.com/YQB520)

---

Top Contributors

[![YQB520](https://avatars.githubusercontent.com/u/76191566?v=4)](https://github.com/YQB520 "YQB520 (4 commits)")

---

Tags

laraveldnswebsitecloudflaredomain

### Embed Badge

![Health badge](/badges/qbcloud-laravel-cloudflare/health.svg)

```
[![Health](https://phpackages.com/badges/qbcloud-laravel-cloudflare/health.svg)](https://phpackages.com/packages/qbcloud-laravel-cloudflare)
```

###  Alternatives

[psalm/plugin-laravel

Psalm plugin for Laravel

3355.3M346](/packages/psalm-plugin-laravel)[renatomarinho/laravel-page-speed

Laravel Page Speed

2.5k1.7M11](/packages/renatomarinho-laravel-page-speed)[vinkius-labs/laravel-page-speed

Laravel Page Speed

2.5k12.5k1](/packages/vinkius-labs-laravel-page-speed)[emargareten/inertia-modal

Inertia Modal is a Laravel package that lets you implement backend-driven modal dialogs for Inertia apps.

90142.9k](/packages/emargareten-inertia-modal)[orrison/cumulus

Import DNS records from Laravel Vapor into Cloudflare

3920.3k](/packages/orrison-cumulus)[wearepixel/laravel-cart

A cart implementation for Laravel

1374.8k](/packages/wearepixel-laravel-cart)

PHPackages © 2026

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