PHPackages                             kevinzheng/laravel-sendcloud - 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. [Mail &amp; Notifications](/categories/mail)
4. /
5. kevinzheng/laravel-sendcloud

ActiveLibrary[Mail &amp; Notifications](/categories/mail)

kevinzheng/laravel-sendcloud
============================

1.1(10y ago)118MITPHPPHP &gt;=5.6

Since Dec 12Pushed 9y ago1 watchersCompare

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

READMEChangelogDependencies (2)Versions (3)Used By (0)

Laravel-SendCloud
=================

[](#laravel-sendcloud)

Laravel 5.3 的 SendCloud 驱动

##### 优点：

[](#优点)

普通发送方式完全兼容官方用法，可随时修改配置文件改为其他驱动，而不需要改动业务代码

安装
--

[](#安装)

在项目目录下执行

```
composer require kevinzheng/laravel-sendcloud

```

配置
--

[](#配置)

修改 `config/app.php`，添加服务提供者

```
'providers' => [
   // 添加这行
    KVZ\Laravel\Mail\SendCloudServiceProvider::class,
];
```

在 `.env` 中配置你的密钥， 并修改邮件驱动为 `sendcloud`

```
MAIL_DRIVER=sendcloud

SEND_CLOUD_USER=   # 创建的 api_user
SEND_CLOUD_KEY=    # 分配的 api_key
```

使用
--

[](#使用)

#### 普通发送：

[](#普通发送)

用法完全和系统自带的一样, 具体请参照官方文档：

```
Mail::send('emails.welcome', $data, function ($message) {
    $message->from('us@example.com', 'Laravel');

    $message->to('foo@example.com')->cc('bar@example.com');
});
```

#### 模板发送

[](#模板发送)

用法和普通发送类似，不过需要将 `body` 设置为 `SendCloudTemplate` 对象，达到目的有几种方法

##### 第一种用法：

[](#第一种用法)

```
Mail::send('随便传个空view', [], function ($message) {
    $message->from('us@example.com', 'Laravel');

    $message->to('foo@example.com')->cc('bar@example.com');

    // 模板变量
    $bind_data = ['url' => 'http://naux.me'];
    $template = new SendCloudTemplate('模板名', $bind_data);

    $message->getSwiftMessage()->setBody($template);
});
```

##### 第二种用法：

[](#第二种用法)

```
// 模板变量
$bind_data = ['url' => 'http://naux.me'];
$template = new SendCloudTemplate('模板名', $bind_data);

Mail::raw($template, function ($message) {
    $message->from('us@example.com', 'Laravel');

    $message->to('foo@example.com')->cc('bar@example.com');
});
```

##### 其他用法：

[](#其他用法)

看了上面两种用法，其他用法对照官方文档也能猜出来了吧，如使用 `queue` 发送等 ~

###  Health Score

26

—

LowBetter than 41% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity8

Limited adoption so far

Community9

Small or concentrated contributor base

Maturity59

Maturing project, gaining track record

 Bus Factor1

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

Every ~144 days

Total

2

Last Release

3708d ago

### Community

Maintainers

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

---

Top Contributors

[![nauxliu](https://avatars.githubusercontent.com/u/9570112?v=4)](https://github.com/nauxliu "nauxliu (20 commits)")[![kvzn](https://avatars.githubusercontent.com/u/313271?v=4)](https://github.com/kvzn "kvzn (1 commits)")

### Embed Badge

![Health badge](/badges/kevinzheng-laravel-sendcloud/health.svg)

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

###  Alternatives

[craftcms/cms

Craft CMS

3.6k3.6M2.9k](/packages/craftcms-cms)[erag/laravel-disposable-email

A Laravel package to detect and block disposable email addresses.

252143.0k](/packages/erag-laravel-disposable-email)[spatie/laravel-export

Create a static site bundle from a Laravel app

672139.5k6](/packages/spatie-laravel-export)[jasara/php-amzn-selling-partner-api

A fluent interface for Amazon's Selling Partner API in PHP

1348.1k1](/packages/jasara-php-amzn-selling-partner-api)[eslazarev/wildberries-sdk

Wildberries OpenAPI clients (generated).

252.5k](/packages/eslazarev-wildberries-sdk)

PHPackages © 2026

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