smsir_mh_js6
Advanced tools
Comparing version 1.0.0 to 1.0.1
{ | ||
"name": "smsir_mh_js6", | ||
"version": "1.0.0", | ||
"version": "1.0.1", | ||
"description": "This package is for using SMS service from sms.ir should get API and templetId from sms.ir javaScript, ES6 support", | ||
@@ -8,3 +8,3 @@ "main": "smsir_mh_js6.js", | ||
"scripts": { | ||
"test": "echo \"Error: no test specified\" && exit 1" | ||
"test": "jest" | ||
}, | ||
@@ -24,3 +24,10 @@ "repository": { | ||
"axios": "^1.7.2" | ||
}, | ||
"devDependencies": { | ||
"@babel/preset-env": "^7.24.7", | ||
"axios-mock-adapter": "^1.22.0", | ||
"babel-jest": "^29.7.0", | ||
"jest": "^29.7.0", | ||
"jest-mock-axios": "^4.7.3" | ||
} | ||
} | ||
} |
# smsir_mh_js6 | ||
This package is for using SMS service from sms.ir should get API and templetId from sms.ir javaScript, ES6 support | ||
@@ -6,2 +7,17 @@ | ||
## Test Resalt | ||
```bash | ||
npm test | ||
PASS ./smsir_mh_js6.test.js | ||
sendAlertSMSIR | ||
√ should send a message successfully (33 ms) | ||
√ should handle a request error (130 ms) | ||
√ should handle a response error (12ms) | ||
Test Suites: 1 passed, 1 total | ||
Tests: 3 passed, 3 total | ||
Snapshots: 0 total | ||
Time: 1.157 s | ||
Ran all test suites. | ||
``` | ||
## Author | ||
@@ -12,3 +28,3 @@ | ||
Donate address : TS3ZnWGHfDnW7FcG8p6BYrWAis2nzX3gDG //USDT TRC20 | ||
Donate address : `TS3ZnWGHfDnW7FcG8p6BYrWAis2nzX3gDG` //USDT TRC20 | ||
@@ -18,2 +34,3 @@ ## Installation | ||
To install the package, run: | ||
```bash | ||
@@ -25,19 +42,24 @@ | ||
``` | ||
```bash | ||
#yarn | ||
yarn add axios | ||
yarn add smsir_mh_js6 | ||
``` | ||
# Example use: | ||
```bash | ||
import SendAlertSMSIR from 'smsir_mh_js6'; | ||
const apiKey = '121212121212121212121'; //Example API Key | ||
const apiKey = '121212121212121212121'; //Example API Key | ||
const to = '09100059323'; //Example Phone Number | ||
const message = 'Hello,this test message!'; //Max 24 Character Length | ||
const templateId = '750016'; //Example template ID | ||
const templateId = '750016'; //Example template ID | ||
SendAlertSMSIR(to, message, apiKey, templateId); | ||
``` | ||
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
No tests
QualityPackage does not have any tests. This is a strong signal of a poorly maintained or low quality package.
Found 1 instance in 1 package
5516
7
101
1
62
5