Skip to content

Commit fa60fb4

Browse files
authored
feat: Sync with Seam API via b6c2b7fe7638be8a77fc4a93912d3630b6de0248 (#2555)
1 parent a2de749 commit fa60fb4

File tree

4 files changed

+270
-0
lines changed

4 files changed

+270
-0
lines changed

src/lib/seam/connect/models/devices/device-metadata.ts

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -681,6 +681,12 @@ export const device_metadata = z
681681
has_photo: z
682682
.boolean()
683683
.describe(`Whether the KeyNest device has a photo.`),
684+
is_quadient_locker: z
685+
.boolean()
686+
.optional()
687+
.describe(
688+
`Whether the key is in a locker that does not support the access codes API.`,
689+
),
684690
})
685691
.partial()
686692
.describe(`Metadata for a KeyNest device.`),

src/lib/seam/connect/models/devices/device.ts

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -431,6 +431,17 @@ const hub_required_for_addtional_capabilities = common_device_warning.extend({
431431
Indicates that a hub or relay must be connected to unlock additional capabilities such as remote unlock.
432432
`)
433433

434+
const keynest_unsupported_locker = common_device_warning.extend({
435+
warning_code: z
436+
.literal('keynest_unsupported_locker')
437+
.describe(warning_code_description),
438+
}).describe(`
439+
---
440+
variant_group_key: locks
441+
---
442+
Indicates that the key is in a locker that does not support the access codes API.
443+
`)
444+
434445
const device_warning = z.discriminatedUnion('warning_code', [
435446
partial_backup_access_code_pool,
436447
many_active_backup_codes,
@@ -450,6 +461,7 @@ const device_warning = z.discriminatedUnion('warning_code', [
450461
unknown_issue_with_phone,
451462
lockly_time_zone_not_configured,
452463
hub_required_for_addtional_capabilities,
464+
keynest_unsupported_locker,
453465
])
454466

455467
export type DeviceWarning = z.infer<typeof device_warning>
@@ -496,6 +508,7 @@ const _device_warning_map = z.object({
496508
.nullable(),
497509
hub_required_for_addtional_capabilities:
498510
hub_required_for_addtional_capabilities.optional().nullable(),
511+
keynest_unsupported_locker: keynest_unsupported_locker.optional().nullable(),
499512
})
500513

501514
export type DeviceWarningMap = z.infer<typeof _device_warning_map>

src/lib/seam/connect/openapi.ts

Lines changed: 57 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11105,6 +11105,11 @@ export default {
1110511105
'Whether the KeyNest device has a photo.',
1110611106
type: 'boolean',
1110711107
},
11108+
is_quadient_locker: {
11109+
description:
11110+
'Whether the key is in a locker that does not support the access codes API.',
11111+
type: 'boolean',
11112+
},
1110811113
key_id: {
1110911114
description: 'Key ID for a KeyNest device.',
1111011115
type: 'string',
@@ -13324,6 +13329,32 @@ export default {
1332413329
type: 'object',
1332513330
'x-variant-group-key': 'locks',
1332613331
},
13332+
{
13333+
description:
13334+
'Indicates that the key is in a locker that does not support the access codes API.',
13335+
properties: {
13336+
created_at: {
13337+
description:
13338+
'Date and time at which Seam created the warning.',
13339+
format: 'date-time',
13340+
type: 'string',
13341+
},
13342+
message: {
13343+
description:
13344+
'Detailed description of the warning. Provides insights into the issue and potentially how to rectify it.',
13345+
type: 'string',
13346+
},
13347+
warning_code: {
13348+
description:
13349+
'Unique identifier of the type of warning. Enables quick recognition and categorization of the issue.',
13350+
enum: ['keynest_unsupported_locker'],
13351+
type: 'string',
13352+
},
13353+
},
13354+
required: ['message', 'created_at', 'warning_code'],
13355+
type: 'object',
13356+
'x-variant-group-key': 'locks',
13357+
},
1332713358
],
1332813359
},
1332913360
type: 'array',
@@ -25858,6 +25889,32 @@ export default {
2585825889
type: 'object',
2585925890
'x-variant-group-key': 'locks',
2586025891
},
25892+
{
25893+
description:
25894+
'Indicates that the key is in a locker that does not support the access codes API.',
25895+
properties: {
25896+
created_at: {
25897+
description:
25898+
'Date and time at which Seam created the warning.',
25899+
format: 'date-time',
25900+
type: 'string',
25901+
},
25902+
message: {
25903+
description:
25904+
'Detailed description of the warning. Provides insights into the issue and potentially how to rectify it.',
25905+
type: 'string',
25906+
},
25907+
warning_code: {
25908+
description:
25909+
'Unique identifier of the type of warning. Enables quick recognition and categorization of the issue.',
25910+
enum: ['keynest_unsupported_locker'],
25911+
type: 'string',
25912+
},
25913+
},
25914+
required: ['message', 'created_at', 'warning_code'],
25915+
type: 'object',
25916+
'x-variant-group-key': 'locks',
25917+
},
2586125918
],
2586225919
},
2586325920
type: 'array',

0 commit comments

Comments
 (0)