https://github.com/xialeistudio/node-yimei
yimei sms sdk
https://github.com/xialeistudio/node-yimei
Last synced: 2 months ago
JSON representation
yimei sms sdk
- Host: GitHub
- URL: https://github.com/xialeistudio/node-yimei
- Owner: xialeistudio
- Created: 2018-01-19T03:41:08.000Z (over 7 years ago)
- Default Branch: master
- Last Pushed: 2018-01-19T06:56:48.000Z (over 7 years ago)
- Last Synced: 2025-03-12T23:02:41.716Z (3 months ago)
- Language: TypeScript
- Size: 10.7 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# 亿美短信
## Features
+ [x] sendSMS
+ [x] sendVoice
+ [x] getBalance
+ [x] getEachFee
+ [x] login## Get Started
### Typescript Usage
```typescript
import {Client} from 'yimei';(async()=>{
const client = new Client({
serialNumber: 'SERIAL_NUMBER',
password: 'PASSWORD',
sessionKey: 'SESSION_KEY', // optional,you can login after
gatewayUrl: 'GATEWAY_URL', // optional
timeout: 5000, // optional, default is 5000ms
});
const ret = await client.sendSMS(['13666666666','13777777777'],'验证码:1111');
console.log(ret);
})();
```### Javascript Usage
```javascript
var Client = require('yimei').Client;var client = new Client({
serialNumber: 'SERIAL_NUMBER',
password: 'PASSWORD',
sessionKey: 'SESSION_KEY', // optional,you can login after
gatewayUrl: 'GATEWAY_URL', // optional
timeout: 5000, // optional, default is 5000ms
});
client.sendSMS(['13666666666','13777777777'],'验证码:1111').then(console.log).catch(console.log);
```