@seamapi/types 1.894.0 → 1.896.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.
@@ -24681,6 +24681,20 @@ declare const seam_event: z.ZodDiscriminatedUnion<"event_type", [z.ZodObject<{
24681
24681
  connected_account_custom_metadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnion<[z.ZodString, z.ZodBoolean]>>>;
24682
24682
  } & {
24683
24683
  event_type: z.ZodLiteral<"access_code.changed">;
24684
+ changed_properties: z.ZodOptional<z.ZodArray<z.ZodObject<{
24685
+ property: z.ZodString;
24686
+ from: z.ZodNullable<z.ZodString>;
24687
+ to: z.ZodNullable<z.ZodString>;
24688
+ }, "strip", z.ZodTypeAny, {
24689
+ from: string | null;
24690
+ to: string | null;
24691
+ property: string;
24692
+ }, {
24693
+ from: string | null;
24694
+ to: string | null;
24695
+ property: string;
24696
+ }>, "many">>;
24697
+ change_reason: z.ZodOptional<z.ZodString>;
24684
24698
  }, "strip", z.ZodTypeAny, {
24685
24699
  device_id: string;
24686
24700
  workspace_id: string;
@@ -24692,6 +24706,12 @@ declare const seam_event: z.ZodDiscriminatedUnion<"event_type", [z.ZodObject<{
24692
24706
  event_type: "access_code.changed";
24693
24707
  device_custom_metadata?: Record<string, string | boolean> | undefined;
24694
24708
  connected_account_custom_metadata?: Record<string, string | boolean> | undefined;
24709
+ changed_properties?: {
24710
+ from: string | null;
24711
+ to: string | null;
24712
+ property: string;
24713
+ }[] | undefined;
24714
+ change_reason?: string | undefined;
24695
24715
  }, {
24696
24716
  device_id: string;
24697
24717
  workspace_id: string;
@@ -24703,6 +24723,12 @@ declare const seam_event: z.ZodDiscriminatedUnion<"event_type", [z.ZodObject<{
24703
24723
  event_type: "access_code.changed";
24704
24724
  device_custom_metadata?: Record<string, string | boolean> | undefined;
24705
24725
  connected_account_custom_metadata?: Record<string, string | boolean> | undefined;
24726
+ changed_properties?: {
24727
+ from: string | null;
24728
+ to: string | null;
24729
+ property: string;
24730
+ }[] | undefined;
24731
+ change_reason?: string | undefined;
24706
24732
  }>, z.ZodObject<{
24707
24733
  event_id: z.ZodString;
24708
24734
  workspace_id: z.ZodString;
@@ -76290,6 +76316,17 @@ type Routes = {
76290
76316
  [x: string]: string | boolean;
76291
76317
  } | undefined;
76292
76318
  event_type: 'access_code.changed';
76319
+ /** List of properties that changed on the access code. */
76320
+ changed_properties?: {
76321
+ /** Name of the property that changed (e.g. `code`). */
76322
+ property: string;
76323
+ /** Previous value of the property, or null if not set. */
76324
+ from: string | null;
76325
+ /** New value of the property, or null if cleared. */
76326
+ to: string | null;
76327
+ }[] | undefined;
76328
+ /** Human-readable reason for the change (e.g. `ongoing code auto-renewed`). */
76329
+ change_reason?: string | undefined;
76293
76330
  } | {
76294
76331
  /** ID of the event. */
76295
76332
  event_id: string;
@@ -79136,6 +79173,17 @@ type Routes = {
79136
79173
  [x: string]: string | boolean;
79137
79174
  } | undefined;
79138
79175
  event_type: 'access_code.changed';
79176
+ /** List of properties that changed on the access code. */
79177
+ changed_properties?: {
79178
+ /** Name of the property that changed (e.g. `code`). */
79179
+ property: string;
79180
+ /** Previous value of the property, or null if not set. */
79181
+ from: string | null;
79182
+ /** New value of the property, or null if cleared. */
79183
+ to: string | null;
79184
+ }[] | undefined;
79185
+ /** Human-readable reason for the change (e.g. `ongoing code auto-renewed`). */
79186
+ change_reason?: string | undefined;
79139
79187
  } | {
79140
79188
  /** ID of the event. */
79141
79189
  event_id: string;
@@ -107425,6 +107473,17 @@ type Routes = {
107425
107473
  [x: string]: string | boolean;
107426
107474
  } | undefined;
107427
107475
  event_type: 'access_code.changed';
107476
+ /** List of properties that changed on the access code. */
107477
+ changed_properties?: {
107478
+ /** Name of the property that changed (e.g. `code`). */
107479
+ property: string;
107480
+ /** Previous value of the property, or null if not set. */
107481
+ from: string | null;
107482
+ /** New value of the property, or null if cleared. */
107483
+ to: string | null;
107484
+ }[] | undefined;
107485
+ /** Human-readable reason for the change (e.g. `ongoing code auto-renewed`). */
107486
+ change_reason?: string | undefined;
107428
107487
  } | {
107429
107488
  /** ID of the event. */
107430
107489
  event_id: string;
@@ -143949,6 +144008,17 @@ type Routes = {
143949
144008
  [x: string]: string | boolean;
143950
144009
  } | undefined;
143951
144010
  event_type: 'access_code.changed';
144011
+ /** List of properties that changed on the access code. */
144012
+ changed_properties?: {
144013
+ /** Name of the property that changed (e.g. `code`). */
144014
+ property: string;
144015
+ /** Previous value of the property, or null if not set. */
144016
+ from: string | null;
144017
+ /** New value of the property, or null if cleared. */
144018
+ to: string | null;
144019
+ }[] | undefined;
144020
+ /** Human-readable reason for the change (e.g. `ongoing code auto-renewed`). */
144021
+ change_reason?: string | undefined;
143952
144022
  } | {
143953
144023
  /** ID of the event. */
143954
144024
  event_id: string;
package/dist/index.cjs CHANGED
@@ -5540,7 +5540,17 @@ var access_code_created_event = access_code_event.extend({
5540
5540
  An [access code](https://docs.seam.co/low-level-apis/smart-locks/access-codes) was created.
5541
5541
  `);
5542
5542
  var access_code_changed_event = access_code_event.extend({
5543
- event_type: zod.z.literal("access_code.changed")
5543
+ event_type: zod.z.literal("access_code.changed"),
5544
+ changed_properties: zod.z.array(
5545
+ zod.z.object({
5546
+ property: zod.z.string().describe("Name of the property that changed (e.g. `code`)."),
5547
+ from: zod.z.string().nullable().describe("Previous value of the property, or null if not set."),
5548
+ to: zod.z.string().nullable().describe("New value of the property, or null if cleared.")
5549
+ })
5550
+ ).optional().describe("List of properties that changed on the access code."),
5551
+ change_reason: zod.z.string().optional().describe(
5552
+ "Human-readable reason for the change (e.g. `ongoing code auto-renewed`)."
5553
+ )
5544
5554
  }).describe(`
5545
5555
  ---
5546
5556
  route_path: /access_codes
@@ -23055,6 +23065,34 @@ var openapi = {
23055
23065
  format: "uuid",
23056
23066
  type: "string"
23057
23067
  },
23068
+ change_reason: {
23069
+ description: "Human-readable reason for the change (e.g. `ongoing code auto-renewed`).",
23070
+ type: "string"
23071
+ },
23072
+ changed_properties: {
23073
+ description: "List of properties that changed on the access code.",
23074
+ items: {
23075
+ properties: {
23076
+ from: {
23077
+ description: "Previous value of the property, or null if not set.",
23078
+ nullable: true,
23079
+ type: "string"
23080
+ },
23081
+ property: {
23082
+ description: "Name of the property that changed (e.g. `code`).",
23083
+ type: "string"
23084
+ },
23085
+ to: {
23086
+ description: "New value of the property, or null if cleared.",
23087
+ nullable: true,
23088
+ type: "string"
23089
+ }
23090
+ },
23091
+ required: ["property", "from", "to"],
23092
+ type: "object"
23093
+ },
23094
+ type: "array"
23095
+ },
23058
23096
  connected_account_custom_metadata: {
23059
23097
  additionalProperties: {
23060
23098
  oneOf: [{ type: "string" }, { type: "boolean" }]