homebridge-adt-pulse 3.0.0-beta.5 → 3.0.0-beta.7

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.
@@ -1,237 +1,308 @@
1
1
  {
2
- "pluginAlias": "ADTPulse",
3
- "pluginType": "platform",
4
- "singular": true,
5
- "headerDisplay": "An account to link your [ADT Pulse](https://portal.adtpulse.com/) system to Homebridge is required. This will be used to control your security panel and read sensor status.",
6
- "footerDisplay": "If you need assistance, you may read the [plugin instructions](https://github.com/mrjackyliang/homebridge-adt-pulse#readme) or feel free to [submit an issue](https://github.com/mrjackyliang/homebridge-adt-pulse/issues/new/choose).",
7
- "schema": {
8
- "type": "object",
9
- "properties": {
2
+ "pluginAlias": "ADTPulse",
3
+ "pluginType": "platform",
4
+ "singular": true,
5
+ "headerDisplay": "Welcome to the configuration page for **[ADT Pulse for Homebridge](https://github.com/mrjackyliang/homebridge-adt-pulse)**! You will find customizable settings to tailor your experience here. Start by inputting your login credentials, and then specify the sensors you want to incorporate into this setup.",
6
+ "footerDisplay": "For further assistance, please consult the [readme](https://github.com/mrjackyliang/homebridge-adt-pulse#readme) file. Should you encounter any issues, such as crashes or unexpected results, please [create a new issue](https://github.com/mrjackyliang/homebridge-adt-pulse/issues/new/choose) on GitHub.",
7
+ "schema": {
8
+ "type": "object",
9
+ "properties": {
10
+ "name": {
11
+ "title": "Name",
12
+ "type": "string",
13
+ "required": true,
14
+ "description": "Enter a unique name for this plugin. The name will mainly be used for identification purposes, such as in Homebridge logs.",
15
+ "default": "ADT Pulse",
16
+ "placeholder": "ADT Pulse",
17
+ "minLength": 1,
18
+ "maxLength": 50
19
+ },
20
+ "subdomain": {
21
+ "title": "Portal Region",
22
+ "type": "string",
23
+ "required": true,
24
+ "description": "Select the portal region based on where you are subscribed in. For subscribers in Canada, choose \"Canada\" from the dropdown menu.",
25
+ "oneOf": [
26
+ {
27
+ "title": "United States \uD83C\uDDFA\uD83C\uDDF8 - portal.adtpulse.com</span>",
28
+ "enum": [
29
+ "portal"
30
+ ]
31
+ },
32
+ {
33
+ "title": "Canada \uD83C\uDDE8\uD83C\uDDE6 - portal-ca.adtpulse.com",
34
+ "enum": [
35
+ "portal-ca"
36
+ ]
37
+ }
38
+ ],
39
+ "default": "portal"
40
+ },
41
+ "username": {
42
+ "title": "Username",
43
+ "type": "string",
44
+ "required": true,
45
+ "description": "Provide the username you use to login to the portal.",
46
+ "placeholder": "e.g. user@example.com",
47
+ "minLength": 1,
48
+ "maxLength": 100
49
+ },
50
+ "password": {
51
+ "title": "Password",
52
+ "type": "string",
53
+ "required": true,
54
+ "description": "Provide the password you use to login to the portal.",
55
+ "placeholder": "e.g. Mys7r0nG!P@ssw0rd",
56
+ "minLength": 1,
57
+ "maxLength": 300
58
+ },
59
+ "fingerprint": {
60
+ "title": "Fingerprint",
61
+ "type": "string",
62
+ "required": true,
63
+ "description": "After logging in and selecting \"Trust this device\", paste in the device fingerprint generated through the <a href=\"https://raw.githack.com/mrjackyliang/homebridge-adt-pulse/main/fingerprint/index.html\" target=\"_blank\">ADT Pulse Device Fingerprint Detector</a>.",
64
+ "placeholder": "e.g. VGhpc0lzQVNlY3VyZVBhc3N3b3JkMTIzIQ==",
65
+ "minLength": 1,
66
+ "maxLength": 5120
67
+ },
68
+ "mode": {
69
+ "title": "Operational Mode",
70
+ "type": "string",
71
+ "required": true,
72
+ "description": "Choose the operational mode for the plugin. Debug mode is enabled only when Homebridge debug mode is on; there is no separate setting for this.",
73
+ "oneOf": [
74
+ {
75
+ "title": "Normal",
76
+ "enum": [
77
+ "normal"
78
+ ]
79
+ },
80
+ {
81
+ "title": "Paused",
82
+ "enum": [
83
+ "paused"
84
+ ]
85
+ },
86
+ {
87
+ "title": "Reset (danger)",
88
+ "enum": [
89
+ "reset"
90
+ ]
91
+ }
92
+ ],
93
+ "default": "normal"
94
+ },
95
+ "speed": {
96
+ "title": "Operational Speed",
97
+ "type": "number",
98
+ "required": true,
99
+ "description": "Choose the operational speed for the plugin. Designed to enhance the performance of devices with older hardware. May result in slower device updates.",
100
+ "oneOf": [
101
+ {
102
+ "title": "Normal Speed (1x)",
103
+ "enum": [
104
+ 1
105
+ ]
106
+ },
107
+ {
108
+ "title": "Moderate Speed (0.75x)",
109
+ "enum": [
110
+ 0.75
111
+ ]
112
+ },
113
+ {
114
+ "title": "Slower Speed (0.5x)",
115
+ "enum": [
116
+ 0.5
117
+ ]
118
+ },
119
+ {
120
+ "title": "Slowest Speed (0.25x)",
121
+ "enum": [
122
+ 0.25
123
+ ]
124
+ }
125
+ ],
126
+ "default": 1
127
+ },
128
+ "sensors": {
129
+ "title": "Sensors",
130
+ "type": "array",
131
+ "required": true,
132
+ "description": "Define your sensors here. Sensors include devices like \"Door/Window Sensor\" or \"Motion Sensor\". <strong class=\"font-weight-bold\">Please note that Z-Wave accessories are not supported.</strong> Ensure at least one sensor is specified for proper functionality.",
133
+ "items": {
134
+ "type": "object",
135
+ "properties": {
10
136
  "name": {
11
- "title": "Name",
12
- "type": "string",
13
- "default": "ADT Pulse",
14
- "required": true,
15
- "description": "Plugin name as displayed in the Homebridge log"
137
+ "title": "Name",
138
+ "type": "string",
139
+ "required": false,
140
+ "description": "<strong class=\"font-weight-bold\">Optional.</strong> Provide a display name for this sensor to differentiate it from the names assigned by ADT technicians during installation.",
141
+ "placeholder": "e.g. Family Room Couch Window 1",
142
+ "minLength": 1,
143
+ "maxLength": 50
144
+ },
145
+ "adtName": {
146
+ "title": "ADT Sensor Name",
147
+ "type": "string",
148
+ "required": true,
149
+ "description": "Specify the <strong class=\"font-weight-bold\">exact name</strong> associated with the sensor you want to add. Double-check the names to ensure they don't include extra characters when copying and pasting.",
150
+ "placeholder": "e.g. Family Room Window (99)",
151
+ "minLength": 1,
152
+ "maxLength": 100
16
153
  },
17
- "username": {
18
- "title": "Username",
19
- "type": "string",
20
- "default": "",
21
- "required": true,
22
- "format": "email",
23
- "minLength": 6,
24
- "maxLength": 50,
25
- "description": "Email address used for ADT Pulse login"
154
+ "adtType": {
155
+ "title": "ADT Sensor Type",
156
+ "type": "string",
157
+ "required": true,
158
+ "description": "Select the <strong class=\"font-weight-bold\">type</strong> associated with the sensor you want to add. Ensure your selection matches the sensor type, as selecting the wrong type may lead to incorrect status detection.",
159
+ "oneOf": [
160
+ {
161
+ "title": "Carbon Monoxide Detector",
162
+ "enum": [
163
+ "co"
164
+ ]
165
+ },
166
+ {
167
+ "title": "Door/Window Sensor / Door Sensor / Window Sensor",
168
+ "enum": [
169
+ "doorWindow"
170
+ ]
171
+ },
172
+ {
173
+ "title": "Fire (Smoke/Heat) Detector",
174
+ "enum": [
175
+ "fire"
176
+ ]
177
+ },
178
+ {
179
+ "title": "Glass Break Detector",
180
+ "enum": [
181
+ "glass"
182
+ ]
183
+ },
184
+ {
185
+ "title": "Motion Sensor / Motion Sensor (Notable Events Only)",
186
+ "enum": [
187
+ "motion"
188
+ ]
189
+ },
190
+ {
191
+ "title": "Temperature Sensor",
192
+ "enum": [
193
+ "temperature"
194
+ ]
195
+ },
196
+ {
197
+ "title": "Water/Flood Sensor",
198
+ "enum": [
199
+ "flood"
200
+ ]
201
+ }
202
+ ]
26
203
  },
27
- "password": {
28
- "title": "Password",
29
- "type": "string",
30
- "default": "",
31
- "required": true,
32
- "minLength": 8,
33
- "maxLength": 50,
34
- "description": "Password used for ADT Pulse login"
204
+ "adtZone": {
205
+ "title": "ADT Sensor Zone",
206
+ "type": "number",
207
+ "required": true,
208
+ "description": "Specify the <strong class=\"font-weight-bold\">exact zone</strong> associated with the sensor you want to add. Double-check the zone to ensure the correct sensor is added.",
209
+ "placeholder": "e.g. 99",
210
+ "minimum": 1,
211
+ "maximum": 99
212
+ }
213
+ }
214
+ },
215
+ "minItems": 1,
216
+ "maxItems": 148
217
+ }
218
+ }
219
+ },
220
+ "layout": [
221
+ {
222
+ "type": "tabs",
223
+ "tabs": [
224
+ {
225
+ "title": "General",
226
+ "htmlClass": "px-3 pt-3 pb-0",
227
+ "items": [
228
+ {
229
+ "key": "name",
230
+ "type": "text"
35
231
  },
36
- "fingerprint": {
37
- "title": "MFA Fingerprint",
38
- "type": "string",
39
- "default": "",
40
- "required": true,
41
- "description": "MFA Fingerprint from browser registered with ADT Pulse"
232
+ {
233
+ "key": "mode",
234
+ "type": "select"
42
235
  },
43
- "overrideSensors": {
44
- "title": "Override Sensors",
45
- "type": "array",
46
- "items": {
47
- "type": "object",
48
- "properties": {
49
- "name": {
50
- "title": "Name",
51
- "type": "string",
52
- "default": "",
53
- "required": true,
54
- "description": "The sensor name for the sensor you would like to override"
55
- },
56
- "type": {
57
- "title": "Type",
58
- "type": "string",
59
- "default": "",
60
- "oneOf": [
61
- {
62
- "title": "Door/Window Sensor",
63
- "enum": [
64
- "sensor,doorWindow"
65
- ]
66
- },
67
- {
68
- "title": "Glass Break Detector",
69
- "enum": [
70
- "sensor,glass"
71
- ]
72
- },
73
- {
74
- "title": "Motion Sensor",
75
- "enum": [
76
- "sensor,motion"
77
- ]
78
- },
79
- {
80
- "title": "Carbon Monoxide Detector",
81
- "enum": [
82
- "sensor,co"
83
- ]
84
- },
85
- {
86
- "title": "Fire (Smoke/Heat) Detector",
87
- "enum": [
88
- "sensor,fire"
89
- ]
90
- }
91
- ],
92
- "required": true,
93
- "description": "The sensor type for the sensor you would like to override"
94
- }
95
- }
96
- },
97
- "description": "When a sensor cannot be detected accurately, you can manually set the sensor here to override the default detection features"
236
+ {
237
+ "key": "speed",
238
+ "type": "select"
239
+ }
240
+ ]
241
+ },
242
+ {
243
+ "title": "Login",
244
+ "htmlClass": "px-3 pt-3 pb-0",
245
+ "items": [
246
+ {
247
+ "key": "subdomain",
248
+ "type": "select"
98
249
  },
99
- "country": {
100
- "title": "Country",
101
- "type": "string",
102
- "default": "us",
103
- "oneOf": [
104
- {
105
- "title": "United States",
106
- "enum": [
107
- "us"
108
- ]
109
- },
110
- {
111
- "title": "Canada",
112
- "enum": [
113
- "ca"
114
- ]
115
- }
116
- ],
117
- "required": false,
118
- "description": "Select a country where ADT Pulse will connect to"
250
+ {
251
+ "key": "username",
252
+ "type": "text"
119
253
  },
120
- "logLevel": {
121
- "title": "Log Level",
122
- "type": "integer",
123
- "default": 30,
124
- "oneOf": [
125
- {
126
- "title": "Errors (Level 10)",
127
- "enum": [
128
- 10
129
- ]
130
- },
254
+ {
255
+ "key": "password",
256
+ "type": "password"
257
+ },
258
+ {
259
+ "key": "fingerprint",
260
+ "type": "password"
261
+ },
262
+ {
263
+ "type": "help",
264
+ "helpvalue": "<div class=\"alert alert-primary\" role=\"alert\">If you wish, you can optionally view the \"Device Details\" tab to see what information the device fingerprint contains about your browser.</div>"
265
+ }
266
+ ]
267
+ },
268
+ {
269
+ "title": "Devices",
270
+ "htmlClass": "px-3 pt-3 pb-0",
271
+ "items": [
272
+ {
273
+ "key": "sensors",
274
+ "htmlClass": "p-10",
275
+ "buttonText": "Add Sensor",
276
+ "items": [
277
+ {
278
+ "type": "div",
279
+ "htmlClass": "my-3",
280
+ "items": [
131
281
  {
132
- "title": "Warnings (Level 20)",
133
- "enum": [
134
- 20
135
- ]
282
+ "key": "sensors[].name",
283
+ "type": "text"
136
284
  },
137
285
  {
138
- "title": "Info (Level 30)",
139
- "enum": [
140
- 30
141
- ]
286
+ "key": "sensors[].adtName",
287
+ "type": "text"
142
288
  },
143
289
  {
144
- "title": "Debug (Level 40)",
145
- "enum": [
146
- 40
147
- ]
290
+ "key": "sensors[].adtType",
291
+ "type": "select"
148
292
  },
149
293
  {
150
- "title": "Verbose (Level 50)",
151
- "enum": [
152
- 50
153
- ]
294
+ "key": "sensors[].adtZone",
295
+ "type": "number"
154
296
  }
155
- ],
156
- "required": false,
157
- "pattern": "^([1-5])([0])$",
158
- "description": "Higher levels mean more logs will show. Turn on Homebridge Debug Mode for levels 40 and 50. Recommended setting is \"Info (Level 30)\""
159
- },
160
- "logActivity": {
161
- "title": "Log Activity",
162
- "type": "boolean",
163
- "default": true,
164
- "required": false
165
- },
166
- "removeObsoleteZones": {
167
- "title": "Remove Obsolete Zones",
168
- "type": "boolean",
169
- "default": true,
170
- "required": false
171
- },
172
- "pausePlugin": {
173
- "title": "Pause Plugin",
174
- "type": "boolean",
175
- "default": false,
176
- "required": false
177
- },
178
- "resetAll": {
179
- "title": "Reset Plugin \uD83D\uDED1",
180
- "type": "boolean",
181
- "default": false,
182
- "required": false
183
- }
184
- }
185
- },
186
- "layout": [
187
- {
188
- "key": "name"
189
- },
190
- {
191
- "display": "flex",
192
- "flex-flow": "row nowrap",
193
- "justify-content": "space-between",
194
- "items": [
195
- {
196
- "key": "username",
197
- "flex": "1 0 0px"
198
- },
199
- {
200
- "key": "password",
201
- "flex": "1 0 0px"
297
+ ]
202
298
  }
203
- ]
204
- },
205
- {
206
- "key": "fingerprint"
207
- },
208
- {
209
- "key": "overrideSensors",
210
- "buttonText": "Add Sensor",
211
- "items": [
212
- "overrideSensors[].name",
213
- "overrideSensors[].type"
214
- ]
215
- },
216
- {
217
- "key": "country"
218
- },
219
- {
220
- "key": "logLevel"
221
- },
222
- {
223
- "key": "logActivity"
224
- },
225
- {
226
- "key": "removeObsoleteZones"
227
- },
228
- {
229
- "key": "pausePlugin"
230
- },
231
- {
232
- "key": "resetAll"
299
+ ]
300
+ }
301
+ ]
233
302
  }
234
- ],
235
- "form": null,
236
- "display": null
303
+ ]
304
+ }
305
+ ],
306
+ "form": null,
307
+ "display": null
237
308
  }
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "homebridge-adt-pulse",
3
3
  "displayName": "Homebridge ADT Pulse",
4
- "version": "3.0.0-beta.5",
4
+ "version": "3.0.0-beta.7",
5
5
  "description": "Homebridge security system platform for ADT Pulse",
6
6
  "exports": "./build/src/index.js",
7
7
  "type": "module",
@@ -55,6 +55,7 @@
55
55
  "axios-cookiejar-support": "4.0.7",
56
56
  "chalk": "5.3.0",
57
57
  "jsdom": "23.0.1",
58
+ "latest-version": "7.0.0",
58
59
  "lodash": "4.17.21",
59
60
  "serialize-error": "11.0.3",
60
61
  "tough-cookie": "4.1.3",
@@ -63,14 +64,14 @@
63
64
  "devDependencies": {
64
65
  "@types/jsdom": "21.1.6",
65
66
  "@types/lodash": "4.14.202",
66
- "@types/node": "20.10.4",
67
+ "@types/node": "20.10.5",
67
68
  "@types/tough-cookie": "4.0.5",
68
- "@typescript-eslint/eslint-plugin": "6.13.2",
69
- "@typescript-eslint/parser": "6.13.2",
70
- "eslint": "8.55.0",
69
+ "@typescript-eslint/eslint-plugin": "6.15.0",
70
+ "@typescript-eslint/parser": "6.15.0",
71
+ "eslint": "8.56.0",
71
72
  "eslint-config-airbnb-base": "15.0.0",
72
73
  "eslint-config-airbnb-typescript": "17.1.0",
73
- "eslint-plugin-import": "2.29.0",
74
+ "eslint-plugin-import": "2.29.1",
74
75
  "homebridge": "1.7.0",
75
76
  "npm-run-all": "4.1.5",
76
77
  "rimraf": "5.0.5",