Merge branch 'master' into feat/status-page-summary-api

This commit is contained in:
Gero Gerke 2025-06-03 15:51:30 +02:00 committed by GitHub
commit 6bb66ec442
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
80 changed files with 2817 additions and 1264 deletions

View file

@ -0,0 +1,12 @@
exports.up = function (knex) {
return knex.schema
.alterTable("monitor", function (table) {
table.string("smtp_security").defaultTo(null);
});
};
exports.down = function (knex) {
return knex.schema.alterTable("monitor", function (table) {
table.dropColumn("smtp_security");
});
};

View file

@ -0,0 +1,24 @@
/* SQL:
ALTER TABLE monitor ADD ping_count INTEGER default 1 not null;
ALTER TABLE monitor ADD ping_numeric BOOLEAN default true not null;
ALTER TABLE monitor ADD ping_per_request_timeout INTEGER default 2 not null;
*/
exports.up = function (knex) {
// Add new columns to table monitor
return knex.schema
.alterTable("monitor", function (table) {
table.integer("ping_count").defaultTo(1).notNullable();
table.boolean("ping_numeric").defaultTo(true).notNullable();
table.integer("ping_per_request_timeout").defaultTo(2).notNullable();
});
};
exports.down = function (knex) {
return knex.schema
.alterTable("monitor", function (table) {
table.dropColumn("ping_count");
table.dropColumn("ping_numeric");
table.dropColumn("ping_per_request_timeout");
});
};

View file

@ -0,0 +1,13 @@
// Add column custom_url to monitor_group table
exports.up = function (knex) {
return knex.schema
.alterTable("monitor_group", function (table) {
table.text("custom_url", "text");
});
};
exports.down = function (knex) {
return knex.schema.alterTable("monitor_group", function (table) {
table.dropColumn("custom_url");
});
};

View file

@ -3,6 +3,7 @@ console.log("== Uptime Kuma Reset Password Tool ==");
const Database = require("../server/database");
const { R } = require("redbean-node");
const readline = require("readline");
const { passwordStrength } = require("check-password-strength");
const { initJWTSecret } = require("../server/util-server");
const User = require("../server/model/user");
const { io } = require("socket.io-client");
@ -42,8 +43,15 @@ const main = async () => {
console.log("Using password from argument");
console.warn("\x1b[31m%s\x1b[0m", "Warning: the password might be stored, in plain text, in your shell's history");
password = confirmPassword = args["new-password"] + "";
if (passwordStrength(password).value === "Too weak") {
throw new Error("Password is too weak, please use a stronger password.");
}
} else {
password = await question("New Password: ");
if (passwordStrength(password).value === "Too weak") {
console.log("Password is too weak, please try again.");
continue;
}
confirmPassword = await question("Confirm New Password: ");
}

1881
package-lock.json generated

File diff suppressed because it is too large Load diff

View file

@ -32,7 +32,7 @@
"test-e2e-ui": "playwright test --config ./config/playwright.config.js --ui --ui-port=51063",
"playwright-codegen": "playwright codegen localhost:3000 --save-storage=./private/e2e-auth.json",
"playwright-show-report": "playwright show-report ./private/playwright-report",
"tsc": "tsc",
"tsc": "tsc --project ./tsconfig-backend.json",
"vite-preview-dist": "vite preview --host --config ./config/vite.config.js",
"build-docker-base": "docker buildx build -f docker/debian-base.dockerfile --platform linux/amd64,linux/arm64,linux/arm/v7 -t louislam/uptime-kuma:base2 --target base2 . --push",
"build-docker-base-slim": "docker buildx build -f docker/debian-base.dockerfile --platform linux/amd64,linux/arm64,linux/arm/v7 -t louislam/uptime-kuma:base2-slim --target base2-slim . --push",
@ -72,7 +72,7 @@
"@louislam/sqlite3": "15.1.6",
"@vvo/tzdb": "^6.125.0",
"args-parser": "~1.3.0",
"axios": "~0.29.0",
"axios": "~0.30.0",
"badge-maker": "~3.3.1",
"bcryptjs": "~2.4.3",
"chardet": "~1.4.0",
@ -82,6 +82,7 @@
"command-exists": "~1.2.9",
"compare-versions": "~3.6.0",
"compression": "~1.7.4",
"country-flag-emoji-polyfill": "^0.1.8",
"croner": "~8.1.0",
"dayjs": "~1.11.5",
"dev-null": "^0.1.1",

View file

@ -736,7 +736,7 @@ class Database {
if (Database.dbConfig.type === "sqlite") {
return "DATETIME('now', ? || ' hours')";
} else {
return "DATE_ADD(NOW(), INTERVAL ? HOUR)";
return "DATE_ADD(UTC_TIMESTAMP(), INTERVAL ? HOUR)";
}
}

View file

@ -34,7 +34,7 @@ class Group extends BeanModel {
*/
async getMonitorList() {
return R.convertToBeans("monitor", await R.getAll(`
SELECT monitor.*, monitor_group.send_url FROM monitor, monitor_group
SELECT monitor.*, monitor_group.send_url, monitor_group.custom_url FROM monitor, monitor_group
WHERE monitor.id = monitor_group.monitor_id
AND group_id = ?
ORDER BY monitor_group.weight

View file

@ -2,7 +2,11 @@ const dayjs = require("dayjs");
const axios = require("axios");
const { Prometheus } = require("../prometheus");
const { log, UP, DOWN, PENDING, MAINTENANCE, flipStatus, MAX_INTERVAL_SECOND, MIN_INTERVAL_SECOND,
SQL_DATETIME_FORMAT, evaluateJsonQuery
SQL_DATETIME_FORMAT, evaluateJsonQuery,
PING_PACKET_SIZE_MIN, PING_PACKET_SIZE_MAX, PING_PACKET_SIZE_DEFAULT,
PING_GLOBAL_TIMEOUT_MIN, PING_GLOBAL_TIMEOUT_MAX, PING_GLOBAL_TIMEOUT_DEFAULT,
PING_COUNT_MIN, PING_COUNT_MAX, PING_COUNT_DEFAULT,
PING_PER_REQUEST_TIMEOUT_MIN, PING_PER_REQUEST_TIMEOUT_MAX, PING_PER_REQUEST_TIMEOUT_DEFAULT
} = require("../../src/util");
const { tcping, ping, checkCertificate, checkStatusCode, getTotalClientInRoom, setting, mssqlQuery, postgresQuery, mysqlQuery, setSetting, httpNtlm, radius, grpcQuery,
redisPingAsync, kafkaProducerAsync, getOidcTokenClientCredentials, rootCertificatesFingerprints, axiosAbortSignal
@ -69,7 +73,7 @@ class Monitor extends BeanModel {
};
if (this.sendUrl) {
obj.url = this.url;
obj.url = this.customUrl ?? this.url;
}
if (showTags) {
@ -174,8 +178,14 @@ class Monitor extends BeanModel {
snmpOid: this.snmpOid,
jsonPathOperator: this.jsonPathOperator,
snmpVersion: this.snmpVersion,
smtpSecurity: this.smtpSecurity,
rabbitmqNodes: JSON.parse(this.rabbitmqNodes),
conditions: JSON.parse(this.conditions),
// ping advanced options
ping_numeric: this.isPingNumeric(),
ping_count: this.ping_count,
ping_per_request_timeout: this.ping_per_request_timeout,
};
if (includeSensitiveData) {
@ -268,6 +278,14 @@ class Monitor extends BeanModel {
return Boolean(this.expiryNotification);
}
/**
* Check if ping should use numeric output only
* @returns {boolean} True if IP addresses will be output instead of symbolic hostnames
*/
isPingNumeric() {
return Boolean(this.ping_numeric);
}
/**
* Parse to boolean
* @returns {boolean} Should TLS errors be ignored?
@ -401,39 +419,6 @@ class Monitor extends BeanModel {
if (await Monitor.isUnderMaintenance(this.id)) {
bean.msg = "Monitor under maintenance";
bean.status = MAINTENANCE;
} else if (this.type === "group") {
const children = await Monitor.getChildren(this.id);
if (children.length > 0) {
bean.status = UP;
bean.msg = "All children up and running";
for (const child of children) {
if (!child.active) {
// Ignore inactive childs
continue;
}
const lastBeat = await Monitor.getPreviousHeartbeat(child.id);
// Only change state if the monitor is in worse conditions then the ones before
// lastBeat.status could be null
if (!lastBeat) {
bean.status = PENDING;
} else if (bean.status === UP && (lastBeat.status === PENDING || lastBeat.status === DOWN)) {
bean.status = lastBeat.status;
} else if (bean.status === PENDING && lastBeat.status === DOWN) {
bean.status = lastBeat.status;
}
}
if (bean.status !== UP) {
bean.msg = "Child inaccessible";
}
} else {
// Set status pending if group is empty
bean.status = PENDING;
bean.msg = "Group empty";
}
} else if (this.type === "http" || this.type === "keyword" || this.type === "json-query") {
// Do not do any queries/high loading things before the "bean.ping"
let startTime = dayjs().valueOf();
@ -638,7 +623,7 @@ class Monitor extends BeanModel {
bean.status = UP;
} else if (this.type === "ping") {
bean.ping = await ping(this.hostname, this.packetSize);
bean.ping = await ping(this.hostname, this.ping_count, "", this.ping_numeric, this.packetSize, this.timeout, this.ping_per_request_timeout);
bean.msg = "";
bean.status = UP;
} else if (this.type === "push") { // Type: Push
@ -710,7 +695,7 @@ class Monitor extends BeanModel {
bean.msg = res.data.response.servers[0].name;
try {
bean.ping = await ping(this.hostname, this.packetSize);
bean.ping = await ping(this.hostname, PING_COUNT_DEFAULT, "", true, this.packetSize, PING_GLOBAL_TIMEOUT_DEFAULT, PING_PER_REQUEST_TIMEOUT_DEFAULT);
} catch (_) { }
} else {
throw new Error("Server not found on Steam");
@ -1348,7 +1333,8 @@ class Monitor extends BeanModel {
try {
const heartbeatJSON = bean.toJSON();
const monitorData = [{ id: monitor.id,
active: monitor.active
active: monitor.active,
name: monitor.name
}];
const preloadData = await Monitor.preparePreloadData(monitorData);
// Prevent if the msg is undefined, notifications such as Discord cannot send out.
@ -1521,6 +1507,31 @@ class Monitor extends BeanModel {
if (this.interval < MIN_INTERVAL_SECOND) {
throw new Error(`Interval cannot be less than ${MIN_INTERVAL_SECOND} seconds`);
}
if (this.type === "ping") {
// ping parameters validation
if (this.packetSize && (this.packetSize < PING_PACKET_SIZE_MIN || this.packetSize > PING_PACKET_SIZE_MAX)) {
throw new Error(`Packet size must be between ${PING_PACKET_SIZE_MIN} and ${PING_PACKET_SIZE_MAX} (default: ${PING_PACKET_SIZE_DEFAULT})`);
}
if (this.ping_per_request_timeout && (this.ping_per_request_timeout < PING_PER_REQUEST_TIMEOUT_MIN || this.ping_per_request_timeout > PING_PER_REQUEST_TIMEOUT_MAX)) {
throw new Error(`Per-ping timeout must be between ${PING_PER_REQUEST_TIMEOUT_MIN} and ${PING_PER_REQUEST_TIMEOUT_MAX} seconds (default: ${PING_PER_REQUEST_TIMEOUT_DEFAULT})`);
}
if (this.ping_count && (this.ping_count < PING_COUNT_MIN || this.ping_count > PING_COUNT_MAX)) {
throw new Error(`Echo requests count must be between ${PING_COUNT_MIN} and ${PING_COUNT_MAX} (default: ${PING_COUNT_DEFAULT})`);
}
if (this.timeout) {
const pingGlobalTimeout = Math.round(Number(this.timeout));
if (pingGlobalTimeout < this.ping_per_request_timeout || pingGlobalTimeout < PING_GLOBAL_TIMEOUT_MIN || pingGlobalTimeout > PING_GLOBAL_TIMEOUT_MAX) {
throw new Error(`Timeout must be between ${PING_GLOBAL_TIMEOUT_MIN} and ${PING_GLOBAL_TIMEOUT_MAX} seconds (default: ${PING_GLOBAL_TIMEOUT_DEFAULT})`);
}
this.timeout = pingGlobalTimeout;
}
}
}
/**
@ -1646,7 +1657,7 @@ class Monitor extends BeanModel {
/**
* Gets all Children of the monitor
* @param {number} monitorID ID of monitor to get
* @returns {Promise<LooseObject<any>>} Children
* @returns {Promise<LooseObject<any>[]>} Children
*/
static async getChildren(monitorID) {
return await R.getAll(`

View file

@ -34,12 +34,16 @@ class DnsMonitorType extends MonitorType {
switch (monitor.dns_resolve_type) {
case "A":
case "AAAA":
case "TXT":
case "PTR":
dnsMessage = `Records: ${dnsRes.join(" | ")}`;
conditionsResult = dnsRes.some(record => handleConditions({ record }));
break;
case "TXT":
dnsMessage = `Records: ${dnsRes.join(" | ")}`;
conditionsResult = dnsRes.flat().some(record => handleConditions({ record }));
break;
case "CNAME":
dnsMessage = dnsRes[0];
conditionsResult = handleConditions({ record: dnsRes[0] });

View file

@ -0,0 +1,49 @@
const { UP, PENDING, DOWN } = require("../../src/util");
const { MonitorType } = require("./monitor-type");
const Monitor = require("../model/monitor");
class GroupMonitorType extends MonitorType {
name = "group";
/**
* @inheritdoc
*/
async check(monitor, heartbeat, _server) {
const children = await Monitor.getChildren(monitor.id);
if (children.length > 0) {
heartbeat.status = UP;
heartbeat.msg = "All children up and running";
for (const child of children) {
if (!child.active) {
// Ignore inactive childs
continue;
}
const lastBeat = await Monitor.getPreviousHeartbeat(child.id);
// Only change state if the monitor is in worse conditions then the ones before
// lastBeat.status could be null
if (!lastBeat) {
heartbeat.status = PENDING;
} else if (heartbeat.status === UP && (lastBeat.status === PENDING || lastBeat.status === DOWN)) {
heartbeat.status = lastBeat.status;
} else if (heartbeat.status === PENDING && lastBeat.status === DOWN) {
heartbeat.status = lastBeat.status;
}
}
if (heartbeat.status !== UP) {
heartbeat.msg = "Child inaccessible";
}
} else {
// Set status pending if group is empty
heartbeat.status = PENDING;
heartbeat.msg = "Group empty";
}
}
}
module.exports = {
GroupMonitorType,
};

View file

@ -0,0 +1,35 @@
const { MonitorType } = require("./monitor-type");
const { UP } = require("../../src/util");
const nodemailer = require("nodemailer");
class SMTPMonitorType extends MonitorType {
name = "smtp";
/**
* @inheritdoc
*/
async check(monitor, heartbeat, _server) {
let options = {
port: monitor.port || 25,
host: monitor.hostname,
secure: monitor.smtpSecurity === "secure", // use SMTPS (not STARTTLS)
ignoreTLS: monitor.smtpSecurity === "nostarttls", // don't use STARTTLS even if it's available
requireTLS: monitor.smtpSecurity === "starttls", // use STARTTLS or fail
};
let transporter = nodemailer.createTransport(options);
try {
await transporter.verify();
heartbeat.status = UP;
heartbeat.msg = "SMTP connection verifies successfully";
} catch (e) {
throw new Error(`SMTP connection doesn't verify: ${e}`);
} finally {
transporter.close();
}
}
}
module.exports = {
SMTPMonitorType,
};

View file

@ -46,10 +46,10 @@ class Discord extends NotificationProvider {
name: "Service Name",
value: monitorJSON["name"],
},
{
...(!notification.disableUrl ? [{
name: monitorJSON["type"] === "push" ? "Service Type" : "Service URL",
value: this.extractAddress(monitorJSON),
},
}] : []),
{
name: `Time (${heartbeatJSON["timezone"]})`,
value: heartbeatJSON["localDateTime"],
@ -83,10 +83,10 @@ class Discord extends NotificationProvider {
name: "Service Name",
value: monitorJSON["name"],
},
{
...(!notification.disableUrl ? [{
name: monitorJSON["type"] === "push" ? "Service Type" : "Service URL",
value: this.extractAddress(monitorJSON),
},
}] : []),
{
name: `Time (${heartbeatJSON["timezone"]})`,
value: heartbeatJSON["localDateTime"],

View file

@ -73,13 +73,13 @@ class FlashDuty extends NotificationProvider {
}
const options = {
method: "POST",
url: "https://api.flashcat.cloud/event/push/alert/standard?integration_key=" + notification.flashdutyIntegrationKey,
url: notification.flashdutyIntegrationKey.startsWith("http") ? notification.flashdutyIntegrationKey : "https://api.flashcat.cloud/event/push/alert/standard?integration_key=" + notification.flashdutyIntegrationKey,
headers: { "Content-Type": "application/json" },
data: {
description: `[${title}] [${monitorInfo.name}] ${body}`,
title,
event_status: eventStatus || "Info",
alert_key: String(monitorInfo.id) || Math.random().toString(36).substring(7),
alert_key: monitorInfo.id ? String(monitorInfo.id) : Math.random().toString(36).substring(7),
labels,
}
};

View file

@ -0,0 +1,53 @@
const { getMonitorRelativeURL, UP } = require("../../src/util");
const { setting } = require("../util-server");
const NotificationProvider = require("./notification-provider");
const axios = require("axios");
class Notifery extends NotificationProvider {
name = "notifery";
/**
* @inheritdoc
*/
async send(notification, msg, monitorJSON = null, heartbeatJSON = null) {
const okMsg = "Sent Successfully.";
const url = "https://api.notifery.com/event";
let data = {
title: notification.notiferyTitle || "Uptime Kuma Alert",
message: msg,
};
if (notification.notiferyGroup) {
data.group = notification.notiferyGroup;
}
// Link to the monitor
const baseURL = await setting("primaryBaseURL");
if (baseURL && monitorJSON) {
data.message += `\n\nMonitor: ${baseURL}${getMonitorRelativeURL(monitorJSON.id)}`;
}
if (heartbeatJSON) {
data.code = heartbeatJSON.status === UP ? 0 : 1;
if (heartbeatJSON.ping) {
data.duration = heartbeatJSON.ping;
}
}
try {
const headers = {
"Content-Type": "application/json",
"x-api-key": notification.notiferyApiKey,
};
await axios.post(url, data, { headers });
return okMsg;
} catch (error) {
this.throwGeneralAxiosError(error);
}
}
}
module.exports = Notifery;

View file

@ -0,0 +1,73 @@
const NotificationProvider = require("./notification-provider");
const axios = require("axios");
const { DOWN, UP } = require("../../src/util");
class OneChat extends NotificationProvider {
name = "OneChat";
/**
* @inheritdoc
*/
async send(notification, msg, monitorJSON = null, heartbeatJSON = null) {
const okMsg = "Sent Successfully.";
const url = "https://chat-api.one.th/message/api/v1/push_message";
try {
const config = {
headers: {
"Content-Type": "application/json",
Authorization: "Bearer " + notification.accessToken,
},
};
if (heartbeatJSON == null) {
const testMessage = {
to: notification.recieverId,
bot_id: notification.botId,
type: "text",
message: "Test Successful!",
};
await axios.post(url, testMessage, config);
} else if (heartbeatJSON["status"] === DOWN) {
const downMessage = {
to: notification.recieverId,
bot_id: notification.botId,
type: "text",
message:
`UptimeKuma Alert:
[🔴 Down]
Name: ${monitorJSON["name"]}
${heartbeatJSON["msg"]}
Time (${heartbeatJSON["timezone"]}): ${heartbeatJSON["localDateTime"]}`,
};
await axios.post(url, downMessage, config);
} else if (heartbeatJSON["status"] === UP) {
const upMessage = {
to: notification.recieverId,
bot_id: notification.botId,
type: "text",
message:
`UptimeKuma Alert:
[🟢 Up]
Name: ${monitorJSON["name"]}
${heartbeatJSON["msg"]}
Time (${heartbeatJSON["timezone"]}): ${heartbeatJSON["localDateTime"]}`,
};
await axios.post(url, upMessage, config);
}
return okMsg;
} catch (error) {
// Handle errors and throw a descriptive message
if (error.response) {
const errorMessage =
error.response.data?.message ||
"Unknown API error occurred.";
throw new Error(`OneChat API Error: ${errorMessage}`);
} else {
this.throwGeneralAxiosError(error);
}
}
}
}
module.exports = OneChat;

View file

@ -0,0 +1,48 @@
const NotificationProvider = require("./notification-provider");
const axios = require("axios");
const { UP } = require("../../src/util");
class Pumble extends NotificationProvider {
name = "pumble";
/**
* @inheritDoc
*/
async send(notification, msg, monitorJSON = null, heartbeatJSON = null) {
const okMsg = "Sent Successfully.";
try {
if (heartbeatJSON === null && monitorJSON === null) {
let data = {
"attachments": [
{
"title": "Uptime Kuma Alert",
"text": msg,
"color": "#5BDD8B"
}
]
};
await axios.post(notification.webhookURL, data);
return okMsg;
}
let data = {
"attachments": [
{
"title": `${monitorJSON["name"]} is ${heartbeatJSON["status"] === UP ? "up" : "down"}`,
"text": heartbeatJSON["msg"],
"color": (heartbeatJSON["status"] === UP ? "#5BDD8B" : "#DC3645"),
}
]
};
await axios.post(notification.webhookURL, data);
return okMsg;
} catch (error) {
this.throwGeneralAxiosError(error);
}
}
}
module.exports = Pumble;

View file

@ -1,5 +1,6 @@
const { getMonitorRelativeURL } = require("../../src/util");
const { setting } = require("../util-server");
const { UP } = require("../../src/util");
const NotificationProvider = require("./notification-provider");
const axios = require("axios");
@ -43,15 +44,20 @@ class Pushover extends NotificationProvider {
if (heartbeatJSON == null) {
await axios.post(url, data);
return okMsg;
} else {
data.message += `\n<b>Time (${heartbeatJSON["timezone"]})</b>:${heartbeatJSON["localDateTime"]}`;
await axios.post(url, data);
return okMsg;
}
if (heartbeatJSON.status === UP && notification.pushoversounds_up) {
// default = DOWN => DOWN-sound is also played for non-UP/DOWN notiifcations
data.sound = notification.pushoversounds_up;
}
data.message += `\n<b>Time (${heartbeatJSON["timezone"]})</b>: ${heartbeatJSON["localDateTime"]}`;
await axios.post(url, data);
return okMsg;
} catch (error) {
this.throwGeneralAxiosError(error);
}
}
}

View file

@ -145,6 +145,7 @@ class Slack extends NotificationProvider {
const title = "Uptime Kuma Alert";
let data = {
"text": msg,
"channel": notification.slackchannel,
"username": notification.slackusername,
"icon_emoji": notification.slackiconemo,

View file

@ -0,0 +1,40 @@
const NotificationProvider = require("./notification-provider");
const axios = require("axios");
class SMSPlanet extends NotificationProvider {
name = "SMSPlanet";
/**
* @inheritdoc
*/
async send(notification, msg, monitorJSON = null, heartbeatJSON = null) {
const okMsg = "Sent Successfully.";
const url = "https://api2.smsplanet.pl/sms";
try {
let config = {
headers: {
"Authorization": "Bearer " + notification.smsplanetApiToken,
"content-type": "multipart/form-data"
}
};
let data = {
"from": notification.smsplanetSenderName,
"to": notification.smsplanetPhoneNumbers,
"msg": msg.replace(/🔴/, "❌")
};
let response = await axios.post(url, data, config);
if (!response.data?.messageId) {
throw new Error(response.data?.errorMsg ?? "SMSPlanet server did not respond with the expected result");
}
return okMsg;
} catch (error) {
this.throwGeneralAxiosError(error);
}
}
}
module.exports = SMSPlanet;

View file

@ -11,59 +11,127 @@ class SMSEagle extends NotificationProvider {
const okMsg = "Sent Successfully.";
try {
let config = {
headers: {
"Content-Type": "application/json",
if (notification.smseagleApiType === "smseagle-apiv1") { // according to https://www.smseagle.eu/apiv1/
let config = {
headers: {
"Content-Type": "application/x-www-form-urlencoded",
}
};
let sendMethod;
let recipientType;
let duration;
let voiceId;
if (notification.smseagleRecipientType === "smseagle-contact") {
recipientType = "contactname";
sendMethod = "/send_tocontact";
} else if (notification.smseagleRecipientType === "smseagle-group") {
recipientType = "groupname";
sendMethod = "/send_togroup";
} else if (notification.smseagleRecipientType === "smseagle-to") {
recipientType = "to";
sendMethod = "/send_sms";
if (notification.smseagleMsgType !== "smseagle-sms") {
duration = notification.smseagleDuration ?? 10;
if (notification.smseagleMsgType === "smseagle-ring") {
sendMethod = "/ring_call";
} else if (notification.smseagleMsgType === "smseagle-tts") {
sendMethod = "/tts_call";
} else if (notification.smseagleMsgType === "smseagle-tts-advanced") {
sendMethod = "/tts_adv_call";
voiceId = notification.smseagleTtsModel ? notification.smseagleTtsModel : 1;
}
}
}
};
let postData;
let sendMethod;
let recipientType;
const url = new URL(notification.smseagleUrl + "/http_api" + sendMethod);
let encoding = (notification.smseagleEncoding) ? "1" : "0";
let priority = (notification.smseaglePriority) ? notification.smseaglePriority : "0";
if (notification.smseagleRecipientType === "smseagle-contact") {
recipientType = "contactname";
sendMethod = "sms.send_tocontact";
}
if (notification.smseagleRecipientType === "smseagle-group") {
recipientType = "groupname";
sendMethod = "sms.send_togroup";
}
if (notification.smseagleRecipientType === "smseagle-to") {
recipientType = "to";
sendMethod = "sms.send_sms";
}
let params = {
access_token: notification.smseagleToken,
[recipientType]: notification.smseagleRecipient,
message: msg,
responsetype: "extended",
unicode: encoding,
highpriority: priority
};
postData = {
method: sendMethod,
params: params
};
let resp = await axios.post(notification.smseagleUrl + "/jsonrpc/sms", postData, config);
if ((JSON.stringify(resp.data)).indexOf("message_id") === -1) {
let error = "";
if (resp.data.result && resp.data.result.error_text) {
error = `SMSEagle API returned error: ${JSON.stringify(resp.data.result.error_text)}`;
url.searchParams.append("access_token", notification.smseagleToken);
url.searchParams.append(recipientType, notification.smseagleRecipient);
if (!notification.smseagleRecipientType || notification.smseagleRecipientType === "smseagle-sms") {
url.searchParams.append("unicode", (notification.smseagleEncoding) ? "1" : "0");
url.searchParams.append("highpriority", notification.smseaglePriority ?? "0");
} else {
error = "SMSEagle API returned an unexpected response";
url.searchParams.append("duration", duration);
}
if (notification.smseagleRecipientType !== "smseagle-ring") {
url.searchParams.append("message", msg);
}
if (voiceId) {
url.searchParams.append("voice_id", voiceId);
}
throw new Error(error);
}
return okMsg;
let resp = await axios.get(url.toString(), config);
if (resp.data.indexOf("OK") === -1) {
let error = `SMSEagle API returned error: ${resp.data}`;
throw new Error(error);
}
return okMsg;
} else if (notification.smseagleApiType === "smseagle-apiv2") { // according to https://www.smseagle.eu/docs/apiv2/
let config = {
headers: {
"access-token": notification.smseagleToken,
"Content-Type": "application/json",
}
};
let encoding = (notification.smseagleEncoding) ? "unicode" : "standard";
let priority = (notification.smseaglePriority) ?? 0;
let postData = {
text: msg,
encoding: encoding,
priority: priority
};
if (notification.smseagleRecipientContact) {
postData["contacts"] = notification.smseagleRecipientContact.split(",").map(Number);
}
if (notification.smseagleRecipientGroup) {
postData["groups"] = notification.smseagleRecipientGroup.split(",").map(Number);
}
if (notification.smseagleRecipientTo) {
postData["to"] = notification.smseagleRecipientTo.split(",");
}
let endpoint = "/messages/sms";
if (notification.smseagleMsgType !== "smseagle-sms") {
postData["duration"] = notification.smseagleDuration ?? 10;
if (notification.smseagleMsgType === "smseagle-ring") {
endpoint = "/calls/ring";
} else if (notification.smseagleMsgType === "smseagle-tts") {
endpoint = "/calls/tts";
} else if (notification.smseagleMsgType === "smseagle-tts-advanced") {
endpoint = "/calls/tts_advanced";
postData["voice_id"] = notification.smseagleTtsModel ?? 1;
}
}
let resp = await axios.post(notification.smseagleUrl + "/api/v2" + endpoint, postData, config);
const queuedCount = resp.data.filter(x => x.status === "queued").length;
const unqueuedCount = resp.data.length - queuedCount;
if (resp.status !== 200 || queuedCount === 0) {
if (!resp.data.length) {
throw new Error("SMSEagle API returned an empty response");
}
throw new Error(`SMSEagle API returned error: ${JSON.stringify(resp.data)}`);
}
if (unqueuedCount) {
return `Sent ${queuedCount}/${resp.data.length} Messages Successfully.`;
}
return okMsg;
}
} catch (error) {
this.throwGeneralAxiosError(error);
}

View file

@ -42,6 +42,7 @@ class SMTP extends NotificationProvider {
// default values in case the user does not want to template
let subject = msg;
let body = msg;
let useHTMLBody = false;
if (heartbeatJSON) {
body = `${msg}\nTime (${heartbeatJSON["timezone"]}): ${heartbeatJSON["localDateTime"]}`;
}
@ -50,11 +51,11 @@ class SMTP extends NotificationProvider {
// cannot end with whitespace as this often raises spam scores
const customSubject = notification.customSubject?.trim() || "";
const customBody = notification.customBody?.trim() || "";
if (customSubject !== "") {
subject = await this.renderTemplate(customSubject, msg, monitorJSON, heartbeatJSON);
}
if (customBody !== "") {
useHTMLBody = notification.htmlBody || false;
body = await this.renderTemplate(customBody, msg, monitorJSON, heartbeatJSON);
}
}
@ -67,7 +68,8 @@ class SMTP extends NotificationProvider {
bcc: notification.smtpBCC,
to: notification.smtpTo,
subject: subject,
text: body,
// If the email body is custom, and the user wants it, set the email body as HTML
[useHTMLBody ? "html" : "text"]: body
});
return okMsg;

View file

@ -0,0 +1,37 @@
const NotificationProvider = require("./notification-provider");
const axios = require("axios");
const { DOWN, UP } = require("../../src/util");
class SpugPush extends NotificationProvider {
name = "SpugPush";
/**
* @inheritdoc
*/
async send(notification, msg, monitorJSON = null, heartbeatJSON = null) {
let okMsg = "Sent Successfully.";
try {
let formData = {
title: "Uptime Kuma Message",
content: msg
};
if (heartbeatJSON) {
if (heartbeatJSON["status"] === UP) {
formData.title = `UptimeKuma 「${monitorJSON["name"]}」 is Up`;
formData.content = `[✅ Up] ${heartbeatJSON["msg"]}`;
} else if (heartbeatJSON["status"] === DOWN) {
formData.title = `UptimeKuma 「${monitorJSON["name"]}」 is Down`;
formData.content = `[🔴 Down] ${heartbeatJSON["msg"]}`;
}
}
const apiUrl = `https://push.spug.cc/send/${notification.templateKey}`;
await axios.post(apiUrl, formData);
return okMsg;
} catch (error) {
this.throwGeneralAxiosError(error);
}
}
}
module.exports = SpugPush;

View file

@ -13,6 +13,7 @@ const DingDing = require("./notification-providers/dingding");
const Discord = require("./notification-providers/discord");
const Elks = require("./notification-providers/46elks");
const Feishu = require("./notification-providers/feishu");
const Notifery = require("./notification-providers/notifery");
const FreeMobile = require("./notification-providers/freemobile");
const GoogleChat = require("./notification-providers/google-chat");
const Gorush = require("./notification-providers/gorush");
@ -30,9 +31,11 @@ const Mattermost = require("./notification-providers/mattermost");
const Nostr = require("./notification-providers/nostr");
const Ntfy = require("./notification-providers/ntfy");
const Octopush = require("./notification-providers/octopush");
const OneChat = require("./notification-providers/onechat");
const OneBot = require("./notification-providers/onebot");
const Opsgenie = require("./notification-providers/opsgenie");
const PagerDuty = require("./notification-providers/pagerduty");
const Pumble = require("./notification-providers/pumble");
const FlashDuty = require("./notification-providers/flashduty");
const PagerTree = require("./notification-providers/pagertree");
const PromoSMS = require("./notification-providers/promosms");
@ -72,6 +75,8 @@ const Onesender = require("./notification-providers/onesender");
const Wpush = require("./notification-providers/wpush");
const SendGrid = require("./notification-providers/send-grid");
const YZJ = require("./notification-providers/yzj");
const SMSPlanet = require("./notification-providers/sms-planet");
const SpugPush = require("./notification-providers/spugpush");
class Notification {
@ -119,6 +124,7 @@ class Notification {
new Nostr(),
new Ntfy(),
new Octopush(),
new OneChat(),
new OneBot(),
new Onesender(),
new Opsgenie(),
@ -126,6 +132,7 @@ class Notification {
new FlashDuty(),
new PagerTree(),
new PromoSMS(),
new Pumble(),
new Pushbullet(),
new PushDeer(),
new Pushover(),
@ -160,7 +167,10 @@ class Notification {
new Cellsynt(),
new Wpush(),
new SendGrid(),
new YZJ()
new YZJ(),
new SMSPlanet(),
new SpugPush(),
new Notifery(),
];
for (let item of list) {
if (! item.name) {

View file

@ -50,7 +50,7 @@ router.all("/api/push/:pushToken", async (request, response) => {
let msg = request.query.msg || "OK";
let ping = parseFloat(request.query.ping) || null;
let statusString = request.query.status || "up";
let status = (statusString === "up") ? UP : DOWN;
const statusFromParam = (statusString === "up") ? UP : DOWN;
let monitor = await R.findOne("monitor", " push_token = ? AND active = 1 ", [
pushToken
@ -80,7 +80,7 @@ router.all("/api/push/:pushToken", async (request, response) => {
msg = "Monitor under maintenance";
bean.status = MAINTENANCE;
} else {
determineStatus(status, previousHeartbeat, monitor.maxretries, monitor.isUpsideDown(), bean);
determineStatus(statusFromParam, previousHeartbeat, monitor.maxretries, monitor.isUpsideDown(), bean);
}
// Calculate uptime
@ -92,21 +92,21 @@ router.all("/api/push/:pushToken", async (request, response) => {
log.debug("router", "PreviousStatus: " + previousHeartbeat?.status);
log.debug("router", "Current Status: " + bean.status);
bean.important = Monitor.isImportantBeat(isFirstBeat, previousHeartbeat?.status, status);
bean.important = Monitor.isImportantBeat(isFirstBeat, previousHeartbeat?.status, bean.status);
if (Monitor.isImportantForNotification(isFirstBeat, previousHeartbeat?.status, status)) {
if (Monitor.isImportantForNotification(isFirstBeat, previousHeartbeat?.status, bean.status)) {
// Reset down count
bean.downCount = 0;
log.debug("monitor", `[${this.name}] sendNotification`);
log.debug("monitor", `[${monitor.name}] sendNotification`);
await Monitor.sendNotification(isFirstBeat, monitor, bean);
} else {
if (bean.status === DOWN && this.resendInterval > 0) {
if (bean.status === DOWN && monitor.resendInterval > 0) {
++bean.downCount;
if (bean.downCount >= this.resendInterval) {
if (bean.downCount >= monitor.resendInterval) {
// Send notification again, because we are still DOWN
log.debug("monitor", `[${this.name}] sendNotification again: Down Count: ${bean.downCount} | Resend Interval: ${this.resendInterval}`);
await Monitor.sendNotification(isFirstBeat, this, bean);
log.debug("monitor", `[${monitor.name}] sendNotification again: Down Count: ${bean.downCount} | Resend Interval: ${monitor.resendInterval}`);
await Monitor.sendNotification(isFirstBeat, monitor, bean);
// Reset down count
bean.downCount = 0;

View file

@ -122,7 +122,7 @@ router.get("/api/status-page/heartbeat/:slug", cache("1 minutes"), async (reques
SELECT * FROM heartbeat
WHERE monitor_id = ?
ORDER BY time DESC
LIMIT 50
LIMIT 100
`, [
monitorID,
]);

View file

@ -866,6 +866,7 @@ let needSetup = false;
monitor.kafkaProducerAllowAutoTopicCreation;
bean.gamedigGivenPortOnly = monitor.gamedigGivenPortOnly;
bean.remote_browser = monitor.remote_browser;
bean.smtpSecurity = monitor.smtpSecurity;
bean.snmpVersion = monitor.snmpVersion;
bean.snmpOid = monitor.snmpOid;
bean.jsonPathOperator = monitor.jsonPathOperator;
@ -875,6 +876,11 @@ let needSetup = false;
bean.rabbitmqPassword = monitor.rabbitmqPassword;
bean.conditions = JSON.stringify(monitor.conditions);
// ping advanced options
bean.ping_numeric = monitor.ping_numeric;
bean.ping_count = monitor.ping_count;
bean.ping_per_request_timeout = monitor.ping_per_request_timeout;
bean.validate();
await R.store(bean);

View file

@ -211,6 +211,10 @@ module.exports.statusPageSocketHandler = (socket) => {
relationBean.send_url = monitor.sendUrl;
}
if (monitor.url !== undefined) {
relationBean.custom_url = monitor.url;
}
await R.store(relationBean);
}

View file

@ -113,6 +113,8 @@ class UptimeKumaServer {
UptimeKumaServer.monitorTypeList["tailscale-ping"] = new TailscalePing();
UptimeKumaServer.monitorTypeList["dns"] = new DnsMonitorType();
UptimeKumaServer.monitorTypeList["mqtt"] = new MqttMonitorType();
UptimeKumaServer.monitorTypeList["smtp"] = new SMTPMonitorType();
UptimeKumaServer.monitorTypeList["group"] = new GroupMonitorType();
UptimeKumaServer.monitorTypeList["snmp"] = new SNMPMonitorType();
UptimeKumaServer.monitorTypeList["mongodb"] = new MongodbMonitorType();
UptimeKumaServer.monitorTypeList["rabbitmq"] = new RabbitMqMonitorType();
@ -551,6 +553,8 @@ const { RealBrowserMonitorType } = require("./monitor-types/real-browser-monitor
const { TailscalePing } = require("./monitor-types/tailscale-ping");
const { DnsMonitorType } = require("./monitor-types/dns");
const { MqttMonitorType } = require("./monitor-types/mqtt");
const { SMTPMonitorType } = require("./monitor-types/smtp");
const { GroupMonitorType } = require("./monitor-types/group");
const { SNMPMonitorType } = require("./monitor-types/snmp");
const { MongodbMonitorType } = require("./monitor-types/mongodb");
const { RabbitMqMonitorType } = require("./monitor-types/rabbitmq");

View file

@ -1,7 +1,11 @@
const tcpp = require("tcp-ping");
const ping = require("@louislam/ping");
const { R } = require("redbean-node");
const { log, genSecret, badgeConstants } = require("../src/util");
const {
log, genSecret, badgeConstants,
PING_PACKET_SIZE_DEFAULT, PING_GLOBAL_TIMEOUT_DEFAULT,
PING_COUNT_DEFAULT, PING_PER_REQUEST_TIMEOUT_DEFAULT
} = require("../src/util");
const passwordHash = require("./password-hash");
const { Resolver } = require("dns");
const iconv = require("iconv-lite");
@ -118,20 +122,33 @@ exports.tcping = function (hostname, port) {
/**
* Ping the specified machine
* @param {string} hostname Hostname / address of machine
* @param {number} size Size of packet to send
* @param {string} destAddr Hostname / IP address of machine to ping
* @param {number} count Number of packets to send before stopping
* @param {string} sourceAddr Source address for sending/receiving echo requests
* @param {boolean} numeric If true, IP addresses will be output instead of symbolic hostnames
* @param {number} size Size (in bytes) of echo request to send
* @param {number} deadline Maximum time in seconds before ping stops, regardless of packets sent
* @param {number} timeout Maximum time in seconds to wait for each response
* @returns {Promise<number>} Time for ping in ms rounded to nearest integer
*/
exports.ping = async (hostname, size = 56) => {
exports.ping = async (
destAddr,
count = PING_COUNT_DEFAULT,
sourceAddr = "",
numeric = true,
size = PING_PACKET_SIZE_DEFAULT,
deadline = PING_GLOBAL_TIMEOUT_DEFAULT,
timeout = PING_PER_REQUEST_TIMEOUT_DEFAULT,
) => {
try {
return await exports.pingAsync(hostname, false, size);
return await exports.pingAsync(destAddr, false, count, sourceAddr, numeric, size, deadline, timeout);
} catch (e) {
// If the host cannot be resolved, try again with ipv6
log.debug("ping", "IPv6 error message: " + e.message);
// As node-ping does not report a specific error for this, try again if it is an empty message with ipv6 no matter what.
if (!e.message) {
return await exports.pingAsync(hostname, true, size);
return await exports.pingAsync(destAddr, true, count, sourceAddr, numeric, size, deadline, timeout);
} else {
throw e;
}
@ -140,18 +157,35 @@ exports.ping = async (hostname, size = 56) => {
/**
* Ping the specified machine
* @param {string} hostname Hostname / address of machine to ping
* @param {string} destAddr Hostname / IP address of machine to ping
* @param {boolean} ipv6 Should IPv6 be used?
* @param {number} size Size of ping packet to send
* @param {number} count Number of packets to send before stopping
* @param {string} sourceAddr Source address for sending/receiving echo requests
* @param {boolean} numeric If true, IP addresses will be output instead of symbolic hostnames
* @param {number} size Size (in bytes) of echo request to send
* @param {number} deadline Maximum time in seconds before ping stops, regardless of packets sent
* @param {number} timeout Maximum time in seconds to wait for each response
* @returns {Promise<number>} Time for ping in ms rounded to nearest integer
*/
exports.pingAsync = function (hostname, ipv6 = false, size = 56) {
exports.pingAsync = function (
destAddr,
ipv6 = false,
count = PING_COUNT_DEFAULT,
sourceAddr = "",
numeric = true,
size = PING_PACKET_SIZE_DEFAULT,
deadline = PING_GLOBAL_TIMEOUT_DEFAULT,
timeout = PING_PER_REQUEST_TIMEOUT_DEFAULT,
) {
return new Promise((resolve, reject) => {
ping.promise.probe(hostname, {
ping.promise.probe(destAddr, {
v6: ipv6,
min_reply: 1,
deadline: 10,
min_reply: count,
sourceAddr: sourceAddr,
numeric: numeric,
packetSize: size,
deadline: deadline,
timeout: timeout
}).then((res) => {
// If ping failed, it will set field to unknown
if (res.alive) {

View file

@ -4,9 +4,11 @@
<script>
import { setPageLocale } from "./util-frontend";
import { polyfillCountryFlagEmojis } from "country-flag-emoji-polyfill";
export default {
created() {
setPageLocale();
},
};
polyfillCountryFlagEmojis();
</script>

View file

@ -3,7 +3,7 @@
@import "node_modules/bootstrap/scss/bootstrap";
#app {
font-family: BlinkMacSystemFont, segoe ui, Roboto, helvetica neue, Arial, noto sans, sans-serif, apple color emoji, segoe ui emoji, segoe ui symbol, noto color emoji;
font-family: "Twemoji Country Flags", BlinkMacSystemFont, segoe ui, Roboto, helvetica neue, Arial, noto sans, sans-serif, apple color emoji, segoe ui emoji, segoe ui symbol, noto color emoji;
}
h1 {

View file

@ -42,6 +42,9 @@ export default {
mounted() {
this.modal = new Modal(this.$refs.modal);
},
beforeUnmount() {
this.cleanupModal();
},
methods: {
/**
* Show the confirm dialog
@ -58,6 +61,19 @@ export default {
this.$emit("added", this.groupName);
this.modal.hide();
},
/**
* Clean up modal and restore scroll behavior
* @returns {void}
*/
cleanupModal() {
if (this.modal) {
try {
this.modal.hide();
} catch (e) {
console.warn("Modal hide failed:", e);
}
}
}
},
};
</script>

View file

@ -14,7 +14,7 @@
<router-link :to="monitorURL(monitor.id)" class="item" :class="{ 'disabled': ! monitor.active }">
<div class="row">
<div class="col-9 col-md-8 small-padding" :class="{ 'monitor-item': $root.userHeartbeatBar == 'bottom' || $root.userHeartbeatBar == 'none' }">
<div class="col-6 small-padding" :class="{ 'monitor-item': $root.userHeartbeatBar == 'bottom' || $root.userHeartbeatBar == 'none' }">
<div class="info">
<Uptime :monitor="monitor" type="24" :pill="true" />
<span v-if="hasChildren" class="collapse-padding" @click.prevent="changeCollapsed">
@ -22,11 +22,11 @@
</span>
{{ monitor.name }}
</div>
<div v-if="monitor.tags.length > 0" class="tags">
<div v-if="monitor.tags.length > 0" class="tags gap-1">
<Tag v-for="tag in monitor.tags" :key="tag" :item="tag" :size="'sm'" />
</div>
</div>
<div v-show="$root.userHeartbeatBar == 'normal'" :key="$root.userHeartbeatBar" class="col-3 col-md-4">
<div v-show="$root.userHeartbeatBar == 'normal'" :key="$root.userHeartbeatBar" class="col-6">
<HeartbeatBar ref="heartbeatBar" size="small" :monitor-id="monitor.id" />
</div>
</div>

View file

@ -10,7 +10,7 @@
</div>
<div class="modal-body">
<div class="my-3 form-check">
<input id="show-clickable-link" v-model="monitor.isClickAble" class="form-check-input" type="checkbox" @click="toggleLink(monitor.group_index, monitor.monitor_index)" />
<input id="show-clickable-link" v-model="monitor.isClickAble" class="form-check-input" type="checkbox" data-testid="show-clickable-link" @click="toggleLink(monitor.group_index, monitor.monitor_index)" />
<label class="form-check-label" for="show-clickable-link">
{{ $t("Show Clickable Link") }}
</label>
@ -19,6 +19,16 @@
</div>
</div>
<!-- Custom URL -->
<template v-if="monitor.isClickAble">
<label for="customUrl" class="form-label">{{ $t("Custom URL") }}</label>
<input id="customUrl" :value="monitor.url" type="url" class="form-control" data-testid="custom-url-input" @input="e => changeUrl(monitor.group_index, monitor.monitor_index, e.target!.value)">
<div class="form-text mb-3">
{{ $t("customUrlDescription") }}
</div>
</template>
<button
class="btn btn-primary btn-add-group me-2"
@click="$refs.badgeGeneratorDialog.show(monitor.id, monitor.name)"
@ -29,7 +39,7 @@
</div>
<div class="modal-footer">
<button type="submit" class="btn btn-danger" data-bs-dismiss="modal">
<button type="submit" class="btn btn-danger" data-bs-dismiss="modal" data-testid="monitor-settings-close">
{{ $t("Close") }}
</button>
</div>
@ -78,6 +88,7 @@ export default {
monitor_index: monitor.index,
group_index: group.index,
isClickAble: this.showLink(monitor),
url: monitor.element.url,
};
this.MonitorSettingDialog.show();
@ -110,6 +121,17 @@ export default {
}
return monitor.element.sendUrl && monitor.element.url && monitor.element.url !== "https://" && !this.editMode;
},
/**
* Toggle the value of sendUrl
* @param {number} groupIndex Index of group monitor is member of
* @param {number} index Index of monitor within group
* @param {string} value The new value of the url
* @returns {void}
*/
changeUrl(groupIndex, index, value) {
this.$root.publicGroupList[groupIndex].monitorList[index].url = value;
},
},
};
</script>

View file

@ -135,11 +135,13 @@ export default {
"nostr": "Nostr",
"ntfy": "Ntfy",
"octopush": "Octopush",
"OneChat": "OneChat",
"OneBot": "OneBot",
"Onesender": "Onesender",
"Opsgenie": "Opsgenie",
"PagerDuty": "PagerDuty",
"PagerTree": "PagerTree",
"pumble": "Pumble",
"pushbullet": "Pushbullet",
"PushByTechulus": "Push by Techulus",
"pushover": "Pushover",
@ -166,7 +168,8 @@ export default {
"waha": "WhatsApp (WAHA)",
"gtxmessaging": "GtxMessaging",
"Cellsynt": "Cellsynt",
"SendGrid": "SendGrid"
"SendGrid": "SendGrid",
"notifery": "Notifery"
};
// Put notifications here if it's not supported in most regions or its documentation is not in English
@ -183,9 +186,11 @@ export default {
"WeCom": "WeCom (企业微信群机器人)",
"ServerChan": "ServerChan (Server酱)",
"PushPlus": "PushPlus (推送加)",
"SpugPush": "SpugPushSpug推送助手",
"smsc": "SMSC",
"WPush": "WPush(wpush.cn)",
"YZJ": "YZJ (云之家自定义机器人)"
"YZJ": "YZJ (云之家自定义机器人)",
"SMSPlanet": "SMSPlanet.pl"
};
// Sort by notification name
@ -235,6 +240,9 @@ export default {
mounted() {
this.modal = new Modal(this.$refs.modal);
},
beforeUnmount() {
this.cleanupModal();
},
methods: {
/**
@ -339,6 +347,20 @@ export default {
});
} while (this.$root.notificationList.find(it => it.name === name));
return name;
},
/**
* Clean up modal and restore scroll behavior
* @returns {void}
*/
cleanupModal() {
if (this.modal) {
try {
this.modal.hide();
} catch (e) {
console.warn("Modal hide failed:", e);
}
}
}
},
};

View file

@ -125,11 +125,12 @@ export default {
}
};
},
mounted() {
this.modal = new Modal(this.$refs.modal);
},
beforeUnmount() {
this.cleanupModal();
},
methods: {
/**
* Show dialog to confirm deletion
@ -209,6 +210,20 @@ export default {
}
});
},
/**
* Clean up modal and restore scroll behavior
* @returns {void}
*/
cleanupModal() {
if (this.modal) {
try {
this.modal.hide();
} catch (e) {
console.warn("Modal hide failed:", e);
}
}
}
},
};
</script>

View file

@ -33,7 +33,7 @@
<template #item="monitor">
<div class="item" data-testid="monitor">
<div class="row">
<div class="col-9 col-md-8 small-padding">
<div class="col-6 small-padding">
<div class="info">
<font-awesome-icon v-if="editMode" icon="arrows-alt-v" class="action drag me-3" />
<font-awesome-icon v-if="editMode" icon="times" class="action remove me-3" @click="removeMonitor(group.index, monitor.index)" />
@ -58,6 +58,7 @@
v-if="editMode"
:class="{'link-active': true, 'btn-link': true}"
icon="cog" class="action me-3"
data-testid="monitor-settings"
@click="$refs.monitorSettingDialog.show(group, monitor)"
/>
</span>
@ -71,7 +72,7 @@
</div>
</div>
</div>
<div :key="$root.userHeartbeatBar" class="col-3 col-md-4">
<div :key="$root.userHeartbeatBar" class="col-6">
<HeartbeatBar size="mid" :monitor-id="monitor.element.id" />
</div>
</div>

View file

@ -6,7 +6,6 @@
'm-2': size == 'normal',
'px-2': size == 'sm',
'py-0': size == 'sm',
'mx-1': size == 'sm',
}"
:style="{ backgroundColor: item.color, fontSize: size == 'sm' ? '0.7em' : '1em' }"
>
@ -48,7 +47,7 @@ export default {
},
computed: {
displayText() {
if (this.item.value === "" || this.item.value === undefined) {
if (this.item.value === "" || this.item.value === undefined || this.item.value === null) {
return this.item.name;
} else {
return `${this.item.name}: ${this.item.value}`;

View file

@ -248,6 +248,9 @@ export default {
this.modal = new Modal(this.$refs.modal);
this.getExistingTags();
},
beforeUnmount() {
this.cleanupModal();
},
methods: {
/**
* Show the add tag dialog
@ -459,6 +462,19 @@ export default {
this.newTags = [];
this.deleteTags = [];
this.processing = false;
},
/**
* Clean up modal and restore scroll behavior
* @returns {void}
*/
cleanupModal() {
if (this.modal) {
try {
this.modal.hide();
} catch (e) {
console.warn("Modal hide failed:", e);
}
}
}
},
};

View file

@ -53,6 +53,13 @@
</div>
</div>
</div>
<div class="mb-3">
<div class="form-check form-switch">
<input id="discord-disable-url" v-model="$parent.notification.disableUrl" class="form-check-input" type="checkbox" role="switch">
<label class="form-check-label" for="discord-disable-url">{{ $t("Disable URL in Notification") }}</label>
</div>
</div>
</template>
<script>
export default {
@ -60,6 +67,9 @@ export default {
if (!this.$parent.notification.discordChannelType) {
this.$parent.notification.discordChannelType = "channel";
}
if (this.$parent.notification.disableUrl === undefined) {
this.$parent.notification.disableUrl = false;
}
}
};
</script>

View file

@ -1,7 +1,10 @@
<template>
<div class="mb-3">
<label for="flashduty-integration-url" class="form-label">Integration Key</label>
<HiddenInput id="flashduty-integration-url" v-model="$parent.notification.flashdutyIntegrationKey" autocomplete="false"></HiddenInput>
<label for="flashduty-integration-url" class="form-label">{{ $t("FlashDuty Push URL") }} <span style="color: red;"><sup>*</sup></span></label>
<HiddenInput id="flashduty-integration-url" v-model="$parent.notification.flashdutyIntegrationKey" autocomplete="false" :placeholder="$t('FlashDuty Push URL Placeholder')" />
<div class="form-text">
<p><span style="color: red;"><sup>*</sup></span>{{ $t("Required") }}</p>
</div>
<i18n-t tag="div" keypath="wayToGetFlashDutyKey" class="form-text">
<a href="https://flashcat.cloud/product/flashduty?from=kuma" target="_blank">{{ $t("here") }}</a>
</i18n-t>
@ -18,7 +21,6 @@
<script>
import HiddenInput from "../HiddenInput.vue";
export default {
components: {
HiddenInput,

View file

@ -18,7 +18,7 @@
{{ $t("matrixDesc1") }}
</p>
<i18n-t tag="p" keypath="matrixDesc2" style="margin-top: 8px;">
<code>curl -XPOST -d '{"type": "m.login.password", "identifier": {"user": "botusername", "type": "m.id.user"}, "password": "passwordforuser"}' "https://home.server/_matrix/client/r0/login"</code>.
<code>curl -XPOST -d '{"type": "m.login.password", "identifier": {"user": "botusername", "type": "m.id.user"}, "password": "passwordforuser"}' "https://home.server/_matrix/client/v3/login"</code>.
</i18n-t>
</div>
</template>

View file

@ -0,0 +1,49 @@
<template>
<div class="mb-3">
<label for="notifery-api-key" class="form-label">{{
$t("API Key")
}}</label>
<HiddenInput
id="notifery-api-key"
v-model="$parent.notification.notiferyApiKey"
:required="true"
autocomplete="new-password"
></HiddenInput>
</div>
<div class="mb-3">
<label for="notifery-title" class="form-label">{{ $t("Title") }}</label>
<input
id="notifery-title"
v-model="$parent.notification.notiferyTitle"
type="text"
class="form-control"
placeholder="Uptime Kuma Alert"
/>
</div>
<div class="mb-3">
<label for="notifery-group" class="form-label">{{ $t("Group") }}</label>
<input
id="notifery-group"
v-model="$parent.notification.notiferyGroup"
type="text"
class="form-control"
:placeholder="$t('Optional')"
/>
</div>
<i18n-t tag="p" keypath="More info on:" style="margin-top: 8px;">
<a href="https://docs.notifery.com/api/event/" target="_blank">https://docs.notifery.com/api/event/</a>
</i18n-t>
</template>
<script>
import HiddenInput from "../HiddenInput.vue";
export default {
components: {
HiddenInput,
},
};
</script>

View file

@ -0,0 +1,64 @@
<template>
<div class="mb-3">
<!-- Access Token Input -->
<div class="mb-3">
<label for="onechat-access-token" class="form-label">
OneChat Access Token<span style="color: red;"><sup>*</sup></span>
</label>
<HiddenInput
id="onechat-access-token"
v-model="$parent.notification.accessToken"
:required="true"
>
</HiddenInput>
<div class="form-text">
<p>{{ $t("OneChatAccessToken") }}</p>
</div>
</div>
<!-- Receiver ID Input -->
<div class="mb-3">
<label for="onechat-receiver-id" class="form-label">
{{ $t("OneChatUserIdOrGroupId") }}<span style="color: red;"><sup>*</sup></span>
</label>
<input
id="onechat-receiver-id"
v-model="$parent.notification.recieverId"
type="text"
class="form-control"
required
/>
</div>
<!-- Bot ID Input -->
<div class="mb-3">
<label for="onechat-bot-id" class="form-label">
{{ $t("OneChatBotId") }}<span style="color: red;"><sup>*</sup></span>
</label>
<input
id="onechat-bot-id"
v-model="$parent.notification.botId"
type="text"
class="form-control"
required
/>
</div>
<!-- Document Link -->
<div class="form-text">
<i18n-t tag="p" keypath="Read more:">
<a href="https://chat-develop.one.th/docs" target="_blank">https://chat-develop.one.th/docs</a>
</i18n-t>
</div>
</div>
</template>
<script>
import HiddenInput from "../HiddenInput.vue";
export default {
components: {
HiddenInput,
},
};
</script>

View file

@ -0,0 +1,9 @@
<template>
<div class="mb-3">
<label for="pumble-webhook-url" class="form-label mb-2">{{ $t("Webhook URL") }}</label><span style="color: red;"><sup>*</sup></span>
<input id="pumble-webhook-url" v-model="$parent.notification.webhookURL" type="url" class="form-control" required>
</div>
<div class="mb-3">
<a href="https://pumble.com/help/integrations/add-pumble-apps/incoming-webhooks-for-pumble/" target="_blank">{{ $t("documentationOf", ["Pumble Webbhook"]) }}</a>
</div>
</template>

View file

@ -16,34 +16,24 @@
<option>1</option>
<option>2</option>
</select>
<label for="pushover-sound" class="form-label">{{ $t("Notification Sound") }}</label>
<select id="pushover-sound" v-model="$parent.notification.pushoversounds" class="form-select">
<option value="pushover">{{ $t("pushoversounds pushover") }}</option>
<option value="bike">{{ $t("pushoversounds bike") }}</option>
<option value="bugle">{{ $t("pushoversounds bugle") }}</option>
<option value="cashregister">{{ $t("pushoversounds cashregister") }}</option>
<option value="classical">{{ $t("pushoversounds classical") }}</option>
<option value="cosmic">{{ $t("pushoversounds cosmic") }}</option>
<option value="falling">{{ $t("pushoversounds falling") }}</option>
<option value="gamelan">{{ $t("pushoversounds gamelan") }}</option>
<option value="incoming">{{ $t("pushoversounds incoming") }}</option>
<option value="intermission">{{ $t("pushoversounds intermission") }}</option>
<option value="magic">{{ $t("pushoversounds magic") }}</option>
<option value="mechanical">{{ $t("pushoversounds mechanical") }}</option>
<option value="pianobar">{{ $t("pushoversounds pianobar") }}</option>
<option value="siren">{{ $t("pushoversounds siren") }}</option>
<option value="spacealarm">{{ $t("pushoversounds spacealarm") }}</option>
<option value="tugboat">{{ $t("pushoversounds tugboat") }}</option>
<option value="alien">{{ $t("pushoversounds alien") }}</option>
<option value="climb">{{ $t("pushoversounds climb") }}</option>
<option value="persistent">{{ $t("pushoversounds persistent") }}</option>
<option value="echo">{{ $t("pushoversounds echo") }}</option>
<option value="updown">{{ $t("pushoversounds updown") }}</option>
<option value="vibrate">{{ $t("pushoversounds vibrate") }}</option>
<option value="none">{{ $t("pushoversounds none") }}</option>
<label for="pushover-sound-down" class="form-label">{{ $t("Notification Sound") }} - Up</label>
<select id="pushover-sound-down" v-model="$parent.notification.pushoversounds" class="form-select">
<option v-for="sound in soundOptions" :key="sound" :value="sound">
{{ $t(`pushoversounds ${sound}`) }}
</option>
</select>
<label for="pushover-sound-up" class="form-label">{{ $t("Notification Sound") }} - Down</label>
<select id="pushover-sound-up" v-model="$parent.notification.pushoversounds_up" class="form-select">
<option v-for="sound in soundOptions" :key="sound" :value="sound">
{{ $t(`pushoversounds ${sound}`) }}
</option>
</select>
<label for="pushover-ttl" class="form-label">{{ $t("pushoverMessageTtl") }}</label>
<input id="pushover-ttl" v-model="$parent.notification.pushoverttl" type="number" min="0" step="1" class="form-control">
<div class="form-text">
<span style="color: red;"><sup>*</sup></span>{{ $t("Required") }}
<i18n-t tag="p" keypath="More info on:" style="margin-top: 8px;">
@ -66,5 +56,34 @@ export default {
components: {
HiddenInput,
},
data() {
return {
soundOptions: [
"pushover",
"bike",
"bugle",
"cashregister",
"classical",
"cosmic",
"falling",
"gamelan",
"incoming",
"intermission",
"magic",
"mechanical",
"pianobar",
"siren",
"spacealarm",
"tugboat",
"alien",
"climb",
"persistent",
"echo",
"updown",
"vibrate",
"none",
],
};
},
};
</script>

View file

@ -1,31 +1,123 @@
<template>
<div class="mb-3">
<label for="smseagle-url" class="form-label">{{ $t("smseagleUrl") }}</label>
<input id="smseagle-url" v-model="$parent.notification.smseagleUrl" type="text" minlength="7" class="form-control" placeholder="http://127.0.0.1" required>
<input
id="smseagle-url" v-model="$parent.notification.smseagleUrl" type="text" minlength="7"
class="form-control" placeholder="http://127.0.0.1" required
>
</div>
<div class="mb-3">
<label for="smseagle-token" class="form-label">{{ $t("smseagleToken") }}</label>
<HiddenInput id="smseagle-token" v-model="$parent.notification.smseagleToken" :required="true"></HiddenInput>
</div>
<div class="mb-3">
<label for="smseagle-recipient-type" class="form-label">{{ $t("smseagleRecipientType") }}</label>
<select id="smseagle-recipient-type" v-model="$parent.notification.smseagleRecipientType" class="form-select">
<option value="smseagle-to" selected>{{ $t("smseagleTo") }}</option>
<option value="smseagle-group">{{ $t("smseagleGroup") }}</option>
<option value="smseagle-contact">{{ $t("smseagleContact") }}</option>
<label for="smseagle-api-type" class="form-label">{{ $t("smseagleApiType") }} </label>
<select id="smseagle-api-type" v-model="$parent.notification.smseagleApiType" class="form-select">
<option value="smseagle-apiv1" selected>{{ $t("smseagleApiv1") }} </option>
<option value="smseagle-apiv2">{{ $t("smseagleApiv2") }} </option>
</select>
<i18n-t tag="div" keypath="smseagleDocs" class="form-text">
<a href="https://www.smseagle.eu/api/" target="_blank">https://www.smseagle.eu/api/</a>
</i18n-t>
</div>
<div class="mb-3">
<label for="smseagle-recipient" class="form-label">{{ $t("smseagleRecipient") }}</label>
<input id="smseagle-recipient" v-model="$parent.notification.smseagleRecipient" type="text" class="form-control" required>
<div v-if="$parent.notification.smseagleApiType === 'smseagle-apiv1'" class="mb-3">
<div class="mb-3">
<label for="smseagle-recipient-type" class="form-label">{{ $t("smseagleRecipientType") }}</label>
<select
id="smseagle-recipient-type" v-model="$parent.notification.smseagleRecipientType"
class="form-select"
>
<!-- phone number -->
<option value="smseagle-to" selected>{{ $t("smseagleTo") }}</option>
<option value="smseagle-group">{{ $t("smseagleGroup") }}</option>
<option value="smseagle-contact">{{ $t("smseagleContact") }}</option>
</select>
</div>
<div class="mb-3">
<label for="smseagle-recipient" class="form-label">{{ $t("smseagleRecipient") }}</label>
<input id="smseagle-recipient" v-model="$parent.notification.smseagleRecipient" type="text" class="form-control" required>
</div>
<div
v-if="$parent.notification.smseagleMsgType === 'smseagle-sms'
|| $parent.notification.smseagleRecipientType !== 'smseagle-to'" class="mb-3"
>
<label for="smseagle-priority" class="form-label">{{ $t("smseaglePriority") }}</label>
<input id="smseagle-priority" v-model="$parent.notification.smseaglePriority" type="number" class="form-control" min="0" max="9" step="1" placeholder="0" required>
</div>
<div
v-if="$parent.notification.smseagleMsgType === 'smseagle-sms'
|| $parent.notification.smseagleRecipientType !== 'smseagle-to'" class="mb-3 form-check form-switch"
>
<label for="smseagle-encoding" class="form-label">{{ $t("smseagleEncoding") }}</label>
<input id="smseagle-encoding" v-model="$parent.notification.smseagleEncoding" type="checkbox" class="form-check-input">
</div>
<div v-if="$parent.notification.smseagleRecipientType === 'smseagle-to'" class="mb-3">
<div class="mb-3">
<label for="smseagle-msg-type" class="form-label">{{ $t("smseagleMsgType") }} </label>
<select id="smseagle-msg-type" v-model="$parent.notification.smseagleMsgType" class="form-select">
<option value="smseagle-sms" selected>{{ $t("smseagleMsgSms") }} </option>
<option value="smseagle-ring">{{ $t("smseagleMsgRing") }} </option>
<option value="smseagle-tts">{{ $t("smseagleMsgTts") }} </option>
<option value="smseagle-tts-advanced">{{ $t("smseagleMsgTtsAdvanced") }} </option>
</select>
</div>
<div
v-if="$parent.notification.smseagleMsgType === 'smseagle-ring'
|| $parent.notification.smseagleMsgType === 'smseagle-tts'
|| $parent.notification.smseagleMsgType === 'smseagle-tts-advanced'" class="mb-3"
>
<label for="smseagle-duration" class="form-label">{{ $t("smseagleDuration") }}</label>
<input id="smseagle-duration" v-model="$parent.notification.smseagleDuration" type="number" class="form-control" min="0" max="30" step="1" placeholder="10">
</div>
<div v-if="$parent.notification.smseagleMsgType === 'smseagle-tts-advanced'" class="mb-3">
<label for="smseagle-tts-model" class="form-label">{{ $t("smseagleTtsModel") }} </label>
<input id="smseagle-tts-model" v-model="$parent.notification.smseagleTtsModel" type="number" class="form-control" placeholder="1" required>
</div>
</div>
</div>
<div class="mb-3">
<label for="smseagle-priority" class="form-label">{{ $t("smseaglePriority") }}</label>
<input id="smseagle-priority" v-model="$parent.notification.smseaglePriority" type="number" class="form-control" min="0" max="9" step="1" placeholder="0">
</div>
<div class="mb-3 form-check form-switch">
<label for="smseagle-encoding" class="form-label">{{ $t("smseagleEncoding") }}</label>
<input id="smseagle-encoding" v-model="$parent.notification.smseagleEncoding" type="checkbox" class="form-check-input">
<div v-if="$parent.notification.smseagleApiType === 'smseagle-apiv2'" class="mb-3">
<div class="mb-3">
<!-- phone number -->
<label for="smseagle-recipient-to" class="form-label">{{ $t("smseagleTo") }}</label>
<input id="smseagle-recipient-to" v-model="$parent.notification.smseagleRecipientTo" type="text" class="form-control">
<i18n-t tag="div" keypath="smseagleComma" class="form-text" />
</div>
<div class="mb-3">
<label for="smseagle-recipient-group" class="form-label">{{ $t("smseagleGroupV2") }}</label>
<input id="smseagle-recipient-group" v-model="$parent.notification.smseagleRecipientGroup" type="text" class="form-control">
<i18n-t tag="div" keypath="smseagleComma" class="form-text" />
</div>
<div class="mb-3">
<label for="smseagle-recipient-contact" class="form-label">{{ $t("smseagleContactV2") }}</label>
<input id="smseagle-recipient-contact" v-model="$parent.notification.smseagleRecipientContact" type="text" class="form-control">
<i18n-t tag="div" keypath="smseagleComma" class="form-text" />
</div>
<div class="mb-3">
<label for="smseagle-priority-v2" class="form-label">{{ $t("smseaglePriority") }}</label>
<input id="smseagle-priority-v2" v-model="$parent.notification.smseaglePriority" type="number" class="form-control" min="0" max="9" step="1" placeholder="0">
</div>
<div class="mb-3 form-check form-switch">
<label for="smseagle-encoding-v2" class="form-label">{{ $t("smseagleEncoding") }}</label>
<input id="smseagle-encoding-v2" v-model="$parent.notification.smseagleEncoding" type="checkbox" class="form-check-input">
</div>
<div class="mb-3">
<label for="smseagle-msg-type-v2" class="form-label">{{ $t("smseagleMsgType") }} </label>
<select id="smseagle-msg-type-v2" v-model="$parent.notification.smseagleMsgType" class="form-select">
<option value="smseagle-sms" selected>{{ $t("smseagleMsgSms") }} </option>
<option value="smseagle-ring">{{ $t("smseagleMsgRing") }} </option>
<option value="smseagle-tts">{{ $t("smseagleMsgTts") }} </option>
<option value="smseagle-tts-advanced">{{ $t("smseagleMsgTtsAdvanced") }} </option>
</select>
</div>
<div v-if="$parent.notification.smseagleMsgType && $parent.notification.smseagleMsgType !== 'smseagle-sms'" class="mb-3">
<label for="smseagle-duration-v2" class="form-label">{{ $t("smseagleDuration") }}</label>
<input id="smseagle-duration-v2" v-model="$parent.notification.smseagleDuration" type="number" class="form-control" min="0" max="30" step="1" placeholder="10">
</div>
<div v-if="$parent.notification.smseagleMsgType === 'smseagle-tts-advanced'" class="mb-3">
<label for="smseagle-tts-model-v2" class="form-label">{{ $t("smseagleTtsModel") }} </label>
<input id="smseagle-tts-model-v2" v-model="$parent.notification.smseagleTtsModel" type="number" class="form-control" placeholder="1" required>
</div>
</div>
</template>
@ -36,5 +128,16 @@ export default {
components: {
HiddenInput,
},
mounted() {
if (!this.$parent.notification.smseagleApiType) {
this.$parent.notification.smseagleApiType = "smseagle-apiv1";
}
if (!this.$parent.notification.smseagleMsgType) {
this.$parent.notification.smseagleMsgType = "smseagle-sms";
}
if (!this.$parent.notification.smseagleRecipientType) {
this.$parent.notification.smseagleRecipientType = "smseagle-to";
}
}
};
</script>

View file

@ -0,0 +1,46 @@
<template>
<div class="mb-3">
<label for="smsplanet-api-token" class="form-label">{{ $t('smsplanetApiToken') }}</label>
<HiddenInput id="smsplanet-api-token" v-model="$parent.notification.smsplanetApiToken" :required="true"></HiddenInput>
<i18n-t tag="div" keypath="smsplanetApiDocs" class="form-text">
<template #the_smsplanet_documentation>
<a
href="https://smsplanet.pl/doc/slate/index.html#introduction"
target="_blank"
>{{ $t("the smsplanet documentation") }}</a>
</template>
</i18n-t>
</div>
<div class="mb-3">
<label for="smsplanet-phone-numbers" class="form-label">{{ $t("Phone numbers") }}</label>
<textarea
id="smsplanet-phone-numbers"
v-model="$parent.notification.smsplanetPhoneNumbers"
class="form-control"
:placeholder="smsplanetPhoneNumbers"
required
></textarea>
</div>
<div class="mb-3">
<label for="smsplanet-sender-name" class="form-label">{{ $t("Sender name") }}</label>
<input id="smsplanet-sender-name" v-model="$parent.notification.smsplanetSenderName" type="text" minlength="3" maxlength="11" class="form-control">
<div class="form-text">{{ $t("smsplanetNeedToApproveName") }}</div>
</div>
</template>
<script>
import HiddenInput from "../HiddenInput.vue";
export default {
components: {
HiddenInput,
},
computed: {
smsplanetPhoneNumbers() {
return this.$t("Example:", [
"+48123456789,+48111222333",
]);
}
}
};
</script>

View file

@ -79,6 +79,15 @@
<div class="form-text">{{ $t("leave blank for default body") }}</div>
</div>
<div class="mb-3">
<div class="form-check">
<input id="use-html-body" v-model="$parent.notification.htmlBody" class="form-check-input" type="checkbox" value="">
<label class="form-check-label" for="use-html-body">
{{ $t("Use HTML for custom E-mail body") }}
</label>
</div>
</div>
<ToggleSection :heading="$t('smtpDkimSettings')">
<i18n-t tag="div" keypath="smtpDkimDesc" class="form-text mb-3">
<a href="https://nodemailer.com/dkim/" target="_blank">{{ $t("documentation") }}</a>

View file

@ -0,0 +1,19 @@
<template>
<div class="mb-3">
<label for="spugpush-templateKey" class="form-label">{{ $t("SpugPush Template Code") }}</label>
<HiddenInput id="spugpush-templateKey" v-model="$parent.notification.templateKey" :required="true" autocomplete="new-password"></HiddenInput>
</div>
<i18n-t tag="p" keypath="More info on:" style="margin-top: 8px;">
<a href="https://push.spug.cc/guide/plugin/kuma" rel="noopener noreferrer" target="_blank">https://push.spug.cc</a>
</i18n-t>
</template>
<script>
import HiddenInput from "../HiddenInput.vue";
export default {
components: {
HiddenInput,
},
};
</script>

View file

@ -4,6 +4,7 @@ import AliyunSMS from "./AliyunSms.vue";
import Apprise from "./Apprise.vue";
import Bark from "./Bark.vue";
import Bitrix24 from "./Bitrix24.vue";
import Notifery from "./Notifery.vue";
import ClickSendSMS from "./ClickSendSMS.vue";
import CallMeBot from "./CallMeBot.vue";
import SMSC from "./SMSC.vue";
@ -29,6 +30,7 @@ import Mattermost from "./Mattermost.vue";
import Nostr from "./Nostr.vue";
import Ntfy from "./Ntfy.vue";
import Octopush from "./Octopush.vue";
import OneChat from "./OneChat.vue";
import OneBot from "./OneBot.vue";
import Onesender from "./Onesender.vue";
import Opsgenie from "./Opsgenie.vue";
@ -36,6 +38,7 @@ import PagerDuty from "./PagerDuty.vue";
import FlashDuty from "./FlashDuty.vue";
import PagerTree from "./PagerTree.vue";
import PromoSMS from "./PromoSMS.vue";
import Pumble from "./Pumble.vue";
import Pushbullet from "./Pushbullet.vue";
import PushDeer from "./PushDeer.vue";
import Pushover from "./Pushover.vue";
@ -62,6 +65,7 @@ import WeCom from "./WeCom.vue";
import GoAlert from "./GoAlert.vue";
import ZohoCliq from "./ZohoCliq.vue";
import Splunk from "./Splunk.vue";
import SpugPush from "./SpugPush.vue";
import SevenIO from "./SevenIO.vue";
import Whapi from "./Whapi.vue";
import WAHA from "./WAHA.vue";
@ -70,6 +74,7 @@ import WPush from "./WPush.vue";
import SIGNL4 from "./SIGNL4.vue";
import SendGrid from "./SendGrid.vue";
import YZJ from "./YZJ.vue";
import SMSPlanet from "./SMSPlanet.vue";
/**
* Manage all notification form.
@ -106,6 +111,7 @@ const NotificationFormList = {
"nostr": Nostr,
"ntfy": Ntfy,
"octopush": Octopush,
"OneChat": OneChat,
"OneBot": OneBot,
"Onesender": Onesender,
"Opsgenie": Opsgenie,
@ -113,6 +119,7 @@ const NotificationFormList = {
"FlashDuty": FlashDuty,
"PagerTree": PagerTree,
"promosms": PromoSMS,
"pumble": Pumble,
"pushbullet": Pushbullet,
"PushByTechulus": TechulusPush,
"PushDeer": PushDeer,
@ -135,6 +142,7 @@ const NotificationFormList = {
"threema": Threema,
"twilio": Twilio,
"Splunk": Splunk,
"SpugPush": SpugPush,
"webhook": Webhook,
"WeCom": WeCom,
"GoAlert": GoAlert,
@ -142,12 +150,14 @@ const NotificationFormList = {
"ZohoCliq": ZohoCliq,
"SevenIO": SevenIO,
"whapi": Whapi,
"notifery": Notifery,
"waha": WAHA,
"gtxmessaging": GtxMessaging,
"Cellsynt": Cellsynt,
"WPush": WPush,
"SendGrid": SendGrid,
"YZJ": YZJ,
"SMSPlanet": SMSPlanet,
};
export default NotificationFormList;

View file

@ -21,6 +21,9 @@
<label><input v-model="settings.checkBeta" type="checkbox" :disabled="!settings.checkUpdate" @change="saveSettings()" /> {{ $t("Also check beta release") }}</label>
</div>
</div>
<div class="mt-5">
<p>{{ $t("Font Twemoji by Twitter licensed under") }} <a href="https://creativecommons.org/licenses/by/4.0/">CC-BY 4.0</a></p>
</div>
</div>
</div>
</template>

View file

@ -1117,5 +1117,6 @@
"wayToWriteWahaChatId": "Телефонният номер с международния префикс, но без знака плюс в началото ({0}), ID на контакта ({1}) или ID на групата ({2}). Известията се изпращат до това чат ID от WAHA сесия.",
"wayToGetWahaSession": "От тази сесия WAHA изпраща известия до чат ID. Можете да го намерите в таблото за управление на WAHA.",
"telegramServerUrlDescription": "За премахване на API бот ограниченията за Telegram или за получаване на достъп в блокирани зони (Китай, Иран и др.). За повече информация щракнете върху {0}. По подразбиране: {1}",
"telegramServerUrl": "(По избор) URL адрес на сървъра"
"telegramServerUrl": "(По избор) URL адрес на сървъра",
"Font Twemoji by Twitter licensed under": "Шрифт Twemoji от Twitter, лицензиран под"
}

View file

@ -457,7 +457,7 @@
"installing": "Instal·lant",
"uninstall": "Desinstal·la",
"confirmUninstallPlugin": "Estàs segur de desinstal·lar aquest connector?",
"notificationRegional": "Regional",
"notificationRegional": "Local",
"Clone Monitor": "Clona el monitor",
"Clone": "Clona",
"cloneOf": "Clon de {0}",
@ -478,7 +478,7 @@
"To Email": "Destí email",
"smtpCC": "CC",
"smtpBCC": "BCC",
"Discord Webhook URL": "Discord Webhook URL",
"Discord Webhook URL": "URL del Webhook de Discord",
"wayToGetDiscordURL": "Pots rebre aquest per anar a Paràmetres de Servidor -> Integracions -> Vista *Webhooks -> Nou *Webhook",
"Bot Display Name": "Nom de pantalla de bot",
"Prefix Custom Message": "Prefix de missatge personalitzat",
@ -560,5 +560,14 @@
"templateStatus": "Estat",
"telegramUseTemplate": "Fes servir una plantilla de missatge personalitzada",
"telegramUseTemplateDescription": "Si s'activa, el missatge s'enviarà fent servir una plantilla personalitzada.",
"telegramTemplateFormatDescription": "Telegram permet l'ús de diferents tipus de llenguatges de marcat, llegeix Telegram {0} per més detalls."
"telegramTemplateFormatDescription": "Telegram permet l'ús de diferents tipus de llenguatges de marcat, llegeix Telegram {0} per més detalls.",
"wayToGetDiscordThreadId": "Obtenir un identificador de publicació del fil/fòrum és semblant a obtenir un identificador de canal. Més informació sobre com obtenir identificadors {0}",
"lineDevConsoleTo": "Consola de desenvolupadors de linia - {0}",
"Basic Settings": "Configuracions bàsiques",
"User ID": "ID d'usuari",
"Your User ID": "El teu identificador d'usuari",
"Messaging API": "API de missatges",
"wayToGetLineChannelToken": "Primer accediu a {0}, creeu un proveïdor i un canal (API de missatgeria) i, a continuació, podeu obtenir el token d'accés al canal i l'identificador d'usuari dels elements del menú esmentats anteriorment.",
"Icon URL": "URL de la icona",
"aboutIconURL": "Pots donar un enllaç a la imatge a \"URL de la icona\" per sobreposar-la a la imatge de perfil pere defecte. No s'usarà si hi ha una icona d'emoji establerta."
}

View file

@ -1114,5 +1114,6 @@
"wayToGetWahaApiKey": "API-Schlüssel ist der Wert der WHATSAPP_API_KEY-Umgebungsvariable, den du beim Ausführen von WAHA verwendet hast.",
"wayToWriteWahaChatId": "Die Telefonnummer mit internationaler Vorwahl, ohne den anfänglichen Pluszeichen ({0}), die Kontakt-ID ({1}) oder die Gruppen-ID ({2}). Die Benachrichtigungen werden an diese Chat-ID von der WAHA-Sitzung gesendet.",
"telegramServerUrl": "(Optional) Server URL",
"telegramServerUrlDescription": "Um die Telegram-Bot-API-Beschränkungen aufzuheben oder in gesperrten Gebieten (China, Iran usw.) Zugriff zu erhalten. Weitere Informationen findest du unter {0}. Standard: {1}"
"telegramServerUrlDescription": "Um die Telegram-Bot-API-Beschränkungen aufzuheben oder in gesperrten Gebieten (China, Iran usw.) Zugriff zu erhalten. Weitere Informationen findest du unter {0}. Standard: {1}",
"Font Twemoji by Twitter licensed under": "Schriftart Twemoji von Twitter lizenziert unter"
}

View file

@ -1117,5 +1117,6 @@
"wayToGetWahaSession": "Von dieser Sitzung aus sendet WAHA Benachrichtigungen an die Chat-ID. Du kannst sie im WAHA Dashboard finden.",
"wayToWriteWahaChatId": "Die Telefonnummer mit internationaler Vorwahl, ohne den anfänglichen Pluszeichen ({0}), die Kontakt-ID ({1}) oder die Gruppen-ID ({2}). Die Benachrichtigungen werden an diese Chat-ID von der WAHA-Sitzung gesendet.",
"telegramServerUrlDescription": "Um die Telegram-Bot-API-Beschränkungen aufzuheben oder in gesperrten Gebieten (China, Iran usw.) Zugriff zu erhalten. Weitere Informationen findest du unter {0}. Standard: {1}",
"telegramServerUrl": "(Optional) Server URL"
"telegramServerUrl": "(Optional) Server URL",
"Font Twemoji by Twitter licensed under": "Schriftart Twemoji von Twitter lizenziert unter"
}

View file

@ -64,6 +64,7 @@
"Expected Value": "Expected Value",
"Json Query Expression": "Json Query Expression",
"Friendly Name": "Friendly Name",
"defaultFriendlyName": "New Monitor",
"URL": "URL",
"Hostname": "Hostname",
"Host URL": "Host URL",
@ -517,6 +518,7 @@
"Clone": "Clone",
"cloneOf": "Clone of {0}",
"smtp": "Email (SMTP)",
"Use HTML for custom E-mail body": "Use HTML for custom E-mail body",
"secureOptionNone": "None / STARTTLS (25, 587)",
"secureOptionTLS": "TLS (465)",
"Ignore TLS Error": "Ignore TLS Error",
@ -757,12 +759,26 @@
"smseagleTo": "Phone number(s)",
"smseagleGroup": "Phonebook group name(s)",
"smseagleContact": "Phonebook contact name(s)",
"smseagleGroupV2": "Phonebook group ID(s)",
"smseagleContactV2": "Phonebook contact ID(s)",
"smseagleRecipientType": "Recipient type",
"smseagleRecipient": "Recipient(s) (multiple must be separated with comma)",
"smseagleToken": "API Access token",
"smseagleUrl": "Your SMSEagle device URL",
"smseagleEncoding": "Send as Unicode",
"smseaglePriority": "Message priority (0-9, default = 0)",
"smseagleEncoding": "Send as Unicode (default=GSM-7)",
"smseaglePriority": "Message priority (0-9, highest priority = 9)",
"smseagleMsgType": "Message type",
"smseagleMsgSms": "Sms message (default)",
"smseagleMsgRing": "Ring call",
"smseagleMsgTts": "Text-to-speech call",
"smseagleMsgTtsAdvanced": "Text-to-speech Advanced call",
"smseagleDuration": "Duration (in seconds)",
"smseagleTtsModel": "Text-to-speech model ID",
"smseagleApiType": "API version",
"smseagleApiv1": "APIv1 (for existing projects and backward compatibility)",
"smseagleApiv2": "APIv2 (recommended for new integrations)",
"smseagleDocs": "Check documentation or APIv2 availability: {0}",
"smseagleComma": "Multiple must be separated with comma",
"smspartnerApiurl": "You can find your API key in your dashboard at {0}",
"smspartnerPhoneNumber": "Phone number(s)",
"smspartnerPhoneNumberHelptext": "The number must be in the international format {0}, {1}. Multiple numbers must be separated by {2}",
@ -784,6 +800,7 @@
"PushDeer Server": "PushDeer Server",
"pushDeerServerDescription": "Leave blank to use the official server",
"PushDeer Key": "PushDeer Key",
"SpugPush Template Code": "Template Code",
"wayToGetClickSendSMSToken": "You can get API Username and API Key from {0} .",
"Custom Monitor Type": "Custom Monitor Type",
"Google Analytics ID": "Google Analytics ID",
@ -878,8 +895,10 @@
"noGroupMonitorMsg": "Not Available. Create a Group Monitor First.",
"Close": "Close",
"Request Body": "Request Body",
"wayToGetFlashDutyKey": "You can go to Channel -> (Select a Channel) -> Integrations -> Add a new integration' page, add a 'Uptime Kuma' to get a push address, copy the Integration Key in the address. For more information, please visit",
"wayToGetFlashDutyKey": "To integrate Uptime Kuma with Flashduty: Go to Channels > Select a channel > Integrations > Add a new integration, choose Uptime Kuma, and copy the Push URL.",
"FlashDuty Severity": "Severity",
"FlashDuty Push URL": "Push URL",
"FlashDuty Push URL Placeholder": "Copy from the alerting integration page",
"nostrRelays": "Nostr relays",
"nostrRelaysHelp": "One relay URL per line",
"nostrSender": "Sender Private Key (nsec)",
@ -1057,6 +1076,21 @@
"rabbitmqHelpText": "To use the monitor, you will need to enable the Management Plugin in your RabbitMQ setup. For more information, please consult the {rabitmq_documentation}.",
"SendGrid API Key": "SendGrid API Key",
"Separate multiple email addresses with commas": "Separate multiple email addresses with commas",
"pingCountLabel": "Max Packets",
"pingCountDescription": "Number of packets to send before stopping",
"pingNumericLabel": "Numeric Output",
"pingNumericDescription": "If checked, IP addresses will be output instead of symbolic hostnames",
"pingGlobalTimeoutLabel": "Global Timeout",
"pingGlobalTimeoutDescription": "Total time in seconds before ping stops, regardless of packets sent",
"pingPerRequestTimeoutLabel": "Per-Ping Timeout",
"pingPerRequestTimeoutDescription": "This is the maximum waiting time (in seconds) before considering a single ping packet lost",
"pingIntervalAdjustedInfo": "Interval adjusted based on packet count, global timeout and per-ping timeout",
"smtpHelpText": "'SMTPS' tests that SMTP/TLS is working; 'Ignore TLS' connects over plaintext; 'STARTTLS' connects, issues a STARTTLS command and verifies the server certificate. None of these send an email.",
"Custom URL": "Custom URL",
"customUrlDescription": "Will be used as the clickable URL instead of the monitor's one.",
"OneChatAccessToken": "OneChat Access Token",
"OneChatUserIdOrGroupId": "OneChat User ID or Group ID",
"OneChatBotId": "OneChat Bot ID",
"wahaSession": "Session",
"wahaChatId": "Chat ID (Phone Number / Contact ID / Group ID)",
"wayToGetWahaApiUrl": "Your WAHA Instance URL.",
@ -1067,5 +1101,13 @@
"YZJ Robot Token": "YZJ Robot token",
"Plain Text": "Plain Text",
"Message Template": "Message Template",
"Template Format": "Template Format"
"Template Format": "Template Format",
"Font Twemoji by Twitter licensed under": "Font Twemoji by Twitter licensed under",
"smsplanetApiToken": "Token for the SMSPlanet API",
"smsplanetApiDocs": "Detailed information on obtaining API tokens can be found in {the_smsplanet_documentation}.",
"the smsplanet documentation": "the smsplanet documentation",
"Phone numbers": "Phone numbers",
"Sender name": "Sender name",
"smsplanetNeedToApproveName": "Needs to be approved in the client panel",
"Disable URL in Notification": "Disable URL in Notification"
}

View file

@ -341,7 +341,7 @@
"Packet Size": "Paketin koko",
"telegram": "Telegram",
"ZohoCliq": "ZohoCliq",
"Bot Token": "Botin token",
"Bot Token": "Botin tokeni",
"wayToGetTelegramToken": "Voit saada tunnuksen osoitteesta {0}.",
"Chat ID": "Chat-tunnus",
"wayToGetTelegramChatID": "Saat chat-tunnuksesi lähettämällä viestin botille ja siirtymällä tähän URL-osoitteeseen nähdäksesi chat_id:",
@ -1096,5 +1096,25 @@
"RabbitMQ Nodes": "RabbitMQ-hallintasolmut",
"rabbitmqNodesDescription": "Anna URL RabbitMQ-hallintasolmuille sisältäen protokollan ja portin. Esimerkki: {0}",
"rabbitmqHelpText": "Jotta voit käyttää seurainta, sinun on otettava hallintalaajennus käyttöön RabbitMQ-asetuksissa. Lisätietoja saat osoitteesta {rabitmq_documentation}.",
"aboutSlackUsername": "Muuttaa viestin lähettäjän näyttönimeä. Jos haluat mainita jonkun, lisää se ystävälliseen nimeen."
"aboutSlackUsername": "Muuttaa viestin lähettäjän näyttönimeä. Jos haluat mainita jonkun, lisää se ystävälliseen nimeen.",
"Font Twemoji by Twitter licensed under": "Twemoji-fontti (Twitter) on lisensoitu seuraavalla lisenssillä",
"wayToGetWahaSession": "Tästä istunnosta WAHA lähettää ilmoituksia Chat ID:hen. Löydät sen WAHA kojelaudasta.",
"wayToWriteWahaChatId": "Puhelinnumero kansainvälisellä etuliitteellä, mutta ilman plusmerkkiä alussa ({0}), yhteystietotunnusta ({1}) tai ryhmätunnusta ({2}). Ilmoitukset lähetetään tähän chat-tunnukseen WAHA-istunnosta.",
"wahaSession": "Istunto",
"wahaChatId": "Viesti ID (Puhelinnumero / Yhteystieto ID / Ryhmä ID)",
"Template Format": "Malli Muotoilu",
"wayToGetWahaApiUrl": "Sinun WAHA instanssin URL.",
"YZJ Webhook URL": "YZJ Webhook URL",
"telegramServerUrl": "(Valinnainen) Palvelin Url",
"telegramServerUrlDescription": "Telegramin bot-api-rajoitusten poistamiseksi tai pääsyn saamiseksi estetyille alueille (Kiina, Iran jne.). Saat lisätietoja napsauttamalla {0}. Oletus: {1}",
"Message Template": "Viesti Malli",
"YZJ Robot Token": "YZJ Robotti tokeni",
"wayToGetWahaApiKey": "API Key on WHATSAPP_API_KEY ympäristömuuttujan arvo, jota käytit WAHA käynnistämiseen.",
"Plain Text": "Pelkkää tekstiä",
"templateServiceName": "palvelin nimi",
"templateHostnameOrURL": "isäntänimi tai URL",
"templateStatus": "tila",
"telegramUseTemplate": "Käytä mukautettua viesti mallia",
"telegramUseTemplateDescription": "Jos aktivoitu, viesti lähetetään käyttämällä mukautettua mallia.",
"telegramTemplateFormatDescription": "Telegram sallii erilaisten merkintäkielien käytön viesteissä, katso Telegram {0} tarkempia tietoja."
}

View file

@ -1117,5 +1117,6 @@
"wayToGetWahaApiKey": "La clé API est la valeur de la variable d'environnement WHATSAPP_API_KEY que vous avez utilisée pour exécuter WAHA.",
"wayToWriteWahaChatId": "Le numéro de téléphone avec le préfixe international, mais sans le signe plus ({0}), l'identifiant de contact ({1}) ni l'identifiant de groupe ({2}). Les notifications sont envoyées à cet identifiant de chat depuis la session WAHA.",
"telegramServerUrlDescription": "Pour lever les limitations de lAPI des bots Telegram ou accéder aux zones bloquées (Chine, Iran, etc.). Pour plus dinformations, cliquez sur {0}. Par défaut : {1}",
"telegramServerUrl": "(Facultatif) URL du serveur"
"telegramServerUrl": "(Facultatif) URL du serveur",
"Font Twemoji by Twitter licensed under": "La police Twemoji de Twitter est sous licence"
}

View file

@ -1080,5 +1080,24 @@
"Fail": "Hiba",
"Pop": "Megjelen",
"Bitrix24 Webhook URL": "Bitrix24 Webhook URL",
"wayToGetHeiiOnCallDetails": "A Trigger ID és az API kulcsok megszerzésének módja a {dokumentáció}"
"wayToGetHeiiOnCallDetails": "A Trigger ID és az API kulcsok megszerzésének módja a {dokumentáció}",
"telegramServerUrl": "(Választható) Szerver Url",
"telegramServerUrlDescription": "A Telegram bot api korlátozásainak feloldása vagy hozzáférés a blokkolt területekhez (Kína, Irán stb.). További információért kattintson a {0} gombra. Alapértelmezett: {1}",
"wahaSession": "Munkamenet",
"wahaChatId": "Beszélgetés azonosító (Telefonszám / Kontakt azonosító / Csoport azonosító)",
"wayToGetWahaApiUrl": "WAHA példányod URL-je.",
"wayToGetWahaApiKey": "Az API-kulcs a WHATSAPP_API_KEY környezeti változó értéke, amelyet a WAHA futtatásához használt.",
"wayToWriteWahaChatId": "A telefonszám nemzetközi előtaggal, de az elején lévő pluszjel ({0}), a kapcsolattartó azonosítója ({1}) vagy a csoportazonosító ({2}) nélkül. A WAHA Session értesítéseket küld erre a beszélgetési azonosítóra.",
"Plain Text": "Sima Szöveg",
"Message Template": "Üzenet Sablon",
"Template Format": "Sablon Formátum",
"wayToGetWahaSession": "A munkamenetből WAHA küld egy értesítést a Beszélgetés azonosítóra. Az értesítést megtalálhatod a WAHA műszerfalon.",
"YZJ Webhook URL": "YZJ Webhook URL",
"YZJ Robot Token": "YZJ Robot token",
"templateServiceName": "szolgáltatás név",
"templateHostnameOrURL": "kiszolgáló név vagy URL",
"templateStatus": "státusz",
"telegramUseTemplate": "Egyéni üzenetsablon használata",
"telegramUseTemplateDescription": "Ha engedélyezve van, az üzenet egy egyéni sablon szerint lesz elküldve.",
"telegramTemplateFormatDescription": "Telegram különböző jelölőnyelvek használatát engedi, további információkért lásd {0}."
}

View file

@ -59,7 +59,7 @@
"day": "giorno | giorni",
"-day": "-giorni",
"hour": "ora",
"-hour": "-ore",
"-hour": "-ora",
"Response": "Risposta",
"Ping": "Ping",
"Monitor Type": "Modalità di monitoraggio",
@ -80,7 +80,7 @@
"pushOptionalParams": "Parametri aggiuntivi: {0}",
"Save": "Salva",
"Notifications": "Notifiche",
"Not available, please setup.": "Non disponibili, richiesta configurazione manuale.",
"Not available, please setup.": "Non disponibile, richiesta configurazione manuale.",
"Setup Notification": "Configura le notifiche",
"Light": "Chiaro",
"Dark": "Scuro",
@ -738,5 +738,9 @@
"invertKeywordDescription": "Cerca la parola chiave essere assente anziché presente.",
"octopushAPIKey": "\"API Key\" dalle credenziali API HTTP nel pannello di controllo",
"Enable TLS": "Abilita TLS",
"ignoredTLSError": "Ignora errori TLS/SSL"
"ignoredTLSError": "Ignora errori TLS/SSL",
"templateHostnameOrURL": "nome host o URL",
"templateStatus": "stato",
"templateServiceName": "nome del servizio",
"locally configured mail transfer agent": "agente mail configurato localmente"
}

View file

@ -1065,5 +1065,25 @@
"Key Added": "追加キー",
"Bark Sound": "Bark通知音",
"Badge URL": "バッジURL",
"pushoversounds intermission": "Intermission"
"pushoversounds intermission": "Intermission",
"telegramServerUrl": "(任意)サーバーUrl",
"telegramServerUrlDescription": "Telegramのボットapiの制限を解除したり、ブロックされた地域中国、イランなどでアクセスする。詳しくは {0} をクリックしてください。デフォルト: {1}",
"wayToWriteWahaChatId": "電話番号の先頭にプラス記号を付けない国際電話番号({0})、コンタクトID ({1})、またはグループID ({2}) 。WAHAセッションからこのチャットIDに通知が送信されます。",
"wahaSession": "セッション",
"wahaChatId": "チャットID電話番号連絡先IDグループID",
"wayToGetWahaApiUrl": "WAHAインスタンスのURL。",
"wayToGetWahaApiKey": "APIキーはWAHAを実行するために使用したWHATSAPP_API_KEY環境変数の値です。",
"wayToGetWahaSession": "このセッションから WAHA はチャット ID に通知を送信します。WAHAダッシュボードで確認できます。",
"YZJ Webhook URL": "YZJ ウェブフック URL",
"YZJ Robot Token": "YZJ ロボットトークン",
"Plain Text": "平文",
"Message Template": "メッセージテンプレート",
"Template Format": "テンプレート形式",
"templateServiceName": "サービス名",
"templateHostnameOrURL": "ホスト名またはURL",
"templateStatus": "ステータス",
"telegramUseTemplate": "カスタムメッセージテンプレートを使用",
"telegramUseTemplateDescription": "有効にすると、メッセージはカスタムテンプレートを使って送信されます。",
"telegramTemplateFormatDescription": "Telegramではメッセージに異なるマークアップ言語を使用することができます。詳細はTelegram {0} を参照してください。",
"Font Twemoji by Twitter licensed under": "TwemojiフォントはTwitterライセンス下でライセンスされています"
}

View file

@ -76,7 +76,7 @@
"Accepted Status Codes": "응답 성공 상태 코드",
"Save": "저장",
"Notifications": "알림",
"Not available, please setup.": "존재하지 않아요, 새로운 거 하나 만드는 건 어때요?",
"Not available, please setup.": "존재하지 않아요. 새로운 거 하나 만드는 건 어때요?",
"Setup Notification": "알림 설정",
"Light": "화이트",
"Dark": "다크",
@ -797,5 +797,42 @@
"successKeywordExplanation": "성공으로 간주되는 MQTT 키워드",
"Reset Token": "토큰 초기화",
"Check/Uncheck": "체크/체크 해제",
"pushViewCode": "푸시 모니터링는 어떻게 사용하나요? (코드 보기)"
"pushViewCode": "푸시 모니터링는 어떻게 사용하나요? (코드 보기)",
"Search monitored sites": "모니터링중인 사이트 검색",
"templateHeartbeatJSON": "heartbeat를 설명하는 오브젝트",
"shrinkDatabaseDescriptionSqlite": "SQLite 데이터베이스에서 {vacuum} 명령을 실행해요. {auto_vacuum}이 이미 활성화되어 있지만, {auto_vacuum}은 {vacuum}이 하는 것처럼 데이터베이스를 조각 모음 하거나 페이지를 다시 압축하지는 않아요.",
"statusPageSpecialSlugDesc": "특별한 주소 {0}: 아무런 주소도 입력되지 않으면 이 페이지가 보여요",
"Add a new expiry notification day": "새 만료 알림 날짜 추가",
"Refresh Interval Description": "이 상태 페이지는 {0}초마다 완전 새로고침(F5) 돼요",
"telegramServerUrlDescription": "텔레그램 봇 API의 제한을 해제하거나, 차단된 지역(중국, 이란 등)에서 액세스하려면 {0}을 클릭하세요. 기본값: {1}",
"chromeExecutableDescription": "Docker 사용자의 경우, Chromium이 아직 설치되지 않았다면 이를 설치하고 테스트 결과를 표시하는 데 몇 분이 걸릴 수 있어요. 1GB의 디스크 공간을 사용해요.",
"templateMonitorJSON": "monitor를 설명하는 오브젝트",
"webhookBodyCustomOption": "커스텀 Body",
"telegramServerUrl": "(선택) 서버 URL",
"and": "그리고",
"emailCustomisableContent": "사용자 지정 가능한 콘텐츠",
"smtpLiquidIntroduction": "다음 두 개 필드는 Liquid 템플릿 언어를 통해 템플릿화할 수 있습니다. 사용 지침은 {0}을 참조하세요. 사용 가능한 변수는 다음과 같습니다:",
"leave blank for default subject": "기본값을 사용하려면 비워두세요",
"emailCustomBody": "커스텀 Body",
"leave blank for default body": "기본값을 사용하려면 비워두세요",
"templateServiceName": "서비스 이름",
"templateHostnameOrURL": "호스트명 또는 URL",
"templateStatus": "상태",
"selectedMonitorCount": "선택됨: {0}",
"Remove the expiry notification": "만료 알림 날짜 제거",
"Refresh Interval": "새로고침 주기",
"noDockerHostMsg": "사용할 수 없습니다. 먼저 도커 호스트를 설정하세요.",
"DockerHostRequired": "이 모니터링을 위한 도커 호스트를 설정해 주세요.",
"tailscalePingWarning": "Tailscale Ping 모니터링을 사용하려면 Docker 없이 Uptime Kuma를 설치하고 서버에 Tailscale 클라이언트도 설치해야 합니다.",
"telegramUseTemplate": "커스텀 메시지 템플릿 사용",
"telegramUseTemplateDescription": "활성화하면 메시지를 보낼 때 커스텀 템플릿을 사용해요.",
"telegramTemplateFormatDescription": "텔레그램은 메시지에 다양한 마크업 언어를 사용할 수 있어요. 자세한 내용은 텔레그램 {0}을 참조하세요.",
"RabbitMQ Username": "RabbitMQ 사용자명",
"RabbitMQ Password": "RabbitMQ 비밀번호",
"wahaSession": "세션",
"emailTemplateMsg": "알림 메시지",
"Select message type": "메시지 유형 선택",
"Send to channel": "채널로 전송",
"Create new forum post": "새 포럼 게시물 만들기",
"Your User ID": "사용자 ID"
}

7
src/lang/lv.json Normal file
View file

@ -0,0 +1,7 @@
{
"languageName": "Latviešu",
"setupDatabaseChooseDatabase": "Kuru datubāzi izmantosiet?",
"setupDatabaseEmbeddedMariaDB": "Jums nav nekas jādara. Docker imidžā ir iebūvēta un automātiski konfigurēta MariaDB datubāze. Uptime Kuma pieslēgsies šai datubāzei izmantojot unix soketu.",
"setupDatabaseSQLite": "Vienkāršs datu bāzes fails, iesakāms maza izmēra risinājumiem. Pirms versijas v2.0.0 SQLite bija noklusējuma datubāze.",
"setupDatabaseMariaDB": "Pieslēgties ārējai MariaDB datubāzei. Jums būs jākonfigurē datubāzes pieslēgšanās informācija."
}

View file

@ -7,24 +7,24 @@
"Game": "Permainan",
"Primary Base URL": "URL Pangkalan Utama",
"Version": "Versi",
"Add": "Menambah",
"Quick Stats": "Statistik ringkas",
"Up": "Dalam talian",
"Down": "Luar talian",
"Pending": "Belum selesai",
"statusMaintenance": "Membaiki",
"Maintenance": "Membaiki",
"Unknown": "Tidak ketahui",
"General Monitor Type": "Jenis monitor umum",
"Check Update On GitHub": "Semak kemas kini dalam GitHub",
"Add": "Tambah",
"Quick Stats": "Statistik Pantas",
"Up": "Atas",
"Down": "Bawah",
"Pending": "Dalam Proses",
"statusMaintenance": "Penyelenggaraan",
"Maintenance": "Penyelenggaraan",
"Unknown": "Tidak Diketahui",
"General Monitor Type": "Jenis Monitor Umum",
"Check Update On GitHub": "Semak kemas kini di GitHub",
"List": "Senarai",
"Specific Monitor Type": "Jenis monitor spesifik",
"Specific Monitor Type": "Jenis Monitor Spesifik",
"markdownSupported": "Sintaks markdown disokong",
"languageName": "Bahasa inggeris",
"Dashboard": "Papan pemuka",
"Language": "Bahasa",
"Add New Monitor": "Tambah monitor baharu",
"Passive Monitor Type": "Jenis monitor pasif",
"Add New Monitor": "Tambah Monitor Baharu",
"Passive Monitor Type": "Jenis Monitor Pasif",
"No Services": "Tiada Servis",
"Add a monitor": "Tambah Monitor",
"High": "Tinggi",
@ -49,5 +49,41 @@
"Content Type": "Jenis Content",
"Home": "Laman Utama",
"Settings": "Tetapan",
"Save": "Simpan"
"Save": "Simpan",
"Cannot connect to the socket server": "Tidak dapat disambungkan kepada pelayan soket",
"Resume": "Sambung",
"Current": "Terkini",
"Uptime": "Uptime",
"Cert Exp.": "Tamat Sijil",
"now": "sekarang",
"setupDatabaseMariaDB": "Sambungan kepada pangkalan data MariaDB secara luaran. Anda perlu tetapkan maklumat sambungan pangkalan data.",
"hour": "jam",
"Ping": "Ping",
"settingUpDatabaseMSG": "Pangkalan data sedang ditetapkan. Sila tunggu sebentar.",
"Reconnecting...": "Penyambungan...",
"Message": "Mesej",
"No important events": "Tiada info penting",
"Edit": "Sunting",
"Delete": "Padam",
"Monitor": "Monitor | Monitors",
"time ago": "{0} yang lepas",
"day": "hari | hari",
"-day": "-hari",
"-year": "-tahun",
"Pause": "Rehat",
"Status": "Status",
"DateTime": "TarikhMasa",
"dbName": "Nama Pangkalan Data",
"-hour": "-jam",
"Response": "Tindakbalas",
"Monitor Type": "Jenis Monitor",
"Keyword": "Katakunci",
"pauseDashboardHome": "Rehat",
"Name": "Nama",
"setupDatabaseChooseDatabase": "Pangkalan Data yang mana hendak digunakan ?",
"Host URL": "URL Host",
"URL": "URL",
"Expected Value": "Nilai Sepatutnya",
"Friendly Name": "Nama Mudah",
"Hostname": "Nama Host"
}

View file

@ -127,7 +127,7 @@
"Create": "Aanmaken",
"Clear Data": "Data wissen",
"Events": "Gebeurtenissen",
"Heartbeats": "Heartbeats",
"Heartbeats": "Hartslagen",
"Auto Get": "Auto Get",
"backupDescription": "U kunt een back-up maken van alle monitoren en alle meldingen in een JSON-bestand.",
"backupDescription2": "PS: Geschiedenis- en gebeurtenisgegevens zijn niet inbegrepen.",
@ -464,24 +464,24 @@
"Show Powered By": "Laat \"Mogeljik gemaakt door\" zien",
"Domain Names": "Domein Namen",
"pushoversounds pushover": "Pushover (standaard)",
"pushoversounds bike": "Bike",
"pushoversounds bugle": "Bugle",
"pushoversounds cashregister": "Cash Register",
"pushoversounds bike": "Fiets",
"pushoversounds bugle": "Trompet",
"pushoversounds cashregister": "Kassa",
"pushoversounds classical": "Classical",
"pushoversounds cosmic": "Cosmic",
"pushoversounds falling": "Falling",
"pushoversounds cosmic": "Buitenaards",
"pushoversounds falling": "Vallend",
"pushoversounds gamelan": "Gamelan",
"pushoversounds incoming": "Incoming",
"pushoversounds intermission": "Intermission",
"pushoversounds magic": "Magic",
"pushoversounds mechanical": "Mechanical",
"pushoversounds incoming": "Inkomend",
"pushoversounds intermission": "Pauze",
"pushoversounds magic": "Magie",
"pushoversounds mechanical": "Mechanisch",
"pushoversounds pianobar": "Piano Bar",
"pushoversounds siren": "Siren",
"pushoversounds spacealarm": "Space Alarm",
"pushoversounds siren": "Sirene",
"pushoversounds spacealarm": "Ruimte Alarm",
"pushoversounds tugboat": "Tug Boat",
"pushoversounds alien": "Alien Alarm (long)",
"pushoversounds climb": "Climb (long)",
"pushoversounds persistent": "Persistent (long)",
"pushoversounds persistent": "Aanhoudend (lang)",
"pushoversounds echo": "Pushover Echo (long)",
"pushoversounds updown": "Up Down (long)",
"pushoversounds vibrate": "Alleen trillen",
@ -649,8 +649,8 @@
"smseagleTo": "Telefoonnummer(s)",
"Custom Monitor Type": "Custom Monitor Type",
"trustProxyDescription": "'X-Forwarded-*' headers vertrouwen. Als je de correcte client IP wilt krijgen en de Uptime Kuma installatie is achter een proxy zoals Nginx of Apache, schakel dan dit in.",
"RadiusCalledStationId": "Called Station Id",
"RadiusCalledStationIdDescription": "Identifier of the called device",
"RadiusCalledStationId": "Genoemde stations ID",
"RadiusCalledStationIdDescription": "Identificatie van het genoemde apparaat",
"RadiusCallingStationId": "Calling Station Id",
"ZohoCliq": "ZohoCliq",
"Long-Lived Access Token": "Long-Lived Access Token",
@ -789,7 +789,7 @@
"Badge Warn Days": "Badge Waarschuwing dagen",
"Badge Down Days": "Badge Offline dagen",
"Badge Style": "Badge stijl",
"chromeExecutable": "Chrome/Chromium Executable",
"chromeExecutable": "Chrome/Chromium Uitvoerbaar bestand",
"chromeExecutableAutoDetect": "Automatisch detecteren",
"Edit Maintenance": "Onderhoud bewerken",
"Badge Label": "Badge Label",
@ -1039,36 +1039,36 @@
"ends with": "eindigt met",
"not ends with": "eindigt niet met",
"less than": "minder dan",
"greater than": "meer dan",
"greater than": "groter dan",
"record": "dossier",
"jsonQueryDescription": "Parseer en haal specifieke gegevens uit de JSON-respons van de server met behulp van JSON-query of gebruik \"$\" voor de onbewerkte respons, als u geen JSON verwacht. Het resultaat wordt vervolgens vergeleken met de verwachte waarde, als strings. Zie {0} voor documentatie en gebruik {1} om te experimenteren met query's.",
"rabbitmqNodesDescription": "Voer het URL voor de RabbitMQ beheerkooppunt inclusief protocol en poort in. Bijvoorbeeld: {0}",
"rabbitmqNodesDescription": "Voer het URL voor de RabbitMQ beheer nodes inclusief protocol en poort in. Bijvoorbeeld: {0}",
"rabbitmqNodesRequired": "Aub stel de knooppunten voor deze monitor in.",
"rabbitmqNodesInvalid": "Stel gebruik een volledig gekwalificeerde (beginnend met 'http') URL voor RabbitMQ-knooppunten.",
"rabbitmqNodesInvalid": "Gebruik een volledig gekwalificeerde (beginnend met 'http') URL voor de RabbitMQ nodes.",
"RabbitMQ Username": "RabbitMQ gebruikersnaam",
"RabbitMQ Password": "RabbitMQ wachtwoord",
"rabbitmqHelpText": "Om gebruik te maken van de monitor moet je de Management Plugin in de RabbitMQ setup aanzetten. Voor meer informatie zie de {rabitmq_documentatie}.",
"SendGrid API Key": "SendGrid API sleutel",
"Separate multiple email addresses with commas": "Splits meerdere emailadressen met kommas",
"RabbitMQ Nodes": "RabbitMQ Beheerknoppunten",
"RabbitMQ Nodes": "RabbitMQ beheer Nodes",
"shrinkDatabaseDescriptionSqlite": "Trigger database {vacuum} voor SQLite. {auto_vacuum} is al ingeschakeld, maar hiermee wordt de database niet gedefragmenteerd en worden ook databasepagina's niet afzonderlijke opnieuw ingepakt zoals de opdracht {vacuum} dat doet.",
"aboutSlackUsername": "Wijzigt de weergavenaam van de afzender van het bericht. Als je iemand wilt vermelden, voer in dat geval de naam in als vriendelijke naam.",
"cacheBusterParam": "Voeg de parameter {0} toe",
"Form Data Body": "Formulier Gegevens Content",
"Optional: Space separated list of scopes": "Optioneel: Reikwijdte door spaties gescheiden lijst",
"Alphanumerical string and hyphens only": "Alleen alfanumerieke tekenreeksen en koppeltekens",
"aboutSlackUsername": "Verandert de weergavenaam van de afzender. Als je iemand wil vermelden, voeg dit dan aan de vriendelijke naam toe.",
"cacheBusterParam": "Voeg de {0} parameter",
"Form Data Body": "Formulier Gegevens Body",
"Optional: Space separated list of scopes": "Optioneel: door spaties gescheiden lijst met scopes",
"Alphanumerical string and hyphens only": "Alleen alfanumerieke tekens en streepjes",
"Time sensitive notifications will be delivered immediately, even if the device is in do not disturb mode.": "Tijdsgevoelige meldingen worden meteen afgeleverd, zelfs als het apparaat in niet storen modus staat.",
"Message format": "Berichtformaat",
"Send rich messages": "Stuur rijke berichten",
"OAuth Scope": "OAuth Reikwijdte",
"equals": "gelijk aan",
"Message format": "Bericht opmaak",
"Send rich messages": "Verstuur berichten met opmaak",
"OAuth Scope": "OAuth bereik",
"equals": "hetzelfde als",
"not equals": "niet gelijk aan",
"less than or equal to": "kleiner dan of gelijk aan",
"greater than or equal to": "groter dan of gelijk aan",
"Notification Channel": "Meldingskanaal",
"less than or equal to": "minder dan of gelijk aan",
"greater than or equal to": "meer dan of gelijk aan",
"Notification Channel": "Notificatie kanaal",
"Sound": "Geluid",
"Arcade": "Speelhal",
"Correct": "Juist",
"Correct": "Goed",
"Fail": "Mislukt",
"Harp": "Harp",
"Reveal": "Laat zien",
@ -1082,12 +1082,31 @@
"Time Sensitive (iOS Only)": "Tijdsgevoelig (alleen voor iOs)",
"From": "Van",
"Can be found on:": "Kan gevonden worden op: {0}",
"The phone number of the recipient in E.164 format.": "Het telefoonnummer van de ontvanger in E.164 formaat",
"The phone number of the recipient in E.164 format.": "Het telefoonnummer van de ontvanger in E.164 formaat.",
"Either a text sender ID or a phone number in E.164 format if you want to be able to receive replies.": "Ofwel een sms zender ID of een telefoonnummer in E.164 formaat als je reacties wil ontvangen.",
"Clear": "Helder",
"Elevator": "Lift",
"Pop": "Pop",
"Community String": "Gemeenschap Tekst",
"Json Query Expression": "Json Query Expressie",
"ignoredTLSError": "TLS/SSL-fouten zijn genegeerd"
"Community String": "Gemeenschapsreeks",
"Json Query Expression": "JSON Query Expressie",
"ignoredTLSError": "TLS/SSL-fouten zijn genegeerd",
"telegramServerUrl": "(Optioneel) Server Url",
"telegramServerUrlDescription": "Om de beperkingen van Telegram's bot api op te heffen of toegang te krijgen in geblokkeerde gebieden (China, Iran, enz.). Klik voor meer informatie op {0}. Standaard: {1}",
"wahaSession": "Sessie",
"wahaChatId": "Chat-ID (telefoonnummer / contact-ID / groeps-ID)",
"wayToGetWahaApiUrl": "Je WAHA Instance URL.",
"wayToGetWahaApiKey": "API Key is de WHATSAPP_API_KEY omgevingsvariabele die je hebt gebruikt om WAHA uit te voeren.",
"wayToGetWahaSession": "Vanaf deze sessie stuurt WAHA meldingen naar Chat ID. Je kunt deze vinden in WAHA Dashboard.",
"wayToWriteWahaChatId": "Het telefoonnummer met het internationale voorvoegsel, maar zonder het plusteken aan het begin ({0}), de contact-ID ({1}) of de groeps-ID ({2}). Vanuit WAHA Sessie worden meldingen naar deze Chat-ID verzonden.",
"YZJ Robot Token": "YZJ Robot token",
"Plain Text": "Platte tekst",
"Message Template": "Bericht Sjabloon",
"YZJ Webhook URL": "YZJ Webhook URL",
"Template Format": "Sjabloonformaat",
"templateServiceName": "service naam",
"templateHostnameOrURL": "hostnaam of url",
"templateStatus": "status",
"telegramUseTemplate": "Gebruik aangepaste bericht sjabloon",
"telegramTemplateFormatDescription": "Telegram staat het gebruik van verschillende opmaaktalen voor berichten toe, zie Telegram {0} voor specifieke details.",
"telegramUseTemplateDescription": "Indien ingeschakeld, wordt het bericht verzonden met een aangepaste sjabloon."
}

View file

@ -1098,5 +1098,24 @@
"RabbitMQ Username": "Nazwa użytkownika RabbitMQ",
"RabbitMQ Password": "Hasło RabbitMQ",
"SendGrid API Key": "Klucz API SendGrid",
"Separate multiple email addresses with commas": "Oddziel wiele adresów e-mail przecinkami"
"Separate multiple email addresses with commas": "Oddziel wiele adresów e-mail przecinkami",
"templateServiceName": "service name",
"telegramServerUrlDescription": "Aby znieść ograniczenia api bota Telegrama lub uzyskać dostęp w zablokowanych obszarach (Chiny, Iran itp.). Aby uzyskać więcej informacji, kliknij {0}. Domyślnie: {1}",
"wayToGetWahaSession": "Z tej sesji WAHA wysyła powiadomienia do Chat ID. Można go znaleźć w WAHA Dashboard.",
"wayToWriteWahaChatId": "Numer telefonu z prefiksem międzynarodowym, ale bez znaku plus na początku ({0}), identyfikator kontaktu ({1}) lub identyfikator grupy ({2}). Powiadomienia są wysyłane do tego identyfikatora czatu z sesji WAHA.",
"wahaSession": "Sesja",
"wahaChatId": "Identyfikator czatu (numer telefonu / identyfikator kontaktu / identyfikator grupy)",
"wayToGetWahaApiUrl": "Adres URL instancji WAHA.",
"wayToGetWahaApiKey": "Klucz API to wartość zmiennej środowiskowej WHATSAPP_API_KEY użytej do uruchomienia WAHA.",
"YZJ Robot Token": "Token robota YZJ",
"YZJ Webhook URL": "Adres URL usługi YZJ Webhook",
"telegramServerUrl": "(Opcjonalnie) Adres URL serwera",
"Plain Text": "Zwykły tekst",
"Message Template": "Szablon wiadomości",
"Template Format": "Format szablonu",
"templateHostnameOrURL": "nazwa hosta lub adres URL",
"templateStatus": "status",
"telegramUseTemplate": "Użyj niestandardowego szablonu wiadomości",
"telegramUseTemplateDescription": "Jeśli opcja ta jest włączona, wiadomość zostanie wysłana przy użyciu niestandardowego szablonu.",
"telegramTemplateFormatDescription": "Telegram pozwala na używanie różnych języków znaczników dla wiadomości, zobacz Telegram {0}, aby uzyskać szczegółowe informacje."
}

View file

@ -1068,5 +1068,19 @@
"telegramTemplateFormatDescription": "O Telegram permite o uso de diferentes linguagens de marcação para mensagens. Veja o Telegram {0} para detalhes específicos.",
"templateHostnameOrURL": "hostname ou URL",
"templateStatus": "status",
"telegramUseTemplateDescription": "Se habilitado, a mensagem será enviada usando um template personalizado."
"telegramUseTemplateDescription": "Se habilitado, a mensagem será enviada usando um template personalizado.",
"telegramServerUrlDescription": "Para suspender as limitações da API de bots do Telegram ou obter acesso em áreas bloqueadas (China, Irã, etc). Para mais informações, clique em {0}. Padrão: {1}",
"wahaSession": "Sessão",
"wayToGetWahaApiUrl": "URL da sua instância WAHA.",
"wayToGetWahaApiKey": "API Key é o valor da variável de ambiente WHATSAPP_API_KEY que você usou para executar o WAHA.",
"wayToGetWahaSession": "A partir desta sessão, o WAHA envia notificações para o Chat ID. Você pode encontrá-lo no WAHA Dashboard.",
"wayToWriteWahaChatId": "O número de telefone com o prefixo internacional, mas sem o sinal de mais no início ({0}), o Contact ID ({1}) ou o Group ID ({2}). As notificações são enviadas para este Chat ID da sessão WAHA.",
"Plain Text": "Texto Simples",
"wahaChatId": "Chat ID (Número de Telefone / Contact ID / Group ID)",
"YZJ Webhook URL": "YZJ Webhook URL",
"YZJ Robot Token": "YZJ Robot token",
"telegramServerUrl": "(Opcional) URL do Servidor",
"Message Template": "Modelo de Mensagem",
"Template Format": "Formato do Modelo",
"Font Twemoji by Twitter licensed under": "Fonte Twemoji do Twitter licenciada sob"
}

View file

@ -1109,5 +1109,21 @@
"Json Query Expression": "Выражение запроса Json",
"templateServiceName": "имя сервиса",
"templateHostnameOrURL": "hostname или URL",
"templateStatus": "статус"
"templateStatus": "статус",
"telegramServerUrlDescription": "Чтобы поднять ограничения API API Telegram или получить доступ к заблокированным районам (Китай, Иран и т.д.). Для получения дополнительной информации нажмите {0}. По умолчанию: {1}",
"wayToGetWahaApiKey": "Ключ API - это значение переменной среды WHATSAPP_API_KEY, которое вы использовали для запуска WAHA.",
"wayToGetWahaSession": "Из этой сессии WAHA отправляет уведомления на удостоверение личности чата. Вы можете найти его на приборной панели Waha.",
"wayToWriteWahaChatId": "Номер телефона с международным префиксом, но без знака плюс в начале ({0}), идентификатор контакта ({1}) или идентификатора группы ({2}). Уведомления отправляются на этот идентификатор чата от сеанса Waha.",
"wahaSession": "Сессия",
"wahaChatId": "Идентификатор чата (номер телефона / идентификатор контакта / идентификатор группы)",
"wayToGetWahaApiUrl": "Ваш экземпляр WAHA URL.",
"YZJ Webhook URL": "YZJ Вебхук URL",
"YZJ Robot Token": "YZJ Токен Робота",
"telegramServerUrl": "(Необязательно) URL Сервера",
"telegramUseTemplate": "Используйте пользовательский шаблон сообщения",
"telegramUseTemplateDescription": "Если включено, сообщение будет отправлено с помощью пользовательского шаблона.",
"telegramTemplateFormatDescription": "Telegram позволяет использовать различные языки разметки для сообщений, см. Telegram {0} для конкретных деталей.",
"Plain Text": "Простой текст",
"Message Template": "Шаблон сообщения",
"Template Format": "Формат шаблона"
}

View file

@ -1,5 +1,5 @@
{
"languageName": "English",
"languageName": "İngilizce",
"checkEverySecond": "{0} saniyede bir kontrol et",
"retryCheckEverySecond": "{0} saniyede bir dene",
"resendEveryXTimes": "Her {0} bir yeniden gönder",
@ -183,7 +183,7 @@
"Entry Page": "Giriş Sayfası",
"statusPageNothing": "Burada hiçbir şey yok, lütfen bir grup veya servis ekleyin.",
"No Services": "Hizmet Yok",
"All Systems Operational": "Tüm Sistemler Operasyonel",
"All Systems Operational": "Tüm Sistemler Sorunsuz",
"Partially Degraded Service": "Kısmen Bozulmuş Hizmet",
"Degraded Service": "Bozulmuş Hizmet",
"Add Group": "Grup Ekle",
@ -224,7 +224,7 @@
"Prefix Custom Message": "Özel Önek Mesajı",
"Hello @everyone is...": "Merhaba {'@'}everyone…",
"teams": "Microsoft Teams",
"Webhook URL": "Webhook URL",
"Webhook URL": "Webhook URL'si",
"wayToGetTeamsURL": "Bir webhook URL'sinin nasıl oluşturulacağını öğrenebilirsiniz {0}.",
"signal": "Sinyal",
"Number": "Numara",
@ -378,8 +378,8 @@
"auto resolve": "otomatik çözümleme",
"gorush": "Gorush",
"alerta": "Alerta",
"alertaApiEndpoint": "API Endpoint",
"alertaEnvironment": "Environment",
"alertaApiEndpoint": "API Uç Noktası",
"alertaEnvironment": "Ortam",
"alertaApiKey": "API Anahtarı",
"alertaAlertState": "Uyarı Durumu",
"alertaRecoverState": "Kurtarma Durumu",
@ -403,7 +403,7 @@
"Sms template must contain parameters: ": "Sms şablonu parametreleri içermelidir: ",
"Bark Endpoint": "Bark Endpoint",
"Bark Group": "Bark Group",
"Bark Sound": "Bark Sound",
"Bark Sound": "Havlama Sesi",
"WebHookUrl": "WebHookUrl",
"SecretKey": "SecretKey",
"For safety, must use secret key": "Güvenlik için gizli anahtar kullanılmalıdır",
@ -593,7 +593,7 @@
"Kook": "Kook",
"wayToGetKookBotToken": "Uygulama oluşturun ve {0} adresinde bot tokenı alın",
"wayToGetKookGuildID": "Kook ayarında \"Geliştirici Modu\"nu açın ve kimliğini almak için guild'e sağ tıklayın",
"Guild ID": "Guild ID",
"Guild ID": "Sunucu ID'si",
"smseagle": "SMSEagle",
"smseagleTo": "Telefon numara(ları)",
"smseagleGroup": "Telefon defteri grubu ad(lar)ı",
@ -840,11 +840,11 @@
"styleElapsedTime": "Kalp atışı çubuğunun altında geçen süre",
"styleElapsedTimeShowWithLine": "Göster (Satır ile birlikte)",
"enableNSCD": "Tüm DNS isteklerini önbelleğe almak için NSCD'yi (Ad Hizmeti Önbellek Programı) etkinleştirin",
"setupDatabaseEmbeddedMariaDB": "Hiçbir şey ayarlamanıza gerek yok. Bu docker imajı, MariaDB'yi sizin için otomatik olarak yerleştirdi ve yapılandırdı. Çalışma Süresi Kuma bu veritabanına unix soketi aracılığıyla bağlanacaktır.",
"setupDatabaseEmbeddedMariaDB": "Hiçbir şey ayarlamanıza gerek yok. Bu docker imajı, MariaDB'yi sizin için otomatik olarak yerleştirdi ve yapılandırdı. Çalışma Süresi Kuma bu veri tabanına unix soketi aracılığıyla bağlanacaktır.",
"setupDatabaseSQLite": "Küçük ölçekli dağıtımlar için önerilen basit bir veritabanı dosyası. v2.0.0'dan önce Uptime Kuma, varsayılan veritabanı olarak SQLite'ı kullanıyordu.",
"setupDatabaseChooseDatabase": "Hangi veritabanını kullanmak istersiniz?",
"setupDatabaseMariaDB": "Harici bir MariaDB veritabanına bağlanın. Veritabanı bağlantı bilgilerini ayarlamanız gerekir.",
"dbName": "Veritabanı ismi",
"setupDatabaseChooseDatabase": "Hangi veri tabanını kullanmak istersiniz?",
"setupDatabaseMariaDB": "Harici bir MariaDB veri tabanına bağlanın. Veri tabanı bağlantı bilgilerini ayarlamanız gerekir.",
"dbName": "Veri tabanı ismi",
"Saved.": "Kaydedildi.",
"toastErrorTimeout": "Hata Bildirimleri için Zaman Aşımı",
"toastSuccessTimeout": "Başarı Bildirimleri için Zaman Aşımı",
@ -958,7 +958,7 @@
"whatHappensAtForumPost": "Yeni bir forum gönderisi oluşturun. Bu, mevcut gönderiye mesaj YAYINLAMAZ. Mevcut gönderide yayınlamak için \"{option}\" seçeneğini kullanın",
"Command": "Komut",
"mongodbCommandDescription": "Veritabanına karşı bir MongoDB komutu çalıştırın. Mevcut komutlar hakkında bilgi için {dokümantasyona} bakın",
"Bitrix24 Webhook URL": "Bitrix24 Webhook URL",
"Bitrix24 Webhook URL": "Bitrix24 Webhook URL'si",
"wayToGetBitrix24Webhook": "{0} adresindeki adımları izleyerek bir web kancası oluşturabilirsiniz",
"bitrix24SupportUserID": "Bitrix24'e kullanıcı kimliğinizi girin. Kullanıcının profiline giderek bağlantıdan kimliğini öğrenebilirsiniz.",
"Select message type": "Mesaj türünü seçin",
@ -1098,5 +1098,24 @@
"RabbitMQ Nodes": "RabbitMQ Yönetim Sunucuları",
"rabbitmqNodesDescription": "Protokol ve port dahil olmak üzere RabbitMQ yönetim düğümleri için URL'yi girin. Örnek: {0}",
"rabbitmqHelpText": "Monitörü kullanmak için, RabbitMQ kurulumunuzda Yönetim Eklentisini etkinleştirmeniz gerekecektir. Daha fazla bilgi için lütfen {rabitmq_documentation}'a bakın.",
"aboutSlackUsername": "Mesaj göndericinin görünen adını değiştir. Eğer birilerini etiketlemek isterseniz, onu ismini dostça ekleyebilirsiniz."
"aboutSlackUsername": "Mesaj göndericinin görünen adını değiştir. Eğer birilerini etiketlemek isterseniz, onu ismini dostça ekleyebilirsiniz.",
"templateHostnameOrURL": "ana bilgisayar adı veya URL",
"templateStatus": "durum",
"telegramUseTemplate": "Özel mesaj şablonu kullan",
"telegramUseTemplateDescription": "Etkinleştirilirse mesaj özel bir şablon kullanılarak gönderilecektir.",
"telegramTemplateFormatDescription": "Telegram, mesajlar için farklı işaretleme dillerinin kullanılmasına izin verir, ayrıntılar için Telegram {0} bölümüne bakın.",
"templateServiceName": "servis adı",
"telegramServerUrlDescription": "Telegram'ın bot API sınırlamalarını kaldırmak veya engellenen alanlarda (Çin, İran vb.) erişim sağlamak için. Daha fazla bilgi için tıklayın {0}. Varsayılan: {1}",
"wahaSession": "Oturum",
"wahaChatId": "Sohbet Kimliği (Telefon Numarası / Kişi Kimliği / Grup Kimliği)",
"wayToGetWahaApiUrl": "WAHA Örnek URL'niz.",
"wayToGetWahaApiKey": "API Anahtarı, WAHA'yı çalıştırmak için kullandığınız WHATSAPP_API_KEY ortam değişkeni değeridir.",
"wayToGetWahaSession": "Bu oturumdan itibaren WAHA, Chat ID'ye bildirimler gönderir. Bunu WAHA Dashboard'da bulabilirsiniz.",
"wayToWriteWahaChatId": "Uluslararası ön eke sahip, ancak başında artı işareti olmayan telefon numarası ({0}), Kişi Kimliği ({1}) veya Grup Kimliği ({2}). Bildirimler WAHA Session'dan bu Sohbet Kimliğine gönderilir.",
"Plain Text": "Düz Metin",
"Message Template": "Mesaj Şablonu",
"Template Format": "Şablon Biçimi",
"YZJ Webhook URL": "YZJ Webhook URL'si",
"YZJ Robot Token": "YZJ Robot tokeni",
"telegramServerUrl": "(İsteğe bağlı) Sunucu URL'si"
}

View file

@ -1123,5 +1123,6 @@
"wayToGetWahaSession": "З цієї сесії WAHA надсилає сповіщення на ID чату. Ви можете знайти його в інформаційній панелі WAHA.",
"wayToWriteWahaChatId": "Номер телефону з міжнародним префіксом, але без знака плюс на початку ({0}), ID контакту ({1}) або ID групи ({2}). На цей ID чату надсилаються сповіщення з сеансу WAHA.",
"telegramServerUrl": "(Необов'язково) URL сервера",
"telegramServerUrlDescription": "Щоб зняти обмеження з Telegram bot api або отримати доступ у заблокованих регіонах (Китай, Іран тощо). Для отримання додаткової інформації натисніть {0}. За замовчуванням: {1}"
"telegramServerUrlDescription": "Щоб зняти обмеження з Telegram bot api або отримати доступ у заблокованих регіонах (Китай, Іран тощо). Для отримання додаткової інформації натисніть {0}. За замовчуванням: {1}",
"Font Twemoji by Twitter licensed under": "Шрифт Twemoji від Twitter ліцензований під"
}

View file

@ -1117,5 +1117,8 @@
"wayToGetWahaApiKey": "API 密钥是你用于运行 WAHA 的 WHATSAPP_API_KEY 环境变量值。",
"telegramTemplateFormatDescription": "Telegram 允许在消息中使用不同的标记语言,具体细节请参见 Telegram {0}。",
"YZJ Webhook URL": "YZJ Webhook 地址",
"YZJ Robot Token": "YZJ 机器人令牌"
"YZJ Robot Token": "YZJ 机器人令牌",
"telegramServerUrl": "(可选) 服务器 Url",
"telegramServerUrlDescription": "用以解除 Telegram 的机器人 API 限制或在封锁区域(中国、伊朗等)获得访问权限。获取更多信息,请点击 {0}。默认值:{1}",
"Font Twemoji by Twitter licensed under": "由 Twitter 制作的 Twemoji 字体根据此许可证授权"
}

View file

@ -24,6 +24,9 @@
<option value="ping">
Ping
</option>
<option value="smtp">
SMTP
</option>
<option value="snmp">
SNMP
</option>
@ -109,7 +112,7 @@
<!-- Friendly Name -->
<div class="my-3">
<label for="name" class="form-label">{{ $t("Friendly Name") }}</label>
<input id="name" v-model="monitor.name" type="text" class="form-control" required data-testid="friendly-name-input">
<input id="name" v-model="monitor.name" type="text" class="form-control" data-testid="friendly-name-input" :placeholder="defaultFriendlyName">
</div>
<!-- URL -->
@ -281,8 +284,8 @@
</template>
<!-- Hostname -->
<!-- TCP Port / Ping / DNS / Steam / MQTT / Radius / Tailscale Ping / SNMP only -->
<div v-if="monitor.type === 'port' || monitor.type === 'ping' || monitor.type === 'dns' || monitor.type === 'steam' || monitor.type === 'gamedig' || monitor.type === 'mqtt' || monitor.type === 'radius' || monitor.type === 'tailscale-ping' || monitor.type === 'snmp'" class="my-3">
<!-- TCP Port / Ping / DNS / Steam / MQTT / Radius / Tailscale Ping / SNMP / SMTP only -->
<div v-if="monitor.type === 'port' || monitor.type === 'ping' || monitor.type === 'dns' || monitor.type === 'steam' || monitor.type === 'gamedig' || monitor.type === 'mqtt' || monitor.type === 'radius' || monitor.type === 'tailscale-ping' || monitor.type === 'smtp' || monitor.type === 'snmp'" class="my-3">
<label for="hostname" class="form-label">{{ $t("Hostname") }}</label>
<input
id="hostname"
@ -297,7 +300,7 @@
<!-- Port -->
<!-- For TCP Port / Steam / MQTT / Radius Type / SNMP -->
<div v-if="monitor.type === 'port' || monitor.type === 'steam' || monitor.type === 'gamedig' || monitor.type === 'mqtt' || monitor.type === 'radius' || monitor.type === 'snmp'" class="my-3">
<div v-if="monitor.type === 'port' || monitor.type === 'steam' || monitor.type === 'gamedig' || monitor.type === 'mqtt' || monitor.type === 'radius' || monitor.type === 'smtp' || monitor.type === 'snmp'" class="my-3">
<label for="port" class="form-label">{{ $t("Port") }}</label>
<input id="port" v-model="monitor.port" type="number" class="form-control" required min="0" max="65535" step="1">
</div>
@ -329,6 +332,18 @@
</select>
</div>
<div v-if="monitor.type === 'smtp'" class="my-3">
<label for="smtp_security" class="form-label">{{ $t("SMTP Security") }}</label>
<select id="smtp_security" v-model="monitor.smtpSecurity" class="form-select">
<option value="secure">SMTPS</option>
<option value="nostarttls">Ignore STARTTLS</option>
<option value="starttls">Use STARTTLS</option>
</select>
<div class="form-text">
{{ $t("smtpHelpText") }}
</div>
</div>
<!-- Json Query -->
<!-- For Json Query / SNMP -->
<div v-if="monitor.type === 'json-query' || monitor.type === 'snmp'" class="my-3">
@ -595,10 +610,14 @@
<input id="retry-interval" v-model="monitor.retryInterval" type="number" class="form-control" required :min="minInterval" step="1">
</div>
<!-- Timeout: HTTP / Keyword / SNMP only -->
<div v-if="monitor.type === 'http' || monitor.type === 'keyword' || monitor.type === 'json-query' || monitor.type === 'snmp' || monitor.type === 'rabbitmq'" class="my-3">
<label for="timeout" class="form-label">{{ $t("Request Timeout") }} ({{ $t("timeoutAfter", [ monitor.timeout || clampTimeout(monitor.interval) ]) }})</label>
<input id="timeout" v-model="monitor.timeout" type="number" class="form-control" required min="0" step="0.1">
<!-- Timeout: HTTP / JSON query / Keyword / Ping / RabbitMQ / SNMP only -->
<div v-if="monitor.type === 'http' || monitor.type === 'json-query' || monitor.type === 'keyword' || monitor.type === 'ping' || monitor.type === 'rabbitmq' || monitor.type === 'snmp'" class="my-3">
<label for="timeout" class="form-label">
{{ monitor.type === 'ping' ? $t("pingGlobalTimeoutLabel") : $t("Request Timeout") }}
<span v-if="monitor.type !== 'ping'">({{ $t("timeoutAfter", [monitor.timeout || clampTimeout(monitor.interval)]) }})</span>
</label>
<input id="timeout" v-model="monitor.timeout" type="number" class="form-control" :min="timeoutMin" :max="timeoutMax" :step="timeoutStep" required>
<div v-if="monitor.type === 'ping'" class="form-text">{{ $t("pingGlobalTimeoutDescription") }}</div>
</div>
<div class="my-3">
@ -660,10 +679,39 @@
</div>
</div>
<!-- Ping packet size -->
<!-- Max Packets / Count -->
<div v-if="monitor.type === 'ping'" class="my-3">
<label for="ping-count" class="form-label">{{ $t("pingCountLabel") }}</label>
<input id="ping-count" v-model="monitor.ping_count" type="number" class="form-control" required min="1" max="100" step="1">
<div class="form-text">
{{ $t("pingCountDescription") }}
</div>
</div>
<!-- Numeric Output -->
<div v-if="monitor.type === 'ping'" class="my-3 form-check">
<input id="ping_numeric" v-model="monitor.ping_numeric" type="checkbox" class="form-check-input" :checked="monitor.ping_numeric">
<label class="form-check-label" for="ping_numeric">
{{ $t("pingNumericLabel") }}
</label>
<div class="form-text">
{{ $t("pingNumericDescription") }}
</div>
</div>
<!-- Packet size -->
<div v-if="monitor.type === 'ping'" class="my-3">
<label for="packet-size" class="form-label">{{ $t("Packet Size") }}</label>
<input id="packet-size" v-model="monitor.packetSize" type="number" class="form-control" required min="1" max="65500" step="1">
<input id="packet-size" v-model="monitor.packetSize" type="number" class="form-control" required min="1" :max="65500" step="1">
</div>
<!-- per-request timeout -->
<div v-if="monitor.type === 'ping'" class="my-3">
<label for="ping_per_request_timeout" class="form-label">{{ $t("pingPerRequestTimeoutLabel") }}</label>
<input id="ping_per_request_timeout" v-model="monitor.ping_per_request_timeout" type="number" class="form-control" required min="0" max="300" step="1">
<div class="form-text">
{{ $t("pingPerRequestTimeoutDescription") }}
</div>
</div>
<!-- HTTP / Keyword only -->
@ -1060,7 +1108,13 @@ import DockerHostDialog from "../components/DockerHostDialog.vue";
import RemoteBrowserDialog from "../components/RemoteBrowserDialog.vue";
import ProxyDialog from "../components/ProxyDialog.vue";
import TagsManager from "../components/TagsManager.vue";
import { genSecret, isDev, MAX_INTERVAL_SECOND, MIN_INTERVAL_SECOND, sleep } from "../util.ts";
import {
genSecret,
isDev,
MAX_INTERVAL_SECOND,
MIN_INTERVAL_SECOND,
sleep,
} from "../util.ts";
import { hostNameRegexPattern } from "../util-frontend";
import HiddenInput from "../components/HiddenInput.vue";
import EditMonitorConditions from "../components/EditMonitorConditions.vue";
@ -1082,7 +1136,6 @@ const monitorDefaults = {
notificationIDList: {},
ignoreTls: false,
upsideDown: false,
packetSize: 56,
expiryNotification: false,
maxredirects: 10,
accepted_statuscodes: [ "200-299" ],
@ -1157,6 +1210,48 @@ export default {
},
computed: {
timeoutStep() {
return this.monitor.type === "ping" ? 1 : 0.1;
},
timeoutMin() {
return this.monitor.type === "ping" ? 1 : 0;
},
timeoutMax() {
return this.monitor.type === "ping" ? 60 : undefined;
},
timeoutLabel() {
return this.monitor.type === "ping" ? this.$t("pingTimeoutLabel") : this.$t("Request Timeout");
},
timeoutDescription() {
if (this.monitor.type === "ping") {
return this.$t("pingTimeoutDescription");
}
return "";
},
defaultFriendlyName() {
if (this.monitor.hostname) {
return this.monitor.hostname;
}
if (this.monitor.url) {
if (this.monitor.url !== "http://" && this.monitor.url !== "https://") {
// Ensure monitor without a URL is not affected by invisible URL.
try {
const url = new URL(this.monitor.url);
return url.hostname;
} catch (e) {
return this.monitor.url.replace(/https?:\/\//, "");
}
}
}
// Default placeholder if neither hostname nor URL is available
return this.$t("defaultFriendlyName");
},
ipRegex() {
// Allow to test with simple dns server with port (127.0.0.1:5300)
@ -1175,6 +1270,7 @@ export default {
}
return this.$t(name);
},
remoteBrowsersOptions() {
return this.$root.remoteBrowserList.map(browser => {
return {
@ -1183,6 +1279,7 @@ export default {
};
});
},
remoteBrowsersToggle: {
get() {
return this.remoteBrowsersEnabled || this.monitor.remote_browser != null;
@ -1200,6 +1297,7 @@ export default {
}
}
},
isAdd() {
return this.$route.path === "/add";
},
@ -1250,6 +1348,7 @@ message HealthCheckResponse {
}
` ]);
},
bodyPlaceholder() {
if (this.monitor && this.monitor.httpBodyEncoding && this.monitor.httpBodyEncoding === "xml") {
return this.$t("Example:", [ `
@ -1415,9 +1514,25 @@ message HealthCheckResponse {
},
"monitor.timeout"(value, oldValue) {
// keep timeout within 80% range
if (value && value !== oldValue) {
this.monitor.timeout = this.clampTimeout(value);
if (this.monitor.type === "ping") {
this.finishUpdateInterval();
} else {
// keep timeout within 80% range
if (value && value !== oldValue) {
this.monitor.timeout = this.clampTimeout(value);
}
}
},
"monitor.ping_count"() {
if (this.monitor.type === "ping") {
this.finishUpdateInterval();
}
},
"monitor.ping_per_request_timeout"() {
if (this.monitor.type === "ping") {
this.finishUpdateInterval();
}
},
@ -1446,8 +1561,10 @@ message HealthCheckResponse {
// Set a default timeout if the monitor type has changed or if it's a new monitor
if (oldType || this.isAdd) {
if (this.monitor.type === "snmp") {
// snmp is not expected to be executed via the internet => we can choose a lower default timeout
// snmp is not expected to be executed via the internet => we can choose a lower default timeout
this.monitor.timeout = 5;
} else if (this.monitor.type === "ping") {
this.monitor.timeout = 10;
} else {
this.monitor.timeout = 48;
}
@ -1564,7 +1681,11 @@ message HealthCheckResponse {
if (this.isAdd) {
this.monitor = {
...monitorDefaults
...monitorDefaults,
ping_count: 3,
ping_numeric: true,
packetSize: 56,
ping_per_request_timeout: 2,
};
if (this.$root.proxyList && !this.monitor.proxyId) {
@ -1627,7 +1748,12 @@ message HealthCheckResponse {
}
// Handling for monitors that are missing/zeroed timeout
if (!this.monitor.timeout) {
this.monitor.timeout = ~~(this.monitor.interval * 8) / 10;
if (this.monitor.type === "ping") {
// set to default
this.monitor.timeout = 10;
} else {
this.monitor.timeout = ~~(this.monitor.interval * 8) / 10;
}
}
} else {
this.$root.toastError(res.msg);
@ -1700,6 +1826,10 @@ message HealthCheckResponse {
this.processing = true;
if (!this.monitor.name) {
this.monitor.name = this.defaultFriendlyName;
}
if (!this.isInputValid()) {
this.processing = false;
return;
@ -1840,11 +1970,48 @@ message HealthCheckResponse {
return Number.isFinite(clamped) ? clamped : maxTimeout;
},
calculatePingInterval() {
// If monitor.type is not "ping", simply return the configured interval
if (this.monitor.type !== "ping") {
return this.monitor.interval;
}
// Calculate the maximum theoretical time needed if every ping request times out
const theoreticalTotal = this.monitor.ping_count * this.monitor.ping_per_request_timeout;
// The global timeout (aka deadline) forces ping to terminate, so the effective limit
// is the smaller value between deadline and theoreticalTotal
const effectiveLimit = Math.min(this.monitor.timeout, theoreticalTotal);
// Add a 10% margin to the effective limit to ensure proper handling
const adjustedLimit = Math.ceil(effectiveLimit * 1.1);
// If the calculated limit is lower than the minimum allowed interval, use the minimum interval
if (adjustedLimit < this.minInterval) {
return this.minInterval;
}
return adjustedLimit;
},
finishUpdateInterval() {
// Update timeout if it is greater than the clamp timeout
let clampedValue = this.clampTimeout(this.monitor.interval);
if (this.monitor.timeout > clampedValue) {
this.monitor.timeout = clampedValue;
if (this.monitor.type === "ping") {
// Calculate the minimum required interval based on ping configuration
const calculatedPingInterval = this.calculatePingInterval();
// If the configured interval is too small, adjust it to the minimum required value
if (this.monitor.interval < calculatedPingInterval) {
this.monitor.interval = calculatedPingInterval;
// Notify the user that the interval has been automatically adjusted
toast.info(this.$t("pingIntervalAdjustedInfo"));
}
} else {
// Update timeout if it is greater than the clamp timeout
let clampedValue = this.clampTimeout(this.monitor.interval);
if (this.monitor.timeout > clampedValue) {
this.monitor.timeout = clampedValue;
}
}
},

View file

@ -8,15 +8,10 @@
// Backend uses the compiled file util.js
// Frontend uses util.ts
*/
var __importDefault = (this && this.__importDefault) || function (mod) {
return (mod && mod.__esModule) ? mod : { "default": mod };
};
var _a;
Object.defineProperty(exports, "__esModule", { value: true });
exports.sleep = exports.flipStatus = exports.badgeConstants = exports.CONSOLE_STYLE_BgGray = exports.CONSOLE_STYLE_BgWhite = exports.CONSOLE_STYLE_BgCyan = exports.CONSOLE_STYLE_BgMagenta = exports.CONSOLE_STYLE_BgBlue = exports.CONSOLE_STYLE_BgYellow = exports.CONSOLE_STYLE_BgGreen = exports.CONSOLE_STYLE_BgRed = exports.CONSOLE_STYLE_BgBlack = exports.CONSOLE_STYLE_FgPink = exports.CONSOLE_STYLE_FgBrown = exports.CONSOLE_STYLE_FgViolet = exports.CONSOLE_STYLE_FgLightBlue = exports.CONSOLE_STYLE_FgLightGreen = exports.CONSOLE_STYLE_FgOrange = exports.CONSOLE_STYLE_FgGray = exports.CONSOLE_STYLE_FgWhite = exports.CONSOLE_STYLE_FgCyan = exports.CONSOLE_STYLE_FgMagenta = exports.CONSOLE_STYLE_FgBlue = exports.CONSOLE_STYLE_FgYellow = exports.CONSOLE_STYLE_FgGreen = exports.CONSOLE_STYLE_FgRed = exports.CONSOLE_STYLE_FgBlack = exports.CONSOLE_STYLE_Hidden = exports.CONSOLE_STYLE_Reverse = exports.CONSOLE_STYLE_Blink = exports.CONSOLE_STYLE_Underscore = exports.CONSOLE_STYLE_Dim = exports.CONSOLE_STYLE_Bright = exports.CONSOLE_STYLE_Reset = exports.MIN_INTERVAL_SECOND = exports.MAX_INTERVAL_SECOND = exports.SQL_DATETIME_FORMAT_WITHOUT_SECOND = exports.SQL_DATETIME_FORMAT = exports.SQL_DATE_FORMAT = exports.STATUS_PAGE_MAINTENANCE = exports.STATUS_PAGE_PARTIAL_DOWN = exports.STATUS_PAGE_ALL_UP = exports.STATUS_PAGE_ALL_DOWN = exports.MAINTENANCE = exports.PENDING = exports.UP = exports.DOWN = exports.appName = exports.isNode = exports.isDev = void 0;
exports.evaluateJsonQuery = exports.intHash = exports.localToUTC = exports.utcToLocal = exports.utcToISODateTime = exports.isoToUTCDateTime = exports.parseTimeFromTimeObject = exports.parseTimeObject = exports.getMaintenanceRelativeURL = exports.getMonitorRelativeURL = exports.genSecret = exports.getCryptoRandomInt = exports.getRandomInt = exports.getRandomArbitrary = exports.TimeLogger = exports.polyfill = exports.log = exports.debug = exports.ucfirst = void 0;
exports.intHash = exports.localToUTC = exports.utcToLocal = exports.utcToISODateTime = exports.isoToUTCDateTime = exports.parseTimeFromTimeObject = exports.parseTimeObject = exports.getMaintenanceRelativeURL = exports.getMonitorRelativeURL = exports.genSecret = exports.getCryptoRandomInt = exports.getRandomInt = exports.getRandomArbitrary = exports.TimeLogger = exports.polyfill = exports.log = exports.debug = exports.ucfirst = void 0;
const dayjs_1 = __importDefault(require("dayjs"));
exports.CONSOLE_STYLE_FgPink = exports.CONSOLE_STYLE_FgBrown = exports.CONSOLE_STYLE_FgViolet = exports.CONSOLE_STYLE_FgLightBlue = exports.CONSOLE_STYLE_FgLightGreen = exports.CONSOLE_STYLE_FgOrange = exports.CONSOLE_STYLE_FgGray = exports.CONSOLE_STYLE_FgWhite = exports.CONSOLE_STYLE_FgCyan = exports.CONSOLE_STYLE_FgMagenta = exports.CONSOLE_STYLE_FgBlue = exports.CONSOLE_STYLE_FgYellow = exports.CONSOLE_STYLE_FgGreen = exports.CONSOLE_STYLE_FgRed = exports.CONSOLE_STYLE_FgBlack = exports.CONSOLE_STYLE_Hidden = exports.CONSOLE_STYLE_Reverse = exports.CONSOLE_STYLE_Blink = exports.CONSOLE_STYLE_Underscore = exports.CONSOLE_STYLE_Dim = exports.CONSOLE_STYLE_Bright = exports.CONSOLE_STYLE_Reset = exports.PING_PER_REQUEST_TIMEOUT_DEFAULT = exports.PING_PER_REQUEST_TIMEOUT_MAX = exports.PING_PER_REQUEST_TIMEOUT_MIN = exports.PING_COUNT_DEFAULT = exports.PING_COUNT_MAX = exports.PING_COUNT_MIN = exports.PING_GLOBAL_TIMEOUT_DEFAULT = exports.PING_GLOBAL_TIMEOUT_MAX = exports.PING_GLOBAL_TIMEOUT_MIN = exports.PING_PACKET_SIZE_DEFAULT = exports.PING_PACKET_SIZE_MAX = exports.PING_PACKET_SIZE_MIN = exports.MIN_INTERVAL_SECOND = exports.MAX_INTERVAL_SECOND = exports.SQL_DATETIME_FORMAT_WITHOUT_SECOND = exports.SQL_DATETIME_FORMAT = exports.SQL_DATE_FORMAT = exports.STATUS_PAGE_MAINTENANCE = exports.STATUS_PAGE_PARTIAL_DOWN = exports.STATUS_PAGE_ALL_UP = exports.STATUS_PAGE_ALL_DOWN = exports.MAINTENANCE = exports.PENDING = exports.UP = exports.DOWN = exports.appName = exports.isNode = exports.isDev = void 0;
exports.evaluateJsonQuery = exports.intHash = exports.localToUTC = exports.utcToLocal = exports.utcToISODateTime = exports.isoToUTCDateTime = exports.parseTimeFromTimeObject = exports.parseTimeObject = exports.getMaintenanceRelativeURL = exports.getMonitorRelativeURL = exports.genSecret = exports.getCryptoRandomInt = exports.getRandomInt = exports.getRandomArbitrary = exports.TimeLogger = exports.polyfill = exports.log = exports.debug = exports.ucfirst = exports.sleep = exports.flipStatus = exports.badgeConstants = exports.CONSOLE_STYLE_BgGray = exports.CONSOLE_STYLE_BgWhite = exports.CONSOLE_STYLE_BgCyan = exports.CONSOLE_STYLE_BgMagenta = exports.CONSOLE_STYLE_BgBlue = exports.CONSOLE_STYLE_BgYellow = exports.CONSOLE_STYLE_BgGreen = exports.CONSOLE_STYLE_BgRed = exports.CONSOLE_STYLE_BgBlack = void 0;
const dayjs = require("dayjs");
const jsonata = require("jsonata");
exports.isDev = process.env.NODE_ENV === "development";
@ -35,6 +30,18 @@ exports.SQL_DATETIME_FORMAT = "YYYY-MM-DD HH:mm:ss";
exports.SQL_DATETIME_FORMAT_WITHOUT_SECOND = "YYYY-MM-DD HH:mm";
exports.MAX_INTERVAL_SECOND = 2073600;
exports.MIN_INTERVAL_SECOND = 20;
exports.PING_PACKET_SIZE_MIN = 1;
exports.PING_PACKET_SIZE_MAX = 65500;
exports.PING_PACKET_SIZE_DEFAULT = 56;
exports.PING_GLOBAL_TIMEOUT_MIN = 1;
exports.PING_GLOBAL_TIMEOUT_MAX = 300;
exports.PING_GLOBAL_TIMEOUT_DEFAULT = 10;
exports.PING_COUNT_MIN = 1;
exports.PING_COUNT_MAX = 100;
exports.PING_COUNT_DEFAULT = 1;
exports.PING_PER_REQUEST_TIMEOUT_MIN = 1;
exports.PING_PER_REQUEST_TIMEOUT_MAX = 60;
exports.PING_PER_REQUEST_TIMEOUT_DEFAULT = 2;
exports.CONSOLE_STYLE_Reset = "\x1b[0m";
exports.CONSOLE_STYLE_Bright = "\x1b[1m";
exports.CONSOLE_STYLE_Dim = "\x1b[2m";
@ -66,7 +73,6 @@ exports.CONSOLE_STYLE_BgMagenta = "\x1b[45m";
exports.CONSOLE_STYLE_BgCyan = "\x1b[46m";
exports.CONSOLE_STYLE_BgWhite = "\x1b[47m";
exports.CONSOLE_STYLE_BgGray = "\x1b[100m";
const consoleModuleColors = [
exports.CONSOLE_STYLE_FgCyan,
exports.CONSOLE_STYLE_FgGreen,
@ -159,11 +165,11 @@ class Logger {
module = module.toUpperCase();
level = level.toUpperCase();
let now;
if (dayjs_1.default.tz) {
now = dayjs_1.default.tz(new Date()).format();
if (dayjs.tz) {
now = dayjs.tz(new Date()).format();
}
else {
now = (0, dayjs_1.default)().format();
now = dayjs().format();
}
const levelColor = consoleLevelColors[level];
const moduleColor = consoleModuleColors[intHash(module, consoleModuleColors.length)];
@ -264,11 +270,11 @@ function polyfill() {
exports.polyfill = polyfill;
class TimeLogger {
constructor() {
this.startTime = (0, dayjs_1.default)().valueOf();
this.startTime = dayjs().valueOf();
}
print(name) {
if (exports.isDev && process.env.TIMELOGGER === "1") {
console.log(name + ": " + ((0, dayjs_1.default)().valueOf() - this.startTime) + "ms");
console.log(name + ": " + (dayjs().valueOf() - this.startTime) + "ms");
}
}
}
@ -380,19 +386,19 @@ function parseTimeFromTimeObject(obj) {
}
exports.parseTimeFromTimeObject = parseTimeFromTimeObject;
function isoToUTCDateTime(input) {
return (0, dayjs_1.default)(input).utc().format(exports.SQL_DATETIME_FORMAT);
return dayjs(input).utc().format(exports.SQL_DATETIME_FORMAT);
}
exports.isoToUTCDateTime = isoToUTCDateTime;
function utcToISODateTime(input) {
return dayjs_1.default.utc(input).toISOString();
return dayjs.utc(input).toISOString();
}
exports.utcToISODateTime = utcToISODateTime;
function utcToLocal(input, format = exports.SQL_DATETIME_FORMAT) {
return dayjs_1.default.utc(input).local().format(format);
return dayjs.utc(input).local().format(format);
}
exports.utcToLocal = utcToLocal;
function localToUTC(input, format = exports.SQL_DATETIME_FORMAT) {
return (0, dayjs_1.default)(input).utc().format(format);
return dayjs(input).utc().format(format);
}
exports.localToUTC = localToUTC;
function intHash(str, length = 10) {
@ -458,4 +464,4 @@ async function evaluateJsonQuery(data, jsonPath, jsonPathOperator, expectedValue
throw new Error(`Error evaluating JSON query: ${err.message}. Response from server was: ${response}`);
}
}
exports.evaluateJsonQuery = evaluateJsonQuery;
exports.evaluateJsonQuery = evaluateJsonQuery;

View file

@ -9,7 +9,7 @@
// Frontend uses util.ts
*/
import dayjs from "dayjs";
import * as dayjs from "dayjs";
// For loading dayjs plugins, don't remove event though it is not used in this file
// eslint-disable-next-line @typescript-eslint/no-unused-vars
@ -39,6 +39,26 @@ export const SQL_DATETIME_FORMAT_WITHOUT_SECOND = "YYYY-MM-DD HH:mm";
export const MAX_INTERVAL_SECOND = 2073600; // 24 days
export const MIN_INTERVAL_SECOND = 20; // 20 seconds
// Packet Size limits
export const PING_PACKET_SIZE_MIN = 1;
export const PING_PACKET_SIZE_MAX = 65500;
export const PING_PACKET_SIZE_DEFAULT = 56;
// Global timeout (aka deadline) limits in seconds
export const PING_GLOBAL_TIMEOUT_MIN = 1;
export const PING_GLOBAL_TIMEOUT_MAX = 300;
export const PING_GLOBAL_TIMEOUT_DEFAULT = 10;
// Ping count limits
export const PING_COUNT_MIN = 1;
export const PING_COUNT_MAX = 100;
export const PING_COUNT_DEFAULT = 1;
// per-request timeout (aka timeout) limits in seconds
export const PING_PER_REQUEST_TIMEOUT_MIN = 1;
export const PING_PER_REQUEST_TIMEOUT_MAX = 60;
export const PING_PER_REQUEST_TIMEOUT_DEFAULT = 2;
// Console colors
// https://stackoverflow.com/questions/9781218/how-to-change-node-jss-console-font-color
export const CONSOLE_STYLE_Reset = "\x1b[0m";

View file

@ -0,0 +1,83 @@
import { expect, test } from "@playwright/test";
import { login, restoreSqliteSnapshot, screenshot } from "../util-test";
test.describe("Friendly Name Tests", () => {
test.beforeEach(async ({ page }) => {
await restoreSqliteSnapshot(page);
});
test("hostname", async ({ page }, testInfo) => {
// Test DNS monitor with hostname
await page.goto("./add");
await login(page);
await screenshot(testInfo, page);
await page.getByTestId("monitor-type-select").selectOption("dns");
await page.getByTestId("hostname-input").fill("example.com");
await screenshot(testInfo, page);
await page.getByTestId("save-button").click();
await page.waitForURL("/dashboard/*");
expect(page.getByTestId("monitor-list")).toContainText("example.com");
await screenshot(testInfo, page);
});
test("URL hostname", async ({ page }, testInfo) => {
// Test HTTP monitor with URL
await page.goto("./add");
await login(page);
await screenshot(testInfo, page);
await page.getByTestId("monitor-type-select").selectOption("http");
await page.getByTestId("url-input").fill("https://www.example.com/");
await screenshot(testInfo, page);
await page.getByTestId("save-button").click();
await page.waitForURL("/dashboard/*");
expect(page.getByTestId("monitor-list")).toContainText("www.example.com");
await screenshot(testInfo, page);
});
test("custom friendly name", async ({ page }, testInfo) => {
// Test custom friendly name for HTTP monitor
await page.goto("./add");
await login(page);
await screenshot(testInfo, page);
await page.getByTestId("monitor-type-select").selectOption("http");
await page.getByTestId("url-input").fill("https://www.example.com/");
// Check if the friendly name placeholder is set to the hostname
const friendlyNameInput = page.getByTestId("friendly-name-input");
expect(friendlyNameInput).toHaveAttribute("placeholder", "www.example.com");
await screenshot(testInfo, page);
const customName = "Example Monitor";
await friendlyNameInput.fill(customName);
await screenshot(testInfo, page);
await page.getByTestId("save-button").click();
await page.waitForURL("/dashboard/*");
expect(page.getByTestId("monitor-list")).toContainText(customName);
await screenshot(testInfo, page);
});
test("default friendly name", async ({ page }, testInfo) => {
// Test default friendly name when no custom name is provided
await page.goto("./add");
await login(page);
await screenshot(testInfo, page);
await page.getByTestId("monitor-type-select").selectOption("group");
await screenshot(testInfo, page);
await page.getByTestId("save-button").click();
await page.waitForURL("/dashboard/*");
expect(page.getByTestId("monitor-list")).toContainText("New Monitor");
await screenshot(testInfo, page);
});
});

View file

@ -12,6 +12,8 @@ test.describe("Status Page", () => {
const monitorName = "Monitor for Status Page";
const tagName = "Client";
const tagValue = "Acme Inc";
const monitorUrl = "https://www.example.com/status";
const monitorCustomUrl = "https://www.example.com";
// Status Page
const footerText = "This is footer text.";
@ -30,7 +32,7 @@ test.describe("Status Page", () => {
await expect(page.getByTestId("monitor-type-select")).toBeVisible();
await page.getByTestId("monitor-type-select").selectOption("http");
await page.getByTestId("friendly-name-input").fill(monitorName);
await page.getByTestId("url-input").fill("https://www.example.com/");
await page.getByTestId("url-input").fill(monitorUrl);
await page.getByTestId("add-tag-button").click();
await page.getByTestId("tag-name-input").fill(tagName);
await page.getByTestId("tag-value-input").fill(tagValue);
@ -79,6 +81,13 @@ test.describe("Status Page", () => {
await page.getByTestId("monitor-select").getByRole("option", { name: monitorName }).click();
await expect(page.getByTestId("monitor")).toHaveCount(1);
await expect(page.getByTestId("monitor-name")).toContainText(monitorName);
await expect(page.getByTestId("monitor-name")).not.toHaveAttribute("href");
// Set public url on
await page.getByTestId("monitor-settings").click();
await page.getByTestId("show-clickable-link").check();
await page.getByTestId("custom-url-input").fill(monitorCustomUrl);
await page.getByTestId("monitor-settings-close").click();
// Save the changes
await screenshot(testInfo, page);
@ -94,6 +103,8 @@ test.describe("Status Page", () => {
await expect(page.getByTestId("footer-text")).toContainText(footerText);
await expect(page.getByTestId("powered-by")).toHaveCount(0);
await expect(page.getByTestId("monitor-name")).toHaveAttribute("href", monitorCustomUrl);
await expect(page.getByTestId("update-countdown-text")).toContainText("00:");
const updateCountdown = Number((await page.getByTestId("update-countdown-text").textContent()).match(/(\d+):(\d+)/)[2]);
expect(updateCountdown).toBeGreaterThanOrEqual(refreshInterval); // cant be certain when the timer will start, so ensure it's within expected range

9
tsconfig-backend.json Normal file
View file

@ -0,0 +1,9 @@
{
"extends": "./tsconfig.json",
"compilerOptions": {
"esModuleInterop": false
},
"files": [
"./src/util.ts"
]
}

View file

@ -16,6 +16,6 @@
"esModuleInterop": true
},
"files": [
"./src/util.ts"
]
}