@wix/auto_sdk_events_item-groups 1.0.2 → 1.0.4

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.
@@ -43,12 +43,17 @@ interface ItemGroup {
43
43
  */
44
44
  items?: Item[];
45
45
  /**
46
- * Feature that claimed the group, set by the server. Empty while unclaimed. When the owner stops using a group that others still use, one of them becomes the owner.
46
+ * Feature that uses the group. Empty if none does. Only `type` is set while `reservationEndDate` is set. On create, set `type` to reserve the group for that feature.
47
47
  * @readonly
48
48
  */
49
49
  owner?: Owner;
50
50
  /** Settings used only when the group belongs to a coupon. Empty when not used. */
51
51
  couponOptions?: CouponOptions;
52
+ /**
53
+ * Date and time the group is deleted if no feature uses it by then. Empty unless the group is reserved.
54
+ * @readonly
55
+ */
56
+ reservationEndDate?: Date | null;
52
57
  /** Tags. */
53
58
  tags?: Tags;
54
59
  }
@@ -79,6 +84,7 @@ interface Owner {
79
84
  /**
80
85
  * Owner ID, for example the coupon ID. Free-form, because some legacy coupon IDs aren't GUIDs.
81
86
  * @maxLength 100
87
+ * @readonly
82
88
  */
83
89
  id?: string;
84
90
  }
@@ -5,11 +5,11 @@ export { AccountInfo, ActionEvent, ApplicationError, BulkActionMetadata, BulkUpd
5
5
  declare function createItemGroup$1(httpClient: HttpClient): CreateItemGroupSignature;
6
6
  interface CreateItemGroupSignature {
7
7
  /**
8
- * Creates an unclaimed item group.
8
+ * Creates an item group. Set `owner.type` to reserve it for a feature.
9
9
  * @param - Item group to create.
10
10
  * @returns Created item group.
11
11
  */
12
- (itemGroup: NonNullablePaths<ItemGroup, `itemType` | `items.${number}._id`, 2>): Promise<NonNullablePaths<ItemGroup, `itemType` | `items` | `items.${number}._id` | `owner.type` | `owner._id` | `tags.privateTags.tagIds`, 2> & {
12
+ (itemGroup: NonNullablePaths<ItemGroup, `itemType` | `items.${number}._id` | `owner.type`, 2>): Promise<NonNullablePaths<ItemGroup, `itemType` | `items` | `items.${number}._id` | `owner.type` | `owner._id` | `tags.privateTags.tagIds`, 2> & {
13
13
  __applicationErrorsType?: CreateItemGroupApplicationErrors;
14
14
  }>;
15
15
  }
@@ -43,12 +43,17 @@ interface ItemGroup {
43
43
  */
44
44
  items?: Item[];
45
45
  /**
46
- * Feature that claimed the group, set by the server. Empty while unclaimed. When the owner stops using a group that others still use, one of them becomes the owner.
46
+ * Feature that uses the group. Empty if none does. Only `type` is set while `reservationEndDate` is set. On create, set `type` to reserve the group for that feature.
47
47
  * @readonly
48
48
  */
49
49
  owner?: Owner;
50
50
  /** Settings used only when the group belongs to a coupon. Empty when not used. */
51
51
  couponOptions?: CouponOptions;
52
+ /**
53
+ * Date and time the group is deleted if no feature uses it by then. Empty unless the group is reserved.
54
+ * @readonly
55
+ */
56
+ reservationEndDate?: Date | null;
52
57
  /** Tags. */
53
58
  tags?: Tags;
54
59
  }
@@ -79,6 +84,7 @@ interface Owner {
79
84
  /**
80
85
  * Owner ID, for example the coupon ID. Free-form, because some legacy coupon IDs aren't GUIDs.
81
86
  * @maxLength 100
87
+ * @readonly
82
88
  */
83
89
  _id?: string;
84
90
  }
@@ -533,19 +539,20 @@ type DeleteItemGroupApplicationErrors = {
533
539
  data?: Record<string, any>;
534
540
  };
535
541
  /**
536
- * Creates an unclaimed item group.
542
+ * Creates an item group. Set `owner.type` to reserve it for a feature.
537
543
  * @param itemGroup - Item group to create.
538
544
  * @public
539
545
  * @documentationMaturity preview
540
546
  * @requiredField itemGroup
541
547
  * @requiredField itemGroup.itemType
542
548
  * @requiredField itemGroup.items._id
549
+ * @requiredField itemGroup.owner.type
543
550
  * @permissionId events:itemgroups:v1:item_group:create_item_group
544
551
  * @applicableIdentity APP
545
552
  * @returns Created item group.
546
553
  * @fqn wix.events.itemgroups.v1.ItemGroupService.CreateItemGroup
547
554
  */
548
- declare function createItemGroup(itemGroup: NonNullablePaths<ItemGroup, `itemType` | `items.${number}._id`, 2>): Promise<NonNullablePaths<ItemGroup, `itemType` | `items` | `items.${number}._id` | `owner.type` | `owner._id` | `tags.privateTags.tagIds`, 2> & {
555
+ declare function createItemGroup(itemGroup: NonNullablePaths<ItemGroup, `itemType` | `items.${number}._id` | `owner.type`, 2>): Promise<NonNullablePaths<ItemGroup, `itemType` | `items` | `items.${number}._id` | `owner.type` | `owner._id` | `tags.privateTags.tagIds`, 2> & {
549
556
  __applicationErrorsType?: CreateItemGroupApplicationErrors;
550
557
  }>;
551
558
  /**
@@ -615,12 +622,17 @@ interface UpdateItemGroup {
615
622
  */
616
623
  items?: Item[];
617
624
  /**
618
- * Feature that claimed the group, set by the server. Empty while unclaimed. When the owner stops using a group that others still use, one of them becomes the owner.
625
+ * Feature that uses the group. Empty if none does. Only `type` is set while `reservationEndDate` is set. On create, set `type` to reserve the group for that feature.
619
626
  * @readonly
620
627
  */
621
628
  owner?: Owner;
622
629
  /** Settings used only when the group belongs to a coupon. Empty when not used. */
623
630
  couponOptions?: CouponOptions;
631
+ /**
632
+ * Date and time the group is deleted if no feature uses it by then. Empty unless the group is reserved.
633
+ * @readonly
634
+ */
635
+ reservationEndDate?: Date | null;
624
636
  /** Tags. */
625
637
  tags?: Tags;
626
638
  }
@@ -43,12 +43,17 @@ interface ItemGroup {
43
43
  */
44
44
  items?: Item[];
45
45
  /**
46
- * Feature that claimed the group, set by the server. Empty while unclaimed. When the owner stops using a group that others still use, one of them becomes the owner.
46
+ * Feature that uses the group. Empty if none does. Only `type` is set while `reservationEndDate` is set. On create, set `type` to reserve the group for that feature.
47
47
  * @readonly
48
48
  */
49
49
  owner?: Owner;
50
50
  /** Settings used only when the group belongs to a coupon. Empty when not used. */
51
51
  couponOptions?: CouponOptions;
52
+ /**
53
+ * Date and time the group is deleted if no feature uses it by then. Empty unless the group is reserved.
54
+ * @readonly
55
+ */
56
+ reservationEndDate?: Date | null;
52
57
  /** Tags. */
53
58
  tags?: Tags;
54
59
  }
@@ -79,6 +84,7 @@ interface Owner {
79
84
  /**
80
85
  * Owner ID, for example the coupon ID. Free-form, because some legacy coupon IDs aren't GUIDs.
81
86
  * @maxLength 100
87
+ * @readonly
82
88
  */
83
89
  id?: string;
84
90
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@wix/auto_sdk_events_item-groups",
3
- "version": "1.0.2",
3
+ "version": "1.0.4",
4
4
  "license": "MIT",
5
5
  "publishConfig": {
6
6
  "registry": "https://registry.npmjs.org/",
@@ -50,5 +50,5 @@
50
50
  "fqdn": "wix.events.itemgroups.v1.item_group"
51
51
  }
52
52
  },
53
- "falconPackageHash": "ee223c1b6acc516ab9670ec59243f28a32bcf636db4c2160c4d22199"
53
+ "falconPackageHash": "474445fb65f7cae42e64ec82d76191bd24d712f0bd7ebffab200b5fb"
54
54
  }