@tagsamurai/fats-api-services 1.0.0-alpha.5 → 1.0.0-alpha.50

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.
Files changed (72) hide show
  1. package/api-services.es.js +592 -47
  2. package/api-services.system.js +1 -1
  3. package/main.d.ts +29 -2
  4. package/package.json +1 -1
  5. package/src/dto/aliasCode.dto.d.ts +4 -0
  6. package/src/dto/customField.dto.d.ts +16 -0
  7. package/src/dto/dashboard.dto.d.ts +15 -0
  8. package/src/dto/fileManager.dto.d.ts +25 -0
  9. package/src/dto/groupCategoryService.dto.d.ts +4 -3
  10. package/src/dto/importData.dto.d.ts +7 -0
  11. package/src/dto/importTemporaryData.dto.d.ts +6 -0
  12. package/src/dto/log.dto.d.ts +63 -0
  13. package/src/dto/notification.dto.d.ts +9 -0
  14. package/src/dto/oldAssetService.dto.d.ts +26 -0
  15. package/src/dto/openApi.dto.d.ts +3 -0
  16. package/src/dto/role.dto.d.ts +61 -0
  17. package/src/dto/serviceCenter.dto.d.ts +22 -0
  18. package/src/dto/user.dto.d.ts +143 -0
  19. package/src/services/aliasCode.service.d.ts +10 -0
  20. package/src/services/countryState.service.d.ts +7 -0
  21. package/src/services/fileManager.service.d.ts +53 -0
  22. package/src/services/generalSettings.service.d.ts +6 -0
  23. package/src/services/groupCategory.service.d.ts +3 -2
  24. package/src/services/i18n.service.d.ts +32 -0
  25. package/src/services/importData.service.d.ts +22 -0
  26. package/src/services/notification.service.d.ts +9 -0
  27. package/src/services/oldAliasCode.service.d.ts +10 -0
  28. package/src/services/oldAsset.service.d.ts +20 -0
  29. package/src/services/oldBrand.service.d.ts +7 -0
  30. package/src/services/oldCustomField.service.d.ts +16 -0
  31. package/src/services/oldDashboard.service.d.ts +7 -0
  32. package/src/services/oldFileManager.service.d.ts +53 -0
  33. package/src/services/oldGeneralSettings.service.d.ts +6 -0
  34. package/src/services/oldGroupCategory.service.d.ts +5 -4
  35. package/src/services/oldImportData.service.d.ts +22 -0
  36. package/src/services/oldLog.service.d.ts +14 -0
  37. package/src/services/oldMissing.service.d.ts +5 -0
  38. package/src/services/oldNotification.service.d.ts +7 -0
  39. package/src/services/oldOpenApi.service.d.ts +10 -0
  40. package/src/services/oldReader.service.d.ts +13 -0
  41. package/src/services/oldRole.service.d.ts +53 -0
  42. package/src/services/oldServiceCenter.service.d.ts +19 -0
  43. package/src/services/oldSessionLog.service.d.ts +5 -0
  44. package/src/services/oldTag.service.d.ts +28 -0
  45. package/src/services/oldTracking.service.d.ts +5 -0
  46. package/src/services/oldUser.service.d.ts +56 -0
  47. package/src/services/openApi.service.d.ts +8 -0
  48. package/src/types/aliasCode.type.d.ts +16 -0
  49. package/src/types/customField.type.d.ts +43 -0
  50. package/src/types/dataTable.type.d.ts +7 -0
  51. package/src/types/fetchResponse.type.d.ts +7 -0
  52. package/src/types/fileManager.type.d.ts +24 -0
  53. package/src/types/group.type.d.ts +5 -0
  54. package/src/types/groupCategoryData.type.d.ts +1 -10
  55. package/src/types/i18nService.type.d.ts +22 -0
  56. package/src/types/importData.type.d.ts +92 -0
  57. package/src/types/{changelog.type.d.ts → log.type.d.ts} +21 -0
  58. package/src/types/notification.type.d.ts +17 -0
  59. package/src/types/oldAssetService.type.d.ts +98 -0
  60. package/src/types/oldTagService.type.d.ts +154 -0
  61. package/src/types/reader.d.ts +55 -0
  62. package/src/types/role.type.d.ts +121 -0
  63. package/src/types/serviceCenter.type.d.ts +29 -0
  64. package/src/types/user.type.d.ts +177 -0
  65. package/src/types/userAsset.type.d.ts +18 -0
  66. package/src/types/userGlobalRole.type.d.ts +28 -0
  67. package/src/types/userGroupRole.type.d.ts +30 -0
  68. package/src/types/userLog.type.d.ts +18 -0
  69. package/src/types/userSystemRole.type.d.ts +14 -0
  70. package/src/types/userTransactionRole.type.d.ts +9 -0
  71. package/src/dto/changelog.dto.d.ts +0 -30
  72. package/src/services/oldChangelog.service.d.ts +0 -9
@@ -1,16 +1,16 @@
1
- import P from "axios";
2
- const _ = { BASE_URL: "/", DEV: !1, MODE: "production", PROD: !0, SSR: !1, VITE_APP_API: "https://dev-api.tagsamurai.com", VITE_APP_COUNTRY_STATE_API: "https://api.countrystatecity.in", VITE_APP_COUNTRY_STATE_API_KEY: "ZTc5TVc2STlwTkFFNFltYTRjc05sOHR3ODJEYzVMVTZ5UnBJaWU5SA==", VITE_APP_LOGS_NOTIFICATION_API: "https://dev-api-logs-notification.tagsamurai.com", VITE_APP_TAGSAMURAI_API: "https://dev-api.tagsamurai.com" }, i = (t = "APP_API") => _["VITE_" + t], c = (t = {}, e = !1) => {
3
- const { env: r = "APP_API", prefix: n = "", headers: s = {}, ...a } = t, u = `${i(r)}${n}`, g = JSON.parse(localStorage.getItem("user") ?? "{}"), A = g.jwt ?? g.token ?? "";
4
- return P.create({
5
- ...a,
6
- baseURL: u,
7
- headers: e ? s : {
1
+ import b from "axios";
2
+ const N = { BASE_URL: "/", DEV: !1, MODE: "production", PROD: !0, SSR: !1, VITE_APP_ADMIN_API: "https://dev-admin-api.tagsamurai.com", VITE_APP_API: "https://dev-api.tagsamurai.com", VITE_APP_COUNTRY_STATE_API: "https://api.countrystatecity.in", VITE_APP_COUNTRY_STATE_API_KEY: "ZTc5TVc2STlwTkFFNFltYTRjc05sOHR3ODJEYzVMVTZ5UnBJaWU5SA==", VITE_APP_LOGS_NOTIFICATION_API: "https://dev-api-logs-notification.tagsamurai.com", VITE_APP_TAGSAMURAI_API: "https://dev-api.tagsamurai.com" }, f = (t = "APP_API") => N["VITE_" + t], s = (t = {}, e = !1) => {
3
+ const { env: r = "APP_API", prefix: a = "", headers: C = {}, ...x } = t, F = `${f(r)}${a}`, L = JSON.parse(localStorage.getItem("user") ?? "{}"), E = L.jwt ?? L.token ?? "";
4
+ return b.create({
5
+ ...x,
6
+ baseURL: F,
7
+ headers: e ? C : {
8
8
  "Content-Type": "application/json",
9
- Authorization: `Bearer ${A}`,
10
- ...s
9
+ Authorization: `Bearer ${E}`,
10
+ ...C
11
11
  }
12
12
  });
13
- }, f = (t) => {
13
+ }, V = (t) => {
14
14
  if (!t || typeof t == "string")
15
15
  return;
16
16
  const e = {};
@@ -21,66 +21,611 @@ const _ = { BASE_URL: "/", DEV: !1, MODE: "production", PROD: !0, SSR: !1, VITE_
21
21
  [r]: t[r]
22
22
  });
23
23
  }), e;
24
- }, T = (t, e, r) => {
24
+ }, Y = (t) => {
25
25
  if (!t) return;
26
- const n = i("APP_API"), s = t.startsWith("http") ? t : `${n}/utility/v2/files/${t.replace(/^\/+/, "")}`;
27
- if (e || r) {
28
- const a = new URLSearchParams();
29
- return e && (a.set("width", e.toString()), a.set("height", r ? r == null ? void 0 : r.toString() : e.toString())), `${s}?${a.toString()}`;
30
- }
31
- return s;
32
- }, S = (t) => {
33
- if (!t) return;
34
- const e = i("APP_TAGSAMURAI_API");
26
+ const e = f("APP_TAGSAMURAI_API");
35
27
  return t.startsWith("http") ? t : `${e}/file-manager/v2/files/${t}`;
36
- }, o = c({
28
+ }, c = s({
37
29
  prefix: "/settings-attribute/v2",
38
30
  env: "APP_TAGSAMURAI_API"
39
- }), v = {
40
- getGroupCategory: (t) => {
31
+ }), Q = {
32
+ getGroupCategory: (t, e) => {
33
+ const r = t === "category" ? t : "groups";
34
+ return c.get(`/${r}/tree`, { params: e });
35
+ },
36
+ getGroupCategoryList: (t, e, r) => {
37
+ const a = t === "category" ? t : "groups";
38
+ return c.get(`/${a}/${e}`, { params: r });
39
+ },
40
+ getNames: (t) => {
41
41
  const e = t === "category" ? t : "groups";
42
- return o.get(`/${e}/tree`);
42
+ return c.get(`/${e}/names`);
43
+ },
44
+ getCodes: (t) => {
45
+ const e = t === "category" ? t : "groups";
46
+ return c.get(`/${e}/codes`);
47
+ },
48
+ postCreateGroupCategory: (t, e) => {
49
+ const r = t === "category" ? t : "groups";
50
+ return c.post(`/${r}`, e);
51
+ },
52
+ putEditGroupCategory: (t, e, r) => {
53
+ const a = t === "category" ? t : "groups";
54
+ return c.put(`/${a}/${r}`, e);
55
+ },
56
+ putMoveGroup: (t, e) => c.put(`/groups/${e}/move-group`, t),
57
+ putEditBulkGroups: async (t) => c.put("/groups/bulk", t),
58
+ deleteGroupCategory: (t, e, r) => {
59
+ const a = t === "category" ? t : "groups";
60
+ return c.delete(`/${a}/${r}`, { data: e });
61
+ }
62
+ }, l = s({
63
+ prefix: "/settings-attribute-go/v2"
64
+ }), J = {
65
+ getGroupCategory: (t, e) => {
66
+ const r = t === "category" ? t : "groups";
67
+ return l.get(`/${r}/tree`, { params: e });
43
68
  },
44
69
  getGroupCategoryList: (t, e) => {
45
70
  const r = t === "category" ? t : "groups";
46
- return o.get(`/${r}/${e}`);
71
+ return l.get(`/${r}/${e}`);
47
72
  },
48
73
  getNames: (t) => {
49
74
  const e = t === "category" ? t : "groups";
50
- return o.get(`/${e}/names`);
75
+ return l.get(`/${e}/names`);
76
+ },
77
+ getCodes: (t) => {
78
+ const e = t === "category" ? t : "groups";
79
+ return l.get(`/${e}/codes`);
51
80
  },
52
81
  postCreateGroupCategory: (t, e) => {
53
82
  const r = t === "category" ? t : "groups";
54
- return o.post(`/${r}`, e);
83
+ return l.post(`/${r}`, e);
55
84
  },
56
85
  putEditGroupCategory: (t, e, r) => {
57
- const n = t === "category" ? t : "groups";
58
- return o.put(`/${n}/${r}`, e);
86
+ const a = t === "category" ? t : "groups";
87
+ return l.put(`/${a}/${r}`, e);
59
88
  },
60
- putMoveGroup: (t, e) => o.put(`/groups/${e}/move-group`, t),
61
- putEditBulkGroups: async (t) => o.put("/bulk", t),
62
89
  deleteGroupCategory: (t, e, r) => {
63
- const n = t === "category" ? t : "groups";
64
- return o.delete(`/${n}/${r}`, { data: e });
90
+ const a = t === "category" ? t : "groups";
91
+ return l.delete(`/${a}/${r}`, { data: e });
65
92
  }
66
- }, I = c({
93
+ }, M = s({
67
94
  prefix: "/v2",
68
95
  env: "APP_LOGS_NOTIFICATION_API"
69
- }), $ = {
70
- getTotalApprovals: () => I.get("/approval/count")
71
- }, p = c({
96
+ }), H = {
97
+ getTotalApprovals: () => M.get("/approval/count")
98
+ }, P = s({
72
99
  prefix: "/v2",
73
100
  env: "APP_LOGS_NOTIFICATION_API"
74
- }), O = {
75
- getActionLog: (t) => p.get("/change-log", { params: t }),
76
- getActionLogOption: (t) => p.get("/change-log/options", { params: t })
101
+ }), K = {
102
+ getActionLog: (t) => P.get("/change-log", { params: t }),
103
+ getActionLogOption: (t) => P.get("/change-log/options", { params: t }),
104
+ getSessionLogList: (t) => P.get("/session-log", { params: t }),
105
+ getUserDetailSystemLogList: (t) => P.get("/change-log", { params: t }),
106
+ getUserDetailSystemLogOption: (t) => P.get("/change-log/options", { params: t })
107
+ }, u = s({
108
+ prefix: "/assets/v2/assets"
109
+ }), W = {
110
+ getScanTag: (t) => u.get("/scan", { params: { tag: t } }),
111
+ getAllAssets: (t) => u.get("/", { params: t }),
112
+ getAvailableAssets: (t) => u.get("/available", { params: t }),
113
+ scanAsset: (t) => u.get("", { params: { tag: t } }),
114
+ getAssetsById: (t, e) => u.get("/by-id", { params: { _id: t, ...e } }),
115
+ getOptions: (t, e) => u.get(t ? `/${t}/options` : "/options", { params: e }),
116
+ getUnlinkedAssets: (t) => u.get("/unlinked", { params: t }),
117
+ getAssetDetail: (t, e) => u.get(`/${t}`, { params: e }),
118
+ getLinkedAssetFamily: (t) => u.get("/family", { params: { id: t } }),
119
+ matchAssetWithTag: (t, e) => {
120
+ const r = {
121
+ _id: JSON.stringify([t]),
122
+ tag: e
123
+ };
124
+ return u.get("/by-id", { params: r });
125
+ }
126
+ }, k = s({
127
+ prefix: "/tracking/v2/missing"
128
+ }), z = {
129
+ putFoundAsset: (t, e) => {
130
+ const r = { ids: [t], serialNumber: e };
131
+ return k.put("/found", r);
132
+ }
133
+ }, G = s({
134
+ prefix: "/v2/notification",
135
+ env: "APP_LOGS_NOTIFICATION_API"
136
+ }), Z = {
137
+ getNotifications: (t) => G.get("/", { params: t }),
138
+ readNotification: (t) => G.put(`/${t}`)
139
+ }, U = s({
140
+ prefix: "/utility/v2/notification"
141
+ }), X = {
142
+ getNotifications: (t) => U.get("/", { params: t }),
143
+ readNotification: (t) => U.put(`/${t}`)
144
+ }, w = s({
145
+ prefix: "/v2/session-log",
146
+ env: "APP_LOGS_NOTIFICATION_API"
147
+ }), tt = {
148
+ postLogout: () => w.post("/logout")
149
+ }, n = s({
150
+ prefix: "/tag/v2"
151
+ }), et = {
152
+ getScanQR: (t) => n.get("/qr", { params: { tag: t } }),
153
+ getScanRFID: (t) => n.get("/rfid", { params: { tag: t } }),
154
+ getRFIDQRTAG: (t) => n.get("/rfid-qr/scan", { params: t }),
155
+ getEventLog: (t) => n.get("/tag-transaction/event-log", { params: t }),
156
+ // Tab All
157
+ getRfidQrAll: (t, e) => n.get(`/${t}`, { params: e }),
158
+ // Tab Paired
159
+ getRfidQrPaired: (t, e, r) => n.get(`/${t}/paired/${e}`, { params: r }),
160
+ postAddTAGtoPrelist: (t, e) => n.post(`/prelist/${e}/asset-name`, { body: t }),
161
+ postAddTAGToPrelistUnpair: (t) => n.post("/prelist/unpair-tag", { body: t }),
162
+ postAddTAGtoPending: (t) => n.post("/pending-changes", { body: t }),
163
+ // Available Tab
164
+ getRFIDQrAvailable: (t, e) => n.get(`/${t}/available`, { params: e }),
165
+ // Damaged TAB
166
+ getRFIDQrDamaged: (t, e) => n.get(`/${t}/damaged`, { params: e }),
167
+ // RFID and QR Module
168
+ getRFIDandQRList: (t) => n.get("/rfid-qr", { params: t }),
169
+ deleteUnpairTAG: (t) => n.delete("/rfid-qr", { data: { data: t } }),
170
+ postPairTAG: (t) => n.post("/rfid-qr", { body: { data: t } }),
171
+ // RFID To Be Returned
172
+ getToBeReturnedTAGList: (t) => n.get("/rfid/to-be-returned", { params: t }),
173
+ // Handover TAG
174
+ putHandoverTAG: (t) => n.put("/rfid/handover", { body: { data: t } }),
175
+ // Table Filter
176
+ getFilterOptions: (t, e) => n.get(`/${t}/options`, { params: e }),
177
+ getHolderListOptions: (t) => n.get("/rfid/holder-list/options", { params: t }),
178
+ getHolderList: (t) => n.get("/rfid/holder-list", { params: t }),
179
+ putAuditTAG: (t, e) => n.put(`/${e}/audit`, { body: t }),
180
+ postLogAudit: (t) => n.post("/tag-transaction/log-audit", { body: t })
181
+ }, q = s({
182
+ prefix: "/tracking/v2/tracking"
183
+ }), rt = {
184
+ putFoundAsset: (t, e, r) => {
185
+ const a = {
186
+ tag: t,
187
+ group: e,
188
+ serialNumber: r,
189
+ type: "Global"
190
+ };
191
+ return q.put("/found", { params: a });
192
+ }
193
+ }, o = s({
194
+ prefix: "/settings-user-role/v2"
195
+ }), st = {
196
+ reLogin: (t) => o.post("/auth/login", t),
197
+ changePassword: (t) => o.put("/users/change-password", t),
198
+ /**
199
+ * Retrieves the user list as dropdown options.
200
+ * @returns {Promise<AxiosResponse>} - A promise that resolves to the response from the API.
201
+ */
202
+ getUserDropdown: (t) => o.get("/users/dropdown", { params: t }),
203
+ getUserOptions: (t) => o.get("/users/options", { params: t }),
204
+ getUserList: (t) => o.get("/users", { params: t }),
205
+ getUserDetail: (t) => o.get(`/users/${t}`),
206
+ putEditUser: (t, e) => {
207
+ const r = { "Content-Type": "multipart/form-data" };
208
+ return o.put(`/users/${t}`, e, { headers: r });
209
+ },
210
+ putDeleteProfilePicture: (t) => o.put(`/users/${t}/delete-profile-picture`),
211
+ putCancelEmailChange: (t, e) => o.put("/auth/confirm-email-change/cancel", {
212
+ user: t,
213
+ companyCode: e
214
+ }),
215
+ /**
216
+ *
217
+ * @param id {string} User's _id
218
+ * @param type {"Global" | "Group"} Whether the system role's type is global or group
219
+ * @param params {Record<string, unknown>}
220
+ */
221
+ getUserDetailSystemRoles: (t, e, r) => o.get(`/user-detail/${t}/system-roles`, {
222
+ params: {
223
+ ...r,
224
+ type: e
225
+ }
226
+ }),
227
+ // User Detail
228
+ getUserDetailSystemRoleList: (t, e) => o.get(`/user-detail/${t}/system-role-list`, { params: e }),
229
+ getUserDetailSystemRoleOptions: (t, e) => o.get(`/user-detail/${t}/system-role/option`, { params: e }),
230
+ getUserDetailTransactionRoleList: (t, e) => o.get(`/user-detail/${t}/transaction-role-list`, { params: e }),
231
+ getUserDetailUserLogBorrowingList: (t, e) => o.get(`/users-log/${t}/borrowing`, { params: e }),
232
+ getUserDetailUserLogAssignmentList: (t, e) => o.get(`/users-log/${t}/assignment`, { params: e }),
233
+ getUserDetailUserLogBorrowingOption: (t, e) => o.get(`/users-log/${t}/borrowing/option`, { params: e }),
234
+ getUserDetailUserLogAssignmentOption: (t, e) => o.get(`/users-log/${t}/assignment/option`, { params: e }),
235
+ getUserDetailTransactionAdminLogList: (t, e) => o.get(`/users-log/${t}/transaction-log`, { params: e }),
236
+ getUserDetailTransactionAdminLogOption: (t, e) => o.get(`/users-log/${t}/transaction-log/option`, { params: e })
237
+ }, y = s({
238
+ env: "APP_ADMIN_API",
239
+ prefix: "/settings-attribute/languages"
240
+ }), nt = {
241
+ /**
242
+ * Fetch all translation messages for a specific locale.
243
+ * @param locale The locale code (e.g., 'en', 'id').
244
+ * @returns A promise resolving to a key-value record of messages.
245
+ */
246
+ getMessages: (t) => y.get(`/${t}/translations`),
247
+ /**
248
+ * Fetch all available lang options for LanguageDropdown and LanguageSwitcher
249
+ *
250
+ * @returns Promise Array of options
251
+ */
252
+ getLanguageOptions: async () => {
253
+ const { data: t } = await y.get(
254
+ "/dropdown"
255
+ );
256
+ return t.data;
257
+ },
258
+ /**
259
+ * Fetch single lang option meta data
260
+ *
261
+ * @param isoCode The locale code (e.g., 'en', 'id').
262
+ * @returns Promise LanguageMeta
263
+ */
264
+ getLanguageOptionMeta: async (t) => {
265
+ const { data: e } = await y.get(
266
+ "/dropdown/" + t
267
+ );
268
+ return e.data;
269
+ },
270
+ /**
271
+ * Translate a specific text to the target locale.
272
+ *
273
+ * @param key Unique translation key.
274
+ * @param locale Target locale code.
275
+ */
276
+ translateText: async (t, e) => {
277
+ const { data: r } = await y.post("/translate", {
278
+ q: t,
279
+ target: e
280
+ });
281
+ return r.data.translations[t];
282
+ }
283
+ }, h = s({
284
+ prefix: "/dashboard/v2/dashboard"
285
+ }), ot = {
286
+ getLatestTask: (t) => h.get("/latest-task", { params: t }),
287
+ getSummary: (t) => h.get("/summary", { params: t })
288
+ }, O = s({
289
+ prefix: "/alias-code/api/alias-code"
290
+ }), it = {
291
+ getAliasCode: () => O.get("/"),
292
+ postAliasCode: (t) => O.post("/", t),
293
+ getAliasCodeList: (t) => O.get(`/${t.object}/code-list`, { params: t })
294
+ }, T = s({
295
+ prefix: "/settings-attribute-go/v2/alias-code"
296
+ }), at = {
297
+ getAliasCode: () => T.get("/"),
298
+ postAliasCode: (t) => T.post("/", t),
299
+ getAliasCodeList: (t) => T.get(`/${t.object}/code-list`, { params: t })
300
+ }, D = s({
301
+ prefix: "/settings-attribute/v2/general-settings"
302
+ }), gt = {
303
+ getGeneralSettings: () => D.get("/"),
304
+ putUpdateGeneralSettings: (t) => D.put("/", t)
305
+ }, R = s({
306
+ prefix: "/settings-attribute-go/v2/general-settings"
307
+ }), ut = {
308
+ getGeneralSettings: () => R.get("/"),
309
+ putUpdateGeneralSettings: (t) => R.put("/", t)
310
+ }, $ = s({
311
+ prefix: "/settings-attribute/v2/custom-field"
312
+ }), ct = {
313
+ getCustomField: async (t) => $.get("/", { params: t }),
314
+ getOptions: async (t) => $.get("/options", { params: t }),
315
+ postCreateCustomField: async (t, e) => $.post("/", e, { params: t }),
316
+ putEditCustomField: async (t, e, r) => $.put(`/${r}`, e, { params: t }),
317
+ putChangeStatus: async (t, e) => $.put("/bulk", e, { params: t }),
318
+ deleteCustomField: async (t) => $.delete("/bulk", { data: t })
319
+ }, _ = ({ headers: t = {}, params: e = {} } = {}) => {
320
+ const r = f("APP_COUNTRY_STATE_API"), a = f("APP_COUNTRY_STATE_API_KEY");
321
+ return b.create({
322
+ baseURL: `${r}/v1`,
323
+ headers: {
324
+ "Content-type": "application/json",
325
+ "X-CSCAPI-KEY": a,
326
+ ...t
327
+ },
328
+ params: e
329
+ });
330
+ }, pt = {
331
+ getCountry: () => _().get("/countries"),
332
+ getState: (t) => _().get(`/countries/${t}/states`),
333
+ getCity: (t, e) => _().get(`/countries/${t}/states/${e}/cities`)
334
+ }, g = s({
335
+ prefix: "/routine/v2"
336
+ }), lt = {
337
+ getList: (t) => g.get("/service-center", { params: t }),
338
+ postList: (t) => g.post("/service-center", t),
339
+ putList: (t, e) => g.put(`/service-center/${t}`, e),
340
+ putActivate: (t) => g.put("/service-center/bulk", t),
341
+ getDetailList: (t) => g.get(`/service-center/${t}`),
342
+ getListOptions: (t) => g.get("/service-center/options", { params: t }),
343
+ deleteList: (t) => g.delete("/service-center", { params: t }),
344
+ // Activities
345
+ getActivities: (t) => g.get("/service-activities", { params: t }),
346
+ getActivityOptions: (t) => g.get("/service-activities/options", { params: t }),
347
+ getActivityDetail: (t) => g.get(`/service-activities/${t}`),
348
+ getActivityLog: (t) => g.get(`/service-activities/${t}/activity-log`)
349
+ }, B = s({
350
+ prefix: "/settings-attribute/v2/brands"
351
+ }), dt = {
352
+ getDropdown: (t) => B.get("/dropdown", { params: t })
353
+ }, v = s({
354
+ prefix: "/file-manager/v2"
355
+ }), At = {
356
+ /**
357
+ * Get storage information.
358
+ *
359
+ * @returns {Promise<AxiosResponse>} The Axios Response.
360
+ */
361
+ getStorageInformation: () => v.get("/files/storage"),
362
+ /**
363
+ * Get file manager data.
364
+ *
365
+ * @param {FileType} type - The type of the file.
366
+ * @param {FileManagerFilterParams} [params] - The parameters for filtering.
367
+ * @returns {Promise<AxiosResponse>} The Axios Response.
368
+ */
369
+ getFileManager: (t, e) => v.get(`/${t}`, { params: e }),
370
+ /**
371
+ * Get file manager options.
372
+ *
373
+ * @param {FileType} type - The type of the file.
374
+ * @param {FileManagerOptionBoolean} [params] - The parameters for options.
375
+ * @returns {Promise<AxiosResponse>} The Axios Response.
376
+ */
377
+ getFileManagerOption: (t, e) => v.get(`/${t}/options`, { params: e }),
378
+ /**
379
+ * Recover files.
380
+ *
381
+ * @param {FileType} type - The type of the file.
382
+ * @param {object} body - The body of the request.
383
+ * @returns {Promise<AxiosResponse>} The Axios Response.
384
+ */
385
+ recoverFiles: (t, e) => v.put(`/${t}/recover`, e),
386
+ /**
387
+ * Delete files.
388
+ *
389
+ * @param {FileType} type - The type of the file.
390
+ * @param {DeleteFileManagerDto} params - The params of the request.
391
+ * @returns {Promise<AxiosResponse>} The Axios Response.
392
+ */
393
+ deleteFiles: (t, e) => v.delete(`/${t}`, { params: e }),
394
+ /**
395
+ * Delete files permanently.
396
+ *
397
+ * @param {FileType} type - The type of the file.
398
+ * @param {object} body - The body of the request.
399
+ * @returns {Promise<AxiosResponse>} The Axios Response.
400
+ */
401
+ deletePermanently: (t, e) => v.delete(`/${t}/delete-permanent`, { params: e })
402
+ }, I = s({
403
+ prefix: "/utility/v2"
404
+ }), $t = {
405
+ /**
406
+ * Get storage information.
407
+ *
408
+ * @returns {Promise<AxiosResponse>} The Axios Response.
409
+ */
410
+ getStorageInformation: () => I.get("/files/storage"),
411
+ /**
412
+ * Get file manager data.
413
+ *
414
+ * @param {FileType} type - The type of the file.
415
+ * @param {FileManagerFilterParams} [params] - The parameters for filtering.
416
+ * @returns {Promise<AxiosResponse>} The Axios Response.
417
+ */
418
+ getFileManager: (t, e) => I.get(`/${t}`, { params: e }),
419
+ /**
420
+ * Get file manager options.
421
+ *
422
+ * @param {FileType} type - The type of the file.
423
+ * @param {FileManagerOptionBoolean} [params] - The parameters for options.
424
+ * @returns {Promise<AxiosResponse>} The Axios Response.
425
+ */
426
+ getFileManagerOption: (t, e) => I.get(`/${t}/options`, { params: e }),
427
+ /**
428
+ * Recover files.
429
+ *
430
+ * @param {FileType} type - The type of the file.
431
+ * @param {object} body - The body of the request.
432
+ * @returns {Promise<AxiosResponse>} The Axios Response.
433
+ */
434
+ recoverFiles: (t, e) => I.put(`/${t}/recover`, e),
435
+ /**
436
+ * Delete files.
437
+ *
438
+ * @param {FileType} type - The type of the file.
439
+ * @param {DeleteFileManagerDto} params - The params of the request.
440
+ * @returns {Promise<AxiosResponse>} The Axios Response.
441
+ */
442
+ deleteFiles: (t, e) => I.delete(`/${t}`, { params: e }),
443
+ /**
444
+ * Delete files permanently.
445
+ *
446
+ * @param {FileType} type - The type of the file.
447
+ * @param {object} body - The body of the request.
448
+ * @returns {Promise<AxiosResponse>} The Axios Response.
449
+ */
450
+ deletePermanently: (t, e) => I.delete(`/${t}/delete-permanent`, { params: e })
451
+ }, p = s({
452
+ prefix: "/iot/v2/reader"
453
+ }), vt = {
454
+ getData: (t) => p.get("/", { params: t }),
455
+ getDataOptions: (t) => p.get("/options", { params: t }),
456
+ getActivityLogData: (t) => p.get("/activity-log", { params: t }),
457
+ getActivityLogOptions: (t) => p.get("/activity-log/options", { params: t }),
458
+ getDataById: (t) => p.get(`/${t}`),
459
+ getChangeLog: (t) => p.get(`/${t.id}/change-log`, { params: t }),
460
+ getChangeLogOptions: (t) => p.get(`/${t.id}/change-log/options`, { params: t }),
461
+ putData: (t, e) => p.put(`/${t}`, e)
462
+ }, i = s({
463
+ prefix: "/settings-user-role/v2"
464
+ }), It = {
465
+ /**
466
+ * Retrieves the transaction role for the given group and transaction name.
467
+ * @param {string} groupId - The ID of the group to retrieve the transaction role for.
468
+ * @param {string} transactionName - The name of the transaction to retrieve the role for.
469
+ * @returns {Promise<AxiosResponse>} - A promise that resolves to the response from the API.
470
+ */
471
+ getTransactionRole: (t, e) => i.get(`/transaction-roles/${t}/${e}`),
472
+ /**
473
+ * Updates the users assigned to the given transaction role.
474
+ * @param {string} groupId - The ID of the group the transaction role belongs to.
475
+ * @param {string} transactionName - The name of the transaction to update.
476
+ * @param {UpdateUser} body - The request body containing the updated user information.
477
+ * @returns {Promise<AxiosResponse>} - A promise that resolves to the response from the API.
478
+ */
479
+ putUpdateUsers: (t, e, r) => i.put(
480
+ `/transaction-roles/${t}/${e}/update-user`,
481
+ r
482
+ ),
483
+ /**
484
+ * Updates the approval level for the given transaction role.
485
+ * @param {string} groupId - The ID of the group the transaction role belongs to.
486
+ * @param {string} transactionName - The name of the transaction to update.
487
+ * @param {UserApprovalLevel} body - The request body containing the updated approval level.
488
+ * @returns {Promise<AxiosResponse>} - A promise that resolves to the response from the API.
489
+ */
490
+ putUpdateLevel: (t, e, r) => i.put(
491
+ `/transaction-roles/${t}/${e}/update-approval-level`,
492
+ r
493
+ ),
494
+ /**
495
+ * Updates the group management settings for the given transaction role.
496
+ * @param {string} groupId - The ID of the group the transaction role belongs to.
497
+ * @param {string} transactionName - The name of the transaction to update.
498
+ * @param {GroupManageByParent} body - The request body containing the updated management settings.
499
+ * @returns {Promise<AxiosResponse>} - A promise that resolves to the response from the API.
500
+ */
501
+ putUpdateGroupManage: (t, e, r) => i.put(
502
+ `/transaction-roles/${t}/${e}/update-manage-by-parent`,
503
+ r
504
+ ),
505
+ getAssignedUserAmounts: () => i.get("/system-roles/amounts"),
506
+ getPermissionUser: (t, e) => {
507
+ if (["totalControl", "readOnly"].includes(t ?? "")) {
508
+ const r = t === "totalControl" ? "total-control" : "read-only";
509
+ return i.get(`/system-roles/total-control-read-only/${r}`, {
510
+ params: e
511
+ });
512
+ }
513
+ return i.get(`/system-roles/permission/${t}`, { params: e });
514
+ },
515
+ getPermissionUserOptions: (t, e) => {
516
+ if (["totalControl", "readOnly"].includes(t ?? "")) {
517
+ const r = t === "totalControl" ? "total-control" : "read-only";
518
+ return i.get(`/system-roles/total-control-read-only/${r}/options`, {
519
+ params: e
520
+ });
521
+ }
522
+ return i.get(`/system-roles/permission/${t}/options`, {
523
+ params: e
524
+ });
525
+ },
526
+ getUserGroups: (t, e) => i.get(`/system-roles/permission/${e}/groups`, {
527
+ params: t
528
+ }),
529
+ postAssignUser: (t, e) => {
530
+ if (["totalControl", "readOnly"].includes(e ?? "")) {
531
+ const r = e === "totalControl" ? "total-control" : "read-only";
532
+ return i.post(`/system-roles/total-control-read-only/${r}`, t);
533
+ }
534
+ return i.post(`/system-roles/permission/${e}`, t);
535
+ },
536
+ putEditUser: (t, e) => i.put(`/system-roles/${e}`, t),
537
+ putSetActive: (t, e) => {
538
+ if (["totalControl", "readOnly"].includes(e ?? "")) {
539
+ const r = e === "totalControl" ? "total-control" : "read-only";
540
+ return i.put(`/system-roles/total-control-read-only/${r}`, t);
541
+ }
542
+ return i.put("/system-roles/set-active", t);
543
+ },
544
+ deleteRemoveUser: (t, e) => {
545
+ if (["totalControl", "readOnly"].includes(e ?? "")) {
546
+ const r = e === "totalControl" ? "total-control" : "read-only";
547
+ return i.delete(`/system-roles/total-control-read-only/${r}`, {
548
+ data: t
549
+ });
550
+ }
551
+ return i.delete("/system-roles", { data: t });
552
+ }
553
+ }, m = s({
554
+ prefix: "/settings-attribute/v2/open-api"
555
+ }), Pt = {
556
+ getOpenAPIDocs: (t) => m.get(`/${t.doc}`),
557
+ putGenerateToken: () => m.put("/generate"),
558
+ // This is if the dummy was not dummy
559
+ getToken: () => m.get(""),
560
+ putRequestOpenAPI: () => m.put("/request"),
561
+ putCancelRequestOpenAPI: () => m.put("/cancel-request")
562
+ }, S = s({
563
+ prefix: "/settings-attribute-go/v2/open-api"
564
+ }), mt = {
565
+ putGenerateToken: () => S.put("/generate"),
566
+ // This is if the dummy was not dummy
567
+ getToken: () => S.get(""),
568
+ putRequestOpenAPI: () => S.put("/request"),
569
+ putCancelRequestOpenAPI: () => S.put("/cancel-request")
570
+ }, d = s({
571
+ prefix: "/import/v2"
572
+ }), yt = {
573
+ getImport: (t, e) => d.get(`/${t}`, { params: e }),
574
+ postImportTemporary: (t, e) => {
575
+ const r = { "Content-Type": "multipart/form-data" };
576
+ return d.post(`/${t}/temporary`, e, { headers: r });
577
+ },
578
+ deleteImportTemporary: (t, e) => d.delete(`/${t}/temporary`, { data: e }),
579
+ postDuplicateImport: (t, e) => d.post(`/${t}/duplicate`, e),
580
+ putEditImport: (t, e) => d.put(`/${t}`, e),
581
+ postImport: (t, e, r) => d.post(t, r, { signal: e.signal }),
582
+ putImportCancelProgress: (t) => d.put(`/${t}/cancel-progress`)
583
+ }, A = s({
584
+ prefix: "/import-go/v2"
585
+ }), St = {
586
+ getImport: (t, e) => A.get(`/${t}`, { params: e }),
587
+ postImportTemporary: (t, e) => {
588
+ const r = { "Content-Type": "multipart/form-data" };
589
+ return A.post(`/${t}/temporary`, e, { headers: r });
590
+ },
591
+ deleteImportTemporary: (t, e) => A.delete(`/${t}/temporary`, { params: e }),
592
+ postDuplicateImport: (t, e) => A.post(`/${t}/duplicate`, e),
593
+ putEditImport: (t, e) => A.put(`/${t}`, e),
594
+ postImport: (t, e, r) => A.post(t, r, { signal: e.signal }),
595
+ putImportCancelProgress: (t) => A.put(`/${t}/cancel-progress`)
77
596
  };
78
597
  export {
79
- O as ChangelogServices,
80
- v as GroupCategoryServices,
81
- $ as NotificationApprovalServices,
82
- i as getBaseURL,
83
- T as getImageURL,
84
- S as oldGetImageURL,
85
- f as queryParamsStringfy
598
+ it as AliasCodeServices,
599
+ at as AliasCodeServicesGo,
600
+ W as AssetServices,
601
+ dt as BrandServices,
602
+ K as ChangelogServices,
603
+ pt as CountryStateServices,
604
+ ct as CustomFieldServices,
605
+ ot as DashboardServices,
606
+ At as FileManagerServices,
607
+ $t as FileManagerServicesGo,
608
+ gt as GeneralSettingsServices,
609
+ ut as GeneralSettingsServicesGo,
610
+ Q as GroupCategoryServices,
611
+ J as GroupCategoryServicesGo,
612
+ nt as I18nService,
613
+ yt as ImportServices,
614
+ St as ImportServicesGo,
615
+ z as MissingServices,
616
+ H as NotificationApprovalServices,
617
+ Z as NotificationServices,
618
+ X as NotificationServicesGo,
619
+ Pt as OpenAPIServices,
620
+ mt as OpenAPIServicesGo,
621
+ vt as ReaderServices,
622
+ It as RoleServices,
623
+ lt as ServiceCenterServices,
624
+ tt as SessionLogServices,
625
+ et as TAGServices,
626
+ rt as TrackingServices,
627
+ st as UserServices,
628
+ f as getBaseURL,
629
+ Y as getImageURL,
630
+ V as queryParamsStringfy
86
631
  };