@uipath/uipath-typescript 1.4.2 → 1.5.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.d.ts +4 -1
- package/dist/agents/index.cjs +341 -6
- package/dist/agents/index.d.ts +717 -16
- package/dist/agents/index.mjs +342 -7
- package/dist/assets/index.cjs +25 -9
- package/dist/assets/index.mjs +25 -9
- package/dist/attachments/index.cjs +25 -9
- package/dist/attachments/index.mjs +25 -9
- package/dist/buckets/index.cjs +25 -9
- package/dist/buckets/index.mjs +25 -9
- package/dist/cases/index.cjs +621 -524
- package/dist/cases/index.d.ts +186 -43
- package/dist/cases/index.mjs +621 -524
- package/dist/conversational-agent/index.cjs +25 -9
- package/dist/conversational-agent/index.mjs +25 -9
- package/dist/core/index.cjs +1 -1
- package/dist/core/index.mjs +1 -1
- package/dist/entities/index.cjs +25 -9
- package/dist/entities/index.mjs +25 -9
- package/dist/feedback/index.cjs +25 -9
- package/dist/feedback/index.mjs +25 -9
- package/dist/index.cjs +332 -62
- package/dist/index.d.ts +827 -89
- package/dist/index.mjs +333 -63
- package/dist/index.umd.js +332 -62
- package/dist/jobs/index.cjs +129 -14
- package/dist/jobs/index.d.ts +10 -5
- package/dist/jobs/index.mjs +129 -14
- package/dist/maestro-processes/index.cjs +198 -100
- package/dist/maestro-processes/index.d.ts +188 -43
- package/dist/maestro-processes/index.mjs +198 -100
- package/dist/processes/index.cjs +25 -9
- package/dist/processes/index.d.ts +6 -1
- package/dist/processes/index.mjs +25 -9
- package/dist/queues/index.cjs +25 -9
- package/dist/queues/index.mjs +25 -9
- package/dist/tasks/index.cjs +25 -9
- package/dist/tasks/index.d.ts +4 -1
- package/dist/tasks/index.mjs +25 -9
- package/dist/traces/index.cjs +2 -2
- package/dist/traces/index.d.ts +3 -3
- package/dist/traces/index.mjs +2 -2
- package/package.json +1 -1
|
@@ -1023,7 +1023,16 @@ const CONVERSATIONAL_TOKEN_PARAMS = {
|
|
|
1023
1023
|
* Returns the original value if parsing fails.
|
|
1024
1024
|
*/
|
|
1025
1025
|
/**
|
|
1026
|
-
* Transforms data by
|
|
1026
|
+
* Transforms data by renaming each key in `data` exactly once, using the
|
|
1027
|
+
* mapping (`sourceField → targetField`). Keys not present in the mapping
|
|
1028
|
+
* pass through unchanged. The original (pre-rename) key is dropped — the
|
|
1029
|
+
* result contains only the renamed key.
|
|
1030
|
+
*
|
|
1031
|
+
* Each rename is independent. If the mapping happens to contain chained
|
|
1032
|
+
* entries (`a → b` and `b → c`), they do NOT compose: a field named `a`
|
|
1033
|
+
* in `data` becomes `b` (not `c`), because the renames are applied based
|
|
1034
|
+
* on the original data's keys, not the running result.
|
|
1035
|
+
*
|
|
1027
1036
|
* @param data The source data to transform
|
|
1028
1037
|
* @param fieldMapping Object mapping source field names to target field names
|
|
1029
1038
|
* @returns Transformed data with mapped field names
|
|
@@ -1046,21 +1055,28 @@ const CONVERSATIONAL_TOKEN_PARAMS = {
|
|
|
1046
1055
|
* // { userId: '123', name: 'john' },
|
|
1047
1056
|
* // { userId: '456', name: 'jane' }
|
|
1048
1057
|
* // ]
|
|
1058
|
+
*
|
|
1059
|
+
* // No chaining — `a → b` does not become `a → c` even if the map has `b → c`.
|
|
1060
|
+
* transformData({ a: 1 }, { a: 'b', b: 'c' });
|
|
1061
|
+
* // result = { b: 1 }
|
|
1049
1062
|
* ```
|
|
1050
1063
|
*/
|
|
1051
1064
|
function transformData(data, fieldMapping) {
|
|
1065
|
+
// Pass null/undefined through unchanged — callers (e.g. AttachmentService.getById)
|
|
1066
|
+
// may invoke this on optional fields that an OData `select` excluded.
|
|
1067
|
+
if (data == null) {
|
|
1068
|
+
return data;
|
|
1069
|
+
}
|
|
1052
1070
|
// Handle array of objects
|
|
1053
1071
|
if (Array.isArray(data)) {
|
|
1054
1072
|
return data.map(item => transformData(item, fieldMapping));
|
|
1055
1073
|
}
|
|
1056
|
-
//
|
|
1057
|
-
|
|
1058
|
-
|
|
1059
|
-
|
|
1060
|
-
|
|
1061
|
-
|
|
1062
|
-
result[targetField] = value;
|
|
1063
|
-
}
|
|
1074
|
+
// Walk the ORIGINAL data's keys, look up each in the mapping. One rename
|
|
1075
|
+
// per data key — no mutation of an in-progress result, so chains can't form.
|
|
1076
|
+
const result = {};
|
|
1077
|
+
for (const [key, value] of Object.entries(data)) {
|
|
1078
|
+
const renamedKey = fieldMapping[key] ?? key;
|
|
1079
|
+
result[renamedKey] = value;
|
|
1064
1080
|
}
|
|
1065
1081
|
return result;
|
|
1066
1082
|
}
|
|
@@ -1021,7 +1021,16 @@ const CONVERSATIONAL_TOKEN_PARAMS = {
|
|
|
1021
1021
|
* Returns the original value if parsing fails.
|
|
1022
1022
|
*/
|
|
1023
1023
|
/**
|
|
1024
|
-
* Transforms data by
|
|
1024
|
+
* Transforms data by renaming each key in `data` exactly once, using the
|
|
1025
|
+
* mapping (`sourceField → targetField`). Keys not present in the mapping
|
|
1026
|
+
* pass through unchanged. The original (pre-rename) key is dropped — the
|
|
1027
|
+
* result contains only the renamed key.
|
|
1028
|
+
*
|
|
1029
|
+
* Each rename is independent. If the mapping happens to contain chained
|
|
1030
|
+
* entries (`a → b` and `b → c`), they do NOT compose: a field named `a`
|
|
1031
|
+
* in `data` becomes `b` (not `c`), because the renames are applied based
|
|
1032
|
+
* on the original data's keys, not the running result.
|
|
1033
|
+
*
|
|
1025
1034
|
* @param data The source data to transform
|
|
1026
1035
|
* @param fieldMapping Object mapping source field names to target field names
|
|
1027
1036
|
* @returns Transformed data with mapped field names
|
|
@@ -1044,21 +1053,28 @@ const CONVERSATIONAL_TOKEN_PARAMS = {
|
|
|
1044
1053
|
* // { userId: '123', name: 'john' },
|
|
1045
1054
|
* // { userId: '456', name: 'jane' }
|
|
1046
1055
|
* // ]
|
|
1056
|
+
*
|
|
1057
|
+
* // No chaining — `a → b` does not become `a → c` even if the map has `b → c`.
|
|
1058
|
+
* transformData({ a: 1 }, { a: 'b', b: 'c' });
|
|
1059
|
+
* // result = { b: 1 }
|
|
1047
1060
|
* ```
|
|
1048
1061
|
*/
|
|
1049
1062
|
function transformData(data, fieldMapping) {
|
|
1063
|
+
// Pass null/undefined through unchanged — callers (e.g. AttachmentService.getById)
|
|
1064
|
+
// may invoke this on optional fields that an OData `select` excluded.
|
|
1065
|
+
if (data == null) {
|
|
1066
|
+
return data;
|
|
1067
|
+
}
|
|
1050
1068
|
// Handle array of objects
|
|
1051
1069
|
if (Array.isArray(data)) {
|
|
1052
1070
|
return data.map(item => transformData(item, fieldMapping));
|
|
1053
1071
|
}
|
|
1054
|
-
//
|
|
1055
|
-
|
|
1056
|
-
|
|
1057
|
-
|
|
1058
|
-
|
|
1059
|
-
|
|
1060
|
-
result[targetField] = value;
|
|
1061
|
-
}
|
|
1072
|
+
// Walk the ORIGINAL data's keys, look up each in the mapping. One rename
|
|
1073
|
+
// per data key — no mutation of an in-progress result, so chains can't form.
|
|
1074
|
+
const result = {};
|
|
1075
|
+
for (const [key, value] of Object.entries(data)) {
|
|
1076
|
+
const renamedKey = fieldMapping[key] ?? key;
|
|
1077
|
+
result[renamedKey] = value;
|
|
1062
1078
|
}
|
|
1063
1079
|
return result;
|
|
1064
1080
|
}
|
package/dist/core/index.cjs
CHANGED
|
@@ -4822,7 +4822,7 @@ class EmbeddedTokenManager {
|
|
|
4822
4822
|
* SDK's public API.
|
|
4823
4823
|
*/
|
|
4824
4824
|
/** SDK version placeholder — patched by the SDK publish workflow. */
|
|
4825
|
-
const SDK_VERSION = '1.
|
|
4825
|
+
const SDK_VERSION = '1.5.0';
|
|
4826
4826
|
const CLOUD_ROLE_NAME = 'uipath-ts-sdk';
|
|
4827
4827
|
const SDK_SERVICE_NAME = 'UiPath.TypeScript.Sdk';
|
|
4828
4828
|
const SDK_LOGGER_NAME = 'uipath-ts-sdk-telemetry';
|
package/dist/core/index.mjs
CHANGED
|
@@ -4820,7 +4820,7 @@ class EmbeddedTokenManager {
|
|
|
4820
4820
|
* SDK's public API.
|
|
4821
4821
|
*/
|
|
4822
4822
|
/** SDK version placeholder — patched by the SDK publish workflow. */
|
|
4823
|
-
const SDK_VERSION = '1.
|
|
4823
|
+
const SDK_VERSION = '1.5.0';
|
|
4824
4824
|
const CLOUD_ROLE_NAME = 'uipath-ts-sdk';
|
|
4825
4825
|
const SDK_SERVICE_NAME = 'UiPath.TypeScript.Sdk';
|
|
4826
4826
|
const SDK_LOGGER_NAME = 'uipath-ts-sdk-telemetry';
|
package/dist/entities/index.cjs
CHANGED
|
@@ -976,7 +976,16 @@ const BUCKET_TOKEN_PARAMS = {
|
|
|
976
976
|
* Returns the original value if parsing fails.
|
|
977
977
|
*/
|
|
978
978
|
/**
|
|
979
|
-
* Transforms data by
|
|
979
|
+
* Transforms data by renaming each key in `data` exactly once, using the
|
|
980
|
+
* mapping (`sourceField → targetField`). Keys not present in the mapping
|
|
981
|
+
* pass through unchanged. The original (pre-rename) key is dropped — the
|
|
982
|
+
* result contains only the renamed key.
|
|
983
|
+
*
|
|
984
|
+
* Each rename is independent. If the mapping happens to contain chained
|
|
985
|
+
* entries (`a → b` and `b → c`), they do NOT compose: a field named `a`
|
|
986
|
+
* in `data` becomes `b` (not `c`), because the renames are applied based
|
|
987
|
+
* on the original data's keys, not the running result.
|
|
988
|
+
*
|
|
980
989
|
* @param data The source data to transform
|
|
981
990
|
* @param fieldMapping Object mapping source field names to target field names
|
|
982
991
|
* @returns Transformed data with mapped field names
|
|
@@ -999,21 +1008,28 @@ const BUCKET_TOKEN_PARAMS = {
|
|
|
999
1008
|
* // { userId: '123', name: 'john' },
|
|
1000
1009
|
* // { userId: '456', name: 'jane' }
|
|
1001
1010
|
* // ]
|
|
1011
|
+
*
|
|
1012
|
+
* // No chaining — `a → b` does not become `a → c` even if the map has `b → c`.
|
|
1013
|
+
* transformData({ a: 1 }, { a: 'b', b: 'c' });
|
|
1014
|
+
* // result = { b: 1 }
|
|
1002
1015
|
* ```
|
|
1003
1016
|
*/
|
|
1004
1017
|
function transformData(data, fieldMapping) {
|
|
1018
|
+
// Pass null/undefined through unchanged — callers (e.g. AttachmentService.getById)
|
|
1019
|
+
// may invoke this on optional fields that an OData `select` excluded.
|
|
1020
|
+
if (data == null) {
|
|
1021
|
+
return data;
|
|
1022
|
+
}
|
|
1005
1023
|
// Handle array of objects
|
|
1006
1024
|
if (Array.isArray(data)) {
|
|
1007
1025
|
return data.map(item => transformData(item, fieldMapping));
|
|
1008
1026
|
}
|
|
1009
|
-
//
|
|
1010
|
-
|
|
1011
|
-
|
|
1012
|
-
|
|
1013
|
-
|
|
1014
|
-
|
|
1015
|
-
result[targetField] = value;
|
|
1016
|
-
}
|
|
1027
|
+
// Walk the ORIGINAL data's keys, look up each in the mapping. One rename
|
|
1028
|
+
// per data key — no mutation of an in-progress result, so chains can't form.
|
|
1029
|
+
const result = {};
|
|
1030
|
+
for (const [key, value] of Object.entries(data)) {
|
|
1031
|
+
const renamedKey = fieldMapping[key] ?? key;
|
|
1032
|
+
result[renamedKey] = value;
|
|
1017
1033
|
}
|
|
1018
1034
|
return result;
|
|
1019
1035
|
}
|
package/dist/entities/index.mjs
CHANGED
|
@@ -974,7 +974,16 @@ const BUCKET_TOKEN_PARAMS = {
|
|
|
974
974
|
* Returns the original value if parsing fails.
|
|
975
975
|
*/
|
|
976
976
|
/**
|
|
977
|
-
* Transforms data by
|
|
977
|
+
* Transforms data by renaming each key in `data` exactly once, using the
|
|
978
|
+
* mapping (`sourceField → targetField`). Keys not present in the mapping
|
|
979
|
+
* pass through unchanged. The original (pre-rename) key is dropped — the
|
|
980
|
+
* result contains only the renamed key.
|
|
981
|
+
*
|
|
982
|
+
* Each rename is independent. If the mapping happens to contain chained
|
|
983
|
+
* entries (`a → b` and `b → c`), they do NOT compose: a field named `a`
|
|
984
|
+
* in `data` becomes `b` (not `c`), because the renames are applied based
|
|
985
|
+
* on the original data's keys, not the running result.
|
|
986
|
+
*
|
|
978
987
|
* @param data The source data to transform
|
|
979
988
|
* @param fieldMapping Object mapping source field names to target field names
|
|
980
989
|
* @returns Transformed data with mapped field names
|
|
@@ -997,21 +1006,28 @@ const BUCKET_TOKEN_PARAMS = {
|
|
|
997
1006
|
* // { userId: '123', name: 'john' },
|
|
998
1007
|
* // { userId: '456', name: 'jane' }
|
|
999
1008
|
* // ]
|
|
1009
|
+
*
|
|
1010
|
+
* // No chaining — `a → b` does not become `a → c` even if the map has `b → c`.
|
|
1011
|
+
* transformData({ a: 1 }, { a: 'b', b: 'c' });
|
|
1012
|
+
* // result = { b: 1 }
|
|
1000
1013
|
* ```
|
|
1001
1014
|
*/
|
|
1002
1015
|
function transformData(data, fieldMapping) {
|
|
1016
|
+
// Pass null/undefined through unchanged — callers (e.g. AttachmentService.getById)
|
|
1017
|
+
// may invoke this on optional fields that an OData `select` excluded.
|
|
1018
|
+
if (data == null) {
|
|
1019
|
+
return data;
|
|
1020
|
+
}
|
|
1003
1021
|
// Handle array of objects
|
|
1004
1022
|
if (Array.isArray(data)) {
|
|
1005
1023
|
return data.map(item => transformData(item, fieldMapping));
|
|
1006
1024
|
}
|
|
1007
|
-
//
|
|
1008
|
-
|
|
1009
|
-
|
|
1010
|
-
|
|
1011
|
-
|
|
1012
|
-
|
|
1013
|
-
result[targetField] = value;
|
|
1014
|
-
}
|
|
1025
|
+
// Walk the ORIGINAL data's keys, look up each in the mapping. One rename
|
|
1026
|
+
// per data key — no mutation of an in-progress result, so chains can't form.
|
|
1027
|
+
const result = {};
|
|
1028
|
+
for (const [key, value] of Object.entries(data)) {
|
|
1029
|
+
const renamedKey = fieldMapping[key] ?? key;
|
|
1030
|
+
result[renamedKey] = value;
|
|
1015
1031
|
}
|
|
1016
1032
|
return result;
|
|
1017
1033
|
}
|
package/dist/feedback/index.cjs
CHANGED
|
@@ -966,7 +966,16 @@ const BUCKET_TOKEN_PARAMS = {
|
|
|
966
966
|
* Returns the original value if parsing fails.
|
|
967
967
|
*/
|
|
968
968
|
/**
|
|
969
|
-
* Transforms data by
|
|
969
|
+
* Transforms data by renaming each key in `data` exactly once, using the
|
|
970
|
+
* mapping (`sourceField → targetField`). Keys not present in the mapping
|
|
971
|
+
* pass through unchanged. The original (pre-rename) key is dropped — the
|
|
972
|
+
* result contains only the renamed key.
|
|
973
|
+
*
|
|
974
|
+
* Each rename is independent. If the mapping happens to contain chained
|
|
975
|
+
* entries (`a → b` and `b → c`), they do NOT compose: a field named `a`
|
|
976
|
+
* in `data` becomes `b` (not `c`), because the renames are applied based
|
|
977
|
+
* on the original data's keys, not the running result.
|
|
978
|
+
*
|
|
970
979
|
* @param data The source data to transform
|
|
971
980
|
* @param fieldMapping Object mapping source field names to target field names
|
|
972
981
|
* @returns Transformed data with mapped field names
|
|
@@ -989,21 +998,28 @@ const BUCKET_TOKEN_PARAMS = {
|
|
|
989
998
|
* // { userId: '123', name: 'john' },
|
|
990
999
|
* // { userId: '456', name: 'jane' }
|
|
991
1000
|
* // ]
|
|
1001
|
+
*
|
|
1002
|
+
* // No chaining — `a → b` does not become `a → c` even if the map has `b → c`.
|
|
1003
|
+
* transformData({ a: 1 }, { a: 'b', b: 'c' });
|
|
1004
|
+
* // result = { b: 1 }
|
|
992
1005
|
* ```
|
|
993
1006
|
*/
|
|
994
1007
|
function transformData(data, fieldMapping) {
|
|
1008
|
+
// Pass null/undefined through unchanged — callers (e.g. AttachmentService.getById)
|
|
1009
|
+
// may invoke this on optional fields that an OData `select` excluded.
|
|
1010
|
+
if (data == null) {
|
|
1011
|
+
return data;
|
|
1012
|
+
}
|
|
995
1013
|
// Handle array of objects
|
|
996
1014
|
if (Array.isArray(data)) {
|
|
997
1015
|
return data.map(item => transformData(item, fieldMapping));
|
|
998
1016
|
}
|
|
999
|
-
//
|
|
1000
|
-
|
|
1001
|
-
|
|
1002
|
-
|
|
1003
|
-
|
|
1004
|
-
|
|
1005
|
-
result[targetField] = value;
|
|
1006
|
-
}
|
|
1017
|
+
// Walk the ORIGINAL data's keys, look up each in the mapping. One rename
|
|
1018
|
+
// per data key — no mutation of an in-progress result, so chains can't form.
|
|
1019
|
+
const result = {};
|
|
1020
|
+
for (const [key, value] of Object.entries(data)) {
|
|
1021
|
+
const renamedKey = fieldMapping[key] ?? key;
|
|
1022
|
+
result[renamedKey] = value;
|
|
1007
1023
|
}
|
|
1008
1024
|
return result;
|
|
1009
1025
|
}
|
package/dist/feedback/index.mjs
CHANGED
|
@@ -964,7 +964,16 @@ const BUCKET_TOKEN_PARAMS = {
|
|
|
964
964
|
* Returns the original value if parsing fails.
|
|
965
965
|
*/
|
|
966
966
|
/**
|
|
967
|
-
* Transforms data by
|
|
967
|
+
* Transforms data by renaming each key in `data` exactly once, using the
|
|
968
|
+
* mapping (`sourceField → targetField`). Keys not present in the mapping
|
|
969
|
+
* pass through unchanged. The original (pre-rename) key is dropped — the
|
|
970
|
+
* result contains only the renamed key.
|
|
971
|
+
*
|
|
972
|
+
* Each rename is independent. If the mapping happens to contain chained
|
|
973
|
+
* entries (`a → b` and `b → c`), they do NOT compose: a field named `a`
|
|
974
|
+
* in `data` becomes `b` (not `c`), because the renames are applied based
|
|
975
|
+
* on the original data's keys, not the running result.
|
|
976
|
+
*
|
|
968
977
|
* @param data The source data to transform
|
|
969
978
|
* @param fieldMapping Object mapping source field names to target field names
|
|
970
979
|
* @returns Transformed data with mapped field names
|
|
@@ -987,21 +996,28 @@ const BUCKET_TOKEN_PARAMS = {
|
|
|
987
996
|
* // { userId: '123', name: 'john' },
|
|
988
997
|
* // { userId: '456', name: 'jane' }
|
|
989
998
|
* // ]
|
|
999
|
+
*
|
|
1000
|
+
* // No chaining — `a → b` does not become `a → c` even if the map has `b → c`.
|
|
1001
|
+
* transformData({ a: 1 }, { a: 'b', b: 'c' });
|
|
1002
|
+
* // result = { b: 1 }
|
|
990
1003
|
* ```
|
|
991
1004
|
*/
|
|
992
1005
|
function transformData(data, fieldMapping) {
|
|
1006
|
+
// Pass null/undefined through unchanged — callers (e.g. AttachmentService.getById)
|
|
1007
|
+
// may invoke this on optional fields that an OData `select` excluded.
|
|
1008
|
+
if (data == null) {
|
|
1009
|
+
return data;
|
|
1010
|
+
}
|
|
993
1011
|
// Handle array of objects
|
|
994
1012
|
if (Array.isArray(data)) {
|
|
995
1013
|
return data.map(item => transformData(item, fieldMapping));
|
|
996
1014
|
}
|
|
997
|
-
//
|
|
998
|
-
|
|
999
|
-
|
|
1000
|
-
|
|
1001
|
-
|
|
1002
|
-
|
|
1003
|
-
result[targetField] = value;
|
|
1004
|
-
}
|
|
1015
|
+
// Walk the ORIGINAL data's keys, look up each in the mapping. One rename
|
|
1016
|
+
// per data key — no mutation of an in-progress result, so chains can't form.
|
|
1017
|
+
const result = {};
|
|
1018
|
+
for (const [key, value] of Object.entries(data)) {
|
|
1019
|
+
const renamedKey = fieldMapping[key] ?? key;
|
|
1020
|
+
result[renamedKey] = value;
|
|
1005
1021
|
}
|
|
1006
1022
|
return result;
|
|
1007
1023
|
}
|