@uipath/agent-tool 1.206.0-preview.296 → 1.206.0-preview.297

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.
@@ -5,7 +5,7 @@ compiled into its `dist/` output rather than installed alongside it.
5
5
  Their licences and copyright notices are reproduced here in full, as
6
6
  those licences require.
7
7
 
8
- 35 bundled dependencies:
8
+ 37 bundled dependencies:
9
9
 
10
10
  - @jsep-plugin/object@1.2.2 — MIT
11
11
  - @uipath/agents-storage-schemas@1.42.0 — SEE LICENSE IN LICENSE.txt
@@ -32,7 +32,9 @@ those licences require.
32
32
  - js-yaml@4.3.2 — MIT
33
33
  - jsep@1.4.0 — MIT
34
34
  - json-schema-traverse@1.0.0 — MIT
35
+ - oauth4webapi@3.8.6 — MIT
35
36
  - open@11.0.0 — MIT
37
+ - openid-client@6.8.4 — MIT
36
38
  - powershell-utils@0.1.0 — MIT
37
39
  - reflect-metadata@0.2.2 — Apache-2.0
38
40
  - run-applescript@7.1.0 — MIT
@@ -622,6 +624,36 @@ SOFTWARE.
622
624
 
623
625
  ---
624
626
 
627
+ ## oauth4webapi@3.8.6
628
+
629
+ SPDX: MIT
630
+
631
+ ```
632
+ The MIT License (MIT)
633
+
634
+ Copyright (c) 2022 Filip Skokan
635
+
636
+ Permission is hereby granted, free of charge, to any person obtaining a copy
637
+ of this software and associated documentation files (the "Software"), to deal
638
+ in the Software without restriction, including without limitation the rights
639
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
640
+ copies of the Software, and to permit persons to whom the Software is
641
+ furnished to do so, subject to the following conditions:
642
+
643
+ The above copyright notice and this permission notice shall be included in all
644
+ copies or substantial portions of the Software.
645
+
646
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
647
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
648
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
649
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
650
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
651
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
652
+ SOFTWARE.
653
+ ```
654
+
655
+ ---
656
+
625
657
  ## open@11.0.0
626
658
 
627
659
  SPDX: MIT
@@ -640,6 +672,36 @@ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLI
640
672
 
641
673
  ---
642
674
 
675
+ ## openid-client@6.8.4
676
+
677
+ SPDX: MIT
678
+
679
+ ```
680
+ The MIT License (MIT)
681
+
682
+ Copyright (c) 2016 Filip Skokan
683
+
684
+ Permission is hereby granted, free of charge, to any person obtaining a copy
685
+ of this software and associated documentation files (the "Software"), to deal
686
+ in the Software without restriction, including without limitation the rights
687
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
688
+ copies of the Software, and to permit persons to whom the Software is
689
+ furnished to do so, subject to the following conditions:
690
+
691
+ The above copyright notice and this permission notice shall be included in all
692
+ copies or substantial portions of the Software.
693
+
694
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
695
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
696
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
697
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
698
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
699
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
700
+ SOFTWARE.
701
+ ```
702
+
703
+ ---
704
+
643
705
  ## powershell-utils@0.1.0
644
706
 
645
707
  SPDX: MIT
@@ -0,0 +1,98 @@
1
+ import {
2
+ AUTH_CANCELLED_ERROR_CODE
3
+ } from "./packager-tool-1qg04b7q.js";
4
+ import {
5
+ getGlobalThis
6
+ } from "./packager-tool-zdqbp34f.js";
7
+
8
+ // ../auth/src/strategies/browser-strategy.ts
9
+ class BrowserAuthStrategy {
10
+ async execute(url, _redirectUri, expectedState, opts) {
11
+ const global = getGlobalThis();
12
+ if (!global?.window) {
13
+ throw new Error("Browser environment required for authentication");
14
+ }
15
+ const screenWidth = global.window.screen?.width ?? 1024;
16
+ const screenHeight = global.window.screen?.height ?? 768;
17
+ const width = 600;
18
+ const height = 700;
19
+ const left = screenWidth / 2 - width / 2;
20
+ const top = screenHeight / 2 - height / 2;
21
+ if (!global.window.open) {
22
+ throw new Error("window.open is not available");
23
+ }
24
+ const popupResult = global.window.open(url, "uip_auth", `width=${width},height=${height},left=${left},top=${top},resizable=yes,scrollbars=yes,status=yes`);
25
+ const popup = popupResult;
26
+ if (!popup) {
27
+ throw new Error(`Authentication popup was blocked by your browser.
28
+
29
+ ` + `To continue:
30
+ ` + `1. Look for a popup blocker icon in your address bar
31
+ ` + `2. Allow popups for this site
32
+ ` + `3. Try logging in again
33
+
34
+ ` + "If using an ad blocker, you may need to temporarily disable it.");
35
+ }
36
+ return new Promise((resolve, reject) => {
37
+ let timer;
38
+ const messageHandler = (event) => {
39
+ if (event.data?.type === "UIP_AUTH_CODE" && event.data.code) {
40
+ if (event.data.state !== expectedState) {
41
+ cleanup();
42
+ reject(new Error("OAuth state mismatch — the callback state does not match the expected value. " + "This may indicate a CSRF attack. Please try signing in again."));
43
+ popup.close();
44
+ return;
45
+ }
46
+ cleanup();
47
+ resolve(event.data.code);
48
+ popup.close();
49
+ } else if (event.data?.type === "UIP_AUTH_ERROR") {
50
+ cleanup();
51
+ const errorMsg = event.data.error || "Authentication failed";
52
+ reject(new Error(`Authentication failed: ${errorMsg}
53
+
54
+ ` + "Please check your credentials and try again. " + "If the problem persists, verify your UiPath account is active."));
55
+ popup.close();
56
+ }
57
+ };
58
+ const cleanup = () => {
59
+ global.window?.removeEventListener?.("message", messageHandler);
60
+ opts?.signal?.removeEventListener("abort", onAbort);
61
+ if (timer)
62
+ clearInterval(timer);
63
+ };
64
+ const onAbort = () => {
65
+ cleanup();
66
+ const err = new Error(`Authentication was cancelled.
67
+
68
+ ` + "The sign-in was cancelled before completing the login process. " + "Please try again and complete the authentication flow.");
69
+ err.code = AUTH_CANCELLED_ERROR_CODE;
70
+ reject(err);
71
+ popup.close();
72
+ };
73
+ if (opts?.signal) {
74
+ if (opts.signal.aborted) {
75
+ onAbort();
76
+ return;
77
+ }
78
+ opts.signal.addEventListener("abort", onAbort, { once: true });
79
+ }
80
+ if (global.window?.addEventListener) {
81
+ global.window.addEventListener("message", messageHandler);
82
+ }
83
+ timer = setInterval(() => {
84
+ if (popup.closed) {
85
+ cleanup();
86
+ reject(new Error(`Authentication was cancelled.
87
+
88
+ ` + "The authentication popup was closed before completing the login process. " + "Please try again and complete the authentication flow."));
89
+ }
90
+ }, 1000);
91
+ });
92
+ }
93
+ }
94
+ export {
95
+ BrowserAuthStrategy
96
+ };
97
+
98
+ //# debugId=65561DFA5EC07C3664756E2164756E21
@@ -1,13 +1,14 @@
1
1
  import"./packager-tool-0ajs8pnk.js";
2
- import"./packager-tool-21r3phhc.js";
3
- import"./packager-tool-z6a5nr2d.js";
4
- import"./packager-tool-qr8dtv3r.js";
5
- import"./packager-tool-cc2sgsw1.js";
2
+ import"./packager-tool-dy6gcgks.js";
3
+ import"./packager-tool-2dd1qswc.js";
4
+ import"./packager-tool-1qg04b7q.js";
5
+ import"./packager-tool-9xrkfzn1.js";
6
+ import"./packager-tool-xt86c1ek.js";
6
7
  import {
7
8
  AgentDebugCancelledError,
8
9
  AgentDebugService
9
- } from "./packager-tool-1373myfq.js";
10
- import"./packager-tool-4j09ztk2.js";
10
+ } from "./packager-tool-b0fh39zt.js";
11
+ import"./packager-tool-3t6d1zdz.js";
11
12
  // ../executor/project-executor/src/models/run-status.ts
12
13
  var TERMINAL_RUN_STATUSES = [
13
14
  "Succeeded" /* Succeeded */,
@@ -289,4 +290,4 @@ export {
289
290
  createExecutorFactory
290
291
  };
291
292
 
292
- //# debugId=D5459F1910EAFB7564756E2164756E21
293
+ //# debugId=A43DDB959C48960464756E2164756E21
@@ -5,10 +5,11 @@ import {
5
5
  resolveFolder2,
6
6
  JobAttachmentUploadError2,
7
7
  uploadJobAttachment2
8
- } from "./packager-tool-z6a5nr2d.js";
9
- import"./packager-tool-qr8dtv3r.js";
10
- import"./packager-tool-21r3phhc.js";
8
+ } from "./packager-tool-2dd1qswc.js";
9
+ import"./packager-tool-9xrkfzn1.js";
10
+ import"./packager-tool-dy6gcgks.js";
11
11
  import"./packager-tool-0ajs8pnk.js";
12
+ import"./packager-tool-1qg04b7q.js";
12
13
  export {
13
14
  JobAttachmentUploadError2 as JobAttachmentUploadError,
14
15
  PersonalWorkspacesApi2 as PersonalWorkspacesApi,
@@ -18,4 +19,4 @@ export {
18
19
  uploadJobAttachment2 as uploadJobAttachment
19
20
  };
20
21
 
21
- //# debugId=793ED78C53A9BE0564756E2164756E21
22
+ //# debugId=44CADFADFE4C3DC164756E2164756E21
@@ -6,7 +6,7 @@ import {
6
6
  isSolutionUploadHttpError2,
7
7
  buildSolutionUploadFailureOutput2,
8
8
  uploadOrOverwriteSolution2
9
- } from "./packager-tool-cc2sgsw1.js";
9
+ } from "./packager-tool-xt86c1ek.js";
10
10
  import {
11
11
  prepareProjectLocation2,
12
12
  updateUipxSolutionId2,
@@ -14,8 +14,8 @@ import {
14
14
  updateSolutionFile2,
15
15
  tryRegisterProjectInParentSolution2,
16
16
  findSolutionFileUpward2
17
- } from "./packager-tool-4j09ztk2.js";
18
- import"./packager-tool-21r3phhc.js";
17
+ } from "./packager-tool-3t6d1zdz.js";
18
+ import"./packager-tool-dy6gcgks.js";
19
19
  import"./packager-tool-0ajs8pnk.js";
20
20
  export {
21
21
  StudioWebIncompatibleProjectError2 as StudioWebIncompatibleProjectError,
@@ -0,0 +1,22 @@
1
+ import {
2
+ parseJWT2,
3
+ resolveSessionIdentity2,
4
+ getLoginStatusAsync2,
5
+ getAuthContext2,
6
+ authenticate2
7
+ } from "./packager-tool-9xrkfzn1.js";
8
+ import {
9
+ isBrowser2
10
+ } from "./packager-tool-zdqbp34f.js";
11
+ import"./packager-tool-0ajs8pnk.js";
12
+ import"./packager-tool-1qg04b7q.js";
13
+ export {
14
+ authenticate2 as authenticate,
15
+ getAuthContext2 as getAuthContext,
16
+ getLoginStatusAsync2 as getLoginStatusAsync,
17
+ isBrowser2 as isBrowser,
18
+ parseJWT2 as parseJWT,
19
+ resolveSessionIdentity2 as resolveSessionIdentity
20
+ };
21
+
22
+ //# debugId=96C40B3D5424ED9064756E2164756E21
@@ -6,7 +6,7 @@ import {
6
6
  extractErrorMessage,
7
7
  logger,
8
8
  isGuid
9
- } from "./packager-tool-21r3phhc.js";
9
+ } from "./packager-tool-dy6gcgks.js";
10
10
  import"./packager-tool-4shqngrj.js";
11
11
  import {
12
12
  ErrorCodes,
@@ -57,21 +57,22 @@ import {
57
57
  SolutionDefinitionHelper2,
58
58
  FirstPartyServiceApi2
59
59
  } from "./packager-tool-jjkypwge.js";
60
+ import"./packager-tool-1qg04b7q.js";
60
61
  import {
61
- getLoginStatusAsync
62
- } from "./packager-tool-qr8dtv3r.js";
62
+ getLoginStatusAsync2
63
+ } from "./packager-tool-9xrkfzn1.js";
63
64
  import {
64
65
  UsersApi2,
65
66
  createApiClient2
66
- } from "./packager-tool-z6a5nr2d.js";
67
+ } from "./packager-tool-2dd1qswc.js";
67
68
  import {
68
69
  getSolutionAuthContext2
69
- } from "./packager-tool-qvsazy59.js";
70
+ } from "./packager-tool-9nh85680.js";
70
71
  import {
71
72
  normalizeProjectType,
72
73
  toPortableRelativePath,
73
74
  findSolutionFileUpward2
74
- } from "./packager-tool-4j09ztk2.js";
75
+ } from "./packager-tool-3t6d1zdz.js";
75
76
  import {
76
77
  __toESM,
77
78
  __commonJS
@@ -17710,7 +17711,7 @@ class SolutionAccessProvider {
17710
17711
  userKey = undefined;
17711
17712
  async getStatus() {
17712
17713
  if (!this.loginStatus) {
17713
- this.loginStatus = await getLoginStatusAsync();
17714
+ this.loginStatus = await getLoginStatusAsync2();
17714
17715
  }
17715
17716
  return this.loginStatus;
17716
17717
  }
@@ -19671,4 +19672,4 @@ export {
19671
19672
  writeSolutionFile
19672
19673
  };
19673
19674
 
19674
- //# debugId=B762A5E01AFFAC9664756E2164756E21
19675
+ //# debugId=EF18E0C35DC270A964756E2164756E21
package/dist/index.js CHANGED
@@ -1,18 +1,19 @@
1
1
  #!/usr/bin/env bun
2
2
  import {
3
3
  Command
4
- } from "./packager-tool-21r3phhc.js";
5
- import"./packager-tool-qr8dtv3r.js";
4
+ } from "./packager-tool-dy6gcgks.js";
5
+ import"./packager-tool-1qg04b7q.js";
6
+ import"./packager-tool-9xrkfzn1.js";
6
7
  import"./packager-tool-0ajs8pnk.js";
7
- import"./packager-tool-z6a5nr2d.js";
8
- import"./packager-tool-cc2sgsw1.js";
9
- import"./packager-tool-1373myfq.js";
8
+ import"./packager-tool-2dd1qswc.js";
9
+ import"./packager-tool-xt86c1ek.js";
10
+ import"./packager-tool-b0fh39zt.js";
10
11
  import {
11
12
  metadata2,
12
13
  registerCommands2
13
- } from "./packager-tool-0fh43aka.js";
14
+ } from "./packager-tool-35n6334n.js";
14
15
  import"./packager-tool-bh92xy8d.js";
15
- import"./packager-tool-4j09ztk2.js";
16
+ import"./packager-tool-3t6d1zdz.js";
16
17
 
17
18
  // src/index.ts
18
19
  var program = new Command;
@@ -20,4 +21,4 @@ program.name(metadata2.commandPrefix).description(metadata2.description).version
20
21
  await registerCommands2(program);
21
22
  await program.parseAsync(process.argv);
22
23
 
23
- //# debugId=A9007603878BD8E364756E2164756E21
24
+ //# debugId=B32264EA14BA1D4764756E2164756E21
@@ -1,14 +1,15 @@
1
+ import"./packager-tool-1qg04b7q.js";
1
2
  import {
2
- getAuthContext
3
- } from "./packager-tool-qr8dtv3r.js";
3
+ getAuthContext2
4
+ } from "./packager-tool-9xrkfzn1.js";
4
5
  import"./packager-tool-0ajs8pnk.js";
5
6
  import {
6
7
  catchError
7
- } from "./packager-tool-21r3phhc.js";
8
+ } from "./packager-tool-dy6gcgks.js";
8
9
 
9
10
  // src/services/memory-runtime-service.ts
10
11
  async function resolveAuth() {
11
- const auth = await getAuthContext({
12
+ const auth = await getAuthContext2({
12
13
  ensureTokenValidityMinutes: 10,
13
14
  requireOrganizationId: true,
14
15
  requireTenantName: true
@@ -66,7 +67,7 @@ async function readJson(response, context) {
66
67
  return parsed;
67
68
  }
68
69
  async function resolveRuntimeFolder(input) {
69
- const { resolveFolder } = await import("./index-ybw87d41.js");
70
+ const { resolveFolder } = await import("./index-18dnd3nk.js");
70
71
  const [resolveError, folder] = await catchError(resolveFolder(input));
71
72
  if (resolveError) {
72
73
  if (input.folderPath !== undefined && input.folderKey === undefined && resolveError.message.startsWith("Folder not found")) {
@@ -125,4 +126,4 @@ export {
125
126
  resolveRuntimeFolder
126
127
  };
127
128
 
128
- //# debugId=605D99E8D964AC7564756E2164756E21
129
+ //# debugId=E083F5E57959578364756E2164756E21