@uipath/uipath-typescript 1.3.10 → 1.4.0
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/agent-memory/index.cjs +1765 -0
- package/dist/agent-memory/index.d.ts +588 -0
- package/dist/agent-memory/index.mjs +1763 -0
- package/dist/agents/index.cjs +1726 -0
- package/dist/agents/index.d.ts +502 -0
- package/dist/agents/index.mjs +1724 -0
- package/dist/assets/index.cjs +155 -30
- package/dist/assets/index.d.ts +84 -5
- package/dist/assets/index.mjs +155 -30
- package/dist/attachments/index.cjs +37 -6
- package/dist/attachments/index.d.ts +1 -0
- package/dist/attachments/index.mjs +37 -6
- package/dist/buckets/index.cjs +37 -6
- package/dist/buckets/index.d.ts +1 -0
- package/dist/buckets/index.mjs +37 -6
- package/dist/cases/index.cjs +192 -10
- package/dist/cases/index.d.ts +208 -7
- package/dist/cases/index.mjs +192 -11
- package/dist/conversational-agent/index.cjs +124 -57
- package/dist/conversational-agent/index.d.ts +190 -122
- package/dist/conversational-agent/index.mjs +124 -57
- package/dist/core/index.cjs +413 -105
- package/dist/core/index.d.ts +15 -0
- package/dist/core/index.mjs +413 -105
- package/dist/entities/index.cjs +135 -70
- package/dist/entities/index.d.ts +146 -45
- package/dist/entities/index.mjs +135 -70
- package/dist/feedback/index.cjs +37 -6
- package/dist/feedback/index.d.ts +1 -0
- package/dist/feedback/index.mjs +37 -6
- package/dist/governance/index.cjs +1782 -0
- package/dist/governance/index.d.ts +598 -0
- package/dist/governance/index.mjs +1780 -0
- package/dist/index.cjs +1050 -291
- package/dist/index.d.ts +1313 -134
- package/dist/index.mjs +1050 -292
- package/dist/index.umd.js +4546 -3770
- package/dist/jobs/index.cjs +37 -6
- package/dist/jobs/index.d.ts +1 -0
- package/dist/jobs/index.mjs +37 -6
- package/dist/maestro-processes/index.cjs +224 -18
- package/dist/maestro-processes/index.d.ts +221 -9
- package/dist/maestro-processes/index.mjs +224 -18
- package/dist/processes/index.cjs +37 -6
- package/dist/processes/index.d.ts +1 -0
- package/dist/processes/index.mjs +37 -6
- package/dist/queues/index.cjs +37 -6
- package/dist/queues/index.d.ts +1 -0
- package/dist/queues/index.mjs +37 -6
- package/dist/tasks/index.cjs +37 -6
- package/dist/tasks/index.d.ts +1 -0
- package/dist/tasks/index.mjs +37 -6
- package/dist/traces/index.cjs +1933 -0
- package/dist/traces/index.d.ts +566 -0
- package/dist/traces/index.mjs +1931 -0
- package/package.json +42 -2
package/dist/queues/index.mjs
CHANGED
|
@@ -719,6 +719,32 @@ function filterUndefined(obj) {
|
|
|
719
719
|
*/
|
|
720
720
|
const isBrowser = typeof window !== 'undefined' && typeof window.document !== 'undefined';
|
|
721
721
|
isBrowser && window.self != window.top && window.location.href.includes('source=ActionCenter');
|
|
722
|
+
const _params = isBrowser ? new URLSearchParams(window.location.search) : null;
|
|
723
|
+
/**
|
|
724
|
+
* True when the coded app has been loaded inside a host frame that explicitly
|
|
725
|
+
* opted into token delegation by adding `?host=embed` to the iframe src URL.
|
|
726
|
+
*/
|
|
727
|
+
const isHostEmbedded = isBrowser && window.self !== window.top && _params?.get('host') === 'embed';
|
|
728
|
+
/**
|
|
729
|
+
* The validated parent origin, read from the `?basedomain=` query param set
|
|
730
|
+
* by the embedding host in the iframe src URL.
|
|
731
|
+
* Mirrors the same mechanism used by ActionCenterTokenManager.
|
|
732
|
+
* Non-null only when `?host=embed` is present and `?basedomain=` is a valid URL.
|
|
733
|
+
*/
|
|
734
|
+
(() => {
|
|
735
|
+
if (!isHostEmbedded)
|
|
736
|
+
return null;
|
|
737
|
+
const basedomain = _params?.get('basedomain');
|
|
738
|
+
if (!basedomain)
|
|
739
|
+
return null;
|
|
740
|
+
try {
|
|
741
|
+
return new URL(basedomain).origin;
|
|
742
|
+
}
|
|
743
|
+
catch {
|
|
744
|
+
console.warn('embeddingOrigin: basedomain query param is not a valid URL', basedomain);
|
|
745
|
+
return null;
|
|
746
|
+
}
|
|
747
|
+
})();
|
|
722
748
|
|
|
723
749
|
/**
|
|
724
750
|
* Base64 encoding/decoding
|
|
@@ -1279,8 +1305,9 @@ class PaginationHelpers {
|
|
|
1279
1305
|
});
|
|
1280
1306
|
}
|
|
1281
1307
|
// Extract and transform items from response
|
|
1282
|
-
// Handle both plain array responses and envelope responses ({ value: [...], totalRecordCount: N })
|
|
1283
|
-
|
|
1308
|
+
// Handle both plain array responses and envelope responses ({ value: [...], totalRecordCount: N }).
|
|
1309
|
+
// itemsField may be a dotted path (e.g. 'data.agents') for nested envelopes.
|
|
1310
|
+
const rawItems = Array.isArray(response.data) ? response.data : resolveNestedField(response.data, itemsField);
|
|
1284
1311
|
const rawTotalCount = Array.isArray(response.data) ? undefined : resolveNestedField(response.data, totalCountField);
|
|
1285
1312
|
const totalCount = typeof rawTotalCount === 'number' ? rawTotalCount : undefined;
|
|
1286
1313
|
// Parse items - automatically handle JSON string responses
|
|
@@ -1326,7 +1353,7 @@ class PaginationHelpers {
|
|
|
1326
1353
|
getEndpoint: config.getEndpoint,
|
|
1327
1354
|
folderId,
|
|
1328
1355
|
headers: config.headers,
|
|
1329
|
-
paginationParams: cursor ? { cursor, pageSize } : jumpToPage ? { jumpToPage, pageSize } : { pageSize },
|
|
1356
|
+
paginationParams: cursor ? { cursor, pageSize } : jumpToPage !== undefined ? { jumpToPage, pageSize } : { pageSize },
|
|
1330
1357
|
additionalParams: prefixedOptions,
|
|
1331
1358
|
transformFn: config.transformFn,
|
|
1332
1359
|
method: config.method,
|
|
@@ -1584,6 +1611,8 @@ class BaseService {
|
|
|
1584
1611
|
// When true (default), converts pageNumber to a skip/offset value (e.g., page 3 with pageSize 10 → skip 20).
|
|
1585
1612
|
// When false, passes pageNumber directly as the offset param — used by APIs that accept a page number instead of a record offset.
|
|
1586
1613
|
const convertToSkip = paginationParams?.convertToSkip ?? true;
|
|
1614
|
+
// When true, sends pageNumber - 1 (for 0-based APIs). Default false (1-based).
|
|
1615
|
+
const zeroBased = paginationParams?.zeroBased ?? false;
|
|
1587
1616
|
requestParams[pageSizeParam] = limitedPageSize;
|
|
1588
1617
|
if (convertToSkip) {
|
|
1589
1618
|
if (params.pageNumber && params.pageNumber > 1) {
|
|
@@ -1591,7 +1620,8 @@ class BaseService {
|
|
|
1591
1620
|
}
|
|
1592
1621
|
}
|
|
1593
1622
|
else {
|
|
1594
|
-
|
|
1623
|
+
const sdkPageNumber = params.pageNumber || 1;
|
|
1624
|
+
requestParams[offsetParam] = zeroBased ? sdkPageNumber - 1 : sdkPageNumber;
|
|
1595
1625
|
}
|
|
1596
1626
|
{
|
|
1597
1627
|
requestParams[countParam] = true;
|
|
@@ -1620,8 +1650,9 @@ class BaseService {
|
|
|
1620
1650
|
const totalCountField = fields.totalCountField || 'totalRecordCount';
|
|
1621
1651
|
const continuationTokenField = fields.continuationTokenField || 'continuationToken';
|
|
1622
1652
|
// Extract items and metadata
|
|
1623
|
-
// Handle both plain array responses and envelope responses ({ value: [...], totalRecordCount: N })
|
|
1624
|
-
|
|
1653
|
+
// Handle both plain array responses and envelope responses ({ value: [...], totalRecordCount: N }).
|
|
1654
|
+
// itemsField may be a dotted path (e.g. 'data.agents') for nested envelopes.
|
|
1655
|
+
const items = Array.isArray(response.data) ? response.data : (resolveNestedField(response.data, itemsField) || []);
|
|
1625
1656
|
const rawTotalCount = Array.isArray(response.data) ? undefined : resolveNestedField(response.data, totalCountField);
|
|
1626
1657
|
const totalCount = typeof rawTotalCount === 'number' ? rawTotalCount : undefined;
|
|
1627
1658
|
const continuationToken = response.data[continuationTokenField];
|
package/dist/tasks/index.cjs
CHANGED
|
@@ -979,6 +979,32 @@ function getLimitedPageSize(pageSize) {
|
|
|
979
979
|
*/
|
|
980
980
|
const isBrowser = typeof window !== 'undefined' && typeof window.document !== 'undefined';
|
|
981
981
|
isBrowser && window.self != window.top && window.location.href.includes('source=ActionCenter');
|
|
982
|
+
const _params = isBrowser ? new URLSearchParams(window.location.search) : null;
|
|
983
|
+
/**
|
|
984
|
+
* True when the coded app has been loaded inside a host frame that explicitly
|
|
985
|
+
* opted into token delegation by adding `?host=embed` to the iframe src URL.
|
|
986
|
+
*/
|
|
987
|
+
const isHostEmbedded = isBrowser && window.self !== window.top && _params?.get('host') === 'embed';
|
|
988
|
+
/**
|
|
989
|
+
* The validated parent origin, read from the `?basedomain=` query param set
|
|
990
|
+
* by the embedding host in the iframe src URL.
|
|
991
|
+
* Mirrors the same mechanism used by ActionCenterTokenManager.
|
|
992
|
+
* Non-null only when `?host=embed` is present and `?basedomain=` is a valid URL.
|
|
993
|
+
*/
|
|
994
|
+
(() => {
|
|
995
|
+
if (!isHostEmbedded)
|
|
996
|
+
return null;
|
|
997
|
+
const basedomain = _params?.get('basedomain');
|
|
998
|
+
if (!basedomain)
|
|
999
|
+
return null;
|
|
1000
|
+
try {
|
|
1001
|
+
return new URL(basedomain).origin;
|
|
1002
|
+
}
|
|
1003
|
+
catch {
|
|
1004
|
+
console.warn('embeddingOrigin: basedomain query param is not a valid URL', basedomain);
|
|
1005
|
+
return null;
|
|
1006
|
+
}
|
|
1007
|
+
})();
|
|
982
1008
|
|
|
983
1009
|
/**
|
|
984
1010
|
* Base64 encoding/decoding
|
|
@@ -1208,8 +1234,9 @@ class PaginationHelpers {
|
|
|
1208
1234
|
});
|
|
1209
1235
|
}
|
|
1210
1236
|
// Extract and transform items from response
|
|
1211
|
-
// Handle both plain array responses and envelope responses ({ value: [...], totalRecordCount: N })
|
|
1212
|
-
|
|
1237
|
+
// Handle both plain array responses and envelope responses ({ value: [...], totalRecordCount: N }).
|
|
1238
|
+
// itemsField may be a dotted path (e.g. 'data.agents') for nested envelopes.
|
|
1239
|
+
const rawItems = Array.isArray(response.data) ? response.data : resolveNestedField(response.data, itemsField);
|
|
1213
1240
|
const rawTotalCount = Array.isArray(response.data) ? undefined : resolveNestedField(response.data, totalCountField);
|
|
1214
1241
|
const totalCount = typeof rawTotalCount === 'number' ? rawTotalCount : undefined;
|
|
1215
1242
|
// Parse items - automatically handle JSON string responses
|
|
@@ -1255,7 +1282,7 @@ class PaginationHelpers {
|
|
|
1255
1282
|
getEndpoint: config.getEndpoint,
|
|
1256
1283
|
folderId,
|
|
1257
1284
|
headers: config.headers,
|
|
1258
|
-
paginationParams: cursor ? { cursor, pageSize } : jumpToPage ? { jumpToPage, pageSize } : { pageSize },
|
|
1285
|
+
paginationParams: cursor ? { cursor, pageSize } : jumpToPage !== undefined ? { jumpToPage, pageSize } : { pageSize },
|
|
1259
1286
|
additionalParams: prefixedOptions,
|
|
1260
1287
|
transformFn: config.transformFn,
|
|
1261
1288
|
method: config.method,
|
|
@@ -1944,6 +1971,8 @@ class BaseService {
|
|
|
1944
1971
|
// When true (default), converts pageNumber to a skip/offset value (e.g., page 3 with pageSize 10 → skip 20).
|
|
1945
1972
|
// When false, passes pageNumber directly as the offset param — used by APIs that accept a page number instead of a record offset.
|
|
1946
1973
|
const convertToSkip = paginationParams?.convertToSkip ?? true;
|
|
1974
|
+
// When true, sends pageNumber - 1 (for 0-based APIs). Default false (1-based).
|
|
1975
|
+
const zeroBased = paginationParams?.zeroBased ?? false;
|
|
1947
1976
|
requestParams[pageSizeParam] = limitedPageSize;
|
|
1948
1977
|
if (convertToSkip) {
|
|
1949
1978
|
if (params.pageNumber && params.pageNumber > 1) {
|
|
@@ -1951,7 +1980,8 @@ class BaseService {
|
|
|
1951
1980
|
}
|
|
1952
1981
|
}
|
|
1953
1982
|
else {
|
|
1954
|
-
|
|
1983
|
+
const sdkPageNumber = params.pageNumber || 1;
|
|
1984
|
+
requestParams[offsetParam] = zeroBased ? sdkPageNumber - 1 : sdkPageNumber;
|
|
1955
1985
|
}
|
|
1956
1986
|
{
|
|
1957
1987
|
requestParams[countParam] = true;
|
|
@@ -1980,8 +2010,9 @@ class BaseService {
|
|
|
1980
2010
|
const totalCountField = fields.totalCountField || 'totalRecordCount';
|
|
1981
2011
|
const continuationTokenField = fields.continuationTokenField || 'continuationToken';
|
|
1982
2012
|
// Extract items and metadata
|
|
1983
|
-
// Handle both plain array responses and envelope responses ({ value: [...], totalRecordCount: N })
|
|
1984
|
-
|
|
2013
|
+
// Handle both plain array responses and envelope responses ({ value: [...], totalRecordCount: N }).
|
|
2014
|
+
// itemsField may be a dotted path (e.g. 'data.agents') for nested envelopes.
|
|
2015
|
+
const items = Array.isArray(response.data) ? response.data : (resolveNestedField(response.data, itemsField) || []);
|
|
1985
2016
|
const rawTotalCount = Array.isArray(response.data) ? undefined : resolveNestedField(response.data, totalCountField);
|
|
1986
2017
|
const totalCount = typeof rawTotalCount === 'number' ? rawTotalCount : undefined;
|
|
1987
2018
|
const continuationToken = response.data[continuationTokenField];
|
package/dist/tasks/index.d.ts
CHANGED
package/dist/tasks/index.mjs
CHANGED
|
@@ -977,6 +977,32 @@ function getLimitedPageSize(pageSize) {
|
|
|
977
977
|
*/
|
|
978
978
|
const isBrowser = typeof window !== 'undefined' && typeof window.document !== 'undefined';
|
|
979
979
|
isBrowser && window.self != window.top && window.location.href.includes('source=ActionCenter');
|
|
980
|
+
const _params = isBrowser ? new URLSearchParams(window.location.search) : null;
|
|
981
|
+
/**
|
|
982
|
+
* True when the coded app has been loaded inside a host frame that explicitly
|
|
983
|
+
* opted into token delegation by adding `?host=embed` to the iframe src URL.
|
|
984
|
+
*/
|
|
985
|
+
const isHostEmbedded = isBrowser && window.self !== window.top && _params?.get('host') === 'embed';
|
|
986
|
+
/**
|
|
987
|
+
* The validated parent origin, read from the `?basedomain=` query param set
|
|
988
|
+
* by the embedding host in the iframe src URL.
|
|
989
|
+
* Mirrors the same mechanism used by ActionCenterTokenManager.
|
|
990
|
+
* Non-null only when `?host=embed` is present and `?basedomain=` is a valid URL.
|
|
991
|
+
*/
|
|
992
|
+
(() => {
|
|
993
|
+
if (!isHostEmbedded)
|
|
994
|
+
return null;
|
|
995
|
+
const basedomain = _params?.get('basedomain');
|
|
996
|
+
if (!basedomain)
|
|
997
|
+
return null;
|
|
998
|
+
try {
|
|
999
|
+
return new URL(basedomain).origin;
|
|
1000
|
+
}
|
|
1001
|
+
catch {
|
|
1002
|
+
console.warn('embeddingOrigin: basedomain query param is not a valid URL', basedomain);
|
|
1003
|
+
return null;
|
|
1004
|
+
}
|
|
1005
|
+
})();
|
|
980
1006
|
|
|
981
1007
|
/**
|
|
982
1008
|
* Base64 encoding/decoding
|
|
@@ -1206,8 +1232,9 @@ class PaginationHelpers {
|
|
|
1206
1232
|
});
|
|
1207
1233
|
}
|
|
1208
1234
|
// Extract and transform items from response
|
|
1209
|
-
// Handle both plain array responses and envelope responses ({ value: [...], totalRecordCount: N })
|
|
1210
|
-
|
|
1235
|
+
// Handle both plain array responses and envelope responses ({ value: [...], totalRecordCount: N }).
|
|
1236
|
+
// itemsField may be a dotted path (e.g. 'data.agents') for nested envelopes.
|
|
1237
|
+
const rawItems = Array.isArray(response.data) ? response.data : resolveNestedField(response.data, itemsField);
|
|
1211
1238
|
const rawTotalCount = Array.isArray(response.data) ? undefined : resolveNestedField(response.data, totalCountField);
|
|
1212
1239
|
const totalCount = typeof rawTotalCount === 'number' ? rawTotalCount : undefined;
|
|
1213
1240
|
// Parse items - automatically handle JSON string responses
|
|
@@ -1253,7 +1280,7 @@ class PaginationHelpers {
|
|
|
1253
1280
|
getEndpoint: config.getEndpoint,
|
|
1254
1281
|
folderId,
|
|
1255
1282
|
headers: config.headers,
|
|
1256
|
-
paginationParams: cursor ? { cursor, pageSize } : jumpToPage ? { jumpToPage, pageSize } : { pageSize },
|
|
1283
|
+
paginationParams: cursor ? { cursor, pageSize } : jumpToPage !== undefined ? { jumpToPage, pageSize } : { pageSize },
|
|
1257
1284
|
additionalParams: prefixedOptions,
|
|
1258
1285
|
transformFn: config.transformFn,
|
|
1259
1286
|
method: config.method,
|
|
@@ -1942,6 +1969,8 @@ class BaseService {
|
|
|
1942
1969
|
// When true (default), converts pageNumber to a skip/offset value (e.g., page 3 with pageSize 10 → skip 20).
|
|
1943
1970
|
// When false, passes pageNumber directly as the offset param — used by APIs that accept a page number instead of a record offset.
|
|
1944
1971
|
const convertToSkip = paginationParams?.convertToSkip ?? true;
|
|
1972
|
+
// When true, sends pageNumber - 1 (for 0-based APIs). Default false (1-based).
|
|
1973
|
+
const zeroBased = paginationParams?.zeroBased ?? false;
|
|
1945
1974
|
requestParams[pageSizeParam] = limitedPageSize;
|
|
1946
1975
|
if (convertToSkip) {
|
|
1947
1976
|
if (params.pageNumber && params.pageNumber > 1) {
|
|
@@ -1949,7 +1978,8 @@ class BaseService {
|
|
|
1949
1978
|
}
|
|
1950
1979
|
}
|
|
1951
1980
|
else {
|
|
1952
|
-
|
|
1981
|
+
const sdkPageNumber = params.pageNumber || 1;
|
|
1982
|
+
requestParams[offsetParam] = zeroBased ? sdkPageNumber - 1 : sdkPageNumber;
|
|
1953
1983
|
}
|
|
1954
1984
|
{
|
|
1955
1985
|
requestParams[countParam] = true;
|
|
@@ -1978,8 +2008,9 @@ class BaseService {
|
|
|
1978
2008
|
const totalCountField = fields.totalCountField || 'totalRecordCount';
|
|
1979
2009
|
const continuationTokenField = fields.continuationTokenField || 'continuationToken';
|
|
1980
2010
|
// Extract items and metadata
|
|
1981
|
-
// Handle both plain array responses and envelope responses ({ value: [...], totalRecordCount: N })
|
|
1982
|
-
|
|
2011
|
+
// Handle both plain array responses and envelope responses ({ value: [...], totalRecordCount: N }).
|
|
2012
|
+
// itemsField may be a dotted path (e.g. 'data.agents') for nested envelopes.
|
|
2013
|
+
const items = Array.isArray(response.data) ? response.data : (resolveNestedField(response.data, itemsField) || []);
|
|
1983
2014
|
const rawTotalCount = Array.isArray(response.data) ? undefined : resolveNestedField(response.data, totalCountField);
|
|
1984
2015
|
const totalCount = typeof rawTotalCount === 'number' ? rawTotalCount : undefined;
|
|
1985
2016
|
const continuationToken = response.data[continuationTokenField];
|