ring-client-api 13.2.1 → 14.0.0-beta.1
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/lib/api.d.ts +10 -8
- package/lib/api.js +57 -64
- package/lib/device-data.js +6 -9
- package/lib/ffmpeg.js +2 -6
- package/lib/index.d.ts +7 -7
- package/lib/index.js +7 -23
- package/lib/location.d.ts +32 -31
- package/lib/location.js +67 -72
- package/lib/refresh-token.js +6 -11
- package/lib/rest-client.d.ts +4 -4
- package/lib/rest-client.js +40 -51
- package/lib/ring-auth-cli.js +2 -4
- package/lib/ring-camera.d.ts +26 -23
- package/lib/ring-camera.js +64 -61
- package/lib/ring-chime.d.ts +7 -7
- package/lib/ring-chime.js +14 -18
- package/lib/ring-device-data-cli.js +2 -4
- package/lib/ring-device.d.ts +7 -7
- package/lib/ring-device.js +16 -20
- package/lib/ring-intercom.d.ts +8 -8
- package/lib/ring-intercom.js +23 -27
- package/lib/ring-types.d.ts +142 -133
- package/lib/ring-types.js +137 -153
- package/lib/streaming/peer-connection.d.ts +5 -3
- package/lib/streaming/peer-connection.js +25 -30
- package/lib/streaming/simple-webrtc-session.d.ts +3 -3
- package/lib/streaming/simple-webrtc-session.js +3 -7
- package/lib/streaming/streaming-messages.d.ts +6 -5
- package/lib/streaming/streaming-messages.js +6 -9
- package/lib/streaming/streaming-session.d.ts +5 -5
- package/lib/streaming/streaming-session.js +34 -38
- package/lib/streaming/webrtc-connection.d.ts +5 -5
- package/lib/streaming/webrtc-connection.js +39 -43
- package/lib/subscribed.d.ts +1 -1
- package/lib/subscribed.js +1 -5
- package/lib/test/rest-client.spec.js +44 -45
- package/lib/test/ring-camera.spec.js +12 -13
- package/lib/util.js +33 -54
- package/package.json +17 -19
package/lib/ring-intercom.d.ts
CHANGED
|
@@ -1,16 +1,16 @@
|
|
|
1
|
-
import { IntercomHandsetAudioData, PushNotification } from './ring-types';
|
|
2
|
-
import { RingRestClient } from './rest-client';
|
|
1
|
+
import type { IntercomHandsetAudioData, PushNotification } from './ring-types.ts';
|
|
2
|
+
import type { RingRestClient } from './rest-client.ts';
|
|
3
3
|
import { BehaviorSubject, Subject } from 'rxjs';
|
|
4
4
|
export declare class RingIntercom {
|
|
5
|
-
private initialData;
|
|
6
|
-
private restClient;
|
|
7
5
|
id: number;
|
|
8
|
-
deviceType:
|
|
6
|
+
deviceType: "intercom_handset_audio";
|
|
9
7
|
onData: BehaviorSubject<IntercomHandsetAudioData>;
|
|
10
8
|
onRequestUpdate: Subject<unknown>;
|
|
11
9
|
onBatteryLevel: import("rxjs").Observable<number | null>;
|
|
12
10
|
onDing: Subject<void>;
|
|
13
11
|
onUnlocked: Subject<void>;
|
|
12
|
+
private initialData;
|
|
13
|
+
private restClient;
|
|
14
14
|
constructor(initialData: IntercomHandsetAudioData, restClient: RingRestClient);
|
|
15
15
|
updateData(update: IntercomHandsetAudioData): void;
|
|
16
16
|
requestUpdate(): void;
|
|
@@ -18,9 +18,9 @@ export declare class RingIntercom {
|
|
|
18
18
|
get name(): string;
|
|
19
19
|
get isOffline(): boolean;
|
|
20
20
|
get batteryLevel(): number | null;
|
|
21
|
-
unlock(): Promise<import("./rest-client").ExtendedResponse>;
|
|
21
|
+
unlock(): Promise<import("./rest-client.ts").ExtendedResponse>;
|
|
22
22
|
private doorbotUrl;
|
|
23
|
-
subscribeToDingEvents(): Promise<void & import("./rest-client").ExtendedResponse>;
|
|
24
|
-
unsubscribeFromDingEvents(): Promise<void & import("./rest-client").ExtendedResponse>;
|
|
23
|
+
subscribeToDingEvents(): Promise<void & import("./rest-client.ts").ExtendedResponse>;
|
|
24
|
+
unsubscribeFromDingEvents(): Promise<void & import("./rest-client.ts").ExtendedResponse>;
|
|
25
25
|
processPushNotification(notification: PushNotification): void;
|
|
26
26
|
}
|
package/lib/ring-intercom.js
CHANGED
|
@@ -1,33 +1,30 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
const ring_camera_1 = require("./ring-camera");
|
|
9
|
-
const util_1 = require("./util");
|
|
10
|
-
class RingIntercom {
|
|
11
|
-
initialData;
|
|
12
|
-
restClient;
|
|
1
|
+
import { PushNotificationAction } from "./ring-types.js";
|
|
2
|
+
import { clientApi, commandsApi } from "./rest-client.js";
|
|
3
|
+
import { BehaviorSubject, Subject } from 'rxjs';
|
|
4
|
+
import { distinctUntilChanged, map } from 'rxjs/operators';
|
|
5
|
+
import { getBatteryLevel } from "./ring-camera.js";
|
|
6
|
+
import { logError } from "./util.js";
|
|
7
|
+
export class RingIntercom {
|
|
13
8
|
id;
|
|
14
9
|
deviceType;
|
|
15
10
|
onData;
|
|
16
|
-
onRequestUpdate = new
|
|
11
|
+
onRequestUpdate = new Subject();
|
|
17
12
|
onBatteryLevel;
|
|
18
|
-
onDing = new
|
|
19
|
-
onUnlocked = new
|
|
13
|
+
onDing = new Subject();
|
|
14
|
+
onUnlocked = new Subject();
|
|
15
|
+
initialData;
|
|
16
|
+
restClient;
|
|
20
17
|
constructor(initialData, restClient) {
|
|
21
18
|
this.initialData = initialData;
|
|
22
19
|
this.restClient = restClient;
|
|
23
|
-
this.id =
|
|
24
|
-
this.deviceType =
|
|
25
|
-
this.onData = new
|
|
26
|
-
this.onBatteryLevel = this.onData.pipe(
|
|
20
|
+
this.id = initialData.id;
|
|
21
|
+
this.deviceType = initialData.kind;
|
|
22
|
+
this.onData = new BehaviorSubject(this.initialData);
|
|
23
|
+
this.onBatteryLevel = this.onData.pipe(map((data) => getBatteryLevel(data)), distinctUntilChanged());
|
|
27
24
|
if (!initialData.subscribed) {
|
|
28
25
|
this.subscribeToDingEvents().catch((e) => {
|
|
29
|
-
|
|
30
|
-
|
|
26
|
+
logError('Failed to subscribe ' + initialData.description + ' to ding events');
|
|
27
|
+
logError(e);
|
|
31
28
|
});
|
|
32
29
|
}
|
|
33
30
|
}
|
|
@@ -47,12 +44,12 @@ class RingIntercom {
|
|
|
47
44
|
return this.data.alerts.connection === 'offline';
|
|
48
45
|
}
|
|
49
46
|
get batteryLevel() {
|
|
50
|
-
return
|
|
47
|
+
return getBatteryLevel(this.data);
|
|
51
48
|
}
|
|
52
49
|
unlock() {
|
|
53
50
|
return this.restClient.request({
|
|
54
51
|
method: 'PUT',
|
|
55
|
-
url:
|
|
52
|
+
url: commandsApi(`devices/${this.id}/device_rpc`),
|
|
56
53
|
json: {
|
|
57
54
|
command_name: 'device_rpc',
|
|
58
55
|
request: {
|
|
@@ -67,7 +64,7 @@ class RingIntercom {
|
|
|
67
64
|
});
|
|
68
65
|
}
|
|
69
66
|
doorbotUrl(path = '') {
|
|
70
|
-
return
|
|
67
|
+
return clientApi(`doorbots/${this.id}/${path}`);
|
|
71
68
|
}
|
|
72
69
|
subscribeToDingEvents() {
|
|
73
70
|
return this.restClient.request({
|
|
@@ -84,13 +81,12 @@ class RingIntercom {
|
|
|
84
81
|
processPushNotification(notification) {
|
|
85
82
|
if ('android_config' in notification &&
|
|
86
83
|
notification.android_config.category ===
|
|
87
|
-
|
|
84
|
+
PushNotificationAction.IntercomDing) {
|
|
88
85
|
this.onDing.next();
|
|
89
86
|
}
|
|
90
87
|
else if ('gcmData' in notification.data &&
|
|
91
|
-
notification.data.gcmData.action ===
|
|
88
|
+
notification.data.gcmData.action === PushNotificationAction.IntercomUnlock) {
|
|
92
89
|
this.onUnlocked.next();
|
|
93
90
|
}
|
|
94
91
|
}
|
|
95
92
|
}
|
|
96
|
-
exports.RingIntercom = RingIntercom;
|
package/lib/ring-types.d.ts
CHANGED
|
@@ -1,104 +1,109 @@
|
|
|
1
1
|
type Firmware = string | 'Up To Date';
|
|
2
|
-
export declare
|
|
3
|
-
BaseStation
|
|
4
|
-
BaseStationPro
|
|
5
|
-
Keypad
|
|
6
|
-
SecurityPanel
|
|
7
|
-
ContactSensor
|
|
8
|
-
MotionSensor
|
|
9
|
-
FloodFreezeSensor
|
|
10
|
-
FreezeSensor
|
|
11
|
-
TemperatureSensor
|
|
12
|
-
WaterSensor
|
|
13
|
-
TiltSensor
|
|
14
|
-
GlassbreakSensor
|
|
15
|
-
RangeExtender
|
|
16
|
-
ZigbeeAdapter
|
|
17
|
-
AccessCodeVault
|
|
18
|
-
AccessCode
|
|
19
|
-
SmokeAlarm
|
|
20
|
-
CoAlarm
|
|
21
|
-
SmokeCoListener
|
|
22
|
-
MultiLevelSwitch
|
|
23
|
-
Fan
|
|
24
|
-
MultiLevelBulb
|
|
25
|
-
Switch
|
|
26
|
-
BeamsMotionSensor
|
|
27
|
-
BeamsSwitch
|
|
28
|
-
BeamsMultiLevelSwitch
|
|
29
|
-
BeamsLightGroupSwitch
|
|
30
|
-
BeamsTransformerSwitch
|
|
31
|
-
BeamsDevice
|
|
32
|
-
RetrofitBridge
|
|
33
|
-
RetrofitZone
|
|
34
|
-
Thermostat
|
|
35
|
-
Sensor
|
|
36
|
-
RingNetAdapter
|
|
37
|
-
CodeVault
|
|
38
|
-
SecurityAccessCode
|
|
39
|
-
ZWaveAdapter
|
|
40
|
-
ZWaveExtender
|
|
41
|
-
PanicButton
|
|
42
|
-
UnknownZWave
|
|
43
|
-
OnvifCamera
|
|
44
|
-
ThirdPartyGarageDoorOpener
|
|
45
|
-
IntercomHandsetAudio
|
|
46
|
-
WaterValve
|
|
47
|
-
}
|
|
48
|
-
export
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
2
|
+
export declare const RingDeviceType: {
|
|
3
|
+
readonly BaseStation: "hub.redsky";
|
|
4
|
+
readonly BaseStationPro: "hub.kili";
|
|
5
|
+
readonly Keypad: "security-keypad";
|
|
6
|
+
readonly SecurityPanel: "security-panel";
|
|
7
|
+
readonly ContactSensor: "sensor.contact";
|
|
8
|
+
readonly MotionSensor: "sensor.motion";
|
|
9
|
+
readonly FloodFreezeSensor: "sensor.flood-freeze";
|
|
10
|
+
readonly FreezeSensor: "sensor.freeze";
|
|
11
|
+
readonly TemperatureSensor: "sensor.temperature";
|
|
12
|
+
readonly WaterSensor: "sensor.water";
|
|
13
|
+
readonly TiltSensor: "sensor.tilt";
|
|
14
|
+
readonly GlassbreakSensor: "sensor.glassbreak";
|
|
15
|
+
readonly RangeExtender: "range-extender.zwave";
|
|
16
|
+
readonly ZigbeeAdapter: "adapter.zigbee";
|
|
17
|
+
readonly AccessCodeVault: "access-code.vault";
|
|
18
|
+
readonly AccessCode: "access-code";
|
|
19
|
+
readonly SmokeAlarm: "alarm.smoke";
|
|
20
|
+
readonly CoAlarm: "alarm.co";
|
|
21
|
+
readonly SmokeCoListener: "listener.smoke-co";
|
|
22
|
+
readonly MultiLevelSwitch: "switch.multilevel";
|
|
23
|
+
readonly Fan: "switch.multilevel";
|
|
24
|
+
readonly MultiLevelBulb: "switch.multilevel.bulb";
|
|
25
|
+
readonly Switch: "switch";
|
|
26
|
+
readonly BeamsMotionSensor: "motion-sensor.beams";
|
|
27
|
+
readonly BeamsSwitch: "switch.beams";
|
|
28
|
+
readonly BeamsMultiLevelSwitch: "switch.multilevel.beams";
|
|
29
|
+
readonly BeamsLightGroupSwitch: "group.light-group.beams";
|
|
30
|
+
readonly BeamsTransformerSwitch: "switch.transformer.beams";
|
|
31
|
+
readonly BeamsDevice: "device.beams";
|
|
32
|
+
readonly RetrofitBridge: "bridge.flatline";
|
|
33
|
+
readonly RetrofitZone: "sensor.zone";
|
|
34
|
+
readonly Thermostat: "temperature-control.thermostat";
|
|
35
|
+
readonly Sensor: "sensor";
|
|
36
|
+
readonly RingNetAdapter: "adapter.ringnet";
|
|
37
|
+
readonly CodeVault: "access-code.vault";
|
|
38
|
+
readonly SecurityAccessCode: "access-code";
|
|
39
|
+
readonly ZWaveAdapter: "adapter.zwave";
|
|
40
|
+
readonly ZWaveExtender: "range-extender.zwave";
|
|
41
|
+
readonly PanicButton: "security-panic";
|
|
42
|
+
readonly UnknownZWave: "unknown.zwave";
|
|
43
|
+
readonly OnvifCamera: "onvif_camera";
|
|
44
|
+
readonly ThirdPartyGarageDoorOpener: "third_party_gdo";
|
|
45
|
+
readonly IntercomHandsetAudio: "intercom_handset_audio";
|
|
46
|
+
readonly WaterValve: "valve.water";
|
|
47
|
+
};
|
|
48
|
+
export type RingDeviceType = (typeof RingDeviceType)[keyof typeof RingDeviceType];
|
|
49
|
+
export declare const RingDeviceCategory: {
|
|
50
|
+
readonly Outlets: 1;
|
|
51
|
+
readonly Lights: 2;
|
|
52
|
+
readonly Sensors: 5;
|
|
53
|
+
readonly Appliances: 7;
|
|
54
|
+
readonly Locks: 10;
|
|
55
|
+
readonly Thermostats: 11;
|
|
56
|
+
readonly Cameras: 12;
|
|
57
|
+
readonly Alarms: 15;
|
|
58
|
+
readonly Fans: 17;
|
|
59
|
+
readonly Security: 22;
|
|
60
|
+
readonly Unknown: 29;
|
|
61
|
+
readonly SensorsMotion: 30;
|
|
62
|
+
readonly Controller: 31;
|
|
63
|
+
readonly RangeExtenders: 32;
|
|
64
|
+
readonly Keypads: 33;
|
|
65
|
+
readonly Sirens: 34;
|
|
66
|
+
readonly PanicButtons: 35;
|
|
67
|
+
readonly WaterValves: 37;
|
|
68
|
+
};
|
|
69
|
+
export type RingDeviceCategory = (typeof RingDeviceCategory)[keyof typeof RingDeviceCategory];
|
|
70
|
+
export declare const RingCameraKind: {
|
|
71
|
+
readonly doorbot: "doorbot";
|
|
72
|
+
readonly doorbell: "doorbell";
|
|
73
|
+
readonly doorbell_v3: "doorbell_v3";
|
|
74
|
+
readonly doorbell_v4: "doorbell_v4";
|
|
75
|
+
readonly doorbell_v5: "doorbell_v5";
|
|
76
|
+
readonly doorbell_oyster: "doorbell_oyster";
|
|
77
|
+
readonly doorbell_portal: "doorbell_portal";
|
|
78
|
+
readonly doorbell_scallop: "doorbell_scallop";
|
|
79
|
+
readonly doorbell_scallop_lite: "doorbell_scallop_lite";
|
|
80
|
+
readonly doorbell_graham_cracker: "doorbell_graham_cracker";
|
|
81
|
+
readonly lpd_v1: "lpd_v1";
|
|
82
|
+
readonly lpd_v2: "lpd_v2";
|
|
83
|
+
readonly lpd_v4: "lpd_v4";
|
|
84
|
+
readonly jbox_v1: "jbox_v1";
|
|
85
|
+
readonly stickup_cam: "stickup_cam";
|
|
86
|
+
readonly stickup_cam_v3: "stickup_cam_v3";
|
|
87
|
+
readonly stickup_cam_elite: "stickup_cam_elite";
|
|
88
|
+
readonly stickup_cam_longfin: "stickup_cam_longfin";
|
|
89
|
+
readonly stickup_cam_lunar: "stickup_cam_lunar";
|
|
90
|
+
readonly spotlightw_v2: "spotlightw_v2";
|
|
91
|
+
readonly hp_cam_v1: "hp_cam_v1";
|
|
92
|
+
readonly hp_cam_v2: "hp_cam_v2";
|
|
93
|
+
readonly stickup_cam_v4: "stickup_cam_v4";
|
|
94
|
+
readonly floodlight_v1: "floodlight_v1";
|
|
95
|
+
readonly floodlight_v2: "floodlight_v2";
|
|
96
|
+
readonly floodlight_pro: "floodlight_pro";
|
|
97
|
+
readonly cocoa_camera: "cocoa_camera";
|
|
98
|
+
readonly cocoa_doorbell: "cocoa_doorbell";
|
|
99
|
+
readonly cocoa_doorbell_v2: "cocoa_doorbell_v2";
|
|
100
|
+
readonly cocoa_doorbell_v3: "cocoa_doorbell_v3";
|
|
101
|
+
readonly cocoa_floodlight: "cocoa_floodlight";
|
|
102
|
+
readonly cocoa_spotlight: "cocoa_spotlight";
|
|
103
|
+
readonly stickup_cam_mini: "stickup_cam_mini";
|
|
104
|
+
readonly onvif_camera: "onvif_camera";
|
|
105
|
+
};
|
|
106
|
+
export type RingCameraKind = (typeof RingCameraKind)[keyof typeof RingCameraKind];
|
|
102
107
|
export declare const RingCameraModel: {
|
|
103
108
|
readonly [P in RingCameraKind]: string;
|
|
104
109
|
};
|
|
@@ -334,11 +339,12 @@ export interface TicketAsset {
|
|
|
334
339
|
status: 'online' | 'offline';
|
|
335
340
|
uuid: string;
|
|
336
341
|
}
|
|
337
|
-
export declare
|
|
338
|
-
Mechanical
|
|
339
|
-
Digital
|
|
340
|
-
None
|
|
341
|
-
}
|
|
342
|
+
export declare const DoorbellType: {
|
|
343
|
+
readonly Mechanical: 0;
|
|
344
|
+
readonly Digital: 1;
|
|
345
|
+
readonly None: 2;
|
|
346
|
+
};
|
|
347
|
+
export type DoorbellType = (typeof DoorbellType)[keyof typeof DoorbellType];
|
|
342
348
|
export interface BaseCameraData {
|
|
343
349
|
alerts: {
|
|
344
350
|
connection: 'online' | 'offline' | string;
|
|
@@ -481,7 +487,7 @@ export interface BaseCameraData {
|
|
|
481
487
|
};
|
|
482
488
|
}
|
|
483
489
|
export interface CameraData extends BaseCameraData {
|
|
484
|
-
kind: Omit<RingCameraKind, RingCameraKind.onvif_camera>;
|
|
490
|
+
kind: Omit<RingCameraKind, typeof RingCameraKind.onvif_camera>;
|
|
485
491
|
address: string;
|
|
486
492
|
battery_life: number | string | null;
|
|
487
493
|
battery_life_2?: number | string | null;
|
|
@@ -495,7 +501,7 @@ export interface CameraData extends BaseCameraData {
|
|
|
495
501
|
stolen: boolean;
|
|
496
502
|
}
|
|
497
503
|
export interface OnvifCameraData extends BaseCameraData {
|
|
498
|
-
kind: RingCameraKind.onvif_camera;
|
|
504
|
+
kind: typeof RingCameraKind.onvif_camera;
|
|
499
505
|
metadata: {
|
|
500
506
|
legacy_fw_migrated: boolean;
|
|
501
507
|
imported_from_amazon: boolean;
|
|
@@ -513,7 +519,7 @@ export interface OnvifCameraData extends BaseCameraData {
|
|
|
513
519
|
}
|
|
514
520
|
export interface ThirdPartyGarageDoorOpener {
|
|
515
521
|
id: number;
|
|
516
|
-
kind: RingDeviceType.ThirdPartyGarageDoorOpener;
|
|
522
|
+
kind: typeof RingDeviceType.ThirdPartyGarageDoorOpener;
|
|
517
523
|
description: string;
|
|
518
524
|
location_id: string;
|
|
519
525
|
owner_id: number;
|
|
@@ -537,7 +543,7 @@ export interface IntercomHandsetAudioData {
|
|
|
537
543
|
id: number;
|
|
538
544
|
description: string;
|
|
539
545
|
device_id: string;
|
|
540
|
-
kind: RingDeviceType.IntercomHandsetAudio;
|
|
546
|
+
kind: typeof RingDeviceType.IntercomHandsetAudio;
|
|
541
547
|
function: {
|
|
542
548
|
name: null;
|
|
543
549
|
};
|
|
@@ -860,24 +866,26 @@ export interface RingDeviceHistoryEvent {
|
|
|
860
866
|
body: any;
|
|
861
867
|
}
|
|
862
868
|
export type DingState = 'ringing' | 'connected' | 'timed_out' | 'completed';
|
|
863
|
-
export declare
|
|
864
|
-
Human
|
|
865
|
-
Loitering
|
|
866
|
-
Motion
|
|
867
|
-
OtherMotion
|
|
868
|
-
NotAvailable
|
|
869
|
-
StreamBroken
|
|
870
|
-
}
|
|
871
|
-
export
|
|
872
|
-
|
|
873
|
-
|
|
874
|
-
|
|
875
|
-
|
|
876
|
-
|
|
877
|
-
|
|
878
|
-
|
|
879
|
-
|
|
880
|
-
|
|
869
|
+
export declare const NotificationDetectionType: {
|
|
870
|
+
readonly Human: "human";
|
|
871
|
+
readonly Loitering: "loitering";
|
|
872
|
+
readonly Motion: "motion";
|
|
873
|
+
readonly OtherMotion: "other_motion";
|
|
874
|
+
readonly NotAvailable: "null";
|
|
875
|
+
readonly StreamBroken: "stream_broken";
|
|
876
|
+
};
|
|
877
|
+
export type NotificationDetectionType = (typeof NotificationDetectionType)[keyof typeof NotificationDetectionType];
|
|
878
|
+
export declare const PushNotificationAction: {
|
|
879
|
+
readonly Ding: "com.ring.pn.live-event.ding";
|
|
880
|
+
readonly Motion: "com.ring.pn.live-event.motion";
|
|
881
|
+
readonly IntercomDing: "com.ring.pn.live-event.intercom";
|
|
882
|
+
readonly IntercomUnlock: "com.ring.push.INTERCOM_UNLOCK_FROM_APP";
|
|
883
|
+
readonly AlarmModeNone: "com.ring.push.HANDLE_NEW_SECURITY_PANEL_MODE_NONE_NOTICE";
|
|
884
|
+
readonly AlarmModeSome: "com.ring.push.HANDLE_NEW_SECURITY_PANEL_MODE_SOME_NOTICE";
|
|
885
|
+
readonly AlarmSoundSiren: "com.ring.push.HANDLE_NEW_USER_SOUND_SIREN";
|
|
886
|
+
readonly AlarmSilenceSiren: "com.ring.push.HANDLE_NEW_NON_ALARM_SIREN_SILENCED";
|
|
887
|
+
};
|
|
888
|
+
export type PushNotificationAction = (typeof PushNotificationAction)[keyof typeof PushNotificationAction];
|
|
881
889
|
export interface PushNotificationDingV2 {
|
|
882
890
|
version: '2.0.0' | string;
|
|
883
891
|
android_config: {
|
|
@@ -897,7 +905,7 @@ export interface PushNotificationDingV2 {
|
|
|
897
905
|
device: {
|
|
898
906
|
e2ee_enabled: boolean;
|
|
899
907
|
id: number;
|
|
900
|
-
kind: RingCameraKind | RingDeviceType.IntercomHandsetAudio;
|
|
908
|
+
kind: RingCameraKind | typeof RingDeviceType.IntercomHandsetAudio;
|
|
901
909
|
name: string;
|
|
902
910
|
};
|
|
903
911
|
event: {
|
|
@@ -947,7 +955,7 @@ interface PushNotificationIntercomUnlock {
|
|
|
947
955
|
aps: {
|
|
948
956
|
alert: string;
|
|
949
957
|
};
|
|
950
|
-
action: PushNotificationAction.IntercomUnlock;
|
|
958
|
+
action: typeof PushNotificationAction.IntercomUnlock;
|
|
951
959
|
alarm_meta: {
|
|
952
960
|
device_zid: number;
|
|
953
961
|
location_id: string;
|
|
@@ -1025,10 +1033,11 @@ export interface AccountMonitoringStatus {
|
|
|
1025
1033
|
cmsMonitoringType: 'full' | string;
|
|
1026
1034
|
dispatchSetupComplete: boolean;
|
|
1027
1035
|
}
|
|
1028
|
-
export declare
|
|
1029
|
-
Burglar
|
|
1030
|
-
Fire
|
|
1031
|
-
}
|
|
1036
|
+
export declare const DispatchSignalType: {
|
|
1037
|
+
readonly Burglar: "user-verified-burglar-xa";
|
|
1038
|
+
readonly Fire: "user-verified-fire-xa";
|
|
1039
|
+
};
|
|
1040
|
+
export type DispatchSignalType = (typeof DispatchSignalType)[keyof typeof DispatchSignalType];
|
|
1032
1041
|
export type LocationModeInput = 'home' | 'away' | 'disarmed';
|
|
1033
1042
|
export type LocationMode = LocationModeInput | 'disabled' | 'unset';
|
|
1034
1043
|
export declare const disabledLocationModes: LocationMode[];
|