@modernlock/common 1.0.47 → 1.0.48
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/build/index.d.ts +1 -0
- package/build/index.js +1 -0
- package/build/things/commands.d.ts +105 -0
- package/build/things/commands.js +126 -0
- package/package.json +1 -1
package/build/index.d.ts
CHANGED
package/build/index.js
CHANGED
|
@@ -50,3 +50,4 @@ __exportStar(require("./config/elasticsearchConnection"), exports);
|
|
|
50
50
|
__exportStar(require("./interfaces/reservation"), exports);
|
|
51
51
|
__exportStar(require("./things/events"), exports);
|
|
52
52
|
__exportStar(require("./mqtt/topics"), exports);
|
|
53
|
+
__exportStar(require("./things/commands"), exports);
|
|
@@ -0,0 +1,105 @@
|
|
|
1
|
+
export declare const commandsDictionary: {
|
|
2
|
+
smart_lock: {
|
|
3
|
+
set_lock_state: {
|
|
4
|
+
command: string;
|
|
5
|
+
logoUrl: string;
|
|
6
|
+
parameters: {
|
|
7
|
+
name: string;
|
|
8
|
+
type: string;
|
|
9
|
+
label: string;
|
|
10
|
+
}[];
|
|
11
|
+
};
|
|
12
|
+
};
|
|
13
|
+
thermostat: {
|
|
14
|
+
set_temperature: {
|
|
15
|
+
command: string;
|
|
16
|
+
logoUrl: string;
|
|
17
|
+
parameters: {
|
|
18
|
+
name: string;
|
|
19
|
+
type: string;
|
|
20
|
+
label: string;
|
|
21
|
+
min: number;
|
|
22
|
+
max: number;
|
|
23
|
+
unit: string;
|
|
24
|
+
}[];
|
|
25
|
+
};
|
|
26
|
+
set_mode: {
|
|
27
|
+
command: string;
|
|
28
|
+
logoUrl: string;
|
|
29
|
+
parameters: {
|
|
30
|
+
name: string;
|
|
31
|
+
type: string;
|
|
32
|
+
label: string;
|
|
33
|
+
options: string[];
|
|
34
|
+
}[];
|
|
35
|
+
};
|
|
36
|
+
set_fan_mode: {
|
|
37
|
+
command: string;
|
|
38
|
+
logoUrl: string;
|
|
39
|
+
parameters: {
|
|
40
|
+
name: string;
|
|
41
|
+
type: string;
|
|
42
|
+
label: string;
|
|
43
|
+
options: string[];
|
|
44
|
+
}[];
|
|
45
|
+
};
|
|
46
|
+
set_humidity: {
|
|
47
|
+
command: string;
|
|
48
|
+
logoUrl: string;
|
|
49
|
+
parameters: {
|
|
50
|
+
name: string;
|
|
51
|
+
type: string;
|
|
52
|
+
label: string;
|
|
53
|
+
min: number;
|
|
54
|
+
max: number;
|
|
55
|
+
unit: string;
|
|
56
|
+
}[];
|
|
57
|
+
};
|
|
58
|
+
};
|
|
59
|
+
light_bulb: {
|
|
60
|
+
on: {
|
|
61
|
+
command: string;
|
|
62
|
+
logoUrl: string;
|
|
63
|
+
parameters: {
|
|
64
|
+
name: string;
|
|
65
|
+
type: string;
|
|
66
|
+
label: string;
|
|
67
|
+
min: number;
|
|
68
|
+
max: number;
|
|
69
|
+
unit: string;
|
|
70
|
+
}[];
|
|
71
|
+
};
|
|
72
|
+
off: {
|
|
73
|
+
command: string;
|
|
74
|
+
logoUrl: string;
|
|
75
|
+
parameters: {
|
|
76
|
+
name: string;
|
|
77
|
+
type: string;
|
|
78
|
+
label: string;
|
|
79
|
+
min: number;
|
|
80
|
+
max: number;
|
|
81
|
+
unit: string;
|
|
82
|
+
}[];
|
|
83
|
+
};
|
|
84
|
+
};
|
|
85
|
+
window_sensor: {
|
|
86
|
+
open: {
|
|
87
|
+
command: string;
|
|
88
|
+
logoUrl: string;
|
|
89
|
+
parameters: {
|
|
90
|
+
name: string;
|
|
91
|
+
type: string;
|
|
92
|
+
label: string;
|
|
93
|
+
}[];
|
|
94
|
+
};
|
|
95
|
+
close: {
|
|
96
|
+
command: string;
|
|
97
|
+
logoUrl: string;
|
|
98
|
+
parameters: {
|
|
99
|
+
name: string;
|
|
100
|
+
type: string;
|
|
101
|
+
label: string;
|
|
102
|
+
}[];
|
|
103
|
+
};
|
|
104
|
+
};
|
|
105
|
+
};
|
|
@@ -0,0 +1,126 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.commandsDictionary = void 0;
|
|
4
|
+
exports.commandsDictionary = {
|
|
5
|
+
"smart_lock": {
|
|
6
|
+
"set_lock_state": {
|
|
7
|
+
"command": "set_lock_state",
|
|
8
|
+
"logoUrl": "logoUrl",
|
|
9
|
+
"parameters": [
|
|
10
|
+
{
|
|
11
|
+
"name": "locked",
|
|
12
|
+
"type": "boolean",
|
|
13
|
+
"label": "Lock State"
|
|
14
|
+
}
|
|
15
|
+
]
|
|
16
|
+
}
|
|
17
|
+
},
|
|
18
|
+
"thermostat": {
|
|
19
|
+
"set_temperature": {
|
|
20
|
+
"command": "set_temperature",
|
|
21
|
+
"logoUrl": "logoUrl",
|
|
22
|
+
"parameters": [
|
|
23
|
+
{
|
|
24
|
+
"name": "targetTemp",
|
|
25
|
+
"type": "number",
|
|
26
|
+
"label": "Target Temperature",
|
|
27
|
+
"min": 16,
|
|
28
|
+
"max": 30,
|
|
29
|
+
"unit": "°C"
|
|
30
|
+
}
|
|
31
|
+
]
|
|
32
|
+
},
|
|
33
|
+
"set_mode": {
|
|
34
|
+
"command": "set_mode",
|
|
35
|
+
"logoUrl": "logoUrl",
|
|
36
|
+
"parameters": [
|
|
37
|
+
{
|
|
38
|
+
"name": "mode",
|
|
39
|
+
"type": "enum",
|
|
40
|
+
"label": "Mode",
|
|
41
|
+
"options": ["cool", "heat", "fan_only", "off"]
|
|
42
|
+
}
|
|
43
|
+
]
|
|
44
|
+
},
|
|
45
|
+
"set_fan_mode": {
|
|
46
|
+
"command": "set_fan_mode",
|
|
47
|
+
"logoUrl": "logoUrl",
|
|
48
|
+
"parameters": [
|
|
49
|
+
{
|
|
50
|
+
"name": "fan_mode",
|
|
51
|
+
"type": "enum",
|
|
52
|
+
"label": "Fan Mode",
|
|
53
|
+
"options": ["auto", "on", "off"]
|
|
54
|
+
}
|
|
55
|
+
]
|
|
56
|
+
},
|
|
57
|
+
"set_humidity": {
|
|
58
|
+
"command": "set_humidity",
|
|
59
|
+
"logoUrl": "logoUrl",
|
|
60
|
+
"parameters": [
|
|
61
|
+
{
|
|
62
|
+
"name": "humidity",
|
|
63
|
+
"type": "number",
|
|
64
|
+
"label": "Humidity",
|
|
65
|
+
"min": 0,
|
|
66
|
+
"max": 100,
|
|
67
|
+
"unit": "%"
|
|
68
|
+
}
|
|
69
|
+
]
|
|
70
|
+
}
|
|
71
|
+
},
|
|
72
|
+
"light_bulb": {
|
|
73
|
+
"on": {
|
|
74
|
+
"command": "on",
|
|
75
|
+
"logoUrl": "logoUrl",
|
|
76
|
+
"parameters": [
|
|
77
|
+
{
|
|
78
|
+
"name": "brightness",
|
|
79
|
+
"type": "number",
|
|
80
|
+
"label": "Brightness",
|
|
81
|
+
"min": 0,
|
|
82
|
+
"max": 100,
|
|
83
|
+
"unit": "%"
|
|
84
|
+
}
|
|
85
|
+
]
|
|
86
|
+
},
|
|
87
|
+
"off": {
|
|
88
|
+
"command": "off",
|
|
89
|
+
"logoUrl": "logoUrl",
|
|
90
|
+
"parameters": [
|
|
91
|
+
{
|
|
92
|
+
"name": "brightness",
|
|
93
|
+
"type": "number",
|
|
94
|
+
"label": "Brightness",
|
|
95
|
+
"min": 0,
|
|
96
|
+
"max": 100,
|
|
97
|
+
"unit": "%"
|
|
98
|
+
}
|
|
99
|
+
]
|
|
100
|
+
}
|
|
101
|
+
},
|
|
102
|
+
"window_sensor": {
|
|
103
|
+
"open": {
|
|
104
|
+
"command": "open",
|
|
105
|
+
"logoUrl": "logoUrl",
|
|
106
|
+
"parameters": [
|
|
107
|
+
{
|
|
108
|
+
"name": "open",
|
|
109
|
+
"type": "boolean",
|
|
110
|
+
"label": "Open"
|
|
111
|
+
}
|
|
112
|
+
]
|
|
113
|
+
},
|
|
114
|
+
"close": {
|
|
115
|
+
"command": "close",
|
|
116
|
+
"logoUrl": "logoUrl",
|
|
117
|
+
"parameters": [
|
|
118
|
+
{
|
|
119
|
+
"name": "close",
|
|
120
|
+
"type": "boolean",
|
|
121
|
+
"label": "Close"
|
|
122
|
+
}
|
|
123
|
+
]
|
|
124
|
+
}
|
|
125
|
+
}
|
|
126
|
+
};
|