iobroker.eusec 1.1.0 → 1.1.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +13 -0
- package/admin/i18n/uk/translations.json +26 -0
- package/build/lib/interfaces.js +16 -2
- package/build/lib/interfaces.js.map +7 -1
- package/build/lib/log.js +70 -48
- package/build/lib/log.js.map +7 -1
- package/build/lib/tools.js +79 -84
- package/build/lib/tools.js.map +7 -1
- package/build/lib/types.js +92 -61
- package/build/lib/types.js.map +7 -1
- package/build/lib/utils.js +239 -234
- package/build/lib/utils.js.map +7 -1
- package/build/lib/video.js +243 -258
- package/build/lib/video.js.map +7 -1
- package/build/lib/web.js +58 -84
- package/build/lib/web.js.map +7 -1
- package/build/main.js +1177 -1421
- package/build/main.js.map +7 -1
- package/io-package.json +32 -4
- package/package.json +20 -42
package/README.md
CHANGED
|
@@ -159,6 +159,19 @@ Best is to set the adapter to Debug log mode (see [here](https://bropat.github.i
|
|
|
159
159
|
|
|
160
160
|
## Changelog
|
|
161
161
|
|
|
162
|
+
### 1.1.2 (2023-08-31)
|
|
163
|
+
|
|
164
|
+
* (bropat) Updated version of the package eufy-security-client (2.8.1)
|
|
165
|
+
* (bropat) Further details can be found in the changelog of eufy-security-client (2.8.1)
|
|
166
|
+
|
|
167
|
+
### 1.1.1 (2023-08-20)
|
|
168
|
+
|
|
169
|
+
* (bropat) Fixed issue #365
|
|
170
|
+
* (bropat) Fixed issue #363
|
|
171
|
+
* (bropat) Updated version of the package ffmpeg-static (5.2.0)
|
|
172
|
+
* (bropat) Updated version of the package eufy-security-client (2.8.0)
|
|
173
|
+
* (bropat) Further details can be found in the changelog of eufy-security-client (2.8.0)
|
|
174
|
+
|
|
162
175
|
### 1.1.0 (2023-08-08)
|
|
163
176
|
|
|
164
177
|
* (bropat) Added support for Wired Wall Light Cam S100 (T84A1; #332)
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
{
|
|
2
|
+
"Main settings": "Main settings",
|
|
3
|
+
"Authentication settings": "Authentication settings",
|
|
4
|
+
"Username": "Username",
|
|
5
|
+
"Password": "Password",
|
|
6
|
+
"Other settings": "Other settings",
|
|
7
|
+
"Polling interval (min)": "Polling interval (min)",
|
|
8
|
+
"Time in seconds before event reset": "Time in seconds before event reset",
|
|
9
|
+
"P2P connection type": "P2P connection type",
|
|
10
|
+
"Only local connection": "Only local connection",
|
|
11
|
+
"Quickest connection": "Quickest connection",
|
|
12
|
+
"Accept incoming invitations": "Accept incoming invitations",
|
|
13
|
+
"Alarm sound duration (sec)": "Alarm sound duration (sec)",
|
|
14
|
+
"Livestream settings": "Livestream settings",
|
|
15
|
+
"Max camera livestream duration (sec)": "Max camera livestream duration (sec; 0 = unlimited)",
|
|
16
|
+
"General settings": "General settings",
|
|
17
|
+
"Hostname": "Hostname streaming url",
|
|
18
|
+
"https": "HTTPS streaming url",
|
|
19
|
+
"go2rtc settings": "go2rtc settings",
|
|
20
|
+
"API port": "API port",
|
|
21
|
+
"SRTP port": "SRTP port",
|
|
22
|
+
"WebRTC port": "WebRTC port",
|
|
23
|
+
"RTSP port": "RTSP port",
|
|
24
|
+
"RTSP Username": "RTSP Username",
|
|
25
|
+
"RTSP Password": "RTSP Password"
|
|
26
|
+
}
|
package/build/lib/interfaces.js
CHANGED
|
@@ -1,3 +1,17 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
Object.defineProperty
|
|
3
|
-
|
|
2
|
+
var __defProp = Object.defineProperty;
|
|
3
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
4
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
5
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
6
|
+
var __copyProps = (to, from, except, desc) => {
|
|
7
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
8
|
+
for (let key of __getOwnPropNames(from))
|
|
9
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
10
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
11
|
+
}
|
|
12
|
+
return to;
|
|
13
|
+
};
|
|
14
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
15
|
+
var interfaces_exports = {};
|
|
16
|
+
module.exports = __toCommonJS(interfaces_exports);
|
|
17
|
+
//# sourceMappingURL=interfaces.js.map
|
|
@@ -1 +1,7 @@
|
|
|
1
|
-
{
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../src/lib/interfaces.ts"],
|
|
4
|
+
"sourcesContent": ["\r\n/*export interface AdapterConfig {\r\n username: string;\r\n password: string;\r\n pollingInterval: number;\r\n maxLivestreamDuration: number;\r\n eventDuration: number;\r\n verificationMethod: number;\r\n p2pConnectionType: string;\r\n acceptInvitations: boolean;\r\n alarmSoundDuration: number;\r\n go2rtc_api_port: number;\r\n go2rtc_rtsp_port: number;\r\n go2rtc_srtp_port: number;\r\n go2rtc_webrtc_port: number;\r\n go2rtc_rtsp_username: string;\r\n go2rtc_rtsp_password: string;\r\n hostname: string;\r\n https: boolean;\r\n}*/\r\n\r\nexport interface PersistentData {\r\n version: string;\r\n}\r\n\r\nexport interface IRoleMapping {\r\n [index: string]: string;\r\n}"],
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;AAAA;AAAA;",
|
|
6
|
+
"names": []
|
|
7
|
+
}
|
package/build/lib/log.js
CHANGED
|
@@ -1,53 +1,75 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
Object.defineProperty
|
|
3
|
-
|
|
2
|
+
var __defProp = Object.defineProperty;
|
|
3
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
4
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
5
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
6
|
+
var __export = (target, all) => {
|
|
7
|
+
for (var name in all)
|
|
8
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
9
|
+
};
|
|
10
|
+
var __copyProps = (to, from, except, desc) => {
|
|
11
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
12
|
+
for (let key of __getOwnPropNames(from))
|
|
13
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
14
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
15
|
+
}
|
|
16
|
+
return to;
|
|
17
|
+
};
|
|
18
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
19
|
+
var log_exports = {};
|
|
20
|
+
__export(log_exports, {
|
|
21
|
+
ioBrokerLogger: () => ioBrokerLogger
|
|
22
|
+
});
|
|
23
|
+
module.exports = __toCommonJS(log_exports);
|
|
4
24
|
class ioBrokerLogger {
|
|
5
|
-
|
|
6
|
-
|
|
25
|
+
constructor(log) {
|
|
26
|
+
this.log = log;
|
|
27
|
+
}
|
|
28
|
+
_getStack() {
|
|
29
|
+
var _a;
|
|
30
|
+
const _prepareStackTrace = Error.prepareStackTrace;
|
|
31
|
+
Error.prepareStackTrace = (_, stack2) => stack2;
|
|
32
|
+
const stack = (_a = new Error().stack) == null ? void 0 : _a.slice(3);
|
|
33
|
+
Error.prepareStackTrace = _prepareStackTrace;
|
|
34
|
+
return stack;
|
|
35
|
+
}
|
|
36
|
+
_getMessage(message, hideTag = false, optionalParams) {
|
|
37
|
+
const msg = message ? message : "";
|
|
38
|
+
const stack = this._getStack();
|
|
39
|
+
const typeName = stack[0].getTypeName() !== null ? stack[0].getTypeName() : "";
|
|
40
|
+
const functionName = stack[0].getFunctionName() !== null ? `${stack[0].getFunctionName()}` : "";
|
|
41
|
+
let tag = "";
|
|
42
|
+
if (typeName !== "" && !hideTag) {
|
|
43
|
+
tag = `[${typeName}`;
|
|
44
|
+
if (functionName !== "") {
|
|
45
|
+
tag = `${tag}.${functionName}] `;
|
|
46
|
+
} else {
|
|
47
|
+
tag = `${tag}] `;
|
|
48
|
+
}
|
|
7
49
|
}
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
const _prepareStackTrace = Error.prepareStackTrace;
|
|
11
|
-
Error.prepareStackTrace = (_, stack) => stack;
|
|
12
|
-
const stack = (_a = new Error().stack) === null || _a === void 0 ? void 0 : _a.slice(3);
|
|
13
|
-
Error.prepareStackTrace = _prepareStackTrace;
|
|
14
|
-
return stack;
|
|
15
|
-
}
|
|
16
|
-
_getMessage(message, hideTag = false, optionalParams) {
|
|
17
|
-
const msg = message ? message : "";
|
|
18
|
-
const stack = this._getStack();
|
|
19
|
-
const typeName = stack[0].getTypeName() !== null ? stack[0].getTypeName() : "";
|
|
20
|
-
const functionName = stack[0].getFunctionName() !== null ? `${stack[0].getFunctionName()}` : "";
|
|
21
|
-
let tag = "";
|
|
22
|
-
if (typeName !== "" && !hideTag) {
|
|
23
|
-
tag = `[${typeName}`;
|
|
24
|
-
if (functionName !== "") {
|
|
25
|
-
tag = `${tag}.${functionName}] `;
|
|
26
|
-
}
|
|
27
|
-
else {
|
|
28
|
-
tag = `${tag}] `;
|
|
29
|
-
}
|
|
30
|
-
}
|
|
31
|
-
if (optionalParams && optionalParams.length > 0) {
|
|
32
|
-
return `${tag}${msg} ${JSON.stringify(optionalParams)}`;
|
|
33
|
-
}
|
|
34
|
-
return `${tag}${msg}`;
|
|
35
|
-
}
|
|
36
|
-
trace(message, ...optionalParams) {
|
|
37
|
-
this.log.silly(this._getMessage(message, false, optionalParams));
|
|
38
|
-
}
|
|
39
|
-
debug(message, ...optionalParams) {
|
|
40
|
-
this.log.debug(this._getMessage(message, false, optionalParams));
|
|
41
|
-
}
|
|
42
|
-
info(message, ...optionalParams) {
|
|
43
|
-
this.log.info(this._getMessage(message, true, optionalParams));
|
|
44
|
-
}
|
|
45
|
-
warn(message, ...optionalParams) {
|
|
46
|
-
this.log.warn(this._getMessage(message, true, optionalParams));
|
|
47
|
-
}
|
|
48
|
-
error(message, ...optionalParams) {
|
|
49
|
-
this.log.error(this._getMessage(message, true, optionalParams));
|
|
50
|
+
if (optionalParams && optionalParams.length > 0) {
|
|
51
|
+
return `${tag}${msg} ${JSON.stringify(optionalParams)}`;
|
|
50
52
|
}
|
|
53
|
+
return `${tag}${msg}`;
|
|
54
|
+
}
|
|
55
|
+
trace(message, ...optionalParams) {
|
|
56
|
+
this.log.silly(this._getMessage(message, false, optionalParams));
|
|
57
|
+
}
|
|
58
|
+
debug(message, ...optionalParams) {
|
|
59
|
+
this.log.debug(this._getMessage(message, false, optionalParams));
|
|
60
|
+
}
|
|
61
|
+
info(message, ...optionalParams) {
|
|
62
|
+
this.log.info(this._getMessage(message, true, optionalParams));
|
|
63
|
+
}
|
|
64
|
+
warn(message, ...optionalParams) {
|
|
65
|
+
this.log.warn(this._getMessage(message, true, optionalParams));
|
|
66
|
+
}
|
|
67
|
+
error(message, ...optionalParams) {
|
|
68
|
+
this.log.error(this._getMessage(message, true, optionalParams));
|
|
69
|
+
}
|
|
51
70
|
}
|
|
52
|
-
|
|
53
|
-
|
|
71
|
+
// Annotate the CommonJS export names for ESM import in node:
|
|
72
|
+
0 && (module.exports = {
|
|
73
|
+
ioBrokerLogger
|
|
74
|
+
});
|
|
75
|
+
//# sourceMappingURL=log.js.map
|
package/build/lib/log.js.map
CHANGED
|
@@ -1 +1,7 @@
|
|
|
1
|
-
{
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../src/lib/log.ts"],
|
|
4
|
+
"sourcesContent": ["import { Logger } from \"ts-log\";\r\n\r\nexport class ioBrokerLogger implements Logger {\r\n\r\n private readonly log: ioBroker.Logger;\r\n\r\n public constructor(log: ioBroker.Logger) {\r\n this.log = log;\r\n }\r\n\r\n private _getStack(): any {\r\n const _prepareStackTrace = Error.prepareStackTrace;\r\n Error.prepareStackTrace = (_, stack) => stack;\r\n const stack = new Error().stack?.slice(3);\r\n Error.prepareStackTrace = _prepareStackTrace;\r\n return stack;\r\n }\r\n\r\n private _getMessage(message?: string, hideTag = false, optionalParams?: any[]): string {\r\n const msg = message ? message : \"\";\r\n const stack = this._getStack();\r\n const typeName = stack[0].getTypeName() !== null ? stack[0].getTypeName() : \"\";\r\n const functionName = stack[0].getFunctionName() !== null ? `${stack[0].getFunctionName()}` : \"\";\r\n let tag = \"\";\r\n if (typeName !== \"\" && !hideTag) {\r\n tag = `[${typeName}`;\r\n if (functionName !== \"\") {\r\n tag = `${tag}.${functionName}] `;\r\n } else {\r\n tag = `${tag}] `;\r\n }\r\n }\r\n\r\n if (optionalParams && optionalParams.length > 0) {\r\n return `${tag}${msg} ${JSON.stringify(optionalParams)}`;\r\n }\r\n return `${tag}${msg}`;\r\n }\r\n\r\n public trace(message?: string, ...optionalParams: any[]): void {\r\n this.log.silly(this._getMessage(message, false, optionalParams));\r\n }\r\n\r\n public debug(message?: string, ...optionalParams: any[]): void {\r\n this.log.debug(this._getMessage(message, false, optionalParams));\r\n }\r\n\r\n public info(message?: string, ...optionalParams: any[]): void {\r\n this.log.info(this._getMessage(message, true, optionalParams));\r\n }\r\n\r\n public warn(message?: string, ...optionalParams: any[]): void {\r\n this.log.warn(this._getMessage(message, true, optionalParams));\r\n }\r\n\r\n public error(message?: string, ...optionalParams: any[]): void {\r\n this.log.error(this._getMessage(message, true, optionalParams));\r\n }\r\n\r\n}"],
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAEO,MAAM,eAAiC;AAAA,EAInC,YAAY,KAAsB;AACrC,SAAK,MAAM;AAAA,EACf;AAAA,EAEQ,YAAiB;AAV7B;AAWQ,UAAM,qBAAqB,MAAM;AACjC,UAAM,oBAAoB,CAAC,GAAGA,WAAUA;AACxC,UAAM,SAAQ,SAAI,MAAM,EAAE,UAAZ,mBAAmB,MAAM;AACvC,UAAM,oBAAoB;AAC1B,WAAO;AAAA,EACX;AAAA,EAEQ,YAAY,SAAkB,UAAU,OAAO,gBAAgC;AACnF,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|
3
|
+
var __defProp = Object.defineProperty;
|
|
4
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
5
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
6
|
+
var __getProtoOf = Object.getPrototypeOf;
|
|
7
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
8
|
+
var __export = (target, all) => {
|
|
9
|
+
for (var name in all)
|
|
10
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
4
11
|
};
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
+
var __copyProps = (to, from, except, desc) => {
|
|
13
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
14
|
+
for (let key of __getOwnPropNames(from))
|
|
15
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
16
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
17
|
+
}
|
|
18
|
+
return to;
|
|
19
|
+
};
|
|
20
|
+
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
21
|
+
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
|
|
22
|
+
mod
|
|
23
|
+
));
|
|
24
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
25
|
+
var tools_exports = {};
|
|
26
|
+
__export(tools_exports, {
|
|
27
|
+
isArray: () => isArray,
|
|
28
|
+
isObject: () => isObject,
|
|
29
|
+
translateText: () => translateText
|
|
30
|
+
});
|
|
31
|
+
module.exports = __toCommonJS(tools_exports);
|
|
32
|
+
var import_got = __toESM(require("got"));
|
|
12
33
|
function isObject(it) {
|
|
13
|
-
|
|
14
|
-
// typeof null === 'object'
|
|
15
|
-
// typeof [] === 'object'
|
|
16
|
-
// [] instanceof Object === true
|
|
17
|
-
return Object.prototype.toString.call(it) === "[object Object]";
|
|
34
|
+
return Object.prototype.toString.call(it) === "[object Object]";
|
|
18
35
|
}
|
|
19
|
-
exports.isObject = isObject;
|
|
20
|
-
/**
|
|
21
|
-
* Tests whether the given variable is really an Array
|
|
22
|
-
* @param it The variable to test
|
|
23
|
-
*/
|
|
24
36
|
function isArray(it) {
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
37
|
+
if (Array.isArray != null)
|
|
38
|
+
return Array.isArray(it);
|
|
39
|
+
return Object.prototype.toString.call(it) === "[object Array]";
|
|
28
40
|
}
|
|
29
|
-
exports.isArray = isArray;
|
|
30
|
-
/**
|
|
31
|
-
* Translates text using the Google Translate API
|
|
32
|
-
* @param text The text to translate
|
|
33
|
-
* @param targetLang The target languate
|
|
34
|
-
* @param yandexApiKey The yandex API key. You can create one for free at https://translate.yandex.com/developers
|
|
35
|
-
*/
|
|
36
41
|
async function translateText(text, targetLang, yandexApiKey) {
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
return translateGoogle(text, targetLang);
|
|
48
|
-
}
|
|
42
|
+
if (targetLang === "en") {
|
|
43
|
+
return text;
|
|
44
|
+
} else if (!text) {
|
|
45
|
+
return "";
|
|
46
|
+
}
|
|
47
|
+
if (yandexApiKey) {
|
|
48
|
+
return translateYandex(text, targetLang, yandexApiKey);
|
|
49
|
+
} else {
|
|
50
|
+
return translateGoogle(text, targetLang);
|
|
51
|
+
}
|
|
49
52
|
}
|
|
50
|
-
exports.translateText = translateText;
|
|
51
|
-
/**
|
|
52
|
-
* Translates text with Yandex API
|
|
53
|
-
* @param text The text to translate
|
|
54
|
-
* @param targetLang The target languate
|
|
55
|
-
* @param apiKey The yandex API key. You can create one for free at https://translate.yandex.com/developers
|
|
56
|
-
*/
|
|
57
53
|
async function translateYandex(text, targetLang, apiKey) {
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
}
|
|
68
|
-
throw new Error("Invalid response for translate request");
|
|
69
|
-
}
|
|
70
|
-
catch (e) {
|
|
71
|
-
throw new Error(`Could not translate to "${targetLang}": ${e}`);
|
|
54
|
+
var _a;
|
|
55
|
+
if (targetLang === "zh-cn") {
|
|
56
|
+
targetLang = "zh";
|
|
57
|
+
}
|
|
58
|
+
try {
|
|
59
|
+
const url = `https://translate.yandex.net/api/v1.5/tr.json/translate?key=${apiKey}&text=${encodeURIComponent(text)}&lang=en-${targetLang}`;
|
|
60
|
+
const response = await (0, import_got.default)({ url, timeout: 15e3 });
|
|
61
|
+
if (isArray((_a = response.body) == null ? void 0 : _a.text)) {
|
|
62
|
+
return response.body.text[0];
|
|
72
63
|
}
|
|
64
|
+
throw new Error("Invalid response for translate request");
|
|
65
|
+
} catch (e) {
|
|
66
|
+
throw new Error(`Could not translate to "${targetLang}": ${e}`);
|
|
67
|
+
}
|
|
73
68
|
}
|
|
74
|
-
/**
|
|
75
|
-
* Translates text with Google API
|
|
76
|
-
* @param text The text to translate
|
|
77
|
-
* @param targetLang The target languate
|
|
78
|
-
*/
|
|
79
69
|
async function translateGoogle(text, targetLang) {
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
return response.body[0][0][0];
|
|
87
|
-
}
|
|
88
|
-
throw new Error("Invalid response for translate request");
|
|
70
|
+
var _a;
|
|
71
|
+
try {
|
|
72
|
+
const url = `http://translate.googleapis.com/translate_a/single?client=gtx&sl=en&tl=${targetLang}&dt=t&q=${encodeURIComponent(text)}&ie=UTF-8&oe=UTF-8`;
|
|
73
|
+
const response = await (0, import_got.default)({ url, timeout: 15e3 });
|
|
74
|
+
if (isArray(response.body)) {
|
|
75
|
+
return response.body[0][0][0];
|
|
89
76
|
}
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
77
|
+
throw new Error("Invalid response for translate request");
|
|
78
|
+
} catch (e) {
|
|
79
|
+
if (((_a = e.response) == null ? void 0 : _a.status) === 429) {
|
|
80
|
+
throw new Error(
|
|
81
|
+
`Could not translate to "${targetLang}": Rate-limited by Google Translate`
|
|
82
|
+
);
|
|
83
|
+
} else {
|
|
84
|
+
throw new Error(`Could not translate to "${targetLang}": ${e}`);
|
|
97
85
|
}
|
|
86
|
+
}
|
|
98
87
|
}
|
|
99
|
-
|
|
88
|
+
// Annotate the CommonJS export names for ESM import in node:
|
|
89
|
+
0 && (module.exports = {
|
|
90
|
+
isArray,
|
|
91
|
+
isObject,
|
|
92
|
+
translateText
|
|
93
|
+
});
|
|
94
|
+
//# sourceMappingURL=tools.js.map
|
package/build/lib/tools.js.map
CHANGED
|
@@ -1 +1,7 @@
|
|
|
1
|
-
{
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../src/lib/tools.ts"],
|
|
4
|
+
"sourcesContent": ["import got from \"got\";\r\n\r\n/**\r\n * Tests whether the given variable is a real object and not an Array\r\n * @param it The variable to test\r\n */\r\nexport function isObject(it: unknown): it is Record<string, any> {\r\n // This is necessary because:\r\n // typeof null === 'object'\r\n // typeof [] === 'object'\r\n // [] instanceof Object === true\r\n return Object.prototype.toString.call(it) === \"[object Object]\";\r\n}\r\n\r\n/**\r\n * Tests whether the given variable is really an Array\r\n * @param it The variable to test\r\n */\r\nexport function isArray(it: unknown): it is any[] {\r\n if (Array.isArray != null) return Array.isArray(it);\r\n return Object.prototype.toString.call(it) === \"[object Array]\";\r\n}\r\n\r\n/**\r\n * Translates text using the Google Translate API\r\n * @param text The text to translate\r\n * @param targetLang The target languate\r\n * @param yandexApiKey The yandex API key. You can create one for free at https://translate.yandex.com/developers\r\n */\r\nexport async function translateText(text: string, targetLang: string, yandexApiKey?: string): Promise<string> {\r\n if (targetLang === \"en\") {\r\n return text;\r\n } else if (!text) {\r\n return \"\";\r\n }\r\n if (yandexApiKey) {\r\n return translateYandex(text, targetLang, yandexApiKey);\r\n } else {\r\n return translateGoogle(text, targetLang);\r\n }\r\n}\r\n\r\n/**\r\n * Translates text with Yandex API\r\n * @param text The text to translate\r\n * @param targetLang The target languate\r\n * @param apiKey The yandex API key. You can create one for free at https://translate.yandex.com/developers\r\n */\r\nasync function translateYandex(text: string, targetLang: string, apiKey: string): Promise<string> {\r\n if (targetLang === \"zh-cn\") {\r\n targetLang = \"zh\";\r\n }\r\n try {\r\n const url = `https://translate.yandex.net/api/v1.5/tr.json/translate?key=${apiKey}&text=${encodeURIComponent(text)}&lang=en-${targetLang}`;\r\n const response = await got({url, timeout: 15000});\r\n if (isArray((response.body as any)?.text)) {\r\n return (response.body as any).text[0];\r\n }\r\n throw new Error(\"Invalid response for translate request\");\r\n } catch (e) {\r\n throw new Error(`Could not translate to \"${targetLang}\": ${e}`);\r\n }\r\n}\r\n\r\n/**\r\n * Translates text with Google API\r\n * @param text The text to translate\r\n * @param targetLang The target languate\r\n */\r\nasync function translateGoogle(text: string, targetLang: string): Promise<string> {\r\n try {\r\n const url = `http://translate.googleapis.com/translate_a/single?client=gtx&sl=en&tl=${targetLang}&dt=t&q=${encodeURIComponent(text)}&ie=UTF-8&oe=UTF-8`;\r\n const response = await got({url, timeout: 15000});\r\n if (isArray(response.body)) {\r\n // we got a valid response\r\n return response.body[0][0][0];\r\n }\r\n throw new Error(\"Invalid response for translate request\");\r\n } catch (e: any) {\r\n if (e.response?.status === 429) {\r\n throw new Error(\r\n `Could not translate to \"${targetLang}\": Rate-limited by Google Translate`\r\n );\r\n } else {\r\n throw new Error(`Could not translate to \"${targetLang}\": ${e}`);\r\n }\r\n }\r\n}\r\n"],
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAA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A,EAC5D,SAAS,GAAP;AACE,UAAI,OAAE,aAAF,mBAAY,YAAW,KAAK;AAC5B,YAAM,IAAI;AAAA,QACN,2BAA2B;AAAA,MAC/B;AAAA,IACJ,OAAO;AACH,YAAM,IAAI,MAAM,2BAA2B,gBAAgB,GAAG;AAAA,IAClE;AAAA,EACJ;AACJ;",
|
|
6
|
+
"names": ["got"]
|
|
7
|
+
}
|
package/build/lib/types.js
CHANGED
|
@@ -1,66 +1,97 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
Object.defineProperty
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
TEMP: "tmp"
|
|
2
|
+
var __defProp = Object.defineProperty;
|
|
3
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
4
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
5
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
6
|
+
var __export = (target, all) => {
|
|
7
|
+
for (var name in all)
|
|
8
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
10
9
|
};
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
[eufy_security_client_1.PropertyName.DeviceBattery]: "value.battery",
|
|
19
|
-
[eufy_security_client_1.PropertyName.DeviceBatteryTemp]: "value.temperature",
|
|
20
|
-
[eufy_security_client_1.PropertyName.DeviceMotionDetected]: "sensor.motion",
|
|
21
|
-
[eufy_security_client_1.PropertyName.DevicePersonDetected]: "sensor.motion",
|
|
22
|
-
[eufy_security_client_1.PropertyName.DeviceRinging]: "sensor",
|
|
23
|
-
[eufy_security_client_1.PropertyName.DeviceCryingDetected]: "sensor.noise",
|
|
24
|
-
[eufy_security_client_1.PropertyName.DeviceSoundDetected]: "sensor.noise",
|
|
25
|
-
[eufy_security_client_1.PropertyName.DevicePetDetected]: "sensor",
|
|
26
|
-
[eufy_security_client_1.PropertyName.DeviceSensorOpen]: "sensor",
|
|
27
|
-
[eufy_security_client_1.PropertyName.DeviceBatteryLow]: "indicator.lowbat",
|
|
28
|
-
[eufy_security_client_1.PropertyName.DeviceLockStatus]: "info.status",
|
|
29
|
-
[eufy_security_client_1.PropertyName.DeviceDogLickDetected]: "sensor",
|
|
30
|
-
[eufy_security_client_1.PropertyName.DeviceDogPoopDetected]: "sensor",
|
|
31
|
-
[eufy_security_client_1.PropertyName.DeviceVehicleDetected]: "sensor",
|
|
32
|
-
[eufy_security_client_1.PropertyName.DeviceRadarMotionDetected]: "sensor.motion",
|
|
33
|
-
[eufy_security_client_1.PropertyName.DeviceStrangerPersonDetected]: "sensor.motion",
|
|
34
|
-
[eufy_security_client_1.PropertyName.DeviceIdentityPersonDetected]: "sensor.motion",
|
|
35
|
-
[eufy_security_client_1.PropertyName.DeviceChargingStatus]: "info.status",
|
|
10
|
+
var __copyProps = (to, from, except, desc) => {
|
|
11
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
12
|
+
for (let key of __getOwnPropNames(from))
|
|
13
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
14
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
15
|
+
}
|
|
16
|
+
return to;
|
|
36
17
|
};
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
ROTATE_360: "rotate_360",
|
|
55
|
-
SET_DEFAULT_ANGLE: "set_default_angle",
|
|
56
|
-
SET_PRIVACY_ANGLE: "set_privacy_angle",
|
|
57
|
-
CALIBRATE: "calibrate",
|
|
58
|
-
UNLOCK: "unlock",
|
|
18
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
19
|
+
var types_exports = {};
|
|
20
|
+
__export(types_exports, {
|
|
21
|
+
DataLocation: () => DataLocation,
|
|
22
|
+
DeviceStateID: () => DeviceStateID,
|
|
23
|
+
IMAGE_FILE_JPEG_EXT: () => IMAGE_FILE_JPEG_EXT,
|
|
24
|
+
RoleMapping: () => RoleMapping,
|
|
25
|
+
STREAM_FILE_NAME_EXT: () => STREAM_FILE_NAME_EXT,
|
|
26
|
+
StationStateID: () => StationStateID
|
|
27
|
+
});
|
|
28
|
+
module.exports = __toCommonJS(types_exports);
|
|
29
|
+
var import_eufy_security_client = require("eufy-security-client");
|
|
30
|
+
const DataLocation = {
|
|
31
|
+
LIVESTREAM: "live",
|
|
32
|
+
LAST_LIVESTREAM: "last_live",
|
|
33
|
+
LAST_EVENT: "last_event",
|
|
34
|
+
TEMP: "tmp"
|
|
59
35
|
};
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
36
|
+
const STREAM_FILE_NAME_EXT = ".m3u8";
|
|
37
|
+
const IMAGE_FILE_JPEG_EXT = ".jpg";
|
|
38
|
+
const RoleMapping = {
|
|
39
|
+
[import_eufy_security_client.PropertyName.Name]: "info.name",
|
|
40
|
+
[import_eufy_security_client.PropertyName.StationMacAddress]: "info.mac",
|
|
41
|
+
[import_eufy_security_client.PropertyName.StationLANIpAddress]: "info.ip",
|
|
42
|
+
[import_eufy_security_client.PropertyName.DeviceState]: "info.status",
|
|
43
|
+
[import_eufy_security_client.PropertyName.DeviceBattery]: "value.battery",
|
|
44
|
+
[import_eufy_security_client.PropertyName.DeviceBatteryTemp]: "value.temperature",
|
|
45
|
+
[import_eufy_security_client.PropertyName.DeviceMotionDetected]: "sensor.motion",
|
|
46
|
+
[import_eufy_security_client.PropertyName.DevicePersonDetected]: "sensor.motion",
|
|
47
|
+
[import_eufy_security_client.PropertyName.DeviceRinging]: "sensor",
|
|
48
|
+
[import_eufy_security_client.PropertyName.DeviceCryingDetected]: "sensor.noise",
|
|
49
|
+
[import_eufy_security_client.PropertyName.DeviceSoundDetected]: "sensor.noise",
|
|
50
|
+
[import_eufy_security_client.PropertyName.DevicePetDetected]: "sensor",
|
|
51
|
+
[import_eufy_security_client.PropertyName.DeviceSensorOpen]: "sensor",
|
|
52
|
+
[import_eufy_security_client.PropertyName.DeviceBatteryLow]: "indicator.lowbat",
|
|
53
|
+
[import_eufy_security_client.PropertyName.DeviceLockStatus]: "info.status",
|
|
54
|
+
[import_eufy_security_client.PropertyName.DeviceDogLickDetected]: "sensor",
|
|
55
|
+
[import_eufy_security_client.PropertyName.DeviceDogPoopDetected]: "sensor",
|
|
56
|
+
[import_eufy_security_client.PropertyName.DeviceVehicleDetected]: "sensor",
|
|
57
|
+
[import_eufy_security_client.PropertyName.DeviceRadarMotionDetected]: "sensor.motion",
|
|
58
|
+
[import_eufy_security_client.PropertyName.DeviceStrangerPersonDetected]: "sensor.motion",
|
|
59
|
+
[import_eufy_security_client.PropertyName.DeviceIdentityPersonDetected]: "sensor.motion",
|
|
60
|
+
[import_eufy_security_client.PropertyName.DeviceChargingStatus]: "info.status"
|
|
65
61
|
};
|
|
66
|
-
|
|
62
|
+
const DeviceStateID = {
|
|
63
|
+
LIVESTREAM: "livestream",
|
|
64
|
+
START_STREAM: "start_stream",
|
|
65
|
+
STOP_STREAM: "stop_stream",
|
|
66
|
+
RTSP_STREAM_URL: "rtsp_stream_url",
|
|
67
|
+
TRIGGER_ALARM_SOUND: "trigger_alarm_sound",
|
|
68
|
+
RESET_ALARM_SOUND: "reset_alarm_sound",
|
|
69
|
+
PICTURE_URL: "picture_url",
|
|
70
|
+
PICTURE_HTML: "picture_html",
|
|
71
|
+
LIVESTREAM_RTSP: "livestream_rtsp",
|
|
72
|
+
PAN_LEFT: "pan_left",
|
|
73
|
+
PAN_RIGHT: "pan_right",
|
|
74
|
+
TILT_UP: "tilt_up",
|
|
75
|
+
TILT_DOWN: "titl_down",
|
|
76
|
+
ROTATE_360: "rotate_360",
|
|
77
|
+
SET_DEFAULT_ANGLE: "set_default_angle",
|
|
78
|
+
SET_PRIVACY_ANGLE: "set_privacy_angle",
|
|
79
|
+
CALIBRATE: "calibrate",
|
|
80
|
+
UNLOCK: "unlock"
|
|
81
|
+
};
|
|
82
|
+
const StationStateID = {
|
|
83
|
+
REBOOT: "reboot",
|
|
84
|
+
CONNECTION: "connection",
|
|
85
|
+
TRIGGER_ALARM_SOUND: "trigger_alarm_sound",
|
|
86
|
+
RESET_ALARM_SOUND: "reset_alarm_sound"
|
|
87
|
+
};
|
|
88
|
+
// Annotate the CommonJS export names for ESM import in node:
|
|
89
|
+
0 && (module.exports = {
|
|
90
|
+
DataLocation,
|
|
91
|
+
DeviceStateID,
|
|
92
|
+
IMAGE_FILE_JPEG_EXT,
|
|
93
|
+
RoleMapping,
|
|
94
|
+
STREAM_FILE_NAME_EXT,
|
|
95
|
+
StationStateID
|
|
96
|
+
});
|
|
97
|
+
//# sourceMappingURL=types.js.map
|
package/build/lib/types.js.map
CHANGED
|
@@ -1 +1,7 @@
|
|
|
1
|
-
{
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../src/lib/types.ts"],
|
|
4
|
+
"sourcesContent": ["import { PropertyName } from \"eufy-security-client\";\r\n\r\nimport { IRoleMapping } from \"./interfaces\";\r\n\r\nexport const DataLocation = {\r\n LIVESTREAM: \"live\",\r\n LAST_LIVESTREAM: \"last_live\",\r\n LAST_EVENT: \"last_event\",\r\n TEMP: \"tmp\"\r\n}\r\n\r\nexport const STREAM_FILE_NAME_EXT = \".m3u8\";\r\nexport const IMAGE_FILE_JPEG_EXT = \".jpg\";\r\n\r\nexport const RoleMapping: IRoleMapping = {\r\n [PropertyName.Name]: \"info.name\",\r\n [PropertyName.StationMacAddress]: \"info.mac\",\r\n [PropertyName.StationLANIpAddress]: \"info.ip\",\r\n [PropertyName.DeviceState]: \"info.status\",\r\n [PropertyName.DeviceBattery]: \"value.battery\",\r\n [PropertyName.DeviceBatteryTemp]: \"value.temperature\",\r\n [PropertyName.DeviceMotionDetected]: \"sensor.motion\",\r\n [PropertyName.DevicePersonDetected]: \"sensor.motion\",\r\n [PropertyName.DeviceRinging]: \"sensor\",\r\n [PropertyName.DeviceCryingDetected]: \"sensor.noise\",\r\n [PropertyName.DeviceSoundDetected]: \"sensor.noise\",\r\n [PropertyName.DevicePetDetected]: \"sensor\",\r\n [PropertyName.DeviceSensorOpen]: \"sensor\",\r\n [PropertyName.DeviceBatteryLow]: \"indicator.lowbat\",\r\n [PropertyName.DeviceLockStatus]: \"info.status\",\r\n [PropertyName.DeviceDogLickDetected]: \"sensor\",\r\n [PropertyName.DeviceDogPoopDetected]: \"sensor\",\r\n [PropertyName.DeviceVehicleDetected]: \"sensor\",\r\n [PropertyName.DeviceRadarMotionDetected]: \"sensor.motion\",\r\n [PropertyName.DeviceStrangerPersonDetected]: \"sensor.motion\",\r\n [PropertyName.DeviceIdentityPersonDetected]: \"sensor.motion\",\r\n [PropertyName.DeviceChargingStatus]: \"info.status\",\r\n}\r\n\r\nexport const DeviceStateID = {\r\n /*LAST_EVENT_PIC_URL: \"last_event_pic_url\",\r\n LAST_EVENT_PIC_HTML: \"last_event_pic_html\",\r\n LAST_EVENT_VIDEO_URL: \"last_event_video_url\",*/\r\n LIVESTREAM: \"livestream\",\r\n START_STREAM: \"start_stream\",\r\n STOP_STREAM: \"stop_stream\",\r\n RTSP_STREAM_URL: \"rtsp_stream_url\",\r\n TRIGGER_ALARM_SOUND: \"trigger_alarm_sound\",\r\n RESET_ALARM_SOUND: \"reset_alarm_sound\",\r\n PICTURE_URL: \"picture_url\",\r\n PICTURE_HTML: \"picture_html\",\r\n LIVESTREAM_RTSP: \"livestream_rtsp\",\r\n PAN_LEFT: \"pan_left\",\r\n PAN_RIGHT: \"pan_right\",\r\n TILT_UP: \"tilt_up\",\r\n TILT_DOWN: \"titl_down\",\r\n ROTATE_360: \"rotate_360\",\r\n SET_DEFAULT_ANGLE: \"set_default_angle\",\r\n SET_PRIVACY_ANGLE: \"set_privacy_angle\",\r\n CALIBRATE: \"calibrate\",\r\n UNLOCK: \"unlock\",\r\n}\r\n\r\nexport const StationStateID = {\r\n REBOOT: \"reboot\",\r\n CONNECTION: \"connection\",\r\n TRIGGER_ALARM_SOUND: \"trigger_alarm_sound\",\r\n RESET_ALARM_SOUND: \"reset_alarm_sound\",\r\n}"],
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,kCAA6B;AAItB,MAAM,eAAe;AAAA,EACxB,YAAY;AAAA,EACZ,iBAAiB;AAAA,EACjB,YAAY;AAAA,EACZ,MAAM;AACV;AAEO,MAAM,uBAAuB;AAC7B,MAAM,sBAAsB;AAE5B,MAAM,cAA4B;AAAA,EACrC,CAAC,yCAAa,OAAO;AAAA,EACrB,CAAC,yCAAa,oBAAoB;AAAA,EAClC,CAAC,yCAAa,sBAAsB;AAAA,EACpC,CAAC,yCAAa,cAAc;AAAA,EAC5B,CAAC,yCAAa,gBAAgB;AAAA,EAC9B,CAAC,yCAAa,oBAAoB;AAAA,EAClC,CAAC,yCAAa,uBAAuB;AAAA,EACrC,CAAC,yCAAa,uBAAuB;AAAA,EACrC,CAAC,yCAAa,gBAAgB;AAAA,EAC9B,CAAC,yCAAa,uBAAuB;AAAA,EACrC,CAAC,yCAAa,sBAAsB;AAAA,EACpC,CAAC,yCAAa,oBAAoB;AAAA,EAClC,CAAC,yCAAa,mBAAmB;AAAA,EACjC,CAAC,yCAAa,mBAAmB;AAAA,EACjC,CAAC,yCAAa,mBAAmB;AAAA,EACjC,CAAC,yCAAa,wBAAwB;AAAA,EACtC,CAAC,yCAAa,wBAAwB;AAAA,EACtC,CAAC,yCAAa,wBAAwB;AAAA,EACtC,CAAC,yCAAa,4BAA4B;AAAA,EAC1C,C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