PHPackages                             strayjoke/dogsms - 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. strayjoke/dogsms

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

strayjoke/dogsms
================

a package for send sms

1.0.0(6y ago)02MITPHPCI failing

Since May 4Pushed 6y agoCompare

[ Source](https://github.com/strayjoke/dogsms)[ Packagist](https://packagist.org/packages/strayjoke/dogsms)[ RSS](/packages/strayjoke-dogsms/feed)WikiDiscussions master Synced 3w ago

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

 dogsms
========

[](#-dogsms-)

 发送短信的php开发包, 支持阿里云短信和腾讯云短信

- [![travis-ci](https://camo.githubusercontent.com/6c93132b4a848d64b7c6dddaa8e5d223873567ba641853ed18318652c50a9a73/68747470733a2f2f7472617669732d63692e6f72672f73747261796a6f6b652f646f67736d732e7376673f6272616e63683d6d6173746572)](https://camo.githubusercontent.com/6c93132b4a848d64b7c6dddaa8e5d223873567ba641853ed18318652c50a9a73/68747470733a2f2f7472617669732d63692e6f72672f73747261796a6f6b652f646f67736d732e7376673f6272616e63683d6d6173746572)
- [![StyleCI build status](https://camo.githubusercontent.com/831d778f683362f2de694f23fd13ef694c4e0e9b70da889f60ef4d4d6b8d33d6/68747470733a2f2f6769746875622e7374796c6563692e696f2f7265706f732f3234373639353030312f736869656c64)](https://camo.githubusercontent.com/831d778f683362f2de694f23fd13ef694c4e0e9b70da889f60ef4d4d6b8d33d6/68747470733a2f2f6769746875622e7374796c6563692e696f2f7265706f732f3234373639353030312f736869656c64)

安装
--

[](#安装)

```
$ composer require strayjoke/dogsms -vvv

```

用法
--

[](#用法)

目前只支持国内短信(+86),不支持群发短信。

#### 配置

[](#配置)

```
$config =[
    // 默认发送配置
    'default' => [
        // 默认可用的发送网关
        'gateways' => [
            'alibabaCloud', 'tencentCloud',
        ],
    ],
    // 可用的网关配置
    'gateways' => [
        'tencentCloud' => [
            'secret_id' => 'AKIDTijUzFxxxxxxxxxxxxx', //密钥id
            'secret_key' => 'QcdXBXcT5xxxxxxxxxxxxx', //密钥
            'sign_name' => 'xxxx',               //短信签名
        ],
        'alibabaCloud' => [
            'access_key_id' => 'LTAIMjVxxxxxxxx',     //密钥id
            'access_key_secret' => 'NnE90xxxxxxxxx',   //密钥
            'sign_name' => 'xxxxx',     //短信签名
        ]
    ]
];

```

#### 调用方法

[](#调用方法)

```
use Strayjoke\Dogsms\Dogsms;

$sms = new Dogsms($config);

$sms->sendSms(17533333333,
    [
        'alibabaCloud' => 'aliCode',      //短信模板编号， `alibabacloud` 对应配置文件里的 `alibabacloud`
        'tencentCloud' => 'tencentCode'   //短信模板编号， `tencentCloud` 对应配置文件里的 `tencentCloud`
    ],
    [
        'code' =>1234 //短信模板的参数，阿里云和腾讯云公用参数。其中阿里云短信需要提供数组key， 腾讯云不需要提供。
    ]
);

```

License
-------

[](#license)

MIT

###  Health Score

24

—

LowBetter than 31% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity2

Limited adoption so far

Community8

Small or concentrated contributor base

Maturity57

Maturing project, gaining track record

 Bus Factor1

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

2252d ago

### Community

Maintainers

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

---

Top Contributors

[![matteao03](https://avatars.githubusercontent.com/u/29540820?v=4)](https://github.com/matteao03 "matteao03 (13 commits)")[![strayjoke](https://avatars.githubusercontent.com/u/62241020?v=4)](https://github.com/strayjoke "strayjoke (4 commits)")

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/strayjoke-dogsms/health.svg)

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

###  Alternatives

[aws/aws-sdk-php

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

6.3k543.5M2.6k](/packages/aws-aws-sdk-php)[neuron-core/neuron-ai

The PHP Agentic Framework.

2.0k656.1k38](/packages/neuron-core-neuron-ai)[tencentcloud/tencentcloud-sdk-php

TencentCloudApi php sdk

3741.3M45](/packages/tencentcloud-tencentcloud-sdk-php)[civicrm/civicrm-core

Open source constituent relationship management for non-profits, NGOs and advocacy organizations.

751291.4k43](/packages/civicrm-civicrm-core)[spatie/laravel-export

Create a static site bundle from a Laravel app

674146.0k6](/packages/spatie-laravel-export)[oat-sa/tao-core

TAO core extension

66143.7k124](/packages/oat-sa-tao-core)

PHPackages © 2026

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