@seamapi/types 1.147.0 → 1.148.0
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/dist/connect.cjs +32 -63
- package/dist/connect.cjs.map +1 -1
- package/dist/connect.d.cts +96 -188
- package/lib/seam/connect/internal/model-types.d.ts +2 -1
- package/lib/seam/connect/internal/model-types.js +1 -1
- package/lib/seam/connect/internal/model-types.js.map +1 -1
- package/lib/seam/connect/internal/schemas.d.ts +2 -1
- package/lib/seam/connect/internal/schemas.js +2 -1
- package/lib/seam/connect/internal/schemas.js.map +1 -1
- package/lib/seam/connect/models/connect-webview.d.ts +3 -3
- package/lib/seam/connect/models/custom-metadata.d.ts +4 -2
- package/lib/seam/connect/models/custom-metadata.js +2 -1
- package/lib/seam/connect/models/custom-metadata.js.map +1 -1
- package/lib/seam/connect/models/devices/managed-device.d.ts +53 -3
- package/lib/seam/connect/models/devices/managed-device.js +7 -1
- package/lib/seam/connect/models/devices/managed-device.js.map +1 -1
- package/lib/seam/connect/models/devices/phone.d.ts +3 -3
- package/lib/seam/connect/models/devices/unmanaged-device.d.ts +25 -0
- package/lib/seam/connect/openapi.d.ts +32 -160
- package/lib/seam/connect/openapi.js +25 -60
- package/lib/seam/connect/openapi.js.map +1 -1
- package/lib/seam/connect/route-types.d.ts +59 -23
- package/package.json +1 -1
- package/src/lib/seam/connect/internal/model-types.ts +2 -32
- package/src/lib/seam/connect/internal/schemas.ts +2 -2
- package/src/lib/seam/connect/models/custom-metadata.ts +9 -2
- package/src/lib/seam/connect/models/devices/managed-device.ts +7 -1
- package/src/lib/seam/connect/openapi.ts +26 -60
- package/src/lib/seam/connect/route-types.ts +77 -23
|
@@ -1794,7 +1794,7 @@ export interface Routes {
|
|
|
1794
1794
|
status: 'pending' | 'failed' | 'authorized';
|
|
1795
1795
|
custom_redirect_url: string | null;
|
|
1796
1796
|
custom_redirect_failure_url: string | null;
|
|
1797
|
-
custom_metadata: Record<string, string | boolean
|
|
1797
|
+
custom_metadata: Record<string, string | boolean>;
|
|
1798
1798
|
automatically_manage_new_devices: boolean;
|
|
1799
1799
|
wait_for_device_creation: boolean;
|
|
1800
1800
|
authorized_at: string | null;
|
|
@@ -1838,7 +1838,7 @@ export interface Routes {
|
|
|
1838
1838
|
status: 'pending' | 'failed' | 'authorized';
|
|
1839
1839
|
custom_redirect_url: string | null;
|
|
1840
1840
|
custom_redirect_failure_url: string | null;
|
|
1841
|
-
custom_metadata: Record<string, string | boolean
|
|
1841
|
+
custom_metadata: Record<string, string | boolean>;
|
|
1842
1842
|
automatically_manage_new_devices: boolean;
|
|
1843
1843
|
wait_for_device_creation: boolean;
|
|
1844
1844
|
authorized_at: string | null;
|
|
@@ -1854,7 +1854,7 @@ export interface Routes {
|
|
|
1854
1854
|
commonParams: {
|
|
1855
1855
|
user_identifier_key?: string | undefined;
|
|
1856
1856
|
/** Returns devices where the webview's custom_metadata contains all of the provided key/value pairs. */
|
|
1857
|
-
custom_metadata_has?: Record<string, string | boolean
|
|
1857
|
+
custom_metadata_has?: Record<string, string | boolean> | undefined;
|
|
1858
1858
|
};
|
|
1859
1859
|
formData: {};
|
|
1860
1860
|
jsonResponse: {
|
|
@@ -1873,7 +1873,7 @@ export interface Routes {
|
|
|
1873
1873
|
status: 'pending' | 'failed' | 'authorized';
|
|
1874
1874
|
custom_redirect_url: string | null;
|
|
1875
1875
|
custom_redirect_failure_url: string | null;
|
|
1876
|
-
custom_metadata: Record<string, string | boolean
|
|
1876
|
+
custom_metadata: Record<string, string | boolean>;
|
|
1877
1877
|
automatically_manage_new_devices: boolean;
|
|
1878
1878
|
wait_for_device_creation: boolean;
|
|
1879
1879
|
authorized_at: string | null;
|
|
@@ -1931,7 +1931,7 @@ export interface Routes {
|
|
|
1931
1931
|
account_type_display_name: string;
|
|
1932
1932
|
errors?: any;
|
|
1933
1933
|
warnings?: any;
|
|
1934
|
-
custom_metadata
|
|
1934
|
+
custom_metadata: Record<string, string | boolean>;
|
|
1935
1935
|
automatically_manage_new_devices: boolean;
|
|
1936
1936
|
};
|
|
1937
1937
|
};
|
|
@@ -1943,7 +1943,7 @@ export interface Routes {
|
|
|
1943
1943
|
jsonBody: {};
|
|
1944
1944
|
commonParams: {
|
|
1945
1945
|
/** Returns devices where the account's custom_metadata contains all of the provided key/value pairs. */
|
|
1946
|
-
custom_metadata_has?: Record<string, string | boolean
|
|
1946
|
+
custom_metadata_has?: Record<string, string | boolean> | undefined;
|
|
1947
1947
|
};
|
|
1948
1948
|
formData: {};
|
|
1949
1949
|
jsonResponse: {
|
|
@@ -1961,7 +1961,7 @@ export interface Routes {
|
|
|
1961
1961
|
account_type_display_name: string;
|
|
1962
1962
|
errors?: any;
|
|
1963
1963
|
warnings?: any;
|
|
1964
|
-
custom_metadata
|
|
1964
|
+
custom_metadata: Record<string, string | boolean>;
|
|
1965
1965
|
automatically_manage_new_devices: boolean;
|
|
1966
1966
|
}>;
|
|
1967
1967
|
};
|
|
@@ -1992,7 +1992,7 @@ export interface Routes {
|
|
|
1992
1992
|
account_type_display_name: string;
|
|
1993
1993
|
errors?: any;
|
|
1994
1994
|
warnings?: any;
|
|
1995
|
-
custom_metadata
|
|
1995
|
+
custom_metadata: Record<string, string | boolean>;
|
|
1996
1996
|
automatically_manage_new_devices: boolean;
|
|
1997
1997
|
};
|
|
1998
1998
|
};
|
|
@@ -2045,6 +2045,10 @@ export interface Routes {
|
|
|
2045
2045
|
accessory_keypad?: {
|
|
2046
2046
|
/** Indicates if the accessory_keypad is connected to the device. */
|
|
2047
2047
|
is_connected: boolean;
|
|
2048
|
+
/** Indicates if the keypad battery properties. */
|
|
2049
|
+
battery?: {
|
|
2050
|
+
level: number;
|
|
2051
|
+
} | undefined;
|
|
2048
2052
|
} | undefined;
|
|
2049
2053
|
appearance: {
|
|
2050
2054
|
/** Name of the device as seen from the provider API and application, not settable through Seam. */
|
|
@@ -2513,7 +2517,7 @@ export interface Routes {
|
|
|
2513
2517
|
created_at: string;
|
|
2514
2518
|
/** Indicates whether Seam manages the device. */
|
|
2515
2519
|
is_managed: true;
|
|
2516
|
-
custom_metadata
|
|
2520
|
+
custom_metadata: Record<string, string | boolean>;
|
|
2517
2521
|
can_remotely_unlock?: boolean | undefined;
|
|
2518
2522
|
can_remotely_lock?: boolean | undefined;
|
|
2519
2523
|
can_program_online_access_codes?: boolean | undefined;
|
|
@@ -2538,7 +2542,7 @@ export interface Routes {
|
|
|
2538
2542
|
limit?: number;
|
|
2539
2543
|
created_before?: Date | undefined;
|
|
2540
2544
|
user_identifier_key?: string | undefined;
|
|
2541
|
-
custom_metadata_has?: Record<string, string | boolean
|
|
2545
|
+
custom_metadata_has?: Record<string, string | boolean> | undefined;
|
|
2542
2546
|
include_if?: Array<'can_remotely_unlock' | 'can_remotely_lock' | 'can_program_online_access_codes' | 'can_simulate_removal'> | undefined;
|
|
2543
2547
|
exclude_if?: Array<'can_remotely_unlock' | 'can_remotely_lock' | 'can_program_online_access_codes' | 'can_simulate_removal'> | undefined;
|
|
2544
2548
|
};
|
|
@@ -2570,6 +2574,10 @@ export interface Routes {
|
|
|
2570
2574
|
accessory_keypad?: {
|
|
2571
2575
|
/** Indicates if the accessory_keypad is connected to the device. */
|
|
2572
2576
|
is_connected: boolean;
|
|
2577
|
+
/** Indicates if the keypad battery properties. */
|
|
2578
|
+
battery?: {
|
|
2579
|
+
level: number;
|
|
2580
|
+
} | undefined;
|
|
2573
2581
|
} | undefined;
|
|
2574
2582
|
appearance: {
|
|
2575
2583
|
/** Name of the device as seen from the provider API and application, not settable through Seam. */
|
|
@@ -3038,7 +3046,7 @@ export interface Routes {
|
|
|
3038
3046
|
created_at: string;
|
|
3039
3047
|
/** Indicates whether Seam manages the device. */
|
|
3040
3048
|
is_managed: true;
|
|
3041
|
-
custom_metadata
|
|
3049
|
+
custom_metadata: Record<string, string | boolean>;
|
|
3042
3050
|
can_remotely_unlock?: boolean | undefined;
|
|
3043
3051
|
can_remotely_lock?: boolean | undefined;
|
|
3044
3052
|
can_program_online_access_codes?: boolean | undefined;
|
|
@@ -3183,7 +3191,7 @@ export interface Routes {
|
|
|
3183
3191
|
limit?: number;
|
|
3184
3192
|
created_before?: Date | undefined;
|
|
3185
3193
|
user_identifier_key?: string | undefined;
|
|
3186
|
-
custom_metadata_has?: Record<string, string | boolean
|
|
3194
|
+
custom_metadata_has?: Record<string, string | boolean> | undefined;
|
|
3187
3195
|
include_if?: Array<'can_remotely_unlock' | 'can_remotely_lock' | 'can_program_online_access_codes' | 'can_simulate_removal'> | undefined;
|
|
3188
3196
|
exclude_if?: Array<'can_remotely_unlock' | 'can_remotely_lock' | 'can_program_online_access_codes' | 'can_simulate_removal'> | undefined;
|
|
3189
3197
|
};
|
|
@@ -3461,6 +3469,10 @@ export interface Routes {
|
|
|
3461
3469
|
accessory_keypad?: {
|
|
3462
3470
|
/** Indicates if the accessory_keypad is connected to the device. */
|
|
3463
3471
|
is_connected: boolean;
|
|
3472
|
+
/** Indicates if the keypad battery properties. */
|
|
3473
|
+
battery?: {
|
|
3474
|
+
level: number;
|
|
3475
|
+
} | undefined;
|
|
3464
3476
|
} | undefined;
|
|
3465
3477
|
appearance: {
|
|
3466
3478
|
/** Name of the device as seen from the provider API and application, not settable through Seam. */
|
|
@@ -3929,7 +3941,7 @@ export interface Routes {
|
|
|
3929
3941
|
created_at: string;
|
|
3930
3942
|
/** Indicates whether Seam manages the device. */
|
|
3931
3943
|
is_managed: true;
|
|
3932
|
-
custom_metadata
|
|
3944
|
+
custom_metadata: Record<string, string | boolean>;
|
|
3933
3945
|
can_remotely_unlock?: boolean | undefined;
|
|
3934
3946
|
can_remotely_lock?: boolean | undefined;
|
|
3935
3947
|
can_program_online_access_codes?: boolean | undefined;
|
|
@@ -3961,6 +3973,10 @@ export interface Routes {
|
|
|
3961
3973
|
accessory_keypad?: {
|
|
3962
3974
|
/** Indicates if the accessory_keypad is connected to the device. */
|
|
3963
3975
|
is_connected: boolean;
|
|
3976
|
+
/** Indicates if the keypad battery properties. */
|
|
3977
|
+
battery?: {
|
|
3978
|
+
level: number;
|
|
3979
|
+
} | undefined;
|
|
3964
3980
|
} | undefined;
|
|
3965
3981
|
appearance: {
|
|
3966
3982
|
/** Name of the device as seen from the provider API and application, not settable through Seam. */
|
|
@@ -4429,7 +4445,7 @@ export interface Routes {
|
|
|
4429
4445
|
created_at: string;
|
|
4430
4446
|
/** Indicates whether Seam manages the device. */
|
|
4431
4447
|
is_managed: true;
|
|
4432
|
-
custom_metadata
|
|
4448
|
+
custom_metadata: Record<string, string | boolean>;
|
|
4433
4449
|
can_remotely_unlock?: boolean | undefined;
|
|
4434
4450
|
can_remotely_lock?: boolean | undefined;
|
|
4435
4451
|
can_program_online_access_codes?: boolean | undefined;
|
|
@@ -4454,7 +4470,7 @@ export interface Routes {
|
|
|
4454
4470
|
limit?: number;
|
|
4455
4471
|
created_before?: Date | undefined;
|
|
4456
4472
|
user_identifier_key?: string | undefined;
|
|
4457
|
-
custom_metadata_has?: Record<string, string | boolean
|
|
4473
|
+
custom_metadata_has?: Record<string, string | boolean> | undefined;
|
|
4458
4474
|
include_if?: Array<'can_remotely_unlock' | 'can_remotely_lock' | 'can_program_online_access_codes' | 'can_simulate_removal'> | undefined;
|
|
4459
4475
|
exclude_if?: Array<'can_remotely_unlock' | 'can_remotely_lock' | 'can_program_online_access_codes' | 'can_simulate_removal'> | undefined;
|
|
4460
4476
|
};
|
|
@@ -4486,6 +4502,10 @@ export interface Routes {
|
|
|
4486
4502
|
accessory_keypad?: {
|
|
4487
4503
|
/** Indicates if the accessory_keypad is connected to the device. */
|
|
4488
4504
|
is_connected: boolean;
|
|
4505
|
+
/** Indicates if the keypad battery properties. */
|
|
4506
|
+
battery?: {
|
|
4507
|
+
level: number;
|
|
4508
|
+
} | undefined;
|
|
4489
4509
|
} | undefined;
|
|
4490
4510
|
appearance: {
|
|
4491
4511
|
/** Name of the device as seen from the provider API and application, not settable through Seam. */
|
|
@@ -4954,7 +4974,7 @@ export interface Routes {
|
|
|
4954
4974
|
created_at: string;
|
|
4955
4975
|
/** Indicates whether Seam manages the device. */
|
|
4956
4976
|
is_managed: true;
|
|
4957
|
-
custom_metadata
|
|
4977
|
+
custom_metadata: Record<string, string | boolean>;
|
|
4958
4978
|
can_remotely_unlock?: boolean | undefined;
|
|
4959
4979
|
can_remotely_lock?: boolean | undefined;
|
|
4960
4980
|
can_program_online_access_codes?: boolean | undefined;
|
|
@@ -4986,6 +5006,10 @@ export interface Routes {
|
|
|
4986
5006
|
accessory_keypad?: {
|
|
4987
5007
|
/** Indicates if the accessory_keypad is connected to the device. */
|
|
4988
5008
|
is_connected: boolean;
|
|
5009
|
+
/** Indicates if the keypad battery properties. */
|
|
5010
|
+
battery?: {
|
|
5011
|
+
level: number;
|
|
5012
|
+
} | undefined;
|
|
4989
5013
|
} | undefined;
|
|
4990
5014
|
appearance: {
|
|
4991
5015
|
/** Name of the device as seen from the provider API and application, not settable through Seam. */
|
|
@@ -5454,7 +5478,7 @@ export interface Routes {
|
|
|
5454
5478
|
created_at: string;
|
|
5455
5479
|
/** Indicates whether Seam manages the device. */
|
|
5456
5480
|
is_managed: true;
|
|
5457
|
-
custom_metadata
|
|
5481
|
+
custom_metadata: Record<string, string | boolean>;
|
|
5458
5482
|
can_remotely_unlock?: boolean | undefined;
|
|
5459
5483
|
can_remotely_lock?: boolean | undefined;
|
|
5460
5484
|
can_program_online_access_codes?: boolean | undefined;
|
|
@@ -5809,7 +5833,7 @@ export interface Routes {
|
|
|
5809
5833
|
created_at: string;
|
|
5810
5834
|
/** Indicates whether Seam manages the device. */
|
|
5811
5835
|
is_managed: true;
|
|
5812
|
-
custom_metadata
|
|
5836
|
+
custom_metadata: Record<string, string | boolean>;
|
|
5813
5837
|
can_remotely_unlock?: boolean | undefined;
|
|
5814
5838
|
can_remotely_lock?: boolean | undefined;
|
|
5815
5839
|
can_program_online_access_codes?: boolean | undefined;
|
|
@@ -5884,7 +5908,7 @@ export interface Routes {
|
|
|
5884
5908
|
created_at: string;
|
|
5885
5909
|
/** Indicates whether Seam manages the device. */
|
|
5886
5910
|
is_managed: true;
|
|
5887
|
-
custom_metadata
|
|
5911
|
+
custom_metadata: Record<string, string | boolean>;
|
|
5888
5912
|
can_remotely_unlock?: boolean | undefined;
|
|
5889
5913
|
can_remotely_lock?: boolean | undefined;
|
|
5890
5914
|
can_program_online_access_codes?: boolean | undefined;
|
|
@@ -6127,6 +6151,10 @@ export interface Routes {
|
|
|
6127
6151
|
accessory_keypad?: {
|
|
6128
6152
|
/** Indicates if the accessory_keypad is connected to the device. */
|
|
6129
6153
|
is_connected: boolean;
|
|
6154
|
+
/** Indicates if the keypad battery properties. */
|
|
6155
|
+
battery?: {
|
|
6156
|
+
level: number;
|
|
6157
|
+
} | undefined;
|
|
6130
6158
|
} | undefined;
|
|
6131
6159
|
appearance: {
|
|
6132
6160
|
/** Name of the device as seen from the provider API and application, not settable through Seam. */
|
|
@@ -6595,7 +6623,7 @@ export interface Routes {
|
|
|
6595
6623
|
created_at: string;
|
|
6596
6624
|
/** Indicates whether Seam manages the device. */
|
|
6597
6625
|
is_managed: true;
|
|
6598
|
-
custom_metadata
|
|
6626
|
+
custom_metadata: Record<string, string | boolean>;
|
|
6599
6627
|
can_remotely_unlock?: boolean | undefined;
|
|
6600
6628
|
can_remotely_lock?: boolean | undefined;
|
|
6601
6629
|
can_program_online_access_codes?: boolean | undefined;
|
|
@@ -6696,7 +6724,7 @@ export interface Routes {
|
|
|
6696
6724
|
limit?: number;
|
|
6697
6725
|
created_before?: Date | undefined;
|
|
6698
6726
|
user_identifier_key?: string | undefined;
|
|
6699
|
-
custom_metadata_has?: Record<string, string | boolean
|
|
6727
|
+
custom_metadata_has?: Record<string, string | boolean> | undefined;
|
|
6700
6728
|
include_if?: Array<'can_remotely_unlock' | 'can_remotely_lock' | 'can_program_online_access_codes' | 'can_simulate_removal'> | undefined;
|
|
6701
6729
|
exclude_if?: Array<'can_remotely_unlock' | 'can_remotely_lock' | 'can_program_online_access_codes' | 'can_simulate_removal'> | undefined;
|
|
6702
6730
|
};
|
|
@@ -6728,6 +6756,10 @@ export interface Routes {
|
|
|
6728
6756
|
accessory_keypad?: {
|
|
6729
6757
|
/** Indicates if the accessory_keypad is connected to the device. */
|
|
6730
6758
|
is_connected: boolean;
|
|
6759
|
+
/** Indicates if the keypad battery properties. */
|
|
6760
|
+
battery?: {
|
|
6761
|
+
level: number;
|
|
6762
|
+
} | undefined;
|
|
6731
6763
|
} | undefined;
|
|
6732
6764
|
appearance: {
|
|
6733
6765
|
/** Name of the device as seen from the provider API and application, not settable through Seam. */
|
|
@@ -7196,7 +7228,7 @@ export interface Routes {
|
|
|
7196
7228
|
created_at: string;
|
|
7197
7229
|
/** Indicates whether Seam manages the device. */
|
|
7198
7230
|
is_managed: true;
|
|
7199
|
-
custom_metadata
|
|
7231
|
+
custom_metadata: Record<string, string | boolean>;
|
|
7200
7232
|
can_remotely_unlock?: boolean | undefined;
|
|
7201
7233
|
can_remotely_lock?: boolean | undefined;
|
|
7202
7234
|
can_program_online_access_codes?: boolean | undefined;
|
|
@@ -7512,6 +7544,10 @@ export interface Routes {
|
|
|
7512
7544
|
accessory_keypad?: {
|
|
7513
7545
|
/** Indicates if the accessory_keypad is connected to the device. */
|
|
7514
7546
|
is_connected: boolean;
|
|
7547
|
+
/** Indicates if the keypad battery properties. */
|
|
7548
|
+
battery?: {
|
|
7549
|
+
level: number;
|
|
7550
|
+
} | undefined;
|
|
7515
7551
|
} | undefined;
|
|
7516
7552
|
appearance: {
|
|
7517
7553
|
/** Name of the device as seen from the provider API and application, not settable through Seam. */
|
|
@@ -7980,7 +8016,7 @@ export interface Routes {
|
|
|
7980
8016
|
created_at: string;
|
|
7981
8017
|
/** Indicates whether Seam manages the device. */
|
|
7982
8018
|
is_managed: true;
|
|
7983
|
-
custom_metadata
|
|
8019
|
+
custom_metadata: Record<string, string | boolean>;
|
|
7984
8020
|
can_remotely_unlock?: boolean | undefined;
|
|
7985
8021
|
can_remotely_lock?: boolean | undefined;
|
|
7986
8022
|
can_program_online_access_codes?: boolean | undefined;
|
package/package.json
CHANGED
|
@@ -1,32 +1,2 @@
|
|
|
1
|
-
export type {
|
|
2
|
-
|
|
3
|
-
AcsAccessGroup,
|
|
4
|
-
AcsAccessGroupExternalType,
|
|
5
|
-
AcsCredential,
|
|
6
|
-
AcsCredentialExternalType,
|
|
7
|
-
AcsCredentialPool,
|
|
8
|
-
AcsCredentialPoolExternalType,
|
|
9
|
-
AcsEntranceLatchMetadata,
|
|
10
|
-
AcsSystem,
|
|
11
|
-
AcsSystemExternalType,
|
|
12
|
-
AcsUser,
|
|
13
|
-
AcsUserExternalType,
|
|
14
|
-
AnyDeviceType,
|
|
15
|
-
BatteryStatus,
|
|
16
|
-
Capabilities,
|
|
17
|
-
ClimateSetting,
|
|
18
|
-
ConnectWebview,
|
|
19
|
-
CustomMetadata,
|
|
20
|
-
ManagedDevice as Device,
|
|
21
|
-
DeviceMetadata,
|
|
22
|
-
FanModeSetting,
|
|
23
|
-
HvacModeSetting,
|
|
24
|
-
LockDeviceType,
|
|
25
|
-
ManagedAccessCode,
|
|
26
|
-
ManagedDevice,
|
|
27
|
-
ManagedDeviceWithBackendMetadata,
|
|
28
|
-
NoiseSensorDeviceType,
|
|
29
|
-
ThermostatDeviceType,
|
|
30
|
-
UnmanagedAccessCode,
|
|
31
|
-
UnmanagedDevice,
|
|
32
|
-
} from '../models/index.js'
|
|
1
|
+
export type { ManagedDevice as Device } from '../models/index.js'
|
|
2
|
+
export * from '../models/index.js'
|
|
@@ -20,8 +20,7 @@ export {
|
|
|
20
20
|
climate_setting,
|
|
21
21
|
climate_setting_schedule,
|
|
22
22
|
common_device_properties,
|
|
23
|
-
|
|
24
|
-
custom_metadata,
|
|
23
|
+
custom_metadata_input,
|
|
25
24
|
device_capability_flags,
|
|
26
25
|
dormakaba_oracode_time_slot,
|
|
27
26
|
enrollment_automation,
|
|
@@ -39,3 +38,4 @@ export {
|
|
|
39
38
|
unmanaged_device,
|
|
40
39
|
user_identity,
|
|
41
40
|
} from '../models/index.js'
|
|
41
|
+
export * from '../schemas.js'
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { z } from 'zod'
|
|
2
2
|
|
|
3
|
-
export const
|
|
3
|
+
export const custom_metadata_input = z
|
|
4
4
|
.record(
|
|
5
5
|
z.string().max(40),
|
|
6
6
|
z.union([z.string().max(500), z.boolean(), z.null()]),
|
|
@@ -9,4 +9,11 @@ export const custom_metadata = z
|
|
|
9
9
|
message: 'Custom metadata is limited to a maximum of 50 keys',
|
|
10
10
|
})
|
|
11
11
|
|
|
12
|
-
export
|
|
12
|
+
export const custom_metadata = z.record(
|
|
13
|
+
z.string(),
|
|
14
|
+
z.union([z.string(), z.boolean()]),
|
|
15
|
+
)
|
|
16
|
+
|
|
17
|
+
export type CustomMetadata = z.output<typeof custom_metadata>
|
|
18
|
+
|
|
19
|
+
export type CustomMetadataInput = z.input<typeof custom_metadata_input>
|
|
@@ -34,6 +34,12 @@ export const common_device_properties = z.object({
|
|
|
34
34
|
.describe(
|
|
35
35
|
'Indicates if the accessory_keypad is connected to the device.',
|
|
36
36
|
),
|
|
37
|
+
battery: z
|
|
38
|
+
.object({
|
|
39
|
+
level: z.number().min(0).max(1),
|
|
40
|
+
})
|
|
41
|
+
.optional()
|
|
42
|
+
.describe('Indicates if the keypad battery properties.'),
|
|
37
43
|
})
|
|
38
44
|
.optional()
|
|
39
45
|
.describe('Represents the accessory keypad state.'),
|
|
@@ -218,7 +224,7 @@ export const managed_device = z
|
|
|
218
224
|
is_managed: z
|
|
219
225
|
.literal(true)
|
|
220
226
|
.describe('Indicates whether Seam manages the device.'),
|
|
221
|
-
custom_metadata
|
|
227
|
+
custom_metadata,
|
|
222
228
|
})
|
|
223
229
|
.merge(device_capability_flags)
|
|
224
230
|
|
|
@@ -438,12 +438,7 @@ export default {
|
|
|
438
438
|
created_at: { format: 'date-time', type: 'string' },
|
|
439
439
|
custom_metadata: {
|
|
440
440
|
additionalProperties: {
|
|
441
|
-
|
|
442
|
-
oneOf: [
|
|
443
|
-
{ maxLength: 500, type: 'string' },
|
|
444
|
-
{ type: 'boolean' },
|
|
445
|
-
{ format: 'null', nullable: true, type: 'string' },
|
|
446
|
-
],
|
|
441
|
+
oneOf: [{ type: 'string' }, { type: 'boolean' }],
|
|
447
442
|
},
|
|
448
443
|
type: 'object',
|
|
449
444
|
},
|
|
@@ -499,12 +494,7 @@ export default {
|
|
|
499
494
|
created_at: { format: 'date-time', type: 'string' },
|
|
500
495
|
custom_metadata: {
|
|
501
496
|
additionalProperties: {
|
|
502
|
-
|
|
503
|
-
oneOf: [
|
|
504
|
-
{ maxLength: 500, type: 'string' },
|
|
505
|
-
{ type: 'boolean' },
|
|
506
|
-
{ format: 'null', nullable: true, type: 'string' },
|
|
507
|
-
],
|
|
497
|
+
oneOf: [{ type: 'string' }, { type: 'boolean' }],
|
|
508
498
|
},
|
|
509
499
|
type: 'object',
|
|
510
500
|
},
|
|
@@ -523,6 +513,7 @@ export default {
|
|
|
523
513
|
},
|
|
524
514
|
required: [
|
|
525
515
|
'account_type_display_name',
|
|
516
|
+
'custom_metadata',
|
|
526
517
|
'automatically_manage_new_devices',
|
|
527
518
|
],
|
|
528
519
|
type: 'object',
|
|
@@ -563,12 +554,7 @@ export default {
|
|
|
563
554
|
},
|
|
564
555
|
custom_metadata: {
|
|
565
556
|
additionalProperties: {
|
|
566
|
-
|
|
567
|
-
oneOf: [
|
|
568
|
-
{ maxLength: 500, type: 'string' },
|
|
569
|
-
{ type: 'boolean' },
|
|
570
|
-
{ format: 'null', nullable: true, type: 'string' },
|
|
571
|
-
],
|
|
557
|
+
oneOf: [{ type: 'string' }, { type: 'boolean' }],
|
|
572
558
|
},
|
|
573
559
|
type: 'object',
|
|
574
560
|
},
|
|
@@ -681,6 +667,19 @@ export default {
|
|
|
681
667
|
description:
|
|
682
668
|
'Represents the accessory keypad state.',
|
|
683
669
|
properties: {
|
|
670
|
+
battery: {
|
|
671
|
+
description:
|
|
672
|
+
'Indicates if the keypad battery properties.',
|
|
673
|
+
properties: {
|
|
674
|
+
level: {
|
|
675
|
+
maximum: 1,
|
|
676
|
+
minimum: 0,
|
|
677
|
+
type: 'number',
|
|
678
|
+
},
|
|
679
|
+
},
|
|
680
|
+
required: ['level'],
|
|
681
|
+
type: 'object',
|
|
682
|
+
},
|
|
684
683
|
is_connected: {
|
|
685
684
|
description:
|
|
686
685
|
'Indicates if the accessory_keypad is connected to the device.',
|
|
@@ -1778,6 +1777,7 @@ export default {
|
|
|
1778
1777
|
'warnings',
|
|
1779
1778
|
'created_at',
|
|
1780
1779
|
'is_managed',
|
|
1780
|
+
'custom_metadata',
|
|
1781
1781
|
],
|
|
1782
1782
|
type: 'object',
|
|
1783
1783
|
},
|
|
@@ -1934,12 +1934,7 @@ export default {
|
|
|
1934
1934
|
},
|
|
1935
1935
|
custom_metadata: {
|
|
1936
1936
|
additionalProperties: {
|
|
1937
|
-
|
|
1938
|
-
oneOf: [
|
|
1939
|
-
{ maxLength: 500, type: 'string' },
|
|
1940
|
-
{ type: 'boolean' },
|
|
1941
|
-
{ format: 'null', nullable: true, type: 'string' },
|
|
1942
|
-
],
|
|
1937
|
+
oneOf: [{ type: 'string' }, { type: 'boolean' }],
|
|
1943
1938
|
},
|
|
1944
1939
|
type: 'object',
|
|
1945
1940
|
},
|
|
@@ -2047,6 +2042,7 @@ export default {
|
|
|
2047
2042
|
'warnings',
|
|
2048
2043
|
'created_at',
|
|
2049
2044
|
'is_managed',
|
|
2045
|
+
'custom_metadata',
|
|
2050
2046
|
],
|
|
2051
2047
|
type: 'object',
|
|
2052
2048
|
},
|
|
@@ -7399,12 +7395,7 @@ export default {
|
|
|
7399
7395
|
properties: {
|
|
7400
7396
|
custom_metadata_has: {
|
|
7401
7397
|
additionalProperties: {
|
|
7402
|
-
|
|
7403
|
-
oneOf: [
|
|
7404
|
-
{ maxLength: 500, type: 'string' },
|
|
7405
|
-
{ type: 'boolean' },
|
|
7406
|
-
{ format: 'null', nullable: true, type: 'string' },
|
|
7407
|
-
],
|
|
7398
|
+
oneOf: [{ type: 'string' }, { type: 'boolean' }],
|
|
7408
7399
|
},
|
|
7409
7400
|
description:
|
|
7410
7401
|
"Returns devices where the webview's custom_metadata contains all of the provided key/value pairs.",
|
|
@@ -7591,12 +7582,7 @@ export default {
|
|
|
7591
7582
|
properties: {
|
|
7592
7583
|
custom_metadata_has: {
|
|
7593
7584
|
additionalProperties: {
|
|
7594
|
-
|
|
7595
|
-
oneOf: [
|
|
7596
|
-
{ maxLength: 500, type: 'string' },
|
|
7597
|
-
{ type: 'boolean' },
|
|
7598
|
-
{ format: 'null', nullable: true, type: 'string' },
|
|
7599
|
-
],
|
|
7585
|
+
oneOf: [{ type: 'string' }, { type: 'boolean' }],
|
|
7600
7586
|
},
|
|
7601
7587
|
description:
|
|
7602
7588
|
"Returns devices where the account's custom_metadata contains all of the provided key/value pairs.",
|
|
@@ -7818,12 +7804,7 @@ export default {
|
|
|
7818
7804
|
},
|
|
7819
7805
|
custom_metadata_has: {
|
|
7820
7806
|
additionalProperties: {
|
|
7821
|
-
|
|
7822
|
-
oneOf: [
|
|
7823
|
-
{ maxLength: 500, type: 'string' },
|
|
7824
|
-
{ type: 'boolean' },
|
|
7825
|
-
{ format: 'null', nullable: true, type: 'string' },
|
|
7826
|
-
],
|
|
7807
|
+
oneOf: [{ type: 'string' }, { type: 'boolean' }],
|
|
7827
7808
|
},
|
|
7828
7809
|
type: 'object',
|
|
7829
7810
|
},
|
|
@@ -8212,12 +8193,7 @@ export default {
|
|
|
8212
8193
|
},
|
|
8213
8194
|
custom_metadata_has: {
|
|
8214
8195
|
additionalProperties: {
|
|
8215
|
-
|
|
8216
|
-
oneOf: [
|
|
8217
|
-
{ maxLength: 500, type: 'string' },
|
|
8218
|
-
{ type: 'boolean' },
|
|
8219
|
-
{ format: 'null', nullable: true, type: 'string' },
|
|
8220
|
-
],
|
|
8196
|
+
oneOf: [{ type: 'string' }, { type: 'boolean' }],
|
|
8221
8197
|
},
|
|
8222
8198
|
type: 'object',
|
|
8223
8199
|
},
|
|
@@ -9174,12 +9150,7 @@ export default {
|
|
|
9174
9150
|
},
|
|
9175
9151
|
custom_metadata_has: {
|
|
9176
9152
|
additionalProperties: {
|
|
9177
|
-
|
|
9178
|
-
oneOf: [
|
|
9179
|
-
{ maxLength: 500, type: 'string' },
|
|
9180
|
-
{ type: 'boolean' },
|
|
9181
|
-
{ format: 'null', nullable: true, type: 'string' },
|
|
9182
|
-
],
|
|
9153
|
+
oneOf: [{ type: 'string' }, { type: 'boolean' }],
|
|
9183
9154
|
},
|
|
9184
9155
|
type: 'object',
|
|
9185
9156
|
},
|
|
@@ -10909,12 +10880,7 @@ export default {
|
|
|
10909
10880
|
},
|
|
10910
10881
|
custom_metadata_has: {
|
|
10911
10882
|
additionalProperties: {
|
|
10912
|
-
|
|
10913
|
-
oneOf: [
|
|
10914
|
-
{ maxLength: 500, type: 'string' },
|
|
10915
|
-
{ type: 'boolean' },
|
|
10916
|
-
{ format: 'null', nullable: true, type: 'string' },
|
|
10917
|
-
],
|
|
10883
|
+
oneOf: [{ type: 'string' }, { type: 'boolean' }],
|
|
10918
10884
|
},
|
|
10919
10885
|
type: 'object',
|
|
10920
10886
|
},
|