plaza-sdk 1.3.11 → 1.3.13

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.
@@ -1 +1 @@
1
- "use strict";var e=require("./auth/api.js"),r=require("./products/api.js"),t=require("./applications/api.js");exports.GetToken=e.GetToken,exports.RefreshToken=e.RefreshToken,exports.SingleWarehouseProduct=r.SingleWarehouseProduct,exports.UpdateWarehouseProduct=r.UpdateWarehouseProduct,exports.WarehouseList=r.WarehouseList,exports.ApplicationsList=t.ApplicationsList,exports.DeliverableWithType=t.DeliverableWithType,exports.SingleApplication=t.SingleApplication;
1
+ "use strict";var e=require("./auth/api.js"),r=require("./products/api.js"),s=require("./applications/api.js");exports.GetToken=e.GetToken,exports.RefreshToken=e.RefreshToken,exports.SingleWarehouseProduct=r.SingleWarehouseProduct,exports.UpdateWarehouseProduct=r.UpdateWarehouseProduct,exports.WarehouseCategoriesList=r.WarehouseCategoriesList,exports.WarehouseList=r.WarehouseList,exports.ApplicationsList=s.ApplicationsList,exports.DeliverableWithType=s.DeliverableWithType,exports.SingleApplication=s.SingleApplication;
@@ -1 +1 @@
1
- "use strict";var e=require("../../../../common/utils.js");exports.SingleWarehouseProduct=async(t,s)=>t.get(`/warehouse/items/${s.productId}`,{headers:e.pasteAuthHeaderAndApikey(s.token)}),exports.UpdateWarehouseProduct=(t,s,r)=>t.put(`/warehouse/items/${s.productId}`,r,{headers:e.pasteAuthHeaderAndApikey(s.token)}),exports.WarehouseList=(t,{token:s,...r})=>t.post("/warehouse/items",{params:{...r,q:r.q||""},headers:e.pasteAuthHeaderAndApikey(s)});
1
+ "use strict";var e=require("../../../../common/utils.js");exports.SingleWarehouseProduct=async(s,t)=>s.get(`/warehouse/items/${t.productId}`,{headers:e.pasteAuthHeaderAndApikey(t.token)}),exports.UpdateWarehouseProduct=(s,t,r)=>s.put(`/warehouse/items/${t.productId}`,r,{headers:e.pasteAuthHeaderAndApikey(t.token)}),exports.WarehouseCategoriesList=e=>e.get("/warehouse/app"),exports.WarehouseList=(s,{token:t,...r})=>s.post("/warehouse/items",{params:{...r,q:r.q||""},headers:e.pasteAuthHeaderAndApikey(t)});
@@ -1 +1 @@
1
- "use strict";var e=require("./api.js");exports.SingleWarehouseProduct=e.SingleWarehouseProduct,exports.UpdateWarehouseProduct=e.UpdateWarehouseProduct,exports.WarehouseList=e.WarehouseList;
1
+ "use strict";var e=require("./api.js");exports.SingleWarehouseProduct=e.SingleWarehouseProduct,exports.UpdateWarehouseProduct=e.UpdateWarehouseProduct,exports.WarehouseCategoriesList=e.WarehouseCategoriesList,exports.WarehouseList=e.WarehouseList;
@@ -1 +1 @@
1
- "use strict";var e=require("./core/auth/api.js"),r=require("./core/products/api.js"),o=require("./core/applications/api.js");exports.GetToken=e.GetToken,exports.RefreshToken=e.RefreshToken,exports.SingleWarehouseProduct=r.SingleWarehouseProduct,exports.UpdateWarehouseProduct=r.UpdateWarehouseProduct,exports.WarehouseList=r.WarehouseList,exports.ApplicationsList=o.ApplicationsList,exports.DeliverableWithType=o.DeliverableWithType,exports.SingleApplication=o.SingleApplication;
1
+ "use strict";var e=require("./core/auth/api.js"),r=require("./core/products/api.js"),o=require("./core/applications/api.js");exports.GetToken=e.GetToken,exports.RefreshToken=e.RefreshToken,exports.SingleWarehouseProduct=r.SingleWarehouseProduct,exports.UpdateWarehouseProduct=r.UpdateWarehouseProduct,exports.WarehouseCategoriesList=r.WarehouseCategoriesList,exports.WarehouseList=r.WarehouseList,exports.ApplicationsList=o.ApplicationsList,exports.DeliverableWithType=o.DeliverableWithType,exports.SingleApplication=o.SingleApplication;
@@ -1 +1 @@
1
- export{GetToken,RefreshToken}from"./auth/api.js";export{SingleWarehouseProduct,UpdateWarehouseProduct,WarehouseList}from"./products/api.js";export{ApplicationsList,DeliverableWithType,SingleApplication}from"./applications/api.js";
1
+ export{GetToken,RefreshToken}from"./auth/api.js";export{SingleWarehouseProduct,UpdateWarehouseProduct,WarehouseCategoriesList,WarehouseList}from"./products/api.js";export{ApplicationsList,DeliverableWithType,SingleApplication}from"./applications/api.js";
@@ -1 +1 @@
1
- import{pasteAuthHeaderAndApikey as e}from"../../../../common/utils.js";const o=async(o,s)=>o.get(`/warehouse/items/${s.productId}`,{headers:e(s.token)}),s=(o,s,t)=>o.put(`/warehouse/items/${s.productId}`,t,{headers:e(s.token)}),t=(o,{token:s,...t})=>o.post("/warehouse/items",{params:{...t,q:t.q||""},headers:e(s)});export{o as SingleWarehouseProduct,s as UpdateWarehouseProduct,t as WarehouseList};
1
+ import{pasteAuthHeaderAndApikey as e}from"../../../../common/utils.js";const o=async(o,s)=>o.get(`/warehouse/items/${s.productId}`,{headers:e(s.token)}),s=(o,s,t)=>o.put(`/warehouse/items/${s.productId}`,t,{headers:e(s.token)}),t=(o,{token:s,...t})=>o.post("/warehouse/items",{params:{...t,q:t.q||""},headers:e(s)}),r=e=>e.get("/warehouse/app");export{o as SingleWarehouseProduct,s as UpdateWarehouseProduct,r as WarehouseCategoriesList,t as WarehouseList};
@@ -1 +1 @@
1
- export{SingleWarehouseProduct,UpdateWarehouseProduct,WarehouseList}from"./api.js";
1
+ export{SingleWarehouseProduct,UpdateWarehouseProduct,WarehouseCategoriesList,WarehouseList}from"./api.js";
@@ -1 +1 @@
1
- export{GetToken,RefreshToken}from"./core/auth/api.js";export{SingleWarehouseProduct,UpdateWarehouseProduct,WarehouseList}from"./core/products/api.js";export{ApplicationsList,DeliverableWithType,SingleApplication}from"./core/applications/api.js";
1
+ export{GetToken,RefreshToken}from"./core/auth/api.js";export{SingleWarehouseProduct,UpdateWarehouseProduct,WarehouseCategoriesList,WarehouseList}from"./core/products/api.js";export{ApplicationsList,DeliverableWithType,SingleApplication}from"./core/applications/api.js";
@@ -18,7 +18,7 @@ interface ApplicationsParams extends TokenParams {
18
18
  status_key: ApplicationsEntity.Statuses | (string & {});
19
19
  }
20
20
  interface ApplicationIdBasedParams extends TokenParams {
21
- applicationId: string;
21
+ applicationId: number;
22
22
  }
23
23
 
24
24
  export type { ApplicationIdBasedParams, ApplicationsParams };
@@ -1,6 +1,6 @@
1
1
  export { GetToken, RefreshToken } from './auth/api.js';
2
2
  export { AuthApi } from './auth/types.js';
3
- export { SingleWarehouseProduct, UpdateWarehouseProduct, WarehouseList } from './products/api.js';
3
+ export { SingleWarehouseProduct, UpdateWarehouseProduct, WarehouseCategoriesList, WarehouseList } from './products/api.js';
4
4
  export { ProductsApi, ProductsEntity } from './products/types.js';
5
5
  export { ProductIdBasedParams, WarehouseProductsListParams } from './products/params.js';
6
6
  export { ApplicationsList, DeliverableWithType, SingleApplication } from './applications/api.js';
@@ -6,6 +6,6 @@ import 'axios';
6
6
 
7
7
  declare const GenerateReport: CallerParamPayload<TokenParams, GenerateReportParams, AlifManagementApi.GenerateReport.Response>;
8
8
  declare const CheckReport: CallerParam<CheckReportParams, AlifManagementApi.CheckReport.Response>;
9
- declare const ReportsList: CallerParam<ReportsListParams>;
9
+ declare const ReportsList: CallerParam<ReportsListParams, AlifManagementApi.ReportsList.Response>;
10
10
 
11
11
  export { CheckReport, GenerateReport, ReportsList };
@@ -19,15 +19,15 @@ declare namespace AlifManagementEntity {
19
19
  interface ReportItem {
20
20
  report_id: string;
21
21
  name: string;
22
- app_id: 2;
23
- type_id: 12;
22
+ app_id: number;
23
+ type_id: number;
24
24
  title: {
25
- ru: "Товары";
26
- uz: "Tovarlar";
25
+ ru: string;
26
+ uz: string;
27
27
  };
28
- generated_at: "2025-08-27 14:45:18";
29
- datetime_from: "2025-08-11 00:00:00";
30
- datetime_to: "2025-08-24 00:00:00";
28
+ generated_at: string;
29
+ datetime_from: string;
30
+ datetime_to: string;
31
31
  }
32
32
  }
33
33
  declare namespace AlifManagementApi {
@@ -42,60 +42,7 @@ declare namespace AlifManagementApi {
42
42
  }
43
43
  }
44
44
  namespace ReportsList {
45
- type Response = [
46
- {
47
- report_id: "ea6dfa38-5174-4dc1-96d8-652b2cc2a9eb";
48
- name: "merchants_service";
49
- app_id: 2;
50
- type_id: 12;
51
- title: {
52
- ru: "Товары";
53
- uz: "Tovarlar";
54
- };
55
- generated_at: "2025-08-27 14:45:18";
56
- datetime_from: "2025-08-11 00:00:00";
57
- datetime_to: "2025-08-24 00:00:00";
58
- },
59
- {
60
- report_id: "cb25e596-756b-493c-807e-f3b19a06c05a";
61
- name: "merchants_rejects";
62
- app_id: 2;
63
- type_id: 13;
64
- title: {
65
- ru: "Возвраты";
66
- uz: "Qaytarilgan tovarlar";
67
- };
68
- generated_at: "2024-12-03 16:29:07";
69
- datetime_from: "2023-11-01 00:00:00";
70
- datetime_to: "2023-11-30 00:00:00";
71
- },
72
- {
73
- report_id: null;
74
- name: "merchants_problem";
75
- app_id: 2;
76
- type_id: 16;
77
- title: {
78
- ru: "Проблемные клиенты";
79
- uz: "Muammoli mijozlar";
80
- };
81
- generated_at: null;
82
- datetime_from: null;
83
- datetime_to: null;
84
- },
85
- {
86
- report_id: "70fcb01d-ed08-4346-b09d-46d8798ae330";
87
- name: "merchants_delivery";
88
- app_id: 2;
89
- type_id: 29;
90
- title: {
91
- ru: "Доставки мерчанта";
92
- uz: "Hamkor yetkazmalari";
93
- };
94
- generated_at: "2025-08-27 15:04:00";
95
- datetime_from: "2025-08-01 00:00:00";
96
- datetime_to: "2025-08-28 00:00:00";
97
- }
98
- ];
45
+ type Response = AlifManagementEntity.ReportItem[];
99
46
  }
100
47
  }
101
48
 
@@ -1,4 +1,4 @@
1
- import { CallerParam, CallerParamPayload } from '../../../../common/types.js';
1
+ import { CallerParam, CallerParamPayload, CallerNoParam } from '../../../../common/types.js';
2
2
  import { ProductsApi } from './types.js';
3
3
  import { ProductIdBasedParams, WarehouseProductsListParams } from './params.js';
4
4
  import 'axios';
@@ -9,5 +9,6 @@ import '../../../../common/params.js';
9
9
  declare const SingleWarehouseProduct: CallerParam<ProductIdBasedParams, ProductsApi.SingleWarehouse.Response>;
10
10
  declare const UpdateWarehouseProduct: CallerParamPayload<ProductIdBasedParams, ProductsApi.UpdateWarehouse.Request, ProductsApi.UpdateWarehouse.Response>;
11
11
  declare const WarehouseList: CallerParam<WarehouseProductsListParams, ProductsApi.WarehouseList.Response>;
12
+ declare const WarehouseCategoriesList: CallerNoParam<ProductsApi.WarehouseCategoriesList.Response>;
12
13
 
13
- export { SingleWarehouseProduct, UpdateWarehouseProduct, WarehouseList };
14
+ export { SingleWarehouseProduct, UpdateWarehouseProduct, WarehouseCategoriesList, WarehouseList };
@@ -1,4 +1,4 @@
1
- export { SingleWarehouseProduct, UpdateWarehouseProduct, WarehouseList } from './api.js';
1
+ export { SingleWarehouseProduct, UpdateWarehouseProduct, WarehouseCategoriesList, WarehouseList } from './api.js';
2
2
  export { ProductsApi, ProductsEntity } from './types.js';
3
3
  export { ProductIdBasedParams, WarehouseProductsListParams } from './params.js';
4
4
  import '../../../../common/types.js';
@@ -41,6 +41,16 @@ declare namespace ProductsEntity {
41
41
  is_markable: number;
42
42
  };
43
43
  }
44
+ interface WarehouseRequestStatus {
45
+ status: string;
46
+ body_ru: string;
47
+ body_uz: string;
48
+ }
49
+ interface WarehouseCategoryItem {
50
+ id: number;
51
+ name_ru: string;
52
+ name_uz: string;
53
+ }
44
54
  }
45
55
  declare namespace ProductsApi {
46
56
  namespace SingleWarehouse {
@@ -68,6 +78,13 @@ declare namespace ProductsApi {
68
78
  meta: IMetaWithPagination;
69
79
  }
70
80
  }
81
+ namespace WarehouseCategoriesList {
82
+ interface Response {
83
+ can_export_items: boolean;
84
+ item_categories: ProductsEntity.WarehouseCategoryItem[];
85
+ moderation_request_statuses: ProductsEntity.WarehouseRequestStatus[];
86
+ }
87
+ }
71
88
  }
72
89
 
73
90
  export { ProductsApi, ProductsEntity };
@@ -1,6 +1,6 @@
1
1
  export { GetToken, RefreshToken } from './core/auth/api.js';
2
2
  export { AuthApi } from './core/auth/types.js';
3
- export { SingleWarehouseProduct, UpdateWarehouseProduct, WarehouseList } from './core/products/api.js';
3
+ export { SingleWarehouseProduct, UpdateWarehouseProduct, WarehouseCategoriesList, WarehouseList } from './core/products/api.js';
4
4
  export { ProductsApi, ProductsEntity } from './core/products/types.js';
5
5
  export { ProductIdBasedParams, WarehouseProductsListParams } from './core/products/params.js';
6
6
  export { ApplicationsList, DeliverableWithType, SingleApplication } from './core/applications/api.js';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "plaza-sdk",
3
- "version": "1.3.11",
3
+ "version": "1.3.13",
4
4
  "outputDir": "./lib",
5
5
  "exports": {
6
6
  ".": {