@uipath/uipath-typescript 1.3.2 → 1.3.3
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.
- package/dist/assets/index.cjs +14 -8
- package/dist/assets/index.mjs +14 -8
- package/dist/attachments/index.cjs +14 -8
- package/dist/attachments/index.mjs +14 -8
- package/dist/buckets/index.cjs +14 -8
- package/dist/buckets/index.mjs +14 -8
- package/dist/cases/index.cjs +34 -13
- package/dist/cases/index.d.ts +15 -0
- package/dist/cases/index.mjs +34 -13
- package/dist/conversational-agent/index.cjs +32 -8
- package/dist/conversational-agent/index.d.ts +26 -0
- package/dist/conversational-agent/index.mjs +32 -8
- package/dist/core/index.cjs +16 -1
- package/dist/core/index.d.ts +1 -1
- package/dist/core/index.mjs +16 -1
- package/dist/entities/index.cjs +14 -8
- package/dist/entities/index.mjs +14 -8
- package/dist/feedback/index.cjs +1904 -0
- package/dist/feedback/index.d.ts +475 -0
- package/dist/feedback/index.mjs +1902 -0
- package/dist/index.cjs +364 -189
- package/dist/index.d.ts +277 -12
- package/dist/index.mjs +365 -190
- package/dist/index.umd.js +364 -189
- package/dist/jobs/index.cjs +331 -8
- package/dist/jobs/index.d.ts +168 -2
- package/dist/jobs/index.mjs +332 -9
- package/dist/maestro-processes/index.cjs +14 -8
- package/dist/maestro-processes/index.mjs +14 -8
- package/dist/processes/index.cjs +14 -8
- package/dist/processes/index.mjs +14 -8
- package/dist/queues/index.cjs +14 -8
- package/dist/queues/index.mjs +14 -8
- package/dist/tasks/index.cjs +34 -13
- package/dist/tasks/index.d.ts +25 -10
- package/dist/tasks/index.mjs +35 -14
- package/package.json +12 -1
package/dist/assets/index.cjs
CHANGED
|
@@ -600,7 +600,11 @@ class ApiClient {
|
|
|
600
600
|
const text = await response.text();
|
|
601
601
|
return text;
|
|
602
602
|
}
|
|
603
|
-
|
|
603
|
+
const text = await response.text();
|
|
604
|
+
if (!text) {
|
|
605
|
+
return undefined;
|
|
606
|
+
}
|
|
607
|
+
return JSON.parse(text);
|
|
604
608
|
}
|
|
605
609
|
catch (error) {
|
|
606
610
|
// If it's already one of our errors, re-throw it
|
|
@@ -1232,8 +1236,9 @@ class PaginationHelpers {
|
|
|
1232
1236
|
});
|
|
1233
1237
|
}
|
|
1234
1238
|
// Extract and transform items from response
|
|
1235
|
-
|
|
1236
|
-
const
|
|
1239
|
+
// Handle both plain array responses and envelope responses ({ value: [...], totalRecordCount: N })
|
|
1240
|
+
const rawItems = Array.isArray(response.data) ? response.data : response.data?.[itemsField];
|
|
1241
|
+
const totalCount = Array.isArray(response.data) ? undefined : response.data?.[totalCountField];
|
|
1237
1242
|
// Parse items - automatically handle JSON string responses
|
|
1238
1243
|
const parsedItems = typeof rawItems === 'string' ? JSON.parse(rawItems) : (rawItems || []);
|
|
1239
1244
|
const items = transformFn ? parsedItems.map(transformFn) : parsedItems;
|
|
@@ -1484,7 +1489,7 @@ class BaseService {
|
|
|
1484
1489
|
const params = this.validateAndPreparePaginationParams(paginationType, paginationOptions);
|
|
1485
1490
|
// Prepare request parameters based on pagination type
|
|
1486
1491
|
const requestParams = this.preparePaginationRequestParams(paginationType, params, options.pagination);
|
|
1487
|
-
// For POST requests, merge pagination params into body; for GET, use query params
|
|
1492
|
+
// For POST requests, merge pagination params into body and set params to undefined; for GET, use query params
|
|
1488
1493
|
if (method.toUpperCase() === 'POST') {
|
|
1489
1494
|
const existingBody = (options.body && typeof options.body === 'object') ? options.body : {};
|
|
1490
1495
|
options.body = {
|
|
@@ -1492,6 +1497,7 @@ class BaseService {
|
|
|
1492
1497
|
...options.params,
|
|
1493
1498
|
...requestParams
|
|
1494
1499
|
};
|
|
1500
|
+
options.params = undefined;
|
|
1495
1501
|
}
|
|
1496
1502
|
else {
|
|
1497
1503
|
// Merge pagination parameters with existing parameters
|
|
@@ -1532,7 +1538,6 @@ class BaseService {
|
|
|
1532
1538
|
if (params.pageNumber && params.pageNumber > 1) {
|
|
1533
1539
|
requestParams[offsetParam] = (params.pageNumber - 1) * limitedPageSize;
|
|
1534
1540
|
}
|
|
1535
|
-
// Include total count for ODATA APIs
|
|
1536
1541
|
{
|
|
1537
1542
|
requestParams[countParam] = true;
|
|
1538
1543
|
}
|
|
@@ -1560,8 +1565,9 @@ class BaseService {
|
|
|
1560
1565
|
const totalCountField = fields.totalCountField || 'totalRecordCount';
|
|
1561
1566
|
const continuationTokenField = fields.continuationTokenField || 'continuationToken';
|
|
1562
1567
|
// Extract items and metadata
|
|
1563
|
-
|
|
1564
|
-
const
|
|
1568
|
+
// Handle both plain array responses and envelope responses ({ value: [...], totalRecordCount: N })
|
|
1569
|
+
const items = Array.isArray(response.data) ? response.data : (response.data[itemsField] || []);
|
|
1570
|
+
const totalCount = Array.isArray(response.data) ? undefined : response.data[totalCountField];
|
|
1565
1571
|
const continuationToken = response.data[continuationTokenField];
|
|
1566
1572
|
// Determine if there are more pages
|
|
1567
1573
|
const hasMore = this.determineHasMorePages(paginationType, {
|
|
@@ -1672,7 +1678,7 @@ const AssetMap = {
|
|
|
1672
1678
|
// Connection string placeholder that will be replaced during build
|
|
1673
1679
|
const CONNECTION_STRING = "InstrumentationKey=a6efa11d-1feb-4508-9738-e13e12dcae5e;IngestionEndpoint=https://westeurope-5.in.applicationinsights.azure.com/;LiveEndpoint=https://westeurope.livediagnostics.monitor.azure.com/;ApplicationId=7c58eb1c-9581-4ba6-839e-11725848a037";
|
|
1674
1680
|
// SDK Version placeholder
|
|
1675
|
-
const SDK_VERSION = "1.3.
|
|
1681
|
+
const SDK_VERSION = "1.3.3";
|
|
1676
1682
|
const VERSION = "Version";
|
|
1677
1683
|
const SERVICE = "Service";
|
|
1678
1684
|
const CLOUD_ORGANIZATION_NAME = "CloudOrganizationName";
|
package/dist/assets/index.mjs
CHANGED
|
@@ -598,7 +598,11 @@ class ApiClient {
|
|
|
598
598
|
const text = await response.text();
|
|
599
599
|
return text;
|
|
600
600
|
}
|
|
601
|
-
|
|
601
|
+
const text = await response.text();
|
|
602
|
+
if (!text) {
|
|
603
|
+
return undefined;
|
|
604
|
+
}
|
|
605
|
+
return JSON.parse(text);
|
|
602
606
|
}
|
|
603
607
|
catch (error) {
|
|
604
608
|
// If it's already one of our errors, re-throw it
|
|
@@ -1230,8 +1234,9 @@ class PaginationHelpers {
|
|
|
1230
1234
|
});
|
|
1231
1235
|
}
|
|
1232
1236
|
// Extract and transform items from response
|
|
1233
|
-
|
|
1234
|
-
const
|
|
1237
|
+
// Handle both plain array responses and envelope responses ({ value: [...], totalRecordCount: N })
|
|
1238
|
+
const rawItems = Array.isArray(response.data) ? response.data : response.data?.[itemsField];
|
|
1239
|
+
const totalCount = Array.isArray(response.data) ? undefined : response.data?.[totalCountField];
|
|
1235
1240
|
// Parse items - automatically handle JSON string responses
|
|
1236
1241
|
const parsedItems = typeof rawItems === 'string' ? JSON.parse(rawItems) : (rawItems || []);
|
|
1237
1242
|
const items = transformFn ? parsedItems.map(transformFn) : parsedItems;
|
|
@@ -1482,7 +1487,7 @@ class BaseService {
|
|
|
1482
1487
|
const params = this.validateAndPreparePaginationParams(paginationType, paginationOptions);
|
|
1483
1488
|
// Prepare request parameters based on pagination type
|
|
1484
1489
|
const requestParams = this.preparePaginationRequestParams(paginationType, params, options.pagination);
|
|
1485
|
-
// For POST requests, merge pagination params into body; for GET, use query params
|
|
1490
|
+
// For POST requests, merge pagination params into body and set params to undefined; for GET, use query params
|
|
1486
1491
|
if (method.toUpperCase() === 'POST') {
|
|
1487
1492
|
const existingBody = (options.body && typeof options.body === 'object') ? options.body : {};
|
|
1488
1493
|
options.body = {
|
|
@@ -1490,6 +1495,7 @@ class BaseService {
|
|
|
1490
1495
|
...options.params,
|
|
1491
1496
|
...requestParams
|
|
1492
1497
|
};
|
|
1498
|
+
options.params = undefined;
|
|
1493
1499
|
}
|
|
1494
1500
|
else {
|
|
1495
1501
|
// Merge pagination parameters with existing parameters
|
|
@@ -1530,7 +1536,6 @@ class BaseService {
|
|
|
1530
1536
|
if (params.pageNumber && params.pageNumber > 1) {
|
|
1531
1537
|
requestParams[offsetParam] = (params.pageNumber - 1) * limitedPageSize;
|
|
1532
1538
|
}
|
|
1533
|
-
// Include total count for ODATA APIs
|
|
1534
1539
|
{
|
|
1535
1540
|
requestParams[countParam] = true;
|
|
1536
1541
|
}
|
|
@@ -1558,8 +1563,9 @@ class BaseService {
|
|
|
1558
1563
|
const totalCountField = fields.totalCountField || 'totalRecordCount';
|
|
1559
1564
|
const continuationTokenField = fields.continuationTokenField || 'continuationToken';
|
|
1560
1565
|
// Extract items and metadata
|
|
1561
|
-
|
|
1562
|
-
const
|
|
1566
|
+
// Handle both plain array responses and envelope responses ({ value: [...], totalRecordCount: N })
|
|
1567
|
+
const items = Array.isArray(response.data) ? response.data : (response.data[itemsField] || []);
|
|
1568
|
+
const totalCount = Array.isArray(response.data) ? undefined : response.data[totalCountField];
|
|
1563
1569
|
const continuationToken = response.data[continuationTokenField];
|
|
1564
1570
|
// Determine if there are more pages
|
|
1565
1571
|
const hasMore = this.determineHasMorePages(paginationType, {
|
|
@@ -1670,7 +1676,7 @@ const AssetMap = {
|
|
|
1670
1676
|
// Connection string placeholder that will be replaced during build
|
|
1671
1677
|
const CONNECTION_STRING = "InstrumentationKey=a6efa11d-1feb-4508-9738-e13e12dcae5e;IngestionEndpoint=https://westeurope-5.in.applicationinsights.azure.com/;LiveEndpoint=https://westeurope.livediagnostics.monitor.azure.com/;ApplicationId=7c58eb1c-9581-4ba6-839e-11725848a037";
|
|
1672
1678
|
// SDK Version placeholder
|
|
1673
|
-
const SDK_VERSION = "1.3.
|
|
1679
|
+
const SDK_VERSION = "1.3.3";
|
|
1674
1680
|
const VERSION = "Version";
|
|
1675
1681
|
const SERVICE = "Service";
|
|
1676
1682
|
const CLOUD_ORGANIZATION_NAME = "CloudOrganizationName";
|
|
@@ -476,7 +476,7 @@ const BUCKET_TOKEN_PARAMS = {
|
|
|
476
476
|
// Connection string placeholder that will be replaced during build
|
|
477
477
|
const CONNECTION_STRING = "InstrumentationKey=a6efa11d-1feb-4508-9738-e13e12dcae5e;IngestionEndpoint=https://westeurope-5.in.applicationinsights.azure.com/;LiveEndpoint=https://westeurope.livediagnostics.monitor.azure.com/;ApplicationId=7c58eb1c-9581-4ba6-839e-11725848a037";
|
|
478
478
|
// SDK Version placeholder
|
|
479
|
-
const SDK_VERSION = "1.3.
|
|
479
|
+
const SDK_VERSION = "1.3.3";
|
|
480
480
|
const VERSION = "Version";
|
|
481
481
|
const SERVICE = "Service";
|
|
482
482
|
const CLOUD_ORGANIZATION_NAME = "CloudOrganizationName";
|
|
@@ -1079,7 +1079,11 @@ class ApiClient {
|
|
|
1079
1079
|
const text = await response.text();
|
|
1080
1080
|
return text;
|
|
1081
1081
|
}
|
|
1082
|
-
|
|
1082
|
+
const text = await response.text();
|
|
1083
|
+
if (!text) {
|
|
1084
|
+
return undefined;
|
|
1085
|
+
}
|
|
1086
|
+
return JSON.parse(text);
|
|
1083
1087
|
}
|
|
1084
1088
|
catch (error) {
|
|
1085
1089
|
// If it's already one of our errors, re-throw it
|
|
@@ -1519,8 +1523,9 @@ class PaginationHelpers {
|
|
|
1519
1523
|
});
|
|
1520
1524
|
}
|
|
1521
1525
|
// Extract and transform items from response
|
|
1522
|
-
|
|
1523
|
-
const
|
|
1526
|
+
// Handle both plain array responses and envelope responses ({ value: [...], totalRecordCount: N })
|
|
1527
|
+
const rawItems = Array.isArray(response.data) ? response.data : response.data?.[itemsField];
|
|
1528
|
+
const totalCount = Array.isArray(response.data) ? undefined : response.data?.[totalCountField];
|
|
1524
1529
|
// Parse items - automatically handle JSON string responses
|
|
1525
1530
|
const parsedItems = typeof rawItems === 'string' ? JSON.parse(rawItems) : (rawItems || []);
|
|
1526
1531
|
const items = transformFn ? parsedItems.map(transformFn) : parsedItems;
|
|
@@ -1771,7 +1776,7 @@ class BaseService {
|
|
|
1771
1776
|
const params = this.validateAndPreparePaginationParams(paginationType, paginationOptions);
|
|
1772
1777
|
// Prepare request parameters based on pagination type
|
|
1773
1778
|
const requestParams = this.preparePaginationRequestParams(paginationType, params, options.pagination);
|
|
1774
|
-
// For POST requests, merge pagination params into body; for GET, use query params
|
|
1779
|
+
// For POST requests, merge pagination params into body and set params to undefined; for GET, use query params
|
|
1775
1780
|
if (method.toUpperCase() === 'POST') {
|
|
1776
1781
|
const existingBody = (options.body && typeof options.body === 'object') ? options.body : {};
|
|
1777
1782
|
options.body = {
|
|
@@ -1779,6 +1784,7 @@ class BaseService {
|
|
|
1779
1784
|
...options.params,
|
|
1780
1785
|
...requestParams
|
|
1781
1786
|
};
|
|
1787
|
+
options.params = undefined;
|
|
1782
1788
|
}
|
|
1783
1789
|
else {
|
|
1784
1790
|
// Merge pagination parameters with existing parameters
|
|
@@ -1819,7 +1825,6 @@ class BaseService {
|
|
|
1819
1825
|
if (params.pageNumber && params.pageNumber > 1) {
|
|
1820
1826
|
requestParams[offsetParam] = (params.pageNumber - 1) * limitedPageSize;
|
|
1821
1827
|
}
|
|
1822
|
-
// Include total count for ODATA APIs
|
|
1823
1828
|
{
|
|
1824
1829
|
requestParams[countParam] = true;
|
|
1825
1830
|
}
|
|
@@ -1847,8 +1852,9 @@ class BaseService {
|
|
|
1847
1852
|
const totalCountField = fields.totalCountField || 'totalRecordCount';
|
|
1848
1853
|
const continuationTokenField = fields.continuationTokenField || 'continuationToken';
|
|
1849
1854
|
// Extract items and metadata
|
|
1850
|
-
|
|
1851
|
-
const
|
|
1855
|
+
// Handle both plain array responses and envelope responses ({ value: [...], totalRecordCount: N })
|
|
1856
|
+
const items = Array.isArray(response.data) ? response.data : (response.data[itemsField] || []);
|
|
1857
|
+
const totalCount = Array.isArray(response.data) ? undefined : response.data[totalCountField];
|
|
1852
1858
|
const continuationToken = response.data[continuationTokenField];
|
|
1853
1859
|
// Determine if there are more pages
|
|
1854
1860
|
const hasMore = this.determineHasMorePages(paginationType, {
|
|
@@ -474,7 +474,7 @@ const BUCKET_TOKEN_PARAMS = {
|
|
|
474
474
|
// Connection string placeholder that will be replaced during build
|
|
475
475
|
const CONNECTION_STRING = "InstrumentationKey=a6efa11d-1feb-4508-9738-e13e12dcae5e;IngestionEndpoint=https://westeurope-5.in.applicationinsights.azure.com/;LiveEndpoint=https://westeurope.livediagnostics.monitor.azure.com/;ApplicationId=7c58eb1c-9581-4ba6-839e-11725848a037";
|
|
476
476
|
// SDK Version placeholder
|
|
477
|
-
const SDK_VERSION = "1.3.
|
|
477
|
+
const SDK_VERSION = "1.3.3";
|
|
478
478
|
const VERSION = "Version";
|
|
479
479
|
const SERVICE = "Service";
|
|
480
480
|
const CLOUD_ORGANIZATION_NAME = "CloudOrganizationName";
|
|
@@ -1077,7 +1077,11 @@ class ApiClient {
|
|
|
1077
1077
|
const text = await response.text();
|
|
1078
1078
|
return text;
|
|
1079
1079
|
}
|
|
1080
|
-
|
|
1080
|
+
const text = await response.text();
|
|
1081
|
+
if (!text) {
|
|
1082
|
+
return undefined;
|
|
1083
|
+
}
|
|
1084
|
+
return JSON.parse(text);
|
|
1081
1085
|
}
|
|
1082
1086
|
catch (error) {
|
|
1083
1087
|
// If it's already one of our errors, re-throw it
|
|
@@ -1517,8 +1521,9 @@ class PaginationHelpers {
|
|
|
1517
1521
|
});
|
|
1518
1522
|
}
|
|
1519
1523
|
// Extract and transform items from response
|
|
1520
|
-
|
|
1521
|
-
const
|
|
1524
|
+
// Handle both plain array responses and envelope responses ({ value: [...], totalRecordCount: N })
|
|
1525
|
+
const rawItems = Array.isArray(response.data) ? response.data : response.data?.[itemsField];
|
|
1526
|
+
const totalCount = Array.isArray(response.data) ? undefined : response.data?.[totalCountField];
|
|
1522
1527
|
// Parse items - automatically handle JSON string responses
|
|
1523
1528
|
const parsedItems = typeof rawItems === 'string' ? JSON.parse(rawItems) : (rawItems || []);
|
|
1524
1529
|
const items = transformFn ? parsedItems.map(transformFn) : parsedItems;
|
|
@@ -1769,7 +1774,7 @@ class BaseService {
|
|
|
1769
1774
|
const params = this.validateAndPreparePaginationParams(paginationType, paginationOptions);
|
|
1770
1775
|
// Prepare request parameters based on pagination type
|
|
1771
1776
|
const requestParams = this.preparePaginationRequestParams(paginationType, params, options.pagination);
|
|
1772
|
-
// For POST requests, merge pagination params into body; for GET, use query params
|
|
1777
|
+
// For POST requests, merge pagination params into body and set params to undefined; for GET, use query params
|
|
1773
1778
|
if (method.toUpperCase() === 'POST') {
|
|
1774
1779
|
const existingBody = (options.body && typeof options.body === 'object') ? options.body : {};
|
|
1775
1780
|
options.body = {
|
|
@@ -1777,6 +1782,7 @@ class BaseService {
|
|
|
1777
1782
|
...options.params,
|
|
1778
1783
|
...requestParams
|
|
1779
1784
|
};
|
|
1785
|
+
options.params = undefined;
|
|
1780
1786
|
}
|
|
1781
1787
|
else {
|
|
1782
1788
|
// Merge pagination parameters with existing parameters
|
|
@@ -1817,7 +1823,6 @@ class BaseService {
|
|
|
1817
1823
|
if (params.pageNumber && params.pageNumber > 1) {
|
|
1818
1824
|
requestParams[offsetParam] = (params.pageNumber - 1) * limitedPageSize;
|
|
1819
1825
|
}
|
|
1820
|
-
// Include total count for ODATA APIs
|
|
1821
1826
|
{
|
|
1822
1827
|
requestParams[countParam] = true;
|
|
1823
1828
|
}
|
|
@@ -1845,8 +1850,9 @@ class BaseService {
|
|
|
1845
1850
|
const totalCountField = fields.totalCountField || 'totalRecordCount';
|
|
1846
1851
|
const continuationTokenField = fields.continuationTokenField || 'continuationToken';
|
|
1847
1852
|
// Extract items and metadata
|
|
1848
|
-
|
|
1849
|
-
const
|
|
1853
|
+
// Handle both plain array responses and envelope responses ({ value: [...], totalRecordCount: N })
|
|
1854
|
+
const items = Array.isArray(response.data) ? response.data : (response.data[itemsField] || []);
|
|
1855
|
+
const totalCount = Array.isArray(response.data) ? undefined : response.data[totalCountField];
|
|
1850
1856
|
const continuationToken = response.data[continuationTokenField];
|
|
1851
1857
|
// Determine if there are more pages
|
|
1852
1858
|
const hasMore = this.determineHasMorePages(paginationType, {
|
package/dist/buckets/index.cjs
CHANGED
|
@@ -600,7 +600,11 @@ class ApiClient {
|
|
|
600
600
|
const text = await response.text();
|
|
601
601
|
return text;
|
|
602
602
|
}
|
|
603
|
-
|
|
603
|
+
const text = await response.text();
|
|
604
|
+
if (!text) {
|
|
605
|
+
return undefined;
|
|
606
|
+
}
|
|
607
|
+
return JSON.parse(text);
|
|
604
608
|
}
|
|
605
609
|
catch (error) {
|
|
606
610
|
// If it's already one of our errors, re-throw it
|
|
@@ -1275,8 +1279,9 @@ class PaginationHelpers {
|
|
|
1275
1279
|
});
|
|
1276
1280
|
}
|
|
1277
1281
|
// Extract and transform items from response
|
|
1278
|
-
|
|
1279
|
-
const
|
|
1282
|
+
// Handle both plain array responses and envelope responses ({ value: [...], totalRecordCount: N })
|
|
1283
|
+
const rawItems = Array.isArray(response.data) ? response.data : response.data?.[itemsField];
|
|
1284
|
+
const totalCount = Array.isArray(response.data) ? undefined : response.data?.[totalCountField];
|
|
1280
1285
|
// Parse items - automatically handle JSON string responses
|
|
1281
1286
|
const parsedItems = typeof rawItems === 'string' ? JSON.parse(rawItems) : (rawItems || []);
|
|
1282
1287
|
const items = transformFn ? parsedItems.map(transformFn) : parsedItems;
|
|
@@ -1527,7 +1532,7 @@ class BaseService {
|
|
|
1527
1532
|
const params = this.validateAndPreparePaginationParams(paginationType, paginationOptions);
|
|
1528
1533
|
// Prepare request parameters based on pagination type
|
|
1529
1534
|
const requestParams = this.preparePaginationRequestParams(paginationType, params, options.pagination);
|
|
1530
|
-
// For POST requests, merge pagination params into body; for GET, use query params
|
|
1535
|
+
// For POST requests, merge pagination params into body and set params to undefined; for GET, use query params
|
|
1531
1536
|
if (method.toUpperCase() === 'POST') {
|
|
1532
1537
|
const existingBody = (options.body && typeof options.body === 'object') ? options.body : {};
|
|
1533
1538
|
options.body = {
|
|
@@ -1535,6 +1540,7 @@ class BaseService {
|
|
|
1535
1540
|
...options.params,
|
|
1536
1541
|
...requestParams
|
|
1537
1542
|
};
|
|
1543
|
+
options.params = undefined;
|
|
1538
1544
|
}
|
|
1539
1545
|
else {
|
|
1540
1546
|
// Merge pagination parameters with existing parameters
|
|
@@ -1575,7 +1581,6 @@ class BaseService {
|
|
|
1575
1581
|
if (params.pageNumber && params.pageNumber > 1) {
|
|
1576
1582
|
requestParams[offsetParam] = (params.pageNumber - 1) * limitedPageSize;
|
|
1577
1583
|
}
|
|
1578
|
-
// Include total count for ODATA APIs
|
|
1579
1584
|
{
|
|
1580
1585
|
requestParams[countParam] = true;
|
|
1581
1586
|
}
|
|
@@ -1603,8 +1608,9 @@ class BaseService {
|
|
|
1603
1608
|
const totalCountField = fields.totalCountField || 'totalRecordCount';
|
|
1604
1609
|
const continuationTokenField = fields.continuationTokenField || 'continuationToken';
|
|
1605
1610
|
// Extract items and metadata
|
|
1606
|
-
|
|
1607
|
-
const
|
|
1611
|
+
// Handle both plain array responses and envelope responses ({ value: [...], totalRecordCount: N })
|
|
1612
|
+
const items = Array.isArray(response.data) ? response.data : (response.data[itemsField] || []);
|
|
1613
|
+
const totalCount = Array.isArray(response.data) ? undefined : response.data[totalCountField];
|
|
1608
1614
|
const continuationToken = response.data[continuationTokenField];
|
|
1609
1615
|
// Determine if there are more pages
|
|
1610
1616
|
const hasMore = this.determineHasMorePages(paginationType, {
|
|
@@ -1719,7 +1725,7 @@ const BucketMap = {
|
|
|
1719
1725
|
// Connection string placeholder that will be replaced during build
|
|
1720
1726
|
const CONNECTION_STRING = "InstrumentationKey=a6efa11d-1feb-4508-9738-e13e12dcae5e;IngestionEndpoint=https://westeurope-5.in.applicationinsights.azure.com/;LiveEndpoint=https://westeurope.livediagnostics.monitor.azure.com/;ApplicationId=7c58eb1c-9581-4ba6-839e-11725848a037";
|
|
1721
1727
|
// SDK Version placeholder
|
|
1722
|
-
const SDK_VERSION = "1.3.
|
|
1728
|
+
const SDK_VERSION = "1.3.3";
|
|
1723
1729
|
const VERSION = "Version";
|
|
1724
1730
|
const SERVICE = "Service";
|
|
1725
1731
|
const CLOUD_ORGANIZATION_NAME = "CloudOrganizationName";
|
package/dist/buckets/index.mjs
CHANGED
|
@@ -598,7 +598,11 @@ class ApiClient {
|
|
|
598
598
|
const text = await response.text();
|
|
599
599
|
return text;
|
|
600
600
|
}
|
|
601
|
-
|
|
601
|
+
const text = await response.text();
|
|
602
|
+
if (!text) {
|
|
603
|
+
return undefined;
|
|
604
|
+
}
|
|
605
|
+
return JSON.parse(text);
|
|
602
606
|
}
|
|
603
607
|
catch (error) {
|
|
604
608
|
// If it's already one of our errors, re-throw it
|
|
@@ -1273,8 +1277,9 @@ class PaginationHelpers {
|
|
|
1273
1277
|
});
|
|
1274
1278
|
}
|
|
1275
1279
|
// Extract and transform items from response
|
|
1276
|
-
|
|
1277
|
-
const
|
|
1280
|
+
// Handle both plain array responses and envelope responses ({ value: [...], totalRecordCount: N })
|
|
1281
|
+
const rawItems = Array.isArray(response.data) ? response.data : response.data?.[itemsField];
|
|
1282
|
+
const totalCount = Array.isArray(response.data) ? undefined : response.data?.[totalCountField];
|
|
1278
1283
|
// Parse items - automatically handle JSON string responses
|
|
1279
1284
|
const parsedItems = typeof rawItems === 'string' ? JSON.parse(rawItems) : (rawItems || []);
|
|
1280
1285
|
const items = transformFn ? parsedItems.map(transformFn) : parsedItems;
|
|
@@ -1525,7 +1530,7 @@ class BaseService {
|
|
|
1525
1530
|
const params = this.validateAndPreparePaginationParams(paginationType, paginationOptions);
|
|
1526
1531
|
// Prepare request parameters based on pagination type
|
|
1527
1532
|
const requestParams = this.preparePaginationRequestParams(paginationType, params, options.pagination);
|
|
1528
|
-
// For POST requests, merge pagination params into body; for GET, use query params
|
|
1533
|
+
// For POST requests, merge pagination params into body and set params to undefined; for GET, use query params
|
|
1529
1534
|
if (method.toUpperCase() === 'POST') {
|
|
1530
1535
|
const existingBody = (options.body && typeof options.body === 'object') ? options.body : {};
|
|
1531
1536
|
options.body = {
|
|
@@ -1533,6 +1538,7 @@ class BaseService {
|
|
|
1533
1538
|
...options.params,
|
|
1534
1539
|
...requestParams
|
|
1535
1540
|
};
|
|
1541
|
+
options.params = undefined;
|
|
1536
1542
|
}
|
|
1537
1543
|
else {
|
|
1538
1544
|
// Merge pagination parameters with existing parameters
|
|
@@ -1573,7 +1579,6 @@ class BaseService {
|
|
|
1573
1579
|
if (params.pageNumber && params.pageNumber > 1) {
|
|
1574
1580
|
requestParams[offsetParam] = (params.pageNumber - 1) * limitedPageSize;
|
|
1575
1581
|
}
|
|
1576
|
-
// Include total count for ODATA APIs
|
|
1577
1582
|
{
|
|
1578
1583
|
requestParams[countParam] = true;
|
|
1579
1584
|
}
|
|
@@ -1601,8 +1606,9 @@ class BaseService {
|
|
|
1601
1606
|
const totalCountField = fields.totalCountField || 'totalRecordCount';
|
|
1602
1607
|
const continuationTokenField = fields.continuationTokenField || 'continuationToken';
|
|
1603
1608
|
// Extract items and metadata
|
|
1604
|
-
|
|
1605
|
-
const
|
|
1609
|
+
// Handle both plain array responses and envelope responses ({ value: [...], totalRecordCount: N })
|
|
1610
|
+
const items = Array.isArray(response.data) ? response.data : (response.data[itemsField] || []);
|
|
1611
|
+
const totalCount = Array.isArray(response.data) ? undefined : response.data[totalCountField];
|
|
1606
1612
|
const continuationToken = response.data[continuationTokenField];
|
|
1607
1613
|
// Determine if there are more pages
|
|
1608
1614
|
const hasMore = this.determineHasMorePages(paginationType, {
|
|
@@ -1717,7 +1723,7 @@ const BucketMap = {
|
|
|
1717
1723
|
// Connection string placeholder that will be replaced during build
|
|
1718
1724
|
const CONNECTION_STRING = "InstrumentationKey=a6efa11d-1feb-4508-9738-e13e12dcae5e;IngestionEndpoint=https://westeurope-5.in.applicationinsights.azure.com/;LiveEndpoint=https://westeurope.livediagnostics.monitor.azure.com/;ApplicationId=7c58eb1c-9581-4ba6-839e-11725848a037";
|
|
1719
1725
|
// SDK Version placeholder
|
|
1720
|
-
const SDK_VERSION = "1.3.
|
|
1726
|
+
const SDK_VERSION = "1.3.3";
|
|
1721
1727
|
const VERSION = "Version";
|
|
1722
1728
|
const SERVICE = "Service";
|
|
1723
1729
|
const CLOUD_ORGANIZATION_NAME = "CloudOrganizationName";
|
package/dist/cases/index.cjs
CHANGED
|
@@ -613,7 +613,11 @@ class ApiClient {
|
|
|
613
613
|
const text = await response.text();
|
|
614
614
|
return text;
|
|
615
615
|
}
|
|
616
|
-
|
|
616
|
+
const text = await response.text();
|
|
617
|
+
if (!text) {
|
|
618
|
+
return undefined;
|
|
619
|
+
}
|
|
620
|
+
return JSON.parse(text);
|
|
617
621
|
}
|
|
618
622
|
catch (error) {
|
|
619
623
|
// If it's already one of our errors, re-throw it
|
|
@@ -1387,8 +1391,9 @@ class PaginationHelpers {
|
|
|
1387
1391
|
});
|
|
1388
1392
|
}
|
|
1389
1393
|
// Extract and transform items from response
|
|
1390
|
-
|
|
1391
|
-
const
|
|
1394
|
+
// Handle both plain array responses and envelope responses ({ value: [...], totalRecordCount: N })
|
|
1395
|
+
const rawItems = Array.isArray(response.data) ? response.data : response.data?.[itemsField];
|
|
1396
|
+
const totalCount = Array.isArray(response.data) ? undefined : response.data?.[totalCountField];
|
|
1392
1397
|
// Parse items - automatically handle JSON string responses
|
|
1393
1398
|
const parsedItems = typeof rawItems === 'string' ? JSON.parse(rawItems) : (rawItems || []);
|
|
1394
1399
|
const items = transformFn ? parsedItems.map(transformFn) : parsedItems;
|
|
@@ -1639,7 +1644,7 @@ class BaseService {
|
|
|
1639
1644
|
const params = this.validateAndPreparePaginationParams(paginationType, paginationOptions);
|
|
1640
1645
|
// Prepare request parameters based on pagination type
|
|
1641
1646
|
const requestParams = this.preparePaginationRequestParams(paginationType, params, options.pagination);
|
|
1642
|
-
// For POST requests, merge pagination params into body; for GET, use query params
|
|
1647
|
+
// For POST requests, merge pagination params into body and set params to undefined; for GET, use query params
|
|
1643
1648
|
if (method.toUpperCase() === 'POST') {
|
|
1644
1649
|
const existingBody = (options.body && typeof options.body === 'object') ? options.body : {};
|
|
1645
1650
|
options.body = {
|
|
@@ -1647,6 +1652,7 @@ class BaseService {
|
|
|
1647
1652
|
...options.params,
|
|
1648
1653
|
...requestParams
|
|
1649
1654
|
};
|
|
1655
|
+
options.params = undefined;
|
|
1650
1656
|
}
|
|
1651
1657
|
else {
|
|
1652
1658
|
// Merge pagination parameters with existing parameters
|
|
@@ -1687,7 +1693,6 @@ class BaseService {
|
|
|
1687
1693
|
if (params.pageNumber && params.pageNumber > 1) {
|
|
1688
1694
|
requestParams[offsetParam] = (params.pageNumber - 1) * limitedPageSize;
|
|
1689
1695
|
}
|
|
1690
|
-
// Include total count for ODATA APIs
|
|
1691
1696
|
{
|
|
1692
1697
|
requestParams[countParam] = true;
|
|
1693
1698
|
}
|
|
@@ -1715,8 +1720,9 @@ class BaseService {
|
|
|
1715
1720
|
const totalCountField = fields.totalCountField || 'totalRecordCount';
|
|
1716
1721
|
const continuationTokenField = fields.continuationTokenField || 'continuationToken';
|
|
1717
1722
|
// Extract items and metadata
|
|
1718
|
-
|
|
1719
|
-
const
|
|
1723
|
+
// Handle both plain array responses and envelope responses ({ value: [...], totalRecordCount: N })
|
|
1724
|
+
const items = Array.isArray(response.data) ? response.data : (response.data[itemsField] || []);
|
|
1725
|
+
const totalCount = Array.isArray(response.data) ? undefined : response.data[totalCountField];
|
|
1720
1726
|
const continuationToken = response.data[continuationTokenField];
|
|
1721
1727
|
// Determine if there are more pages
|
|
1722
1728
|
const hasMore = this.determineHasMorePages(paginationType, {
|
|
@@ -1829,7 +1835,7 @@ const MAESTRO_ENDPOINTS = {
|
|
|
1829
1835
|
// Connection string placeholder that will be replaced during build
|
|
1830
1836
|
const CONNECTION_STRING = "InstrumentationKey=a6efa11d-1feb-4508-9738-e13e12dcae5e;IngestionEndpoint=https://westeurope-5.in.applicationinsights.azure.com/;LiveEndpoint=https://westeurope.livediagnostics.monitor.azure.com/;ApplicationId=7c58eb1c-9581-4ba6-839e-11725848a037";
|
|
1831
1837
|
// SDK Version placeholder
|
|
1832
|
-
const SDK_VERSION = "1.3.
|
|
1838
|
+
const SDK_VERSION = "1.3.3";
|
|
1833
1839
|
const VERSION = "Version";
|
|
1834
1840
|
const SERVICE = "Service";
|
|
1835
1841
|
const CLOUD_ORGANIZATION_NAME = "CloudOrganizationName";
|
|
@@ -2395,6 +2401,21 @@ const CASE_INSTANCE_TASK_FILTER = (caseInstanceId) => `Tags/any(tags:tags/Displa
|
|
|
2395
2401
|
*/
|
|
2396
2402
|
const CASE_INSTANCE_TASK_EXPAND = 'AssignedToUser,Activities';
|
|
2397
2403
|
|
|
2404
|
+
var TaskUserType;
|
|
2405
|
+
(function (TaskUserType) {
|
|
2406
|
+
/** A user of this type is supposed to be used by a human. */
|
|
2407
|
+
TaskUserType["User"] = "User";
|
|
2408
|
+
/** A user of this type is automatically created when adding a robot, is associated with Robot role and it is used by a robot when communicating with Orchestrator. */
|
|
2409
|
+
TaskUserType["Robot"] = "Robot";
|
|
2410
|
+
/** A user of type Directory User */
|
|
2411
|
+
TaskUserType["DirectoryUser"] = "DirectoryUser";
|
|
2412
|
+
/** A user of type Directory Group */
|
|
2413
|
+
TaskUserType["DirectoryGroup"] = "DirectoryGroup";
|
|
2414
|
+
/** A user of type Directory Robot Account */
|
|
2415
|
+
TaskUserType["DirectoryRobot"] = "DirectoryRobot";
|
|
2416
|
+
/** A user of type Directory External Application */
|
|
2417
|
+
TaskUserType["DirectoryExternalApplication"] = "DirectoryExternalApplication";
|
|
2418
|
+
})(TaskUserType || (TaskUserType = {}));
|
|
2398
2419
|
/**
|
|
2399
2420
|
* Types of tasks available in Action Center.
|
|
2400
2421
|
* Each type determines the task's behavior, UI rendering, and completion requirements.
|
|
@@ -2618,15 +2639,15 @@ class TaskService extends BaseService {
|
|
|
2618
2639
|
return createTaskWithMethods(transformedData, this);
|
|
2619
2640
|
}
|
|
2620
2641
|
/**
|
|
2621
|
-
* Gets users in the given folder who have Tasks.View and Tasks.Edit permissions
|
|
2642
|
+
* Gets task users (users, robots, groups etc) in the given folder who have Tasks.View and Tasks.Edit permissions
|
|
2622
2643
|
*
|
|
2623
2644
|
* The method returns either:
|
|
2624
|
-
* - An array of users (when no pagination parameters are provided)
|
|
2645
|
+
* - An array of task users (when no pagination parameters are provided)
|
|
2625
2646
|
* - A paginated result with navigation cursors (when any pagination parameter is provided)
|
|
2626
2647
|
*
|
|
2627
|
-
* @param folderId - The folder ID to get users from
|
|
2648
|
+
* @param folderId - The folder ID to get task users from
|
|
2628
2649
|
* @param options - Optional query and pagination parameters
|
|
2629
|
-
* @returns Promise resolving to an array of users or paginated result
|
|
2650
|
+
* @returns Promise resolving to an array of task users or paginated result
|
|
2630
2651
|
*
|
|
2631
2652
|
* @example
|
|
2632
2653
|
* ```typescript
|
|
@@ -2637,7 +2658,7 @@ class TaskService extends BaseService {
|
|
|
2637
2658
|
* // Standard array return
|
|
2638
2659
|
* const users = await tasks.getUsers(123);
|
|
2639
2660
|
*
|
|
2640
|
-
* // Get users with filtering
|
|
2661
|
+
* // Get task users with filtering
|
|
2641
2662
|
* const users = await tasks.getUsers(123, {
|
|
2642
2663
|
* filter: "name eq 'abc'"
|
|
2643
2664
|
* });
|
package/dist/cases/index.d.ts
CHANGED
|
@@ -414,6 +414,20 @@ interface ElementRunMetadata {
|
|
|
414
414
|
parentElementRunId: string | null;
|
|
415
415
|
}
|
|
416
416
|
|
|
417
|
+
declare enum TaskUserType {
|
|
418
|
+
/** A user of this type is supposed to be used by a human. */
|
|
419
|
+
User = "User",
|
|
420
|
+
/** A user of this type is automatically created when adding a robot, is associated with Robot role and it is used by a robot when communicating with Orchestrator. */
|
|
421
|
+
Robot = "Robot",
|
|
422
|
+
/** A user of type Directory User */
|
|
423
|
+
DirectoryUser = "DirectoryUser",
|
|
424
|
+
/** A user of type Directory Group */
|
|
425
|
+
DirectoryGroup = "DirectoryGroup",
|
|
426
|
+
/** A user of type Directory Robot Account */
|
|
427
|
+
DirectoryRobot = "DirectoryRobot",
|
|
428
|
+
/** A user of type Directory External Application */
|
|
429
|
+
DirectoryExternalApplication = "DirectoryExternalApplication"
|
|
430
|
+
}
|
|
417
431
|
interface UserLoginInfo {
|
|
418
432
|
name: string;
|
|
419
433
|
surname: string;
|
|
@@ -421,6 +435,7 @@ interface UserLoginInfo {
|
|
|
421
435
|
emailAddress: string;
|
|
422
436
|
displayName: string;
|
|
423
437
|
id: number;
|
|
438
|
+
type: TaskUserType;
|
|
424
439
|
}
|
|
425
440
|
/**
|
|
426
441
|
* Types of tasks available in Action Center.
|