@tagsamurai/fats-api-services 1.0.0-alpha.227 → 1.0.0-alpha.228

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.
@@ -22,6 +22,9 @@ const createAxiosInstance = (config = {}, useDifferentHeaders = false) => {
22
22
  });
23
23
  return instance;
24
24
  };
25
+ const SERVER_PREFIX = {
26
+ SETTINGS_ATTRIBUTES: "settings-attribute"
27
+ };
25
28
  const queryParamsStringfy = (data) => {
26
29
  if (!data || typeof data === "string") {
27
30
  return;
@@ -69,7 +72,7 @@ const getAssetsFile = async (file, type = "excel") => {
69
72
  return response;
70
73
  };
71
74
  const API$T = createAxiosInstance({
72
- prefix: "/settings-attribute/v2"
75
+ prefix: "/settings-attribute-go/v2"
73
76
  });
74
77
  const getEndpoint = (type) => {
75
78
  return type === "category" ? "category" : "groups";
@@ -107,7 +110,7 @@ const GroupCategoryServices = {
107
110
  }
108
111
  };
109
112
  const API$S = createAxiosInstance({
110
- prefix: "/settings-attribute/v2/alias-code"
113
+ prefix: "/settings-attribute-go/v2/alias-code"
111
114
  });
112
115
  const AliasCodeServices = {
113
116
  getAliasCode: () => {
@@ -121,7 +124,7 @@ const AliasCodeServices = {
121
124
  }
122
125
  };
123
126
  const API$R = createAxiosInstance({
124
- prefix: "/settings-attribute/v2/general-settings"
127
+ prefix: "/settings-attribute-go/v2/general-settings"
125
128
  });
126
129
  const GeneralSettingsServices = {
127
130
  getGeneralSettings: () => {
@@ -330,7 +333,7 @@ const AssetServices$1 = {
330
333
  }
331
334
  };
332
335
  const AssetsAPIs = createAxiosInstance({
333
- prefix: "/assets/v2/assets"
336
+ prefix: "/assets-go/v2/assets"
334
337
  });
335
338
  const AssetServices = {
336
339
  getAllAssets: (params) => {
@@ -702,7 +705,7 @@ const UserServices$1 = {
702
705
  }
703
706
  };
704
707
  const API$F = createAxiosInstance({
705
- prefix: "/settings-user-role/v2"
708
+ prefix: "/settings-user-role-go/v2"
706
709
  });
707
710
  const UserServices = {
708
711
  /**
@@ -807,7 +810,7 @@ const SubUserServices$1 = {
807
810
  }
808
811
  };
809
812
  const API$D = createAxiosInstance({
810
- prefix: "/settings-user-role/v2/users"
813
+ prefix: "/settings-user-role-go/v2/users"
811
814
  });
812
815
  const SubUserServices = {
813
816
  // Sub User
@@ -943,7 +946,7 @@ const CustomFieldServices$1 = {
943
946
  }
944
947
  };
945
948
  const API$z = createAxiosInstance({
946
- prefix: "/settings-attribute/v2/custom-field"
949
+ prefix: "/settings-attribute-go/v2/custom-field"
947
950
  });
948
951
  const CustomFieldServices = {
949
952
  getCustomField: async (params) => {
@@ -1305,7 +1308,7 @@ const RoleServices$1 = {
1305
1308
  }
1306
1309
  };
1307
1310
  const API$r = createAxiosInstance({
1308
- prefix: "/settings-user-role/v2"
1311
+ prefix: "/settings-user-role-go/v2"
1309
1312
  });
1310
1313
  const RoleServices = {
1311
1314
  /**
@@ -1432,7 +1435,7 @@ const OpenAPIServices$1 = {
1432
1435
  }
1433
1436
  };
1434
1437
  const API$p = createAxiosInstance({
1435
- prefix: "/settings-attribute/v2/open-api"
1438
+ prefix: "/settings-attribute-go/v2/open-api"
1436
1439
  });
1437
1440
  const OpenAPIServices = {
1438
1441
  putGenerateToken: () => {
@@ -1477,7 +1480,7 @@ const ImportServices$1 = {
1477
1480
  }
1478
1481
  };
1479
1482
  const API$n = createAxiosInstance({
1480
- prefix: "/import/v2"
1483
+ prefix: "/import-go/v2"
1481
1484
  });
1482
1485
  const ImportServices = {
1483
1486
  getImport: (importUrl, params) => {
@@ -1681,7 +1684,7 @@ const AssignmentServices$1 = {
1681
1684
  }
1682
1685
  };
1683
1686
  const API$k = createAxiosInstance({
1684
- prefix: "/assignment/v2"
1687
+ prefix: "/assignment-go/v2"
1685
1688
  });
1686
1689
  const AssignmentServices = {
1687
1690
  getTransactionData: (params) => {
@@ -1779,7 +1782,7 @@ const LicenseServices$1 = {
1779
1782
  ...LicenseAssetAddonServices
1780
1783
  };
1781
1784
  const API$i = createAxiosInstance({
1782
- prefix: "/license/v2"
1785
+ prefix: "/license-go/v2"
1783
1786
  });
1784
1787
  const TotalLicenseServices = {
1785
1788
  getTotalLicense: () => {
@@ -2071,7 +2074,7 @@ const MyAssetServices$1 = {
2071
2074
  }
2072
2075
  };
2073
2076
  const API$d = createAxiosInstance({
2074
- prefix: "/assets/v2/my-assets"
2077
+ prefix: "/assets-go/v2/my-assets"
2075
2078
  });
2076
2079
  const MyAssetServices = {
2077
2080
  getAssigned: async (params) => {
@@ -2111,7 +2114,7 @@ const RepairServices = {
2111
2114
  }
2112
2115
  };
2113
2116
  const API$b = createAxiosInstance({
2114
- prefix: "/settings-user-role/v2/auth"
2117
+ prefix: "/settings-user-role-go/v2/auth"
2115
2118
  });
2116
2119
  const onRejected$1 = (error) => {
2117
2120
  var _a, _b, _c, _d;
@@ -2393,7 +2396,7 @@ const DisposalServices$1 = {
2393
2396
  }
2394
2397
  };
2395
2398
  const API$9 = createAxiosInstance({
2396
- prefix: "/transfer/v2"
2399
+ prefix: "/transfer-go/v2"
2397
2400
  });
2398
2401
  const TransferServicesGo = {
2399
2402
  getTransactionData: (params) => {
@@ -2459,7 +2462,7 @@ const TransactionSettingServices = {
2459
2462
  }
2460
2463
  };
2461
2464
  const API$4 = createAxiosInstance({
2462
- prefix: "/borrowing/v2"
2465
+ prefix: "/borrowing-go/v2"
2463
2466
  });
2464
2467
  const BorrowServicesGo = {
2465
2468
  getTransactions: async (params) => {
@@ -2487,7 +2490,7 @@ const BorrowServicesGo = {
2487
2490
  }
2488
2491
  };
2489
2492
  const API$3 = createAxiosInstance({
2490
- prefix: "/disposal/v2/"
2493
+ prefix: "/disposal-go/v2/"
2491
2494
  });
2492
2495
  const DisposalServices = {
2493
2496
  getReportedDisposal: (params) => {
@@ -2556,7 +2559,7 @@ const ReportServices$1 = {
2556
2559
  }
2557
2560
  };
2558
2561
  const API$1 = createAxiosInstance({
2559
- prefix: "/report/v2/reports"
2562
+ prefix: "/report-go/v2/reports"
2560
2563
  });
2561
2564
  const ReportServices = {
2562
2565
  getReportList: (params) => {
@@ -2591,7 +2594,7 @@ const ReportServices = {
2591
2594
  }
2592
2595
  };
2593
2596
  const API = createAxiosInstance({
2594
- prefix: "/settings-attribute/v2/asset-name-policy"
2597
+ prefix: `/${SERVER_PREFIX.SETTINGS_ATTRIBUTES}/v2/asset-name-policy`
2595
2598
  });
2596
2599
  const AssetPolicyServices = {
2597
2600
  getList: (params) => {
@@ -29,6 +29,9 @@ System.register(["axios"], function(exports, module) {
29
29
  });
30
30
  return instance;
31
31
  };
32
+ const SERVER_PREFIX = {
33
+ SETTINGS_ATTRIBUTES: "settings-attribute"
34
+ };
32
35
  const queryParamsStringfy = exports("queryParamsStringfy", (data) => {
33
36
  if (!data || typeof data === "string") {
34
37
  return;
@@ -76,7 +79,7 @@ System.register(["axios"], function(exports, module) {
76
79
  return response;
77
80
  });
78
81
  const API$T = createAxiosInstance({
79
- prefix: "/settings-attribute/v2"
82
+ prefix: "/settings-attribute-go/v2"
80
83
  });
81
84
  const getEndpoint = (type) => {
82
85
  return type === "category" ? "category" : "groups";
@@ -114,7 +117,7 @@ System.register(["axios"], function(exports, module) {
114
117
  }
115
118
  });
116
119
  const API$S = createAxiosInstance({
117
- prefix: "/settings-attribute/v2/alias-code"
120
+ prefix: "/settings-attribute-go/v2/alias-code"
118
121
  });
119
122
  const AliasCodeServices = exports("AliasCodeServices", {
120
123
  getAliasCode: () => {
@@ -128,7 +131,7 @@ System.register(["axios"], function(exports, module) {
128
131
  }
129
132
  });
130
133
  const API$R = createAxiosInstance({
131
- prefix: "/settings-attribute/v2/general-settings"
134
+ prefix: "/settings-attribute-go/v2/general-settings"
132
135
  });
133
136
  const GeneralSettingsServices = exports("GeneralSettingsServices", {
134
137
  getGeneralSettings: () => {
@@ -337,7 +340,7 @@ System.register(["axios"], function(exports, module) {
337
340
  }
338
341
  });
339
342
  const AssetsAPIs = createAxiosInstance({
340
- prefix: "/assets/v2/assets"
343
+ prefix: "/assets-go/v2/assets"
341
344
  });
342
345
  const AssetServices = exports("AssetServicesGo", {
343
346
  getAllAssets: (params) => {
@@ -709,7 +712,7 @@ System.register(["axios"], function(exports, module) {
709
712
  }
710
713
  });
711
714
  const API$F = createAxiosInstance({
712
- prefix: "/settings-user-role/v2"
715
+ prefix: "/settings-user-role-go/v2"
713
716
  });
714
717
  const UserServices = exports("UserServicesGo", {
715
718
  /**
@@ -814,7 +817,7 @@ System.register(["axios"], function(exports, module) {
814
817
  }
815
818
  });
816
819
  const API$D = createAxiosInstance({
817
- prefix: "/settings-user-role/v2/users"
820
+ prefix: "/settings-user-role-go/v2/users"
818
821
  });
819
822
  const SubUserServices = exports("SubUserServicesGo", {
820
823
  // Sub User
@@ -950,7 +953,7 @@ System.register(["axios"], function(exports, module) {
950
953
  }
951
954
  });
952
955
  const API$z = createAxiosInstance({
953
- prefix: "/settings-attribute/v2/custom-field"
956
+ prefix: "/settings-attribute-go/v2/custom-field"
954
957
  });
955
958
  const CustomFieldServices = exports("CustomFieldServicesGo", {
956
959
  getCustomField: async (params) => {
@@ -1312,7 +1315,7 @@ System.register(["axios"], function(exports, module) {
1312
1315
  }
1313
1316
  });
1314
1317
  const API$r = createAxiosInstance({
1315
- prefix: "/settings-user-role/v2"
1318
+ prefix: "/settings-user-role-go/v2"
1316
1319
  });
1317
1320
  const RoleServices = exports("RoleServicesGo", {
1318
1321
  /**
@@ -1439,7 +1442,7 @@ System.register(["axios"], function(exports, module) {
1439
1442
  }
1440
1443
  });
1441
1444
  const API$p = createAxiosInstance({
1442
- prefix: "/settings-attribute/v2/open-api"
1445
+ prefix: "/settings-attribute-go/v2/open-api"
1443
1446
  });
1444
1447
  const OpenAPIServices = exports("OpenAPIServicesGo", {
1445
1448
  putGenerateToken: () => {
@@ -1484,7 +1487,7 @@ System.register(["axios"], function(exports, module) {
1484
1487
  }
1485
1488
  });
1486
1489
  const API$n = createAxiosInstance({
1487
- prefix: "/import/v2"
1490
+ prefix: "/import-go/v2"
1488
1491
  });
1489
1492
  const ImportServices = exports("ImportServicesGo", {
1490
1493
  getImport: (importUrl, params) => {
@@ -1688,7 +1691,7 @@ System.register(["axios"], function(exports, module) {
1688
1691
  }
1689
1692
  });
1690
1693
  const API$k = createAxiosInstance({
1691
- prefix: "/assignment/v2"
1694
+ prefix: "/assignment-go/v2"
1692
1695
  });
1693
1696
  const AssignmentServices = exports("AssignmentServicesGo", {
1694
1697
  getTransactionData: (params) => {
@@ -1786,7 +1789,7 @@ System.register(["axios"], function(exports, module) {
1786
1789
  ...LicenseAssetAddonServices
1787
1790
  });
1788
1791
  const API$i = createAxiosInstance({
1789
- prefix: "/license/v2"
1792
+ prefix: "/license-go/v2"
1790
1793
  });
1791
1794
  const TotalLicenseServices = {
1792
1795
  getTotalLicense: () => {
@@ -2078,7 +2081,7 @@ System.register(["axios"], function(exports, module) {
2078
2081
  }
2079
2082
  });
2080
2083
  const API$d = createAxiosInstance({
2081
- prefix: "/assets/v2/my-assets"
2084
+ prefix: "/assets-go/v2/my-assets"
2082
2085
  });
2083
2086
  const MyAssetServices = exports("MyAssetServicesGo", {
2084
2087
  getAssigned: async (params) => {
@@ -2118,7 +2121,7 @@ System.register(["axios"], function(exports, module) {
2118
2121
  }
2119
2122
  });
2120
2123
  const API$b = createAxiosInstance({
2121
- prefix: "/settings-user-role/v2/auth"
2124
+ prefix: "/settings-user-role-go/v2/auth"
2122
2125
  });
2123
2126
  const onRejected$1 = (error) => {
2124
2127
  var _a, _b, _c, _d;
@@ -2400,7 +2403,7 @@ System.register(["axios"], function(exports, module) {
2400
2403
  }
2401
2404
  });
2402
2405
  const API$9 = createAxiosInstance({
2403
- prefix: "/transfer/v2"
2406
+ prefix: "/transfer-go/v2"
2404
2407
  });
2405
2408
  const TransferServicesGo = exports("TransferServicesGo", {
2406
2409
  getTransactionData: (params) => {
@@ -2466,7 +2469,7 @@ System.register(["axios"], function(exports, module) {
2466
2469
  }
2467
2470
  });
2468
2471
  const API$4 = createAxiosInstance({
2469
- prefix: "/borrowing/v2"
2472
+ prefix: "/borrowing-go/v2"
2470
2473
  });
2471
2474
  const BorrowServicesGo = exports("BorrowServicesGo", {
2472
2475
  getTransactions: async (params) => {
@@ -2494,7 +2497,7 @@ System.register(["axios"], function(exports, module) {
2494
2497
  }
2495
2498
  });
2496
2499
  const API$3 = createAxiosInstance({
2497
- prefix: "/disposal/v2/"
2500
+ prefix: "/disposal-go/v2/"
2498
2501
  });
2499
2502
  const DisposalServices = exports("DisposalServicesGo", {
2500
2503
  getReportedDisposal: (params) => {
@@ -2563,7 +2566,7 @@ System.register(["axios"], function(exports, module) {
2563
2566
  }
2564
2567
  });
2565
2568
  const API$1 = createAxiosInstance({
2566
- prefix: "/report/v2/reports"
2569
+ prefix: "/report-go/v2/reports"
2567
2570
  });
2568
2571
  const ReportServices = exports("ReportServicesGo", {
2569
2572
  getReportList: (params) => {
@@ -2598,7 +2601,7 @@ System.register(["axios"], function(exports, module) {
2598
2601
  }
2599
2602
  });
2600
2603
  const API = createAxiosInstance({
2601
- prefix: "/settings-attribute/v2/asset-name-policy"
2604
+ prefix: `/${SERVER_PREFIX.SETTINGS_ATTRIBUTES}/v2/asset-name-policy`
2602
2605
  });
2603
2606
  const AssetPolicyServices = exports("AssetPolicyServices", {
2604
2607
  getList: (params) => {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tagsamurai/fats-api-services",
3
- "version": "1.0.0-alpha.227",
3
+ "version": "1.0.0-alpha.228",
4
4
  "author": "developer.tagsamurai",
5
5
  "description": "Fixed Asset Tag Samurai Services Library",
6
6
  "module": "./api-services.es.js",
@@ -0,0 +1,11 @@
1
+ export declare const PREFIX_MAP: {
2
+ development: {
3
+ SETTINGS_ATTRIBUTES: string;
4
+ };
5
+ staging: {
6
+ SETTINGS_ATTRIBUTES: string;
7
+ };
8
+ production: {
9
+ SETTINGS_ATTRIBUTES: string;
10
+ };
11
+ };
@@ -34,3 +34,6 @@ export interface APIRequestConfig extends Omit<AxiosRequestConfig, 'env'> {
34
34
  * - This utility ensures that the token is resolved on each request, which is useful in scenarios where the script may execute before a user re-login.
35
35
  */
36
36
  export declare const createAxiosInstance: (config?: APIRequestConfig, useDifferentHeaders?: boolean) => AxiosInstance;
37
+ export declare const SERVER_PREFIX: {
38
+ SETTINGS_ATTRIBUTES: string;
39
+ };