@seamapi/types 1.240.0 → 1.242.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 +1592 -904
- package/dist/connect.cjs.map +1 -1
- package/dist/connect.d.cts +3728 -1455
- package/dist/devicedb.d.cts +30 -30
- package/lib/seam/connect/internal/schemas.d.ts +1 -1
- package/lib/seam/connect/internal/schemas.js +1 -1
- package/lib/seam/connect/internal/schemas.js.map +1 -1
- package/lib/seam/connect/model-types.d.ts +1 -1
- package/lib/seam/connect/models/access-codes/managed-access-code.d.ts +4 -4
- package/lib/seam/connect/models/access-codes/unmanaged-access-code.d.ts +1 -1
- package/lib/seam/connect/models/acs/acs-user.d.ts +316 -84
- package/lib/seam/connect/models/acs/acs-user.js +72 -22
- package/lib/seam/connect/models/acs/acs-user.js.map +1 -1
- package/lib/seam/connect/models/action-attempts/action-attempt.d.ts +78 -0
- package/lib/seam/connect/models/action-attempts/action-attempt.js +2 -0
- package/lib/seam/connect/models/action-attempts/action-attempt.js.map +1 -1
- package/lib/seam/connect/models/action-attempts/activate-climate-preset.d.ts +80 -0
- package/lib/seam/connect/models/action-attempts/activate-climate-preset.js +25 -0
- package/lib/seam/connect/models/action-attempts/activate-climate-preset.js.map +1 -0
- package/lib/seam/connect/models/devices/capability-properties/index.d.ts +185 -83
- package/lib/seam/connect/models/devices/capability-properties/thermostat.d.ts +185 -83
- package/lib/seam/connect/models/devices/capability-properties/thermostat.js +15 -6
- package/lib/seam/connect/models/devices/capability-properties/thermostat.js.map +1 -1
- package/lib/seam/connect/models/devices/device.d.ts +263 -119
- package/lib/seam/connect/models/devices/phone.d.ts +187 -85
- package/lib/seam/connect/models/devices/unmanaged-device.d.ts +185 -83
- package/lib/seam/connect/models/thermostats/climate-preset.d.ts +83 -0
- package/lib/seam/connect/models/thermostats/climate-preset.js +18 -0
- package/lib/seam/connect/models/thermostats/climate-preset.js.map +1 -0
- package/lib/seam/connect/models/thermostats/climate-setting-schedule.d.ts +18 -34
- package/lib/seam/connect/models/thermostats/climate-setting-schedule.js +8 -10
- package/lib/seam/connect/models/thermostats/climate-setting-schedule.js.map +1 -1
- package/lib/seam/connect/models/thermostats/index.d.ts +1 -1
- package/lib/seam/connect/models/thermostats/index.js +1 -1
- package/lib/seam/connect/models/thermostats/index.js.map +1 -1
- package/lib/seam/connect/openapi.d.ts +1019 -570
- package/lib/seam/connect/openapi.js +1334 -723
- package/lib/seam/connect/openapi.js.map +1 -1
- package/lib/seam/connect/route-types.d.ts +1824 -476
- package/lib/seam/connect/schemas.d.ts +1 -1
- package/lib/seam/connect/schemas.js +1 -1
- package/lib/seam/connect/schemas.js.map +1 -1
- package/lib/seam/devicedb/models/device-model.d.ts +8 -8
- package/lib/seam/devicedb/models/manufacturer.d.ts +2 -2
- package/lib/seam/devicedb/route-specs.d.ts +20 -20
- package/package.json +2 -2
- package/src/lib/seam/connect/internal/schemas.ts +2 -2
- package/src/lib/seam/connect/model-types.ts +1 -1
- package/src/lib/seam/connect/models/acs/acs-user.ts +100 -27
- package/src/lib/seam/connect/models/action-attempts/action-attempt.ts +2 -0
- package/src/lib/seam/connect/models/action-attempts/activate-climate-preset.ts +36 -0
- package/src/lib/seam/connect/models/devices/capability-properties/thermostat.ts +16 -6
- package/src/lib/seam/connect/models/thermostats/climate-preset.ts +24 -0
- package/src/lib/seam/connect/models/thermostats/climate-setting-schedule.ts +16 -19
- package/src/lib/seam/connect/models/thermostats/index.ts +1 -1
- package/src/lib/seam/connect/openapi.ts +1385 -708
- package/src/lib/seam/connect/route-types.ts +2122 -520
- package/src/lib/seam/connect/schemas.ts +1 -1
- package/lib/seam/connect/models/thermostats/climate-setting.d.ts +0 -24
- package/lib/seam/connect/models/thermostats/climate-setting.js +0 -11
- package/lib/seam/connect/models/thermostats/climate-setting.js.map +0 -1
- package/src/lib/seam/connect/models/thermostats/climate-setting.ts +0 -14
|
@@ -8,39 +8,89 @@ export const acs_user_external_type = z.enum([
|
|
|
8
8
|
'salto_site_user',
|
|
9
9
|
'latch_user',
|
|
10
10
|
]);
|
|
11
|
-
const
|
|
11
|
+
const common_acs_user_error = z.object({
|
|
12
|
+
created_at: z
|
|
13
|
+
.string()
|
|
14
|
+
.datetime()
|
|
15
|
+
.describe('Date and time at which Seam created the error.'),
|
|
16
|
+
message: z
|
|
17
|
+
.string()
|
|
18
|
+
.describe('Detailed description of the error. Provides insights into the issue and potentially how to rectify it.'),
|
|
19
|
+
});
|
|
20
|
+
const acs_users_deleted_externally = common_acs_user_error
|
|
21
|
+
.extend({
|
|
22
|
+
error_code: z.literal('deleted_externally'),
|
|
23
|
+
})
|
|
24
|
+
.describe(`Indicates that the ACS user was deleted from the ACS system outside of Seam.`);
|
|
25
|
+
const acs_users_salto_ks_subscription_limit_exceeded = common_acs_user_error
|
|
26
|
+
.extend({
|
|
27
|
+
error_code: z.literal('salto_ks_subscription_limit_exceeded'),
|
|
28
|
+
})
|
|
29
|
+
.describe(`Indicates that the user could not be subscribed on Salto KS because the subscription limit has been exceeded.`);
|
|
30
|
+
const acs_users_failed_to_create_on_acs_system = common_acs_user_error
|
|
31
|
+
.extend({
|
|
32
|
+
warning_code: z.literal('failed_to_create_on_acs_system'),
|
|
33
|
+
})
|
|
34
|
+
.describe(`Indicates that the user was not created on the ACS system. This is likely due to an internal unexpected error. Please contact Seam's support if you encounter this.`);
|
|
35
|
+
const acs_users_failed_to_update_on_acs_system = common_acs_user_error
|
|
36
|
+
.extend({
|
|
37
|
+
warning_code: z.literal('failed_to_update_on_acs_system'),
|
|
38
|
+
})
|
|
39
|
+
.describe(`Indicates that the user was not updated on the ACS system. This is likely due to an internal unexpected error. Please contact Seam's support if you encounter this.`);
|
|
40
|
+
const acs_users_failed_to_delete_on_acs_system = common_acs_user_error
|
|
41
|
+
.extend({
|
|
42
|
+
warning_code: z.literal('failed_to_delete_on_acs_system'),
|
|
43
|
+
})
|
|
44
|
+
.describe(`Indicates that the user was not deleted on the ACS system. This is likely due to an internal unexpected error. Please contact Seam's support if you encounter this.`);
|
|
45
|
+
const acs_user_errors = z
|
|
46
|
+
.union([
|
|
47
|
+
acs_users_deleted_externally,
|
|
48
|
+
acs_users_salto_ks_subscription_limit_exceeded,
|
|
49
|
+
acs_users_failed_to_create_on_acs_system,
|
|
50
|
+
acs_users_failed_to_update_on_acs_system,
|
|
51
|
+
acs_users_failed_to_delete_on_acs_system,
|
|
52
|
+
])
|
|
53
|
+
.describe('Error associated with the `acs_user`.');
|
|
54
|
+
export const acs_users_error_map = z.object({
|
|
55
|
+
deleted_externally: acs_users_deleted_externally.optional().nullable(),
|
|
56
|
+
salto_ks_subscription_limit_exceeded: acs_users_salto_ks_subscription_limit_exceeded.optional().nullable(),
|
|
57
|
+
failed_to_create_on_acs_system: acs_users_failed_to_create_on_acs_system
|
|
58
|
+
.optional()
|
|
59
|
+
.nullable(),
|
|
60
|
+
failed_to_update_on_acs_system: acs_users_failed_to_update_on_acs_system
|
|
61
|
+
.optional()
|
|
62
|
+
.nullable(),
|
|
63
|
+
failed_to_delete_on_acs_system: acs_users_failed_to_delete_on_acs_system
|
|
64
|
+
.optional()
|
|
65
|
+
.nullable(),
|
|
66
|
+
});
|
|
67
|
+
const common_acs_user_warning = z.object({
|
|
12
68
|
created_at: z.string().datetime(),
|
|
13
69
|
message: z.string(),
|
|
14
70
|
});
|
|
15
|
-
const acs_users_being_deleted =
|
|
71
|
+
const acs_users_being_deleted = common_acs_user_warning
|
|
72
|
+
.extend({
|
|
16
73
|
warning_code: z.literal('being_deleted'),
|
|
17
|
-
})
|
|
18
|
-
|
|
74
|
+
})
|
|
75
|
+
.describe(`Indicates that the user is being deleted from the ACS system. This is a temporary state, and the user will be deleted shortly.`);
|
|
76
|
+
const acs_users_salto_ks_user_not_subscribed = common_acs_user_warning
|
|
77
|
+
.extend({
|
|
19
78
|
warning_code: z.literal('salto_ks_user_not_subscribed'),
|
|
20
|
-
})
|
|
21
|
-
|
|
22
|
-
warning_code: z.literal('failed_to_update_acs_user_on_acs_system'),
|
|
23
|
-
});
|
|
24
|
-
// TODO: Some acs_users already have this warning, so we need to keep it here until we migrate
|
|
25
|
-
const acs_users_salto_site_user_suspended = common_acs_users_warning.extend({
|
|
26
|
-
warning_code: z.literal('salto_site_user_suspended'),
|
|
27
|
-
});
|
|
79
|
+
})
|
|
80
|
+
.describe(`Indicates that the user is not subscribed on the Salto KS, so they cannot unlock doors or perform any actions. This occur when the their access schedule hasn’t started yet, or if their access schedule has ended, or if the site has reached its limit for active users (subscription slots), or if they have been manually unsubscribed.`);
|
|
28
81
|
export const acs_users_warning_map = z.object({
|
|
29
82
|
being_deleted: acs_users_being_deleted.optional().nullable(),
|
|
30
|
-
failed_to_update_acs_user_on_acs_system: acs_users_failed_to_update_acs_user_on_acs_system.optional().nullable(),
|
|
31
83
|
salto_ks_user_not_subscribed: acs_users_salto_ks_user_not_subscribed
|
|
32
84
|
.optional()
|
|
33
85
|
.nullable(),
|
|
34
|
-
salto_site_user_suspended: acs_users_salto_site_user_suspended
|
|
35
|
-
.optional()
|
|
36
|
-
.nullable(),
|
|
37
86
|
});
|
|
38
|
-
export const
|
|
87
|
+
export const acs_users_warnings = z
|
|
88
|
+
.union([
|
|
39
89
|
acs_users_being_deleted,
|
|
40
|
-
|
|
90
|
+
acs_users_failed_to_update_on_acs_system,
|
|
41
91
|
acs_users_salto_ks_user_not_subscribed,
|
|
42
|
-
|
|
43
|
-
|
|
92
|
+
])
|
|
93
|
+
.describe('Warning associated with the `acs_user`.');
|
|
44
94
|
const user_fields = z.object({
|
|
45
95
|
full_name: z.string().optional(),
|
|
46
96
|
email: z.string().email().optional().describe(`
|
|
@@ -72,8 +122,8 @@ const common_acs_user = z
|
|
|
72
122
|
.datetime()
|
|
73
123
|
.optional(),
|
|
74
124
|
is_latest_desired_state_synced_with_provider: z.boolean().optional(),
|
|
75
|
-
warnings: z.array(
|
|
76
|
-
errors: z.
|
|
125
|
+
warnings: z.array(acs_users_warnings),
|
|
126
|
+
errors: z.array(acs_user_errors),
|
|
77
127
|
})
|
|
78
128
|
.merge(user_fields);
|
|
79
129
|
export const acs_user = common_acs_user.merge(z.object({
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"acs-user.js","sourceRoot":"","sources":["../../../../../src/lib/seam/connect/models/acs/acs-user.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AAEvB,OAAO,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAA;AACjD,OAAO,EAAE,QAAQ,EAAE,MAAM,gBAAgB,CAAA;AAEzC,MAAM,CAAC,MAAM,sBAAsB,GAAG,CAAC,CAAC,IAAI,CAAC;IAC3C,UAAU;IACV,YAAY;IACZ,6BAA6B;IAC7B,iBAAiB;IACjB,YAAY;CACb,CAAC,CAAA;AAIF,MAAM,
|
|
1
|
+
{"version":3,"file":"acs-user.js","sourceRoot":"","sources":["../../../../../src/lib/seam/connect/models/acs/acs-user.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AAEvB,OAAO,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAA;AACjD,OAAO,EAAE,QAAQ,EAAE,MAAM,gBAAgB,CAAA;AAEzC,MAAM,CAAC,MAAM,sBAAsB,GAAG,CAAC,CAAC,IAAI,CAAC;IAC3C,UAAU;IACV,YAAY;IACZ,6BAA6B;IAC7B,iBAAiB;IACjB,YAAY;CACb,CAAC,CAAA;AAIF,MAAM,qBAAqB,GAAG,CAAC,CAAC,MAAM,CAAC;IACrC,UAAU,EAAE,CAAC;SACV,MAAM,EAAE;SACR,QAAQ,EAAE;SACV,QAAQ,CAAC,gDAAgD,CAAC;IAC7D,OAAO,EAAE,CAAC;SACP,MAAM,EAAE;SACR,QAAQ,CACP,wGAAwG,CACzG;CACJ,CAAC,CAAA;AAEF,MAAM,4BAA4B,GAAG,qBAAqB;KACvD,MAAM,CAAC;IACN,UAAU,EAAE,CAAC,CAAC,OAA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AAC;CACjC,CAAC;KACD,KAAK,CAAC,WAAW,CAAC,CAAA;AAErB,MAAM,CAAC,MAAM,QAAQ,GAAG,eAAe,CAAC,KAAK,CAC3C,CAAC,CAAC,MAAM,CAAC;IACP,UAAU,EAAE,CAAC,CAAC,OAAO,CAAC,IAAI,CAAC;CAC5B,CAAC,CACH,CAAA;AAED,MAAM,CAAC,MAAM,kBAAkB,GAAG,eAAe,CAAC,KAAK,CACrD,CAAC,CAAC,MAAM,CAAC;IACP,UAAU,EAAE,CAAC,CAAC,OAAO,CAAC,KAAK,CAAC;CAC7B,CAAC,CACH,CAAA"}
|
|
@@ -630,6 +630,84 @@ export declare const action_attempt: z.ZodUnion<[z.ZodObject<z.objectUtil.extend
|
|
|
630
630
|
status: z.ZodLiteral<"pending">;
|
|
631
631
|
result: z.ZodNull;
|
|
632
632
|
error: z.ZodNull;
|
|
633
|
+
}>, {
|
|
634
|
+
action_type: z.ZodLiteral<"ACTIVATE_CLIMATE_PRESET">;
|
|
635
|
+
}>, "strip", z.ZodTypeAny, {
|
|
636
|
+
error: null;
|
|
637
|
+
status: "pending";
|
|
638
|
+
action_attempt_id: string;
|
|
639
|
+
result: null;
|
|
640
|
+
action_type: "ACTIVATE_CLIMATE_PRESET";
|
|
641
|
+
}, {
|
|
642
|
+
error: null;
|
|
643
|
+
status: "pending";
|
|
644
|
+
action_attempt_id: string;
|
|
645
|
+
result: null;
|
|
646
|
+
action_type: "ACTIVATE_CLIMATE_PRESET";
|
|
647
|
+
}>, z.ZodObject<z.objectUtil.extendShape<z.objectUtil.extendShape<{
|
|
648
|
+
action_attempt_id: z.ZodString;
|
|
649
|
+
status: z.ZodEnum<["pending", "success", "error"]>;
|
|
650
|
+
}, {
|
|
651
|
+
status: z.ZodLiteral<"success">;
|
|
652
|
+
error: z.ZodNull;
|
|
653
|
+
}>, {
|
|
654
|
+
action_type: z.ZodLiteral<"ACTIVATE_CLIMATE_PRESET">;
|
|
655
|
+
result: z.ZodObject<{}, "strip", z.ZodTypeAny, {}, {}>;
|
|
656
|
+
}>, "strip", z.ZodTypeAny, {
|
|
657
|
+
error: null;
|
|
658
|
+
status: "success";
|
|
659
|
+
action_attempt_id: string;
|
|
660
|
+
result: {};
|
|
661
|
+
action_type: "ACTIVATE_CLIMATE_PRESET";
|
|
662
|
+
}, {
|
|
663
|
+
error: null;
|
|
664
|
+
status: "success";
|
|
665
|
+
action_attempt_id: string;
|
|
666
|
+
result: {};
|
|
667
|
+
action_type: "ACTIVATE_CLIMATE_PRESET";
|
|
668
|
+
}>, z.ZodObject<z.objectUtil.extendShape<z.objectUtil.extendShape<{
|
|
669
|
+
action_attempt_id: z.ZodString;
|
|
670
|
+
status: z.ZodEnum<["pending", "success", "error"]>;
|
|
671
|
+
}, {
|
|
672
|
+
status: z.ZodLiteral<"error">;
|
|
673
|
+
result: z.ZodNull;
|
|
674
|
+
}>, {
|
|
675
|
+
action_type: z.ZodLiteral<"ACTIVATE_CLIMATE_PRESET">;
|
|
676
|
+
error: z.ZodObject<{
|
|
677
|
+
type: z.ZodString;
|
|
678
|
+
message: z.ZodString;
|
|
679
|
+
}, "strip", z.ZodTypeAny, {
|
|
680
|
+
type: string;
|
|
681
|
+
message: string;
|
|
682
|
+
}, {
|
|
683
|
+
type: string;
|
|
684
|
+
message: string;
|
|
685
|
+
}>;
|
|
686
|
+
}>, "strip", z.ZodTypeAny, {
|
|
687
|
+
error: {
|
|
688
|
+
type: string;
|
|
689
|
+
message: string;
|
|
690
|
+
};
|
|
691
|
+
status: "error";
|
|
692
|
+
action_attempt_id: string;
|
|
693
|
+
result: null;
|
|
694
|
+
action_type: "ACTIVATE_CLIMATE_PRESET";
|
|
695
|
+
}, {
|
|
696
|
+
error: {
|
|
697
|
+
type: string;
|
|
698
|
+
message: string;
|
|
699
|
+
};
|
|
700
|
+
status: "error";
|
|
701
|
+
action_attempt_id: string;
|
|
702
|
+
result: null;
|
|
703
|
+
action_type: "ACTIVATE_CLIMATE_PRESET";
|
|
704
|
+
}>, z.ZodObject<z.objectUtil.extendShape<z.objectUtil.extendShape<{
|
|
705
|
+
action_attempt_id: z.ZodString;
|
|
706
|
+
status: z.ZodEnum<["pending", "success", "error"]>;
|
|
707
|
+
}, {
|
|
708
|
+
status: z.ZodLiteral<"pending">;
|
|
709
|
+
result: z.ZodNull;
|
|
710
|
+
error: z.ZodNull;
|
|
633
711
|
}>, {
|
|
634
712
|
action_type: z.ZodLiteral<"SYNC_ACCESS_CODES">;
|
|
635
713
|
}>, "strip", z.ZodTypeAny, {
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import { z } from 'zod';
|
|
2
|
+
import { activate_climate_preset_action_attempt } from './activate-climate-preset.js';
|
|
2
3
|
import { deprecated_action_attempts } from './deprecated.js';
|
|
3
4
|
import { lock_door_action_attempt } from './lock-door.js';
|
|
4
5
|
import { reset_sandbox_workspace_action_attempt } from './reset-sandbox-workspace.js';
|
|
@@ -17,6 +18,7 @@ export const action_attempt = z.union([
|
|
|
17
18
|
...set_heat_cool_action_attempt.options,
|
|
18
19
|
...set_fan_mode_action_attempt.options,
|
|
19
20
|
...set_thermostat_off_action_attempt.options,
|
|
21
|
+
...activate_climate_preset_action_attempt.options,
|
|
20
22
|
...deprecated_action_attempts,
|
|
21
23
|
]);
|
|
22
24
|
//# sourceMappingURL=action-attempt.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"action-attempt.js","sourceRoot":"","sources":["../../../../../src/lib/seam/connect/models/action-attempts/action-attempt.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AAEvB,OAAO,EAAE,0BAA0B,EAAE,MAAM,iBAAiB,CAAA;AAC5D,OAAO,EAAE,wBAAwB,EAAE,MAAM,gBAAgB,CAAA;AACzD,OAAO,EAAE,sCAAsC,EAAE,MAAM,8BAA8B,CAAA;AACrF,OAAO,EAAE,uBAAuB,EAAE,MAAM,eAAe,CAAA;AACvD,OAAO,EAAE,2BAA2B,EAAE,MAAM,mBAAmB,CAAA;AAC/D,OAAO,EAAE,uBAAuB,EAAE,MAAM,eAAe,CAAA;AACvD,OAAO,EAAE,4BAA4B,EAAE,MAAM,oBAAoB,CAAA;AACjE,OAAO,EAAE,iCAAiC,EAAE,MAAM,yBAAyB,CAAA;AAC3E,OAAO,EAAE,0BAA0B,EAAE,MAAM,kBAAkB,CAAA;AAE7D,MAAM,CAAC,MAAM,cAAc,GAAG,CAAC,CAAC,KAAK,CAAC;IACpC,GAAG,wBAAwB,CAAC,OAAO;IACnC,GAAG,0BAA0B,CAAC,OAAO;IACrC,GAAG,sCAAsC,CAAC,OAAO;IACjD,GAAG,uBAAuB,CAAC,OAAO;IAClC,GAAG,uBAAuB,CAAC,OAAO;IAClC,GAAG,4BAA4B,CAAC,OAAO;IACvC,GAAG,2BAA2B,CAAC,OAAO;IACtC,GAAG,iCAAiC,CAAC,OAAO;IAC5C,GAAG,0BAA0B;CAC9B,CAAC,CAAA"}
|
|
1
|
+
{"version":3,"file":"action-attempt.js","sourceRoot":"","sources":["../../../../../src/lib/seam/connect/models/action-attempts/action-attempt.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AAEvB,OAAO,EAAE,sCAAsC,EAAE,MAAM,8BAA8B,CAAA;AACrF,OAAO,EAAE,0BAA0B,EAAE,MAAM,iBAAiB,CAAA;AAC5D,OAAO,EAAE,wBAAwB,EAAE,MAAM,gBAAgB,CAAA;AACzD,OAAO,EAAE,sCAAsC,EAAE,MAAM,8BAA8B,CAAA;AACrF,OAAO,EAAE,uBAAuB,EAAE,MAAM,eAAe,CAAA;AACvD,OAAO,EAAE,2BAA2B,EAAE,MAAM,mBAAmB,CAAA;AAC/D,OAAO,EAAE,uBAAuB,EAAE,MAAM,eAAe,CAAA;AACvD,OAAO,EAAE,4BAA4B,EAAE,MAAM,oBAAoB,CAAA;AACjE,OAAO,EAAE,iCAAiC,EAAE,MAAM,yBAAyB,CAAA;AAC3E,OAAO,EAAE,0BAA0B,EAAE,MAAM,kBAAkB,CAAA;AAE7D,MAAM,CAAC,MAAM,cAAc,GAAG,CAAC,CAAC,KAAK,CAAC;IACpC,GAAG,wBAAwB,CAAC,OAAO;IACnC,GAAG,0BAA0B,CAAC,OAAO;IACrC,GAAG,sCAAsC,CAAC,OAAO;IACjD,GAAG,uBAAuB,CAAC,OAAO;IAClC,GAAG,uBAAuB,CAAC,OAAO;IAClC,GAAG,4BAA4B,CAAC,OAAO;IACvC,GAAG,2BAA2B,CAAC,OAAO;IACtC,GAAG,iCAAiC,CAAC,OAAO;IAC5C,GAAG,sCAAsC,CAAC,OAAO;IACjD,GAAG,0BAA0B;CAC9B,CAAC,CAAA"}
|
|
@@ -0,0 +1,80 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
export declare const activate_climate_preset_action_attempt: z.ZodDiscriminatedUnion<"status", [z.ZodObject<z.objectUtil.extendShape<z.objectUtil.extendShape<{
|
|
3
|
+
action_attempt_id: z.ZodString;
|
|
4
|
+
status: z.ZodEnum<["pending", "success", "error"]>;
|
|
5
|
+
}, {
|
|
6
|
+
status: z.ZodLiteral<"pending">;
|
|
7
|
+
result: z.ZodNull;
|
|
8
|
+
error: z.ZodNull;
|
|
9
|
+
}>, {
|
|
10
|
+
action_type: z.ZodLiteral<"ACTIVATE_CLIMATE_PRESET">;
|
|
11
|
+
}>, "strip", z.ZodTypeAny, {
|
|
12
|
+
error: null;
|
|
13
|
+
status: "pending";
|
|
14
|
+
action_attempt_id: string;
|
|
15
|
+
result: null;
|
|
16
|
+
action_type: "ACTIVATE_CLIMATE_PRESET";
|
|
17
|
+
}, {
|
|
18
|
+
error: null;
|
|
19
|
+
status: "pending";
|
|
20
|
+
action_attempt_id: string;
|
|
21
|
+
result: null;
|
|
22
|
+
action_type: "ACTIVATE_CLIMATE_PRESET";
|
|
23
|
+
}>, z.ZodObject<z.objectUtil.extendShape<z.objectUtil.extendShape<{
|
|
24
|
+
action_attempt_id: z.ZodString;
|
|
25
|
+
status: z.ZodEnum<["pending", "success", "error"]>;
|
|
26
|
+
}, {
|
|
27
|
+
status: z.ZodLiteral<"success">;
|
|
28
|
+
error: z.ZodNull;
|
|
29
|
+
}>, {
|
|
30
|
+
action_type: z.ZodLiteral<"ACTIVATE_CLIMATE_PRESET">;
|
|
31
|
+
result: z.ZodObject<{}, "strip", z.ZodTypeAny, {}, {}>;
|
|
32
|
+
}>, "strip", z.ZodTypeAny, {
|
|
33
|
+
error: null;
|
|
34
|
+
status: "success";
|
|
35
|
+
action_attempt_id: string;
|
|
36
|
+
result: {};
|
|
37
|
+
action_type: "ACTIVATE_CLIMATE_PRESET";
|
|
38
|
+
}, {
|
|
39
|
+
error: null;
|
|
40
|
+
status: "success";
|
|
41
|
+
action_attempt_id: string;
|
|
42
|
+
result: {};
|
|
43
|
+
action_type: "ACTIVATE_CLIMATE_PRESET";
|
|
44
|
+
}>, z.ZodObject<z.objectUtil.extendShape<z.objectUtil.extendShape<{
|
|
45
|
+
action_attempt_id: z.ZodString;
|
|
46
|
+
status: z.ZodEnum<["pending", "success", "error"]>;
|
|
47
|
+
}, {
|
|
48
|
+
status: z.ZodLiteral<"error">;
|
|
49
|
+
result: z.ZodNull;
|
|
50
|
+
}>, {
|
|
51
|
+
action_type: z.ZodLiteral<"ACTIVATE_CLIMATE_PRESET">;
|
|
52
|
+
error: z.ZodObject<{
|
|
53
|
+
type: z.ZodString;
|
|
54
|
+
message: z.ZodString;
|
|
55
|
+
}, "strip", z.ZodTypeAny, {
|
|
56
|
+
type: string;
|
|
57
|
+
message: string;
|
|
58
|
+
}, {
|
|
59
|
+
type: string;
|
|
60
|
+
message: string;
|
|
61
|
+
}>;
|
|
62
|
+
}>, "strip", z.ZodTypeAny, {
|
|
63
|
+
error: {
|
|
64
|
+
type: string;
|
|
65
|
+
message: string;
|
|
66
|
+
};
|
|
67
|
+
status: "error";
|
|
68
|
+
action_attempt_id: string;
|
|
69
|
+
result: null;
|
|
70
|
+
action_type: "ACTIVATE_CLIMATE_PRESET";
|
|
71
|
+
}, {
|
|
72
|
+
error: {
|
|
73
|
+
type: string;
|
|
74
|
+
message: string;
|
|
75
|
+
};
|
|
76
|
+
status: "error";
|
|
77
|
+
action_attempt_id: string;
|
|
78
|
+
result: null;
|
|
79
|
+
action_type: "ACTIVATE_CLIMATE_PRESET";
|
|
80
|
+
}>]>;
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
import { common_failed_action_attempt, common_pending_action_attempt, common_succeeded_action_attempt, } from './common.js';
|
|
3
|
+
const action_type = z.literal('ACTIVATE_CLIMATE_PRESET');
|
|
4
|
+
const error = z.object({
|
|
5
|
+
type: z.string(),
|
|
6
|
+
message: z.string(),
|
|
7
|
+
});
|
|
8
|
+
const result = z.object({});
|
|
9
|
+
export const activate_climate_preset_action_attempt = z.discriminatedUnion('status', [
|
|
10
|
+
common_pending_action_attempt
|
|
11
|
+
.extend({
|
|
12
|
+
action_type,
|
|
13
|
+
})
|
|
14
|
+
.describe('Activating climate preset.'),
|
|
15
|
+
common_succeeded_action_attempt
|
|
16
|
+
.extend({
|
|
17
|
+
action_type,
|
|
18
|
+
result,
|
|
19
|
+
})
|
|
20
|
+
.describe('Activating climate preset succeeded.'),
|
|
21
|
+
common_failed_action_attempt
|
|
22
|
+
.extend({ action_type, error })
|
|
23
|
+
.describe('Activating climate preset failed.'),
|
|
24
|
+
]);
|
|
25
|
+
//# sourceMappingURL=activate-climate-preset.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"activate-climate-preset.js","sourceRoot":"","sources":["../../../../../src/lib/seam/connect/models/action-attempts/activate-climate-preset.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAA;AAEvB,OAAO,EACL,4BAA4B,EAC5B,6BAA6B,EAC7B,+BAA+B,GAChC,MAAM,aAAa,CAAA;AAEpB,MAAM,WAAW,GAAG,CAAC,CAAC,OAAO,CAAC,yBAAyB,CAAC,CAAA;AAExD,MAAM,KAAK,GAAG,CAAC,CAAC,MAAM,CAAC;IACrB,IAAI,EAAE,CAAC,CAAC,MAAM,EAAE;IAChB,OAAO,EAAE,CAAC,CAAC,MAAM,EAAE;CACpB,CAAC,CAAA;AAEF,MAAM,MAAM,GAAG,CAAC,CAAC,MAAM,CAAC,EAAE,CAAC,CAAA;AAE3B,MAAM,CAAC,MAAM,sCAAsC,GAAG,CAAC,CAAC,kBAAkB,CACxE,QAAQ,EACR;IACE,6BAA6B;SAC1B,MAAM,CAAC;QACN,WAAW;KACZ,CAAC;SACD,QAAQ,CAAC,4BAA4B,CAAC;IACzC,+BAA+B;SAC5B,MAAM,CAAC;QACN,WAAW;QACX,MAAM;KACP,CAAC;SACD,QAAQ,CAAC,sCAAsC,CAAC;IACnD,4BAA4B;SACzB,MAAM,CAAC,EAAE,WAAW,EAAE,KAAK,EAAE,CAAC;SAC9B,QAAQ,CAAC,mCAAmC,CAAC;CACjD,CACF,CAAA"}
|