@uipath/solution-tool 1.205.0-preview.277 → 1.206.0-preview.279
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/{archive-extract-x35t9ktj.js → archive-extract-136rn3ja.js} +13 -15
- package/dist/{cleanup-command-service-dwbrt6d9.js → cleanup-command-service-ejakyhea.js} +34 -31
- package/dist/deploy-delete-service-r7abfh28.js +23 -0
- package/dist/deploy-run-service-rnthz10q.js +23 -0
- package/dist/{deploy-status-service-xw2nzh7m.js → deploy-status-service-6my5vm61.js} +72 -62
- package/dist/deploy.js +35 -37
- package/dist/deployment-search-gfm907tx.js +54 -0
- package/dist/{embedded-file-reader-z4becc02.js → embedded-file-reader-0228j82a.js} +1 -4
- package/dist/feed-resolver-14crsx5y.js +27 -0
- package/dist/feed-scope-failure-67cyybn0.js +20 -0
- package/dist/feed-session-g94q2bjc.js +23 -0
- package/dist/first-party-service-n3vva2m4.js +8 -0
- package/dist/governance-options-t20vsznh.js +19 -0
- package/dist/index-aspmac9f.js +24 -0
- package/dist/index-ddk6v1ej.js +60 -0
- package/dist/{index-sby22td6.js → index-nzr4mx5p.js} +2 -22
- package/dist/index-qq4kre7a.js +93 -0
- package/dist/index-t262f2xv.js +16 -0
- package/dist/index.js +33 -34
- package/dist/init.js +18 -21
- package/dist/{jmespath-231m3hyn.js → jmespath-ab6tdc42.js} +1 -1
- package/dist/{js-yaml-88tdqrtd.js → js-yaml-a2bk27p6.js} +1 -3
- package/dist/{list-zckdhv0c.js → list-jntan9tx.js} +23 -23
- package/dist/models/pack-command-types.d.ts +3 -1
- package/dist/node-kwzcw5ex.js +25 -0
- package/dist/pack-command-service-pwaeha7y.js +29 -0
- package/dist/{pack-project-erd95bt1.js → pack-project-ztt1hfrs.js} +33 -40
- package/dist/pack.js +26 -30
- package/dist/package-id-4tsg5jsb.js +11 -0
- package/dist/{packager-tool-d3cmmbw1.js → packager-tool-1bz9h5ca.js} +11 -11
- package/dist/{packager-tool-gs3f3tf7.js → packager-tool-1ctvbx0h.js} +1 -1
- package/dist/{packager-tool-r1jvvm8y.js → packager-tool-55ztfccd.js} +176 -196
- package/dist/{packager-tool-wrg41m7t.js → packager-tool-95y24705.js} +37 -39
- package/dist/{packager-tool-bkjqza3a.js → packager-tool-9j8e5q1z.js} +184 -33
- package/dist/{packager-tool-tx834spe.js → packager-tool-9vrwpgt3.js} +757 -309
- package/dist/packager-tool-a6va4gc5.js +1178 -0
- package/dist/{packager-tool-pbmqk39a.js → packager-tool-a7s0gbxs.js} +33 -28
- package/dist/{packager-tool-47wzvqw0.js → packager-tool-aws5w512.js} +6 -6
- package/dist/{packager-tool-97rcgwvv.js → packager-tool-bs1jn1yn.js} +331 -55
- package/dist/packager-tool-c64hqa8n.js +106 -0
- package/dist/{packager-tool-5ddtwzva.js → packager-tool-ca5ngmqv.js} +12 -12
- package/dist/{packager-tool-6kz1pv9f.js → packager-tool-d1texmvn.js} +828 -338
- package/dist/{packager-tool-1de529jm.js → packager-tool-epsr41wx.js} +12 -3
- package/dist/packager-tool-f84z7nds.js +130 -0
- package/dist/{packager-tool-8ptbmmmp.js → packager-tool-fp46ebde.js} +147 -76
- package/dist/packager-tool-fqs6hdcy.js +290 -0
- package/dist/{packager-tool-3bwnkjdq.js → packager-tool-fx4ws49n.js} +12 -12
- package/dist/{packager-tool-6ybywxxn.js → packager-tool-m07vyk89.js} +371 -221
- package/dist/{packager-tool-hsya909c.js → packager-tool-nrhqgr4z.js} +273 -255
- package/dist/{packager-tool-61pwb567.js → packager-tool-ppj5f4y7.js} +6 -7
- package/dist/{packager-tool-qqbt4b44.js → packager-tool-pyt9fvty.js} +51 -48
- package/dist/packager-tool-q5d9df2q.js +74 -0
- package/dist/{packager-tool-ph7fg1aa.js → packager-tool-q8ryk6q9.js} +122 -89
- package/dist/{packager-tool-t8gh825q.js → packager-tool-qf8753ee.js} +53 -41
- package/dist/{packager-tool-60af1hw2.js → packager-tool-qzcd5c9s.js} +3 -3
- package/dist/packager-tool-resolver-td3bhccd.js +20 -0
- package/dist/{packager-tool-dfrk01gn.js → packager-tool-rj2d1g0w.js} +154 -154
- package/dist/{packager-tool-a4bs7wtm.js → packager-tool-snm6s7b5.js} +15 -15
- package/dist/{packager-tool-43ahv5mn.js → packager-tool-t39pjz7n.js} +35 -18
- package/dist/{packager-tool-f2hsb9ta.js → packager-tool-t3a48ys5.js} +305 -657
- package/dist/{packager-tool-cjjk2ek2.js → packager-tool-t3ahzjh1.js} +356 -298
- package/dist/{packager-tool-v1f5e8t9.js → packager-tool-vgrswa8p.js} +53 -8
- package/dist/packager-tool-vrtabg73.js +2307 -0
- package/dist/{packager-tool-gmwva4yv.js → packager-tool-vx2c68sb.js} +2 -2
- package/dist/{packager-tool-4pkzxkty.js → packager-tool-vx39dhvn.js} +65 -35
- package/dist/{packager-tool-zn76tbxc.js → packager-tool-w34wyhwf.js} +13 -15
- package/dist/packager-tool-w8bcwfd3.js +280 -0
- package/dist/{packager-tool-3gwrcgrc.js → packager-tool-wm0h0wa1.js} +18 -18
- package/dist/{packager-tool-b2nhscfk.js → packager-tool-wm8nj6e9.js} +18 -18
- package/dist/{packager-tool-amhyxzz6.js → packager-tool-x33sdw6n.js} +16 -16
- package/dist/{packager-tool-wy4fx250.js → packager-tool-yetmzme9.js} +89 -30
- package/dist/{packager-tool-6tyyvhh0.js → packager-tool-z5r49ky9.js} +75 -9
- package/dist/packager-tool.js +6 -7
- package/dist/prepare-solution-resources-pwnyvtza.js +26 -0
- package/dist/{project-command-utils-t6pmpvq3.js → project-command-utils-zcmbecfy.js} +23 -26
- package/dist/project-contributions-kh9yftvg.js +27 -0
- package/dist/publish.js +17 -17
- package/dist/resource-mutations-mfn5k1hb.js +27 -0
- package/dist/{resource-version-lookup-0e3e2j58.js → resource-version-lookup-6ejh1hwd.js} +20 -23
- package/dist/resource.js +13 -16
- package/dist/{restore-command-service-2g02d7s1.js → restore-command-service-n880dxre.js} +37 -34
- package/dist/{run-service-6necpy9s.js → run-service-4vhn6mtb.js} +144 -66
- package/dist/services/deploy-activate-service.d.ts +2 -1
- package/dist/services/deployment-search-client.d.ts +2 -1
- package/dist/services/deployment-search.d.ts +39 -0
- package/dist/services/feed-resolver.d.ts +13 -1
- package/dist/services/feed-selection.d.ts +8 -5
- package/dist/services/feed-session.d.ts +34 -0
- package/dist/services/install-run.d.ts +92 -0
- package/dist/services/prepare-solution-resources.d.ts +11 -2
- package/dist/services/project-contributions.d.ts +2 -0
- package/dist/services/project-identity-telemetry.d.ts +3 -0
- package/dist/services/publish-service.d.ts +20 -3
- package/dist/services/solution-identity.d.ts +18 -0
- package/dist/ship-telemetry-bkf3800w.js +16 -0
- package/dist/solution-auth-jxcgd2m0.js +10 -0
- package/dist/solution-identity-92h2fbpa.js +19 -0
- package/dist/templates/AGENTS.md +27 -29
- package/dist/tool.js +32 -33
- package/package.json +2 -2
- package/dist/deploy-delete-service-7py597ng.js +0 -25
- package/dist/deploy-run-service-446bssn0.js +0 -25
- package/dist/deployment-search-qyd6dv0m.js +0 -55
- package/dist/feed-resolver-va10c73n.js +0 -28
- package/dist/feed-scope-failure-3yxfg1x7.js +0 -19
- package/dist/feed-session-7xqphdrg.js +0 -17
- package/dist/first-party-service-sd8yaf73.js +0 -27
- package/dist/governance-options-8snbrbt1.js +0 -32
- package/dist/index-dqa169gp.js +0 -25
- package/dist/index-fcwmbjap.js +0 -667
- package/dist/index-prm27bvm.js +0 -138
- package/dist/node-9hdy9st1.js +0 -86
- package/dist/pack-command-service-tr3z33gz.js +0 -35
- package/dist/package-id-kdkapmn2.js +0 -13
- package/dist/packager-tool-53w8skv5.js +0 -262
- package/dist/packager-tool-5edvzz80.js +0 -543
- package/dist/packager-tool-6d3fx89p.js +0 -171
- package/dist/packager-tool-d8ng7mex.js +0 -68
- package/dist/packager-tool-gdtpsdn7.js +0 -342
- package/dist/packager-tool-mq5pc4zr.js +0 -418
- package/dist/packager-tool-qw47eyw7.js +0 -43
- package/dist/packager-tool-resolver-994z3jkj.js +0 -23
- package/dist/packager-tool-rg3xgn9a.js +0 -182
- package/dist/packager-tool-sxjehksx.js +0 -5367
- package/dist/packager-tool-yrdyppjd.js +0 -188
- package/dist/prepare-solution-resources-m1djfj62.js +0 -29
- package/dist/project-contributions-79ndycrx.js +0 -32
- package/dist/resource-mutations-c3krjqze.js +0 -36
- package/dist/ship-telemetry-myes7ak5.js +0 -21
- package/dist/solution-auth-aead70sw.js +0 -11
- /package/dist/{packager-tool-act5r386.js → packager-tool-2pxe2r4j.js} +0 -0
- /package/dist/{packager-tool-kkfb5kgn.js → packager-tool-vrqbbh01.js} +0 -0
|
@@ -18,7 +18,7 @@ var __toESM = (mod, isNodeMode, target) => {
|
|
|
18
18
|
return cached;
|
|
19
19
|
}
|
|
20
20
|
target = mod != null ? __create(__getProtoOf(mod)) : {};
|
|
21
|
-
const to = isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target;
|
|
21
|
+
const to = isNodeMode || !mod || !mod.__esModule || !__hasOwnProp.call(mod, "default") ? __defProp(target, "default", { value: mod, enumerable: true }) : target;
|
|
22
22
|
if (mod && typeof mod === "object" || typeof mod === "function") {
|
|
23
23
|
for (let key of __getOwnPropNames(mod))
|
|
24
24
|
if (!__hasOwnProp.call(to, key))
|
|
@@ -32,8 +32,17 @@ var __toESM = (mod, isNodeMode, target) => {
|
|
|
32
32
|
return to;
|
|
33
33
|
};
|
|
34
34
|
var __commonJS = (cb, mod) => () => (mod || cb((mod = { exports: {} }).exports, mod), mod.exports);
|
|
35
|
+
var __exportCjs = (target, getters, setters) => {
|
|
36
|
+
for (var name in getters)
|
|
37
|
+
__defProp(target, name, {
|
|
38
|
+
get: getters[name],
|
|
39
|
+
set: setters[name],
|
|
40
|
+
enumerable: true,
|
|
41
|
+
configurable: true
|
|
42
|
+
});
|
|
43
|
+
};
|
|
35
44
|
var __require = /* @__PURE__ */ createRequire(import.meta.url);
|
|
36
45
|
|
|
37
|
-
export { __toESM, __commonJS, __require };
|
|
46
|
+
export { __toESM, __commonJS, __exportCjs, __require };
|
|
38
47
|
|
|
39
|
-
//# debugId=
|
|
48
|
+
//# debugId=6692E9B4C735B07364756E2164756E21
|
|
@@ -0,0 +1,130 @@
|
|
|
1
|
+
import {
|
|
2
|
+
getFileSystem
|
|
3
|
+
} from "./packager-tool-vgrswa8p.js";
|
|
4
|
+
import {
|
|
5
|
+
ProjectDimensions,
|
|
6
|
+
solutionIdentityProperties,
|
|
7
|
+
projectKey,
|
|
8
|
+
isProjectTelemetryDisabled
|
|
9
|
+
} from "./packager-tool-m07vyk89.js";
|
|
10
|
+
import {
|
|
11
|
+
logger
|
|
12
|
+
} from "./packager-tool-9vrwpgt3.js";
|
|
13
|
+
|
|
14
|
+
// src/services/solution-identity.ts
|
|
15
|
+
var MAX_METADATA_BYTES = 1024 * 1024;
|
|
16
|
+
function logSkipped(what, error) {
|
|
17
|
+
logger.debug(`[solution-identity] ${what} skipped: ${error instanceof Error ? error.message : String(error)}`);
|
|
18
|
+
}
|
|
19
|
+
var unavailable = (status) => ({
|
|
20
|
+
status
|
|
21
|
+
});
|
|
22
|
+
function solutionIdentity(id) {
|
|
23
|
+
if (id === undefined || id === null || id === "")
|
|
24
|
+
return unavailable("missing");
|
|
25
|
+
return typeof id === "string" && id.trim() ? { id, status: "resolved" } : unavailable("invalid");
|
|
26
|
+
}
|
|
27
|
+
function readMetadata(bytes, packed = false) {
|
|
28
|
+
if (bytes.length > MAX_METADATA_BYTES)
|
|
29
|
+
return unavailable("invalid");
|
|
30
|
+
const parsed = JSON.parse(new TextDecoder().decode(bytes));
|
|
31
|
+
if (!parsed || typeof parsed !== "object" || Array.isArray(parsed))
|
|
32
|
+
return unavailable("invalid");
|
|
33
|
+
const record = parsed;
|
|
34
|
+
if (!packed)
|
|
35
|
+
return solutionIdentity(record.SolutionId);
|
|
36
|
+
const spec = record.spec;
|
|
37
|
+
return solutionIdentity(spec && typeof spec === "object" && !Array.isArray(spec) ? spec.projectKey : undefined);
|
|
38
|
+
}
|
|
39
|
+
async function readPackedArchive(bytes) {
|
|
40
|
+
const { unzipSync } = await import("./index-t262f2xv.js");
|
|
41
|
+
let oversized = false;
|
|
42
|
+
const entries = unzipSync(bytes, {
|
|
43
|
+
filter: (entry) => {
|
|
44
|
+
const selected = entry.name === "solutionMetadata.json";
|
|
45
|
+
if (selected && entry.originalSize > MAX_METADATA_BYTES)
|
|
46
|
+
oversized = true;
|
|
47
|
+
return selected && entry.originalSize <= MAX_METADATA_BYTES;
|
|
48
|
+
}
|
|
49
|
+
});
|
|
50
|
+
if (oversized)
|
|
51
|
+
return unavailable("invalid");
|
|
52
|
+
const metadata = entries["solutionMetadata.json"];
|
|
53
|
+
return metadata ? readMetadata(metadata, true) : unavailable("missing");
|
|
54
|
+
}
|
|
55
|
+
async function capturePackedSolutionIdentity2(capture, bytes) {
|
|
56
|
+
if (!capture || isProjectTelemetryDisabled())
|
|
57
|
+
return;
|
|
58
|
+
try {
|
|
59
|
+
capture.setProperties?.(solutionIdentityProperties(await readPackedArchive(bytes)));
|
|
60
|
+
} catch (error) {
|
|
61
|
+
logSkipped("packed solution identity", error);
|
|
62
|
+
}
|
|
63
|
+
}
|
|
64
|
+
async function readSolutionIdentity2(target) {
|
|
65
|
+
try {
|
|
66
|
+
const fs = getFileSystem();
|
|
67
|
+
let path = fs.path.resolve(target);
|
|
68
|
+
let stat = await fs.stat(path);
|
|
69
|
+
if (!stat)
|
|
70
|
+
return unavailable("missing");
|
|
71
|
+
if (stat.isDirectory()) {
|
|
72
|
+
const manifests = (await fs.readdir(path)).filter((name) => name.endsWith(".uipx"));
|
|
73
|
+
if (manifests.length !== 1)
|
|
74
|
+
return unavailable(manifests.length ? "invalid" : "missing");
|
|
75
|
+
path = fs.path.join(path, manifests[0]);
|
|
76
|
+
stat = await fs.stat(path);
|
|
77
|
+
} else if (!path.endsWith(".uipx"))
|
|
78
|
+
return unavailable("unsupported");
|
|
79
|
+
if (!stat?.isFile() || stat.size > MAX_METADATA_BYTES)
|
|
80
|
+
return unavailable("invalid");
|
|
81
|
+
const bytes = await fs.readFile(path);
|
|
82
|
+
if (!bytes)
|
|
83
|
+
return unavailable("missing");
|
|
84
|
+
return readMetadata(bytes);
|
|
85
|
+
} catch (error) {
|
|
86
|
+
logSkipped("solution identity read", error);
|
|
87
|
+
return unavailable("invalid");
|
|
88
|
+
}
|
|
89
|
+
}
|
|
90
|
+
async function captureExtractedSolution2(capture, directory) {
|
|
91
|
+
if (!capture || isProjectTelemetryDisabled())
|
|
92
|
+
return;
|
|
93
|
+
try {
|
|
94
|
+
await capture.setTarget?.(directory);
|
|
95
|
+
} catch (error) {
|
|
96
|
+
logSkipped("extracted solution identity", error);
|
|
97
|
+
}
|
|
98
|
+
}
|
|
99
|
+
function captureSolutionIdentity2(capture, id, previousId) {
|
|
100
|
+
if (!capture || isProjectTelemetryDisabled())
|
|
101
|
+
return;
|
|
102
|
+
try {
|
|
103
|
+
const properties = solutionIdentityProperties(solutionIdentity(id));
|
|
104
|
+
const previousKey = previousId ? projectKey(previousId) : undefined;
|
|
105
|
+
if (properties[ProjectDimensions.SolutionKey] && previousKey && previousKey !== properties[ProjectDimensions.SolutionKey])
|
|
106
|
+
properties[ProjectDimensions.PreviousSolutionKey] = previousKey;
|
|
107
|
+
capture.setProperties?.(properties);
|
|
108
|
+
} catch (error) {
|
|
109
|
+
logSkipped("upload solution identity", error);
|
|
110
|
+
}
|
|
111
|
+
}
|
|
112
|
+
function captureSolutionMember2(capture, memberId) {
|
|
113
|
+
if (!capture || isProjectTelemetryDisabled())
|
|
114
|
+
return;
|
|
115
|
+
try {
|
|
116
|
+
const properties = capture.properties();
|
|
117
|
+
if (!properties[ProjectDimensions.SolutionKey])
|
|
118
|
+
return;
|
|
119
|
+
capture.setProperties?.({
|
|
120
|
+
...properties,
|
|
121
|
+
[ProjectDimensions.SolutionProjectKey]: projectKey(memberId)
|
|
122
|
+
});
|
|
123
|
+
} catch (error) {
|
|
124
|
+
logSkipped("solution member identity", error);
|
|
125
|
+
}
|
|
126
|
+
}
|
|
127
|
+
|
|
128
|
+
export { capturePackedSolutionIdentity2, readSolutionIdentity2, captureExtractedSolution2, captureSolutionIdentity2, captureSolutionMember2 };
|
|
129
|
+
|
|
130
|
+
//# debugId=7B449D46BEB0F9F364756E2164756E21
|
|
@@ -1,12 +1,17 @@
|
|
|
1
1
|
import {
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
} from "./packager-tool-43ahv5mn.js";
|
|
5
|
-
import {
|
|
6
|
-
addSdkUserAgentHeader,
|
|
2
|
+
catchError,
|
|
3
|
+
extractErrorMessage,
|
|
7
4
|
getSdkUserAgentToken,
|
|
5
|
+
addSdkUserAgentHeader,
|
|
8
6
|
installSdkUserAgentHeader
|
|
9
|
-
} from "./packager-tool-
|
|
7
|
+
} from "./packager-tool-m07vyk89.js";
|
|
8
|
+
import {
|
|
9
|
+
logger
|
|
10
|
+
} from "./packager-tool-9vrwpgt3.js";
|
|
11
|
+
import {
|
|
12
|
+
resolveSessionIdentity,
|
|
13
|
+
getAuthContext
|
|
14
|
+
} from "./packager-tool-t39pjz7n.js";
|
|
10
15
|
|
|
11
16
|
// ../orchestrator-sdk/generated/src/runtime.ts
|
|
12
17
|
var BASE_PATH = "https://alpha.uipath.com/Ada/byoa/orchestrator_".replace(/\/+$/, "");
|
|
@@ -1665,6 +1670,75 @@ class FoldersApi extends BaseAPI {
|
|
|
1665
1670
|
}
|
|
1666
1671
|
}
|
|
1667
1672
|
|
|
1673
|
+
// ../orchestrator-sdk/generated/src/apis/PersonalWorkspacesApi.ts
|
|
1674
|
+
class PersonalWorkspacesApi extends BaseAPI {
|
|
1675
|
+
async personalWorkspacesGetRaw(requestParameters, initOverrides) {
|
|
1676
|
+
const queryParameters = {};
|
|
1677
|
+
if (requestParameters["$select"] != null) {
|
|
1678
|
+
queryParameters["$select"] = requestParameters["$select"];
|
|
1679
|
+
}
|
|
1680
|
+
if (requestParameters["$expand"] != null) {
|
|
1681
|
+
queryParameters["$expand"] = requestParameters["$expand"];
|
|
1682
|
+
}
|
|
1683
|
+
if (requestParameters["$filter"] != null) {
|
|
1684
|
+
queryParameters["$filter"] = requestParameters["$filter"];
|
|
1685
|
+
}
|
|
1686
|
+
if (requestParameters["$orderby"] != null) {
|
|
1687
|
+
queryParameters["$orderby"] = requestParameters["$orderby"];
|
|
1688
|
+
}
|
|
1689
|
+
if (requestParameters["$top"] != null) {
|
|
1690
|
+
queryParameters["$top"] = requestParameters["$top"];
|
|
1691
|
+
}
|
|
1692
|
+
if (requestParameters["$skip"] != null) {
|
|
1693
|
+
queryParameters["$skip"] = requestParameters["$skip"];
|
|
1694
|
+
}
|
|
1695
|
+
if (requestParameters["$count"] != null) {
|
|
1696
|
+
queryParameters["$count"] = requestParameters["$count"];
|
|
1697
|
+
}
|
|
1698
|
+
const headerParameters = {};
|
|
1699
|
+
if (this.configuration && this.configuration.accessToken) {
|
|
1700
|
+
headerParameters["Authorization"] = await this.configuration.accessToken("OAuth2", []);
|
|
1701
|
+
}
|
|
1702
|
+
let urlPath = `/odata/PersonalWorkspaces`;
|
|
1703
|
+
const response = await this.request({
|
|
1704
|
+
path: urlPath,
|
|
1705
|
+
method: "GET",
|
|
1706
|
+
headers: headerParameters,
|
|
1707
|
+
query: queryParameters
|
|
1708
|
+
}, initOverrides);
|
|
1709
|
+
return new JSONApiResponse(response, (jsonValue) => ODataValueOfIEnumerableOfPersonalWorkspaceDtoFromJSON(jsonValue));
|
|
1710
|
+
}
|
|
1711
|
+
async personalWorkspacesGet(requestParameters = {}, initOverrides) {
|
|
1712
|
+
const response = await this.personalWorkspacesGetRaw(requestParameters, initOverrides);
|
|
1713
|
+
return await response.value();
|
|
1714
|
+
}
|
|
1715
|
+
async personalWorkspacesGetPersonalWorkspaceRaw(requestParameters, initOverrides) {
|
|
1716
|
+
const queryParameters = {};
|
|
1717
|
+
if (requestParameters["$select"] != null) {
|
|
1718
|
+
queryParameters["$select"] = requestParameters["$select"];
|
|
1719
|
+
}
|
|
1720
|
+
if (requestParameters["$expand"] != null) {
|
|
1721
|
+
queryParameters["$expand"] = requestParameters["$expand"];
|
|
1722
|
+
}
|
|
1723
|
+
const headerParameters = {};
|
|
1724
|
+
if (this.configuration && this.configuration.accessToken) {
|
|
1725
|
+
headerParameters["Authorization"] = await this.configuration.accessToken("OAuth2", []);
|
|
1726
|
+
}
|
|
1727
|
+
let urlPath = `/odata/PersonalWorkspaces/UiPath.Server.Configuration.OData.GetPersonalWorkspace`;
|
|
1728
|
+
const response = await this.request({
|
|
1729
|
+
path: urlPath,
|
|
1730
|
+
method: "GET",
|
|
1731
|
+
headers: headerParameters,
|
|
1732
|
+
query: queryParameters
|
|
1733
|
+
}, initOverrides);
|
|
1734
|
+
return new JSONApiResponse(response, (jsonValue) => PersonalWorkspaceDtoFromJSON(jsonValue));
|
|
1735
|
+
}
|
|
1736
|
+
async personalWorkspacesGetPersonalWorkspace(requestParameters = {}, initOverrides) {
|
|
1737
|
+
const response = await this.personalWorkspacesGetPersonalWorkspaceRaw(requestParameters, initOverrides);
|
|
1738
|
+
return await response.value();
|
|
1739
|
+
}
|
|
1740
|
+
}
|
|
1741
|
+
|
|
1668
1742
|
// ../common/src/session-kind.ts
|
|
1669
1743
|
var SESSION_KIND_KEY = Symbol.for("@uipath/common/SessionKind");
|
|
1670
1744
|
function attachSessionKind(carrier, kind) {
|
|
@@ -1699,7 +1773,7 @@ var package_default = {
|
|
|
1699
1773
|
name: "@uipath/orchestrator-sdk",
|
|
1700
1774
|
author: "UiPath",
|
|
1701
1775
|
license: "SEE LICENSE IN LICENSE.txt",
|
|
1702
|
-
version: "1.
|
|
1776
|
+
version: "1.206.0",
|
|
1703
1777
|
repository: {
|
|
1704
1778
|
type: "git",
|
|
1705
1779
|
url: "https://github.com/UiPath/cli.git",
|
|
@@ -1726,6 +1800,10 @@ var package_default = {
|
|
|
1726
1800
|
types: "./dist/src/index.d.ts",
|
|
1727
1801
|
default: "./dist/index.js"
|
|
1728
1802
|
}
|
|
1803
|
+
},
|
|
1804
|
+
"./folder-feed": {
|
|
1805
|
+
types: "./dist/src/folder-feed.d.ts",
|
|
1806
|
+
default: "./dist/folder-feed.js"
|
|
1729
1807
|
}
|
|
1730
1808
|
},
|
|
1731
1809
|
files: [
|
|
@@ -1733,11 +1811,12 @@ var package_default = {
|
|
|
1733
1811
|
],
|
|
1734
1812
|
private: true,
|
|
1735
1813
|
scripts: {
|
|
1736
|
-
build: "bun build ./src/index.ts --outdir dist --format esm --target node --sourcemap=linked && bun build ./src/index.browser.ts --outdir dist --format esm --target browser --external @uipath/auth --external @uipath/common --sourcemap=linked && tsc -p tsconfig.build.json --noCheck",
|
|
1814
|
+
build: "bun build ./src/index.ts ./src/folder-feed.ts --outdir dist --format esm --target node --sourcemap=linked && bun build ./src/index.browser.ts --outdir dist --format esm --target browser --external @uipath/auth --external @uipath/common --sourcemap=linked && tsc -p tsconfig.build.json --noCheck",
|
|
1737
1815
|
generate: "bun run src/scripts/generate-sdk.ts",
|
|
1738
1816
|
lint: "biome check .",
|
|
1739
1817
|
test: "vitest run",
|
|
1740
|
-
"test:coverage": "vitest run --coverage"
|
|
1818
|
+
"test:coverage": "vitest run --coverage",
|
|
1819
|
+
typecheck: "tsc --noEmit"
|
|
1741
1820
|
},
|
|
1742
1821
|
devDependencies: {
|
|
1743
1822
|
"@uipath/auth": "workspace:*",
|
|
@@ -1802,7 +1881,7 @@ async function resolveFolder(input, options) {
|
|
|
1802
1881
|
}
|
|
1803
1882
|
return resolveByKey(foldersApi, input.folderKey);
|
|
1804
1883
|
}
|
|
1805
|
-
return resolveByPath(foldersApi, input.folderPath);
|
|
1884
|
+
return resolveByPath(config, foldersApi, input.folderPath);
|
|
1806
1885
|
}
|
|
1807
1886
|
async function resolveByKey(foldersApi, folderKey) {
|
|
1808
1887
|
const folder = await foldersApi.foldersGetByKeyByIdentifier({
|
|
@@ -1819,12 +1898,12 @@ async function resolveByKey(foldersApi, folderKey) {
|
|
|
1819
1898
|
feedType: folder.feedType
|
|
1820
1899
|
};
|
|
1821
1900
|
}
|
|
1822
|
-
async function resolveByPath(foldersApi, folderPath) {
|
|
1901
|
+
async function resolveByPath(config, foldersApi, folderPath) {
|
|
1823
1902
|
const response = await foldersApi.foldersGet({
|
|
1824
1903
|
$filter: `FullyQualifiedName eq '${folderPath.replace(/'/g, "''")}'`,
|
|
1825
1904
|
$top: 1
|
|
1826
1905
|
});
|
|
1827
|
-
const folder = response.value?.[0];
|
|
1906
|
+
const folder = response.value?.[0] ?? await resolveInPersonalWorkspace(config, foldersApi, folderPath);
|
|
1828
1907
|
if (!folder?.id || !folder.key || !folder.fullyQualifiedName || !folder.displayName) {
|
|
1829
1908
|
throw new Error(`Folder not found: '${folderPath}'.`);
|
|
1830
1909
|
}
|
|
@@ -1836,73 +1915,65 @@ async function resolveByPath(foldersApi, folderPath) {
|
|
|
1836
1915
|
feedType: folder.feedType
|
|
1837
1916
|
};
|
|
1838
1917
|
}
|
|
1839
|
-
|
|
1840
|
-
|
|
1841
|
-
|
|
1842
|
-
|
|
1843
|
-
|
|
1844
|
-
|
|
1845
|
-
}
|
|
1846
|
-
if (requestParameters["$expand"] != null) {
|
|
1847
|
-
queryParameters["$expand"] = requestParameters["$expand"];
|
|
1848
|
-
}
|
|
1849
|
-
if (requestParameters["$filter"] != null) {
|
|
1850
|
-
queryParameters["$filter"] = requestParameters["$filter"];
|
|
1851
|
-
}
|
|
1852
|
-
if (requestParameters["$orderby"] != null) {
|
|
1853
|
-
queryParameters["$orderby"] = requestParameters["$orderby"];
|
|
1854
|
-
}
|
|
1855
|
-
if (requestParameters["$top"] != null) {
|
|
1856
|
-
queryParameters["$top"] = requestParameters["$top"];
|
|
1857
|
-
}
|
|
1858
|
-
if (requestParameters["$skip"] != null) {
|
|
1859
|
-
queryParameters["$skip"] = requestParameters["$skip"];
|
|
1860
|
-
}
|
|
1861
|
-
if (requestParameters["$count"] != null) {
|
|
1862
|
-
queryParameters["$count"] = requestParameters["$count"];
|
|
1863
|
-
}
|
|
1864
|
-
const headerParameters = {};
|
|
1865
|
-
if (this.configuration && this.configuration.accessToken) {
|
|
1866
|
-
headerParameters["Authorization"] = await this.configuration.accessToken("OAuth2", []);
|
|
1867
|
-
}
|
|
1868
|
-
let urlPath = `/odata/PersonalWorkspaces`;
|
|
1869
|
-
const response = await this.request({
|
|
1870
|
-
path: urlPath,
|
|
1871
|
-
method: "GET",
|
|
1872
|
-
headers: headerParameters,
|
|
1873
|
-
query: queryParameters
|
|
1874
|
-
}, initOverrides);
|
|
1875
|
-
return new JSONApiResponse(response, (jsonValue) => ODataValueOfIEnumerableOfPersonalWorkspaceDtoFromJSON(jsonValue));
|
|
1918
|
+
var CURRENT_USER_FOLDER_PAGE_SIZE = 1000;
|
|
1919
|
+
var CURRENT_USER_FOLDER_PAGE_LIMIT = 50;
|
|
1920
|
+
async function resolveInPersonalWorkspace(config, foldersApi, folderPath) {
|
|
1921
|
+
const workspace = await lookupOrMiss("GetPersonalWorkspace", folderPath, () => new PersonalWorkspacesApi(config).personalWorkspacesGetPersonalWorkspace());
|
|
1922
|
+
if (!workspace?.key || !workspace.name) {
|
|
1923
|
+
return;
|
|
1876
1924
|
}
|
|
1877
|
-
|
|
1878
|
-
|
|
1879
|
-
|
|
1925
|
+
const wanted = folderPath.toLowerCase();
|
|
1926
|
+
const root = workspace.name.toLowerCase();
|
|
1927
|
+
let key;
|
|
1928
|
+
if (wanted === root) {
|
|
1929
|
+
key = workspace.key;
|
|
1930
|
+
} else if (wanted.startsWith(`${root}/`)) {
|
|
1931
|
+
key = await findKeyInCurrentUserFolders(foldersApi, folderPath);
|
|
1880
1932
|
}
|
|
1881
|
-
|
|
1882
|
-
|
|
1883
|
-
if (requestParameters["$select"] != null) {
|
|
1884
|
-
queryParameters["$select"] = requestParameters["$select"];
|
|
1885
|
-
}
|
|
1886
|
-
if (requestParameters["$expand"] != null) {
|
|
1887
|
-
queryParameters["$expand"] = requestParameters["$expand"];
|
|
1888
|
-
}
|
|
1889
|
-
const headerParameters = {};
|
|
1890
|
-
if (this.configuration && this.configuration.accessToken) {
|
|
1891
|
-
headerParameters["Authorization"] = await this.configuration.accessToken("OAuth2", []);
|
|
1892
|
-
}
|
|
1893
|
-
let urlPath = `/odata/PersonalWorkspaces/UiPath.Server.Configuration.OData.GetPersonalWorkspace`;
|
|
1894
|
-
const response = await this.request({
|
|
1895
|
-
path: urlPath,
|
|
1896
|
-
method: "GET",
|
|
1897
|
-
headers: headerParameters,
|
|
1898
|
-
query: queryParameters
|
|
1899
|
-
}, initOverrides);
|
|
1900
|
-
return new JSONApiResponse(response, (jsonValue) => PersonalWorkspaceDtoFromJSON(jsonValue));
|
|
1933
|
+
if (!key) {
|
|
1934
|
+
return;
|
|
1901
1935
|
}
|
|
1902
|
-
|
|
1903
|
-
|
|
1904
|
-
|
|
1936
|
+
const folder = await foldersApi.foldersGetByKeyByIdentifier({
|
|
1937
|
+
identifier: key
|
|
1938
|
+
});
|
|
1939
|
+
return folder?.fullyQualifiedName?.toLowerCase() === wanted ? folder : undefined;
|
|
1940
|
+
}
|
|
1941
|
+
async function findKeyInCurrentUserFolders(foldersApi, folderPath) {
|
|
1942
|
+
const wanted = folderPath.toLowerCase();
|
|
1943
|
+
let skip = 0;
|
|
1944
|
+
for (let page = 0;page < CURRENT_USER_FOLDER_PAGE_LIMIT; page++) {
|
|
1945
|
+
const result = await lookupOrMiss("GetAllForCurrentUser", folderPath, () => foldersApi.foldersGetAllForCurrentUser({
|
|
1946
|
+
take: CURRENT_USER_FOLDER_PAGE_SIZE,
|
|
1947
|
+
skip
|
|
1948
|
+
}));
|
|
1949
|
+
const rows = result?.pageItems ?? [];
|
|
1950
|
+
const match = rows.find((row) => row.fullyQualifiedName?.toLowerCase() === wanted);
|
|
1951
|
+
if (match) {
|
|
1952
|
+
return match.key;
|
|
1953
|
+
}
|
|
1954
|
+
skip += rows.length;
|
|
1955
|
+
if (rows.length === 0 || typeof result?.count === "number" && skip >= result.count) {
|
|
1956
|
+
return;
|
|
1957
|
+
}
|
|
1958
|
+
}
|
|
1959
|
+
logger.debug(`GetAllForCurrentUser: stopped after ${CURRENT_USER_FOLDER_PAGE_LIMIT} pages without finding '${folderPath}'.`);
|
|
1960
|
+
return;
|
|
1961
|
+
}
|
|
1962
|
+
async function lookupOrMiss(endpoint, folderPath, call) {
|
|
1963
|
+
const [error, value] = await catchError(call());
|
|
1964
|
+
if (!error) {
|
|
1965
|
+
return value;
|
|
1905
1966
|
}
|
|
1967
|
+
if (!isLookupMiss(error)) {
|
|
1968
|
+
throw error;
|
|
1969
|
+
}
|
|
1970
|
+
logger.debug(`${endpoint} lookup for '${folderPath}' failed: ${await extractErrorMessage(error)}`);
|
|
1971
|
+
return;
|
|
1972
|
+
}
|
|
1973
|
+
function isLookupMiss(error) {
|
|
1974
|
+
const failure = error;
|
|
1975
|
+
const status = failure?.response?.status ?? failure?.status;
|
|
1976
|
+
return typeof status === "number" && status >= 400 && status < 500 && status !== 408 && status !== 429;
|
|
1906
1977
|
}
|
|
1907
1978
|
// ../orchestrator-sdk/generated/src/apis/UsersApi.ts
|
|
1908
1979
|
class UsersApi extends BaseAPI {
|
|
@@ -2129,4 +2200,4 @@ var KB_INLINE_LIMITS = {
|
|
|
2129
2200
|
};
|
|
2130
2201
|
export { PersonalWorkspacesApi, UsersApi, createOrchestratorConfig, createApiClient, resolveFolder };
|
|
2131
2202
|
|
|
2132
|
-
//# debugId=
|
|
2203
|
+
//# debugId=9B0BFFC7BD32F9C064756E2164756E21
|