@thelllabs/winehaus-sdk 0.0.26 → 0.0.28

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.
@@ -1226,6 +1226,20 @@ var Api = /** @class */ (function (_super) {
1226
1226
  if (params === void 0) { params = {}; }
1227
1227
  return _this.request(__assign({ path: "/admin/tenants/".concat(tenantId, "/requests/").concat(requestId), method: "GET", secure: true, format: "json" }, params));
1228
1228
  },
1229
+ /**
1230
+ * No description
1231
+ *
1232
+ * @tags Admin Tenant Operation Requests
1233
+ * @name GetTenantOperationRequestWinePossibleCases
1234
+ * @request GET:/admin/tenants/{tenantId}/requests/{requestId}/wine-cases
1235
+ * @secure
1236
+ * @response `200` `WineCasesResponseDto`
1237
+ * @response `403` `HttpExceptionDto` Need user with one of these roles: owner, admin, operator
1238
+ */
1239
+ getTenantOperationRequestWinePossibleCases: function (tenantId, requestId, params) {
1240
+ if (params === void 0) { params = {}; }
1241
+ return _this.request(__assign({ path: "/admin/tenants/".concat(tenantId, "/requests/").concat(requestId, "/wine-cases"), method: "GET", secure: true, format: "json" }, params));
1242
+ },
1229
1243
  /**
1230
1244
  * No description
1231
1245
  *
@@ -1443,7 +1457,7 @@ var Api = /** @class */ (function (_super) {
1443
1457
  * @name ListTenantOperationGroups
1444
1458
  * @request GET:/admin/tenants/{tenantId}/operation-groups
1445
1459
  * @secure
1446
- * @response `200` `OperationGroupEntityPaginatedDto`
1460
+ * @response `200` `OperationGroupWithExtraInfoEntityPaginatedDto`
1447
1461
  * @response `403` `HttpExceptionDto` Need user with one of these roles: owner, admin, operator
1448
1462
  */
1449
1463
  listTenantOperationGroups: function (tenantId, query, params) {
@@ -1656,9 +1670,9 @@ var Api = /** @class */ (function (_super) {
1656
1670
  * @response `204` `void`
1657
1671
  * @response `403` `HttpExceptionDto` Need user with one of these roles: owner, admin
1658
1672
  */
1659
- processTenantOperationGroup: function (tenantId, groupId, params) {
1673
+ processTenantOperationGroup: function (tenantId, groupId, data, params) {
1660
1674
  if (params === void 0) { params = {}; }
1661
- return _this.request(__assign({ path: "/admin/tenants/".concat(tenantId, "/operation-groups/").concat(groupId, "/process"), method: "PATCH", secure: true }, params));
1675
+ return _this.request(__assign({ path: "/admin/tenants/".concat(tenantId, "/operation-groups/").concat(groupId, "/process"), method: "PATCH", body: data, secure: true, type: ContentType.Json }, params));
1662
1676
  },
1663
1677
  /**
1664
1678
  * No description
@@ -1220,6 +1220,20 @@ var Api = /** @class */ (function (_super) {
1220
1220
  if (params === void 0) { params = {}; }
1221
1221
  return _this.request(__assign({ path: "/admin/tenants/".concat(tenantId, "/requests/").concat(requestId), method: "GET", secure: true, format: "json" }, params));
1222
1222
  },
1223
+ /**
1224
+ * No description
1225
+ *
1226
+ * @tags Admin Tenant Operation Requests
1227
+ * @name GetTenantOperationRequestWinePossibleCases
1228
+ * @request GET:/admin/tenants/{tenantId}/requests/{requestId}/wine-cases
1229
+ * @secure
1230
+ * @response `200` `WineCasesResponseDto`
1231
+ * @response `403` `HttpExceptionDto` Need user with one of these roles: owner, admin, operator
1232
+ */
1233
+ getTenantOperationRequestWinePossibleCases: function (tenantId, requestId, params) {
1234
+ if (params === void 0) { params = {}; }
1235
+ return _this.request(__assign({ path: "/admin/tenants/".concat(tenantId, "/requests/").concat(requestId, "/wine-cases"), method: "GET", secure: true, format: "json" }, params));
1236
+ },
1223
1237
  /**
1224
1238
  * No description
1225
1239
  *
@@ -1437,7 +1451,7 @@ var Api = /** @class */ (function (_super) {
1437
1451
  * @name ListTenantOperationGroups
1438
1452
  * @request GET:/admin/tenants/{tenantId}/operation-groups
1439
1453
  * @secure
1440
- * @response `200` `OperationGroupEntityPaginatedDto`
1454
+ * @response `200` `OperationGroupWithExtraInfoEntityPaginatedDto`
1441
1455
  * @response `403` `HttpExceptionDto` Need user with one of these roles: owner, admin, operator
1442
1456
  */
1443
1457
  listTenantOperationGroups: function (tenantId, query, params) {
@@ -1650,9 +1664,9 @@ var Api = /** @class */ (function (_super) {
1650
1664
  * @response `204` `void`
1651
1665
  * @response `403` `HttpExceptionDto` Need user with one of these roles: owner, admin
1652
1666
  */
1653
- processTenantOperationGroup: function (tenantId, groupId, params) {
1667
+ processTenantOperationGroup: function (tenantId, groupId, data, params) {
1654
1668
  if (params === void 0) { params = {}; }
1655
- return _this.request(__assign({ path: "/admin/tenants/".concat(tenantId, "/operation-groups/").concat(groupId, "/process"), method: "PATCH", secure: true }, params));
1669
+ return _this.request(__assign({ path: "/admin/tenants/".concat(tenantId, "/operation-groups/").concat(groupId, "/process"), method: "PATCH", body: data, secure: true, type: ContentType.Json }, params));
1656
1670
  },
1657
1671
  /**
1658
1672
  * No description
@@ -146,6 +146,7 @@ export interface CaseWineInventoryItemEntityDto {
146
146
  bottleVintage: WineBottleVintageEntityDto;
147
147
  /** @format uuid */
148
148
  bottleVintageId: string;
149
+ case?: SimpleCaseEntityDto | null;
149
150
  /** @format uuid */
150
151
  caseId?: string | null;
151
152
  /** @format date-time */
@@ -211,6 +212,7 @@ export interface CreateCaseDto {
211
212
  /** @min 0 */
212
213
  maxItems: number;
213
214
  name: string;
215
+ triggerInvoice?: boolean;
214
216
  }
215
217
  export interface CreateCaseOperationDto {
216
218
  /** @format uuid */
@@ -538,17 +540,45 @@ export interface OperationGroupEntityDto {
538
540
  /** @format date-time */
539
541
  updatedAt: string;
540
542
  }
541
- export interface OperationGroupEntityPaginatedDto {
542
- items: OperationGroupEntityDto[];
543
- links?: PaginationLinksDto;
544
- meta: PaginationMetaDto;
543
+ export interface OperationGroupExtraDataDto {
544
+ total: number;
545
+ /** @example "deposit" */
546
+ type: CaseOperationTypesEnum;
545
547
  }
548
+ export interface OperationGroupExtrasEntityDto {
549
+ /** @format uuid */
550
+ groupId: string;
551
+ operationsSummaryByType: OperationGroupExtraDataDto[];
552
+ }
553
+ export type OperationGroupExtrasViewEntity = object;
546
554
  export declare enum OperationGroupStatusEnum {
547
555
  OnHold = "on_hold",
548
556
  Confirmed = "confirmed",
549
557
  Processed = "processed",
550
558
  Cancelled = "cancelled"
551
559
  }
560
+ export interface OperationGroupWithExtraInfoEntityDto {
561
+ /** @format date-time */
562
+ createdAt: string;
563
+ customer: UserEntityDto;
564
+ /** @format uuid */
565
+ customerId: string;
566
+ extraInfo: OperationGroupExtrasViewEntity;
567
+ /** @format uuid */
568
+ id: string;
569
+ notes: string | null;
570
+ /** @example "processed" */
571
+ status: OperationGroupStatusEnum;
572
+ /** @format uuid */
573
+ tenantId: string;
574
+ /** @format date-time */
575
+ updatedAt: string;
576
+ }
577
+ export interface OperationGroupWithExtraInfoEntityPaginatedDto {
578
+ items: OperationGroupWithExtraInfoEntityDto[];
579
+ links?: PaginationLinksDto;
580
+ meta: PaginationMetaDto;
581
+ }
552
582
  export interface OperationRequestEntityDto {
553
583
  /** @format date-time */
554
584
  createdAt: string;
@@ -658,6 +688,9 @@ export interface ProcessDepositDto {
658
688
  /** @minItems 1 */
659
689
  wines: DepositRequestCreateWineInventoryItemDto[];
660
690
  }
691
+ export interface ProcessOperationGroupDto {
692
+ triggerInvoice?: boolean;
693
+ }
661
694
  export interface ProcessWithdrawDto {
662
695
  /** @minItems 0 */
663
696
  extras?: CreateOperationExtraDto[];
@@ -728,6 +761,33 @@ export interface SigninResponseDto {
728
761
  token: string;
729
762
  user: UserEntityDto;
730
763
  }
764
+ export interface SimpleCaseEntityDto {
765
+ /** @format date-time */
766
+ billingEndDate?: string | null;
767
+ /** @format date-time */
768
+ billingStartDate?: string | null;
769
+ /** @format date-time */
770
+ createdAt: string;
771
+ /** @min 0 */
772
+ currentItems: number;
773
+ /** @format uuid */
774
+ customerId: string;
775
+ /** @format date-time */
776
+ deletedAt?: string | null;
777
+ description?: string | null;
778
+ /** @format uuid */
779
+ id: string;
780
+ location?: string | null;
781
+ /** @min 0 */
782
+ maxItems: number;
783
+ name: string;
784
+ /** @format uuid */
785
+ planId?: string | null;
786
+ /** @format uuid */
787
+ tenantId: string;
788
+ /** @format date-time */
789
+ updatedAt: string;
790
+ }
731
791
  export interface StoragePlanEntityDto {
732
792
  /** @format date-time */
733
793
  createdAt: string;
@@ -791,6 +851,7 @@ export interface UpdateCaseDto {
791
851
  /** @min 0 */
792
852
  maxItems: number;
793
853
  name: string;
854
+ triggerInvoice?: boolean;
794
855
  }
795
856
  export interface UpdateCaseOperationDto {
796
857
  /** @format uuid */
@@ -1027,6 +1088,18 @@ export interface WineBrandEntityPaginatedDto {
1027
1088
  links?: PaginationLinksDto;
1028
1089
  meta: PaginationMetaDto;
1029
1090
  }
1091
+ export interface WineCaseItemResponseDto {
1092
+ /** @format uuid */
1093
+ bottleFormatId: string;
1094
+ /** @format uuid */
1095
+ bottleVintageId: string;
1096
+ cases: SimpleCaseEntityDto[];
1097
+ /** @format uuid */
1098
+ wineId: string;
1099
+ }
1100
+ export interface WineCasesResponseDto {
1101
+ wines: WineCaseItemResponseDto[];
1102
+ }
1030
1103
  export interface WineCountryEntityDto {
1031
1104
  /** @format date-time */
1032
1105
  createdAt: string;
@@ -2611,6 +2684,25 @@ export declare namespace Admin {
2611
2684
  type RequestHeaders = {};
2612
2685
  type ResponseBody = FullOperationRequestEntityDto;
2613
2686
  }
2687
+ /**
2688
+ * No description
2689
+ * @tags Admin Tenant Operation Requests
2690
+ * @name GetTenantOperationRequestWinePossibleCases
2691
+ * @request GET:/admin/tenants/{tenantId}/requests/{requestId}/wine-cases
2692
+ * @secure
2693
+ * @response `200` `WineCasesResponseDto`
2694
+ * @response `403` `HttpExceptionDto` Need user with one of these roles: owner, admin, operator
2695
+ */
2696
+ namespace GetTenantOperationRequestWinePossibleCases {
2697
+ type RequestParams = {
2698
+ requestId: string;
2699
+ tenantId: string;
2700
+ };
2701
+ type RequestQuery = {};
2702
+ type RequestBody = never;
2703
+ type RequestHeaders = {};
2704
+ type ResponseBody = WineCasesResponseDto;
2705
+ }
2614
2706
  /**
2615
2707
  * No description
2616
2708
  * @tags Admin Tenant Wine Bottle Formats
@@ -2953,7 +3045,7 @@ export declare namespace Admin {
2953
3045
  * @name ListTenantOperationGroups
2954
3046
  * @request GET:/admin/tenants/{tenantId}/operation-groups
2955
3047
  * @secure
2956
- * @response `200` `OperationGroupEntityPaginatedDto`
3048
+ * @response `200` `OperationGroupWithExtraInfoEntityPaginatedDto`
2957
3049
  * @response `403` `HttpExceptionDto` Need user with one of these roles: owner, admin, operator
2958
3050
  */
2959
3051
  namespace ListTenantOperationGroups {
@@ -2979,7 +3071,7 @@ export declare namespace Admin {
2979
3071
  };
2980
3072
  type RequestBody = never;
2981
3073
  type RequestHeaders = {};
2982
- type ResponseBody = OperationGroupEntityPaginatedDto;
3074
+ type ResponseBody = OperationGroupWithExtraInfoEntityPaginatedDto;
2983
3075
  }
2984
3076
  /**
2985
3077
  * No description
@@ -3456,7 +3548,7 @@ export declare namespace Admin {
3456
3548
  tenantId: string;
3457
3549
  };
3458
3550
  type RequestQuery = {};
3459
- type RequestBody = never;
3551
+ type RequestBody = ProcessOperationGroupDto;
3460
3552
  type RequestHeaders = {};
3461
3553
  type ResponseBody = void;
3462
3554
  }
@@ -4810,6 +4902,17 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
4810
4902
  * @response `403` `HttpExceptionDto` Need user with one of these roles: owner, admin, operator
4811
4903
  */
4812
4904
  getTenantOperationRequestById: (tenantId: string, requestId: string, params?: RequestParams) => Promise<FullOperationRequestEntityDto>;
4905
+ /**
4906
+ * No description
4907
+ *
4908
+ * @tags Admin Tenant Operation Requests
4909
+ * @name GetTenantOperationRequestWinePossibleCases
4910
+ * @request GET:/admin/tenants/{tenantId}/requests/{requestId}/wine-cases
4911
+ * @secure
4912
+ * @response `200` `WineCasesResponseDto`
4913
+ * @response `403` `HttpExceptionDto` Need user with one of these roles: owner, admin, operator
4914
+ */
4915
+ getTenantOperationRequestWinePossibleCases: (tenantId: string, requestId: string, params?: RequestParams) => Promise<WineCasesResponseDto>;
4813
4916
  /**
4814
4917
  * No description
4815
4918
  *
@@ -5035,7 +5138,7 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
5035
5138
  * @name ListTenantOperationGroups
5036
5139
  * @request GET:/admin/tenants/{tenantId}/operation-groups
5037
5140
  * @secure
5038
- * @response `200` `OperationGroupEntityPaginatedDto`
5141
+ * @response `200` `OperationGroupWithExtraInfoEntityPaginatedDto`
5039
5142
  * @response `403` `HttpExceptionDto` Need user with one of these roles: owner, admin, operator
5040
5143
  */
5041
5144
  listTenantOperationGroups: (tenantId: string, query?: {
@@ -5054,7 +5157,7 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
5054
5157
  page?: number;
5055
5158
  sortBy?: string[];
5056
5159
  status?: OperationGroupStatusEnum[];
5057
- }, params?: RequestParams) => Promise<OperationGroupEntityPaginatedDto>;
5160
+ }, params?: RequestParams) => Promise<OperationGroupWithExtraInfoEntityPaginatedDto>;
5058
5161
  /**
5059
5162
  * No description
5060
5163
  *
@@ -5426,7 +5529,7 @@ export declare class Api<SecurityDataType extends unknown> extends HttpClient<Se
5426
5529
  * @response `204` `void`
5427
5530
  * @response `403` `HttpExceptionDto` Need user with one of these roles: owner, admin
5428
5531
  */
5429
- processTenantOperationGroup: (tenantId: string, groupId: string, params?: RequestParams) => Promise<void>;
5532
+ processTenantOperationGroup: (tenantId: string, groupId: string, data: ProcessOperationGroupDto, params?: RequestParams) => Promise<void>;
5430
5533
  /**
5431
5534
  * No description
5432
5535
  *
package/dist/umd/index.ts CHANGED
@@ -19551,6 +19551,20 @@ var Api = /** @class */ (function (_super) {
19551
19551
  if (params === void 0) { params = {}; }
19552
19552
  return _this.request(__assign({ path: "/admin/tenants/".concat(tenantId, "/requests/").concat(requestId), method: "GET", secure: true, format: "json" }, params));
19553
19553
  },
19554
+ /**
19555
+ * No description
19556
+ *
19557
+ * @tags Admin Tenant Operation Requests
19558
+ * @name GetTenantOperationRequestWinePossibleCases
19559
+ * @request GET:/admin/tenants/{tenantId}/requests/{requestId}/wine-cases
19560
+ * @secure
19561
+ * @response `200` `WineCasesResponseDto`
19562
+ * @response `403` `HttpExceptionDto` Need user with one of these roles: owner, admin, operator
19563
+ */
19564
+ getTenantOperationRequestWinePossibleCases: function (tenantId, requestId, params) {
19565
+ if (params === void 0) { params = {}; }
19566
+ return _this.request(__assign({ path: "/admin/tenants/".concat(tenantId, "/requests/").concat(requestId, "/wine-cases"), method: "GET", secure: true, format: "json" }, params));
19567
+ },
19554
19568
  /**
19555
19569
  * No description
19556
19570
  *
@@ -19768,7 +19782,7 @@ var Api = /** @class */ (function (_super) {
19768
19782
  * @name ListTenantOperationGroups
19769
19783
  * @request GET:/admin/tenants/{tenantId}/operation-groups
19770
19784
  * @secure
19771
- * @response `200` `OperationGroupEntityPaginatedDto`
19785
+ * @response `200` `OperationGroupWithExtraInfoEntityPaginatedDto`
19772
19786
  * @response `403` `HttpExceptionDto` Need user with one of these roles: owner, admin, operator
19773
19787
  */
19774
19788
  listTenantOperationGroups: function (tenantId, query, params) {
@@ -19981,9 +19995,9 @@ var Api = /** @class */ (function (_super) {
19981
19995
  * @response `204` `void`
19982
19996
  * @response `403` `HttpExceptionDto` Need user with one of these roles: owner, admin
19983
19997
  */
19984
- processTenantOperationGroup: function (tenantId, groupId, params) {
19998
+ processTenantOperationGroup: function (tenantId, groupId, data, params) {
19985
19999
  if (params === void 0) { params = {}; }
19986
- return _this.request(__assign({ path: "/admin/tenants/".concat(tenantId, "/operation-groups/").concat(groupId, "/process"), method: "PATCH", secure: true }, params));
20000
+ return _this.request(__assign({ path: "/admin/tenants/".concat(tenantId, "/operation-groups/").concat(groupId, "/process"), method: "PATCH", body: data, secure: true, type: ContentType.Json }, params));
19987
20001
  },
19988
20002
  /**
19989
20003
  * No description
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@thelllabs/winehaus-sdk",
3
- "version": "0.0.26",
3
+ "version": "0.0.28",
4
4
  "description": "Winehaus SDK",
5
5
  "main": "dist/cjs/index.js",
6
6
  "module": "dist/esm/index.js",