Socket
Socket
Sign inDemoInstall

@blueshit/aliyun-sms

Package Overview
Dependencies
0
Maintainers
2
Versions
2
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    @blueshit/aliyun-sms

轻量级阿里大于短信客户端,不依赖任何第三方库,体验飞一般的感觉


Version published
Maintainers
2
Install size
8.28 kB
Created

Readme

Source

@blueshit/aliyun-sts

轻量级阿里大于短信客户端,不依赖任何第三方库,体验飞一般的感觉

安装

npm i @blueshit/aliyun-sms -S

使用

const Alidayu = require("@blueshit/aliyun-sms");

// 初始化客户端
const client = new Alidayu({
  AccessKeyId: 'Your-AccessKeyId',
  AccessKeySecret: 'Your-AccessKeySecret'
});

// 发送短信
client.sms({
  phone: 13800138000,
  sign: '签名',
  template: 'SMS_8xxxxx',
  params: { user: 'Yourtion' },
})
.then(console.log)
.catch(console.log);

详情参数指定

/**
* 发送短信
* @param {object} option 发送短信配置
* @param {number} option.phone 手机号
* @param {string} option.sign 签名
* @param {string} option.template 模版
* @param {object} option.params 模版参数
* @return {promise}
*/
sms(option, callback)

授权协议

The MIT License

Keywords

FAQs

Last updated on 19 Apr 2018

Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc