mirror of
https://github.com/louislam/uptime-kuma.git
synced 2025-08-08 13:51:32 +08:00
Add JSDoc to server/notification-providers/*
Signed-off-by: Matthew Nickson <mnickson@sidingsmedia.com>
This commit is contained in:
@@ -37,6 +37,12 @@ class AliyunSMS extends NotificationProvider {
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Send the SMS notification
|
||||
* @param {BeanModel} notification Notification details
|
||||
* @param {string} msgbody Message template
|
||||
* @returns {boolean} True if successful else false
|
||||
*/
|
||||
async sendSms(notification, msgbody) {
|
||||
let params = {
|
||||
PhoneNumbers: notification.phonenumber,
|
||||
@@ -70,7 +76,12 @@ class AliyunSMS extends NotificationProvider {
|
||||
return false;
|
||||
}
|
||||
|
||||
/** Aliyun request sign */
|
||||
/**
|
||||
* Aliyun request sign
|
||||
* @param {Object} param Parameters object to sign
|
||||
* @param {string} AccessKeySecret Secret key to sign parameters with
|
||||
* @returns {string}
|
||||
*/
|
||||
sign(param, AccessKeySecret) {
|
||||
let param2 = {};
|
||||
let data = [];
|
||||
@@ -93,6 +104,11 @@ class AliyunSMS extends NotificationProvider {
|
||||
.digest("base64");
|
||||
}
|
||||
|
||||
/**
|
||||
* Convert status constant to string
|
||||
* @param {const} status The status constant
|
||||
* @returns {string}
|
||||
*/
|
||||
statusToString(status) {
|
||||
switch (status) {
|
||||
case DOWN:
|
||||
|
Reference in New Issue
Block a user