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 2mo ago

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 43% 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

3660d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/e36119970a756f89cf6791d75b3a8c78393b8aaa55b443c1a54bc6b64b2fc3a7?d=identicon)[kevinzheng](/maintainers/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

[laravel-notification-channels/telegram

Telegram Notifications Channel for Laravel

1.1k3.4M35](/packages/laravel-notification-channels-telegram)[laravel-notification-channels/fcm

FCM (Firebase Cloud Messaging) Notifications Driver for Laravel

5917.0M16](/packages/laravel-notification-channels-fcm)[s-ichikawa/laravel-sendgrid-driver

This library adds a 'sendgrid' mail driver to Laravel.

4139.3M1](/packages/s-ichikawa-laravel-sendgrid-driver)[laravel-notification-channels/microsoft-teams

A Laravel Notification Channel for Microsoft Teams

1603.0M7](/packages/laravel-notification-channels-microsoft-teams)[laravel-notification-channels/discord

Laravel notification driver for Discord.

2371.3M11](/packages/laravel-notification-channels-discord)[tzsk/sms

A robust and unified SMS gateway integration package for Laravel, supporting multiple providers.

320244.3k6](/packages/tzsk-sms)

PHPackages © 2026

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