PHPackages                             cherrytools/directmail - 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. cherrytools/directmail

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

cherrytools/directmail
======================

aliyun direct mail for laravel.

2.0(8y ago)41701MITPHPPHP &gt;=7.0.0

Since Nov 28Pushed 8y agoCompare

[ Source](https://github.com/XueTools/Aliyun-DirectMail)[ Packagist](https://packagist.org/packages/cherrytools/directmail)[ RSS](/packages/cherrytools-directmail/feed)WikiDiscussions master Synced 2w ago

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

Aliyun Direct Mail For Laravel 5
================================

[](#aliyun-direct-mail-for-laravel-5)

使用阿里云的邮件推送（[DirectMail](https://www.aliyun.com/product/directmail)）发送邮件，

仅支持单一发信接口（[SingleSendMail](https://help.aliyun.com/document_detail/29444.html?spm=5176.doc29435.2.3.pHDCrc)）。

安装
--

[](#安装)

> 在Laravel 5.4或更低版本，请使用

```
composer require cherrytools/directmail:~1.0
```

> 在Laravel 5.5或更高版本，请使用

```
composer require cherrytools/directmail:~2.0
```

配置
--

[](#配置)

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

```
MAIL_DRIVER=directmail
DIRECT_MAIL_KEY=            # AccessKeyId
DIRECT_MAIL_SECRET=         # AccessKeySecret
```

您也可以进行一些额外的配置，具体请参考阿里云邮件推送[官方文档](https://help.aliyun.com/document_detail/29444.html?spm=5176.doc29435.2.3.pHDCrc)

```
DIRECT_MAIL_REPLAY_TO=      # ReplyToAddress
DIRECT_MAIL_ADDRESS_TYPE=   # AddressType
DIRECT_MAIL_REGION=         # RegionId
DIRECT_MAIL_CLICK_TRACE=    # ClickTrace
```

在Laravel 5.5或更高版本中，该软件包将被自动发现，您可以跳过以下步骤。

如果使用Laravel 5.4或更低版本，则需要将ServiceProvider添加到 `config/app.php` 中的 `providers` 数组中

```
Cherry\DirectMail\DirectMailTransportProvider::class,
```

使用
--

[](#使用)

详细用法请参考 laravel 文档：

>

#### 演示

[](#演示)

```
Mail::raw('Hello World!', function ($message) {
    $message->from('email', 'alias');
    // 单个收件人
    $message->to('email', 'alias');
    // 多个收件人
    $message->to(['email'=>'alias', 'email'=>'alias']);
    $message->subject('Hello World');
});
```

贡献
--

[](#贡献)

-

###  Health Score

29

—

LowBetter than 57% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity16

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity59

Maturing project, gaining track record

 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

Every ~0 days

Total

2

Last Release

3137d ago

Major Versions

1.0 → 2.02017-11-28

PHP version history (2 changes)1.0PHP &gt;=5.5.9

2.0PHP &gt;=7.0.0

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/856748?v=4)[James Ross](/maintainers/cherry)[@Cherry](https://github.com/Cherry)

---

Top Contributors

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

---

Tags

directmail

### Embed Badge

![Health badge](/badges/cherrytools-directmail/health.svg)

```
[![Health](https://phpackages.com/badges/cherrytools-directmail/health.svg)](https://phpackages.com/packages/cherrytools-directmail)
```

###  Alternatives

[aws/aws-sdk-php

AWS SDK for PHP - Use Amazon Web Services in your PHP project

6.2k532.1M2.5k](/packages/aws-aws-sdk-php)[neuron-core/neuron-ai

The PHP Agentic Framework.

2.0k656.1k34](/packages/neuron-core-neuron-ai)[craftcms/cms

Craft CMS

3.6k3.6M2.9k](/packages/craftcms-cms)[tencentcloud/tencentcloud-sdk-php

TencentCloudApi php sdk

3741.3M46](/packages/tencentcloud-tencentcloud-sdk-php)[tempest/framework

The PHP framework that gets out of your way.

2.2k31.1k12](/packages/tempest-framework)[guanguans/notify

Push notification SDK(AnPush、Bark、Chanify、DingTalk、Discord、Gitter、GoogleChat、IGot、Lark、Mattermost、MicrosoftTeams、NotifyX、NowPush、Ntfy、Push、Pushback、PushBullet、PushDeer、PushMe、Pushover、PushPlus、QQ、RocketChat、ServerChan、ShowdocPush、SimplePush、Slack、Telegram、WeWork、WPush、XiZhi、YiFengChuanHua、ZohoCliq、ZohoCliqWebHook、Zulip).

686111.2k8](/packages/guanguans-notify)

PHPackages © 2026

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