@uipath/orchestrator-tool 1.198.0-preview.90 → 1.199.0-preview.91

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.
Files changed (2) hide show
  1. package/dist/tool.js +43 -70
  2. package/package.json +2 -2
package/dist/tool.js CHANGED
@@ -21250,7 +21250,7 @@ var init_server = __esm(() => {
21250
21250
  var package_default = {
21251
21251
  name: "@uipath/orchestrator-tool",
21252
21252
  license: "MIT",
21253
- version: "1.198.0-preview.90",
21253
+ version: "1.199.0-preview.91",
21254
21254
  description: "Manage Orchestrator folders, jobs, processes, and releases.",
21255
21255
  private: false,
21256
21256
  repository: {
@@ -21329,6 +21329,7 @@ function settlePromiseLike(thenable) {
21329
21329
  var DEFAULT_401 = "Unauthorized (401). Run `uip login` to authenticate.";
21330
21330
  var DEFAULT_403 = "Forbidden (403). Ensure the account has the required permissions.";
21331
21331
  var DEFAULT_405 = "Method Not Allowed (405). The endpoint may not exist or the base URL may be incorrect.";
21332
+ var DEFAULT_413 = "Payload too large (413). The upload exceeded the server or CDN size limit. Reduce the package size — for example, exclude unused dependencies or remove large files from the project — and try again.";
21332
21333
  var HTML_RESPONSE_MESSAGE = "Received HTML instead of the expected JSON response.";
21333
21334
  var NETWORK_ERROR_CODES = new Set([
21334
21335
  "ECONNREFUSED",
@@ -21430,6 +21431,9 @@ function classifyError(status, error) {
21430
21431
  if (status === 405) {
21431
21432
  return { errorCode: "method_not_allowed", retry: "RetryWillNotFix" };
21432
21433
  }
21434
+ if (status === 413) {
21435
+ return { errorCode: "invalid_argument", retry: "RetryWillNotFix" };
21436
+ }
21433
21437
  if (status === 408) {
21434
21438
  return { errorCode: "timeout", retry: "RetryLater" };
21435
21439
  }
@@ -21507,6 +21511,8 @@ async function extractErrorDetails(error, options) {
21507
21511
  result = "AuthenticationError";
21508
21512
  } else if (status === 405) {
21509
21513
  message = DEFAULT_405;
21514
+ } else if (status === 413) {
21515
+ message = DEFAULT_413;
21510
21516
  } else if (status === 400 || status === 422) {
21511
21517
  message = formatHttpStatusMessage(status, rawMessage, extractedMessage, inferredStatus);
21512
21518
  result = "ValidationError";
@@ -28196,6 +28202,7 @@ var SKILL_ATTRIBUTION = attributionRecord([
28196
28202
  var KNOWN_SKILL_NAMES = new Set(Object.keys(SKILL_ATTRIBUTION));
28197
28203
  var COMMAND_ATTRIBUTION = commandAttribution([
28198
28204
  ["cli", "troubleshoot", ["uip.feedback"]],
28205
+ ["llm-gateway", "operate", ["uip.llm-gateway"]],
28199
28206
  ["llm-gateway", "operate", ["uip.llm-configuration", "uip.model-hub"]],
28200
28207
  ["context-grounding", "build", ["uip.context-grounding"]],
28201
28208
  ["api-workflow", "build", ["uip.api-workflow"]],
@@ -29442,7 +29449,7 @@ class TextApiResponse {
29442
29449
  var package_default2 = {
29443
29450
  name: "@uipath/orchestrator-sdk",
29444
29451
  license: "MIT",
29445
- version: "1.198.0",
29452
+ version: "1.199.0",
29446
29453
  repository: {
29447
29454
  type: "git",
29448
29455
  url: "https://github.com/UiPath/cli.git",
@@ -49906,6 +49913,7 @@ var resolveConfigAsync = async ({
49906
49913
  customAuthority,
49907
49914
  customClientId,
49908
49915
  customClientSecret,
49916
+ customClientAssertion,
49909
49917
  customScopes
49910
49918
  } = {}) => {
49911
49919
  const fileAuth = getAuthFileConfig();
@@ -49931,7 +49939,7 @@ var resolveConfigAsync = async ({
49931
49939
  if (!clientSecret && fileAuth.clientSecret) {
49932
49940
  clientSecret = fileAuth.clientSecret;
49933
49941
  }
49934
- const isExternalAppAuth = clientId !== DEFAULT_CLIENT_ID && Boolean(clientSecret);
49942
+ const isExternalAppAuth = clientId !== DEFAULT_CLIENT_ID && (Boolean(clientSecret) || Boolean(customClientAssertion));
49935
49943
  const scopes = resolveScopes(isExternalAppAuth, customScopes, fileAuth.scopes);
49936
49944
  return {
49937
49945
  clientId,
@@ -51049,7 +51057,6 @@ var getAuthContext = async (options = {}) => {
51049
51057
  tenantName
51050
51058
  };
51051
51059
  };
51052
-
51053
51060
  // ../auth/src/index.ts
51054
51061
  init_constants();
51055
51062
 
@@ -51335,20 +51342,28 @@ async function resolveEntityOrFail(ApiClass, clientOptions, resolverFn, key, err
51335
51342
  folderKey: clientOptions.folderKey
51336
51343
  }));
51337
51344
  if (apiError) {
51345
+ const details = await extractErrorDetails(apiError);
51338
51346
  OutputFormatter.error({
51339
51347
  Result: RESULTS.Failure,
51348
+ ErrorCode: details.errorCode,
51340
51349
  Message: errorContext,
51341
- Instructions: apply(await extractErrorMessage(apiError))
51350
+ Instructions: apply(details.message),
51351
+ Retry: details.retry,
51352
+ ...details.context ? { Context: details.context } : {}
51342
51353
  });
51343
51354
  processContext.exit(1);
51344
51355
  return null;
51345
51356
  }
51346
51357
  const [resolveError, entity] = await catchError(resolverFn(api, key));
51347
51358
  if (resolveError) {
51359
+ const details = await extractErrorDetails(resolveError);
51348
51360
  OutputFormatter.error({
51349
51361
  Result: RESULTS.Failure,
51362
+ ErrorCode: details.errorCode,
51350
51363
  Message: errorContext,
51351
- Instructions: apply(await extractErrorMessage(resolveError))
51364
+ Instructions: apply(details.message),
51365
+ Retry: details.retry,
51366
+ ...details.context ? { Context: details.context } : {}
51352
51367
  });
51353
51368
  processContext.exit(1);
51354
51369
  return null;
@@ -67298,6 +67313,18 @@ function formatWebhookDetail(w) {
67298
67313
  AllowInsecureSsl: w.allowInsecureSsl ?? false
67299
67314
  };
67300
67315
  }
67316
+ async function emitWebhookError(message, error) {
67317
+ const details = await extractErrorDetails(error);
67318
+ OutputFormatter.error({
67319
+ Result: RESULTS.Failure,
67320
+ ErrorCode: details.errorCode,
67321
+ Message: message,
67322
+ Instructions: details.message,
67323
+ Retry: details.retry,
67324
+ ...details.context ? { Context: details.context } : {}
67325
+ });
67326
+ processContext.exit(1);
67327
+ }
67301
67328
  var WEBHOOKS_LIST_EXAMPLES = [
67302
67329
  {
67303
67330
  Description: "List webhooks in the tenant",
@@ -67430,13 +67457,7 @@ var registerWebhooksCommand = (program2) => {
67430
67457
  tenant: options.tenant
67431
67458
  }));
67432
67459
  if (apiError) {
67433
- const errorMessage2 = await extractErrorMessage(apiError);
67434
- OutputFormatter.error({
67435
- Result: RESULTS.Failure,
67436
- Message: "Error listing webhooks",
67437
- Instructions: errorMessage2
67438
- });
67439
- processContext.exit(1);
67460
+ await emitWebhookError("Error listing webhooks", apiError);
67440
67461
  return;
67441
67462
  }
67442
67463
  const filters = [];
@@ -67457,13 +67478,7 @@ var registerWebhooksCommand = (program2) => {
67457
67478
  $orderby: options.sortBy
67458
67479
  }));
67459
67480
  if (listError) {
67460
- const errorMessage2 = await extractErrorMessage(listError);
67461
- OutputFormatter.error({
67462
- Result: RESULTS.Failure,
67463
- Message: "Error listing webhooks",
67464
- Instructions: errorMessage2
67465
- });
67466
- processContext.exit(1);
67481
+ await emitWebhookError("Error listing webhooks", listError);
67467
67482
  return;
67468
67483
  }
67469
67484
  const limit = parseInt(options.limit, 10);
@@ -67495,13 +67510,7 @@ var registerWebhooksCommand = (program2) => {
67495
67510
  tenant: options.tenant
67496
67511
  }));
67497
67512
  if (apiError) {
67498
- const errorMessage2 = await extractErrorMessage(apiError);
67499
- OutputFormatter.error({
67500
- Result: RESULTS.Failure,
67501
- Message: "Error creating webhook",
67502
- Instructions: errorMessage2
67503
- });
67504
- processContext.exit(1);
67513
+ await emitWebhookError("Error creating webhook", apiError);
67505
67514
  return;
67506
67515
  }
67507
67516
  const subscribeToAllEvents = !options.events;
@@ -67518,13 +67527,7 @@ var registerWebhooksCommand = (program2) => {
67518
67527
  };
67519
67528
  const [createError, result] = await catchError(api.webhooksPost({ body: webhookData }));
67520
67529
  if (createError) {
67521
- const errorMessage2 = await extractErrorMessage(createError);
67522
- OutputFormatter.error({
67523
- Result: RESULTS.Failure,
67524
- Message: "Error creating webhook",
67525
- Instructions: errorMessage2
67526
- });
67527
- processContext.exit(1);
67530
+ await emitWebhookError("Error creating webhook", createError);
67528
67531
  return;
67529
67532
  }
67530
67533
  OutputFormatter.success({
@@ -67569,13 +67572,7 @@ var registerWebhooksCommand = (program2) => {
67569
67572
  body: merged
67570
67573
  }));
67571
67574
  if (putError) {
67572
- const errorMessage2 = await extractErrorMessage(putError);
67573
- OutputFormatter.error({
67574
- Result: RESULTS.Failure,
67575
- Message: "Error updating webhook",
67576
- Instructions: errorMessage2
67577
- });
67578
- processContext.exit(1);
67575
+ await emitWebhookError("Error updating webhook", putError);
67579
67576
  return;
67580
67577
  }
67581
67578
  OutputFormatter.success({
@@ -67598,13 +67595,7 @@ var registerWebhooksCommand = (program2) => {
67598
67595
  key: resolved.entity.id
67599
67596
  }));
67600
67597
  if (deleteError) {
67601
- const errorMessage2 = await extractErrorMessage(deleteError);
67602
- OutputFormatter.error({
67603
- Result: RESULTS.Failure,
67604
- Message: "Error deleting webhook",
67605
- Instructions: errorMessage2
67606
- });
67607
- processContext.exit(1);
67598
+ await emitWebhookError("Error deleting webhook", deleteError);
67608
67599
  return;
67609
67600
  }
67610
67601
  OutputFormatter.success({
@@ -67624,13 +67615,7 @@ var registerWebhooksCommand = (program2) => {
67624
67615
  key: resolved.entity.id
67625
67616
  }));
67626
67617
  if (pingError) {
67627
- const errorMessage2 = await extractErrorMessage(pingError);
67628
- OutputFormatter.error({
67629
- Result: RESULTS.Failure,
67630
- Message: "Error pinging webhook",
67631
- Instructions: errorMessage2
67632
- });
67633
- processContext.exit(1);
67618
+ await emitWebhookError("Error pinging webhook", pingError);
67634
67619
  return;
67635
67620
  }
67636
67621
  OutputFormatter.success({
@@ -67648,24 +67633,12 @@ var registerWebhooksCommand = (program2) => {
67648
67633
  tenant: options.tenant
67649
67634
  }));
67650
67635
  if (apiError) {
67651
- const errorMessage2 = await extractErrorMessage(apiError);
67652
- OutputFormatter.error({
67653
- Result: RESULTS.Failure,
67654
- Message: "Error listing webhook event types",
67655
- Instructions: errorMessage2
67656
- });
67657
- processContext.exit(1);
67636
+ await emitWebhookError("Error listing webhook event types", apiError);
67658
67637
  return;
67659
67638
  }
67660
67639
  const [listError, result] = await catchError(api.webhooksGetEventTypes({}));
67661
67640
  if (listError) {
67662
- const errorMessage2 = await extractErrorMessage(listError);
67663
- OutputFormatter.error({
67664
- Result: RESULTS.Failure,
67665
- Message: "Error listing webhook event types",
67666
- Instructions: errorMessage2
67667
- });
67668
- processContext.exit(1);
67641
+ await emitWebhookError("Error listing webhook event types", listError);
67669
67642
  return;
67670
67643
  }
67671
67644
  const eventTypes = (result.value ?? []).map((et) => ({
@@ -67724,4 +67697,4 @@ export {
67724
67697
  metadata
67725
67698
  };
67726
67699
 
67727
- //# debugId=533FD61CA3FCCC0864756E2164756E21
67700
+ //# debugId=6E768E2715448BDA64756E2164756E21
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@uipath/orchestrator-tool",
3
3
  "license": "MIT",
4
- "version": "1.198.0-preview.90",
4
+ "version": "1.199.0-preview.91",
5
5
  "description": "Manage Orchestrator folders, jobs, processes, and releases.",
6
6
  "private": false,
7
7
  "repository": {
@@ -26,5 +26,5 @@
26
26
  "files": [
27
27
  "dist"
28
28
  ],
29
- "gitHead": "7fa615fb10f91f98f796a038ea70569336611f42"
29
+ "gitHead": "f428cb1e61ba89ad18394b0c6106784055699f02"
30
30
  }