PHPackages                             jundayw/message - 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. jundayw/message

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

jundayw/message
===============

Integrates with SMS, DingTalk, and WeChat through a single API, and supports customizable channels.

v0.1.0(3mo ago)04↓90%MITPHPPHP ^8.0

Since Apr 2Pushed 3mo agoCompare

[ Source](https://github.com/jundayw/message)[ Packagist](https://packagist.org/packages/jundayw/message)[ Docs](https://github.com/jundayw/message)[ RSS](/packages/jundayw-message/feed)WikiDiscussions main Synced 1mo ago

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

Message
=======

[](#message)

Integrates with SMS, DingTalk, and WeChat through a single API, and supports customizable channels.

[![GitHub Tag](https://camo.githubusercontent.com/da3fb9208b2dd81df04709f0f6c3171103dc87e1da126c059f099af98a645705/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f762f7461672f6a756e646179772f6d657373616765)](https://github.com/jundayw/message/tags)[![Total Downloads](https://camo.githubusercontent.com/ea1b2440bfd1e17196643230f1941631b1c5133802f309c43006e6c179251215/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f6a756e646179772f6d6573736167653f7374796c653d666c61742d737175617265)](https://packagist.org/packages/jundayw/message)[![Packagist Version](https://camo.githubusercontent.com/267a5d713a193008b96eecb035fd6d06276f9a127ee6e0ddaef14fc741596eab/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f6a756e646179772f6d657373616765)](https://packagist.org/packages/jundayw/message)[![Packagist PHP Version Support](https://camo.githubusercontent.com/22256839f9c6ffad3cf723011d2253d5d95ed5c3234ae52583acfa94a0fbeb61/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f7068702d762f6a756e646179772f6d657373616765)](https://github.com/jundayw/message)[![Packagist License](https://camo.githubusercontent.com/d566d2070ab5be7819dc966a686a30b4dfd772aff9f21a94c39f4eef7fed662e/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f6c6963656e73652f6a756e646179772f6d657373616765)](https://github.com/jundayw/message)

 Table of Contents1. [Installation](#installation)
2. [Usage](#usage)
3. [Contributing](#contributing)
4. [Contributors](#contributors)
5. [License](#license)

Installation
------------

[](#installation)

You can install the package via [Composer](https://getcomposer.org):

```
composer require jundayw/message
```

\[[back to top](#readme-top)\]

Usage
-----

[](#usage)

### SMS

[](#sms)

method `send`: specify templateCode, templateParam, and signName explicitly (with a placeholder signName that gets

```
Message::channel('sms')->send(['136****5922'], [
    'templateCode'  => 'SMS_275***212',
    'templateParam' => [
        'code' => 123454,
    ],
    'signName'      => '${signName}',
], [
    'signName' => 'aliyun',
]);
```

#### Custom template sending:

[](#custom-template-sending)

uses a logical template name (e.g., 'demo') instead of the provider's template code

```
Message::channel('sms')->sendTemplate(['136****5922'], 'demo', [
    'code' => 234567,
]);
```

### Service provider template number:

[](#service-provider-template-number)

directly uses the provider's official template code (e.g., 'SMS\_275\*\*\*212')

```
Message::channel('sms')->sendTemplate(['136****5922'], 'SMS_275***212', [
    'code' => 345678,
]);
```

### DingTalk

[](#dingtalk)

```
$message = Message::channel('dingtalk_robot')->send(['136****5922'], [
    'msgtype' => 'text',
    'text'    => [
        'content' => 'message.dingtalk_robot.send',
    ],
]);
```

#### Custom template sending:

[](#custom-template-sending-1)

```
return [
    'channels' => [
        'dingtalk_robot' => [
            'webhook'   => env('DINGTALK_ROBOT_WEBHOOK'),
            'secret'    => env('DINGTALK_ROBOT_SECRET'),
            'templates' => [
                'demo' => [
                    'msgtype' => 'text',
                    'text'    => [
                        'content' => '${content}',
                    ],
                ],
            ],
        ],
    ],
];
```

```
$message = Message::channel('dingtalk_robot')->sendTemplate(['136****5922'], 'demo', [], [
    'content' => 'message.dingtalk_robot.send',
    'at_all'  => true,
]);
```

```
$message = Message::channel('dingtalk_robot')->sendTemplate(['136****5922'], 'text', [
    'text' => [
        'content' => 'message.dingtalk_robot.send',
    ],
]);
```

### WeChat

[](#wechat)

#### WechatMiniProgram

[](#wechatminiprogram)

```
$message = Message::channel('wechat_mini_program')->send(['oDx1b*****C3o0'], [
    'template_id' => '1pNJGVRYV***ozu1AJKUlbGQ',
    'page'        => 'index',
    'data'        => [
        'thing1' => ['value' => '验证码'],
        'thing2' => ['value' => '登录验证'],
    ],
]);
$message = Message::channel('wechat_mini_program')->sendTemplate(['oDx1b*****C3o0'], '1pNJGVRYV***ozu1AJKUlbGQ', [
    'page' => '${page}',
    'data' => [
        'thing1' => ['value' => '${data.thing1}'],
        'thing2' => '登录验证',
    ],
], [
    'page' => 'page',
    'data' => [
        'thing1' => '验证码',
    ],
]);
```

#### WechatOfficialAccount

[](#wechatofficialaccount)

```
$message = Message::channel('wechat_official_account')->sendTemplate(['oDx1b*****C3o0'], '1pNJGVRYV***ozu1AJKUlbGQ', [
    'data' => [
        'thing1' => ['value' => '验证码'],
        'thing2' => '登录验证',
    ],
]);
```

#### WechatServiceAccount

[](#wechatserviceaccount)

```
$message = Message::channel('wechat_service_account')->sendTemplate(['oDx1b*****C3o0'], '1pNJGVRYV***ozu1AJKUlbGQ', [
    'page' => '${page}',
    'data' => [
        'thing1' => ['value' => '验证码'],
        'thing2' => '登录验证',
    ],
], [
    'page' => 'page',
]);
```

### WeWork

[](#wework)

```
$message = Message::channel('wework_robot')->send(['oDx1b*****C3o0'], [
    'msgtype' => 'text',
    'text'    => [
        'content' => 'message.wework_robot.send',
    ],
]);
```

```
$message = Message::channel('wework_robot')->sendTemplate(['oDx1b*****C3o0'], 'demo', [
    'text' => [
        'content' => '${content}',
    ],
], [
    'content' => 'content',
    'at_all'  => true,
]);
```

Contributing
------------

[](#contributing)

Contributions are what make the open source community such an amazing place to learn, inspire, and create. Any contributions you make are **greatly appreciated**.

If you have a suggestion that would make this better, please fork the repo and create a pull request. You can also simply open an issue with the tag "enhancement". Don't forget to give the project a star! Thanks again!

1. Fork the Project
2. Create your Feature Branch (`git checkout -b feature/AmazingFeature`)
3. Commit your Changes (`git commit -m 'Add some AmazingFeature'`)
4. Push to the Branch (`git push origin feature/AmazingFeature`)
5. Open a Pull Request

\[[back to top](#readme-top)\]

Contributors
------------

[](#contributors)

Thanks goes to these wonderful people:

[ ![contrib.rocks image](https://camo.githubusercontent.com/3ea3847c7538dbb3cef1356d22a04aa93b79c6b28a4bf65320145f461b801f05/68747470733a2f2f636f6e747269622e726f636b732f696d6167653f7265706f3d6a756e646179772f6d657373616765)](https://github.com/jundayw/message/graphs/contributors)Contributions of any kind are welcome!

\[[back to top](#readme-top)\]

License
-------

[](#license)

Distributed under the MIT License (MIT). Please see [License File](https://github.com/jundayw/message/blob/main/LICENSE) for more information.

\[[back to top](#readme-top)\]

###  Health Score

31

—

LowBetter than 66% of packages

Maintenance82

Actively maintained with recent releases

Popularity3

Limited adoption so far

Community6

Small or concentrated contributor base

Maturity29

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

91d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/16873970?v=4)[Xander Moore](/maintainers/jundayw)[@jundayw](https://github.com/jundayw)

---

Top Contributors

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

---

Tags

smswechatdingtalkweworkWeChat OfficialWeChat ServiceWeChat Mini-Programs

### Embed Badge

![Health badge](/badges/jundayw-message/health.svg)

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

###  Alternatives

[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).

687114.3k8](/packages/guanguans-notify)[mageplaza/module-smtp

SMTP Extension for Magento 2 helps the owner of store simply install SMTP (Simple Mail Transfer Protocol) server which transmits the messages into codes or numbers

3116.2M9](/packages/mageplaza-module-smtp)[laravel-notification-channels/twilio

Provides Twilio notification channel for Laravel

2588.4M17](/packages/laravel-notification-channels-twilio)[cmdotcom/text-sdk-php

PHP SDK to send messages with CM.com

25745.0k4](/packages/cmdotcom-text-sdk-php)[symfony/fake-sms-notifier

Fake SMS (as email or log during development) Notifier Bridge.

27863.3k1](/packages/symfony-fake-sms-notifier)[symfony/twilio-notifier

Symfony Twilio Notifier Bridge

131.3M2](/packages/symfony-twilio-notifier)

PHPackages © 2026

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