@uipath/llmgw-tool 1.198.0-preview.87 → 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 +18 -9
  2. package/package.json +2 -2
package/dist/tool.js CHANGED
@@ -4,7 +4,7 @@ var __require = /* @__PURE__ */ createRequire(import.meta.url);
4
4
  var package_default = {
5
5
  name: "@uipath/llmgw-tool",
6
6
  license: "MIT",
7
- version: "1.198.0-preview.87",
7
+ version: "1.199.0-preview.91",
8
8
  description: "CLI plugin for UiPath AI Trust Layer Bring-Your-Own LLM connections.",
9
9
  private: false,
10
10
  repository: {
@@ -916,6 +916,7 @@ function settlePromiseLike(thenable) {
916
916
  var DEFAULT_401 = "Unauthorized (401). Run `uip login` to authenticate.";
917
917
  var DEFAULT_403 = "Forbidden (403). Ensure the account has the required permissions.";
918
918
  var DEFAULT_405 = "Method Not Allowed (405). The endpoint may not exist or the base URL may be incorrect.";
919
+ 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.";
919
920
  var HTML_RESPONSE_MESSAGE = "Received HTML instead of the expected JSON response.";
920
921
  var NETWORK_ERROR_CODES = new Set([
921
922
  "ECONNREFUSED",
@@ -1017,6 +1018,9 @@ function classifyError(status, error) {
1017
1018
  if (status === 405) {
1018
1019
  return { errorCode: "method_not_allowed", retry: "RetryWillNotFix" };
1019
1020
  }
1021
+ if (status === 413) {
1022
+ return { errorCode: "invalid_argument", retry: "RetryWillNotFix" };
1023
+ }
1020
1024
  if (status === 408) {
1021
1025
  return { errorCode: "timeout", retry: "RetryLater" };
1022
1026
  }
@@ -1094,6 +1098,8 @@ async function extractErrorDetails(error, options) {
1094
1098
  result = "AuthenticationError";
1095
1099
  } else if (status === 405) {
1096
1100
  message = DEFAULT_405;
1101
+ } else if (status === 413) {
1102
+ message = DEFAULT_413;
1097
1103
  } else if (status === 400 || status === 422) {
1098
1104
  message = formatHttpStatusMessage(status, rawMessage, extractedMessage, inferredStatus);
1099
1105
  result = "ValidationError";
@@ -7735,6 +7741,7 @@ var SKILL_ATTRIBUTION = attributionRecord([
7735
7741
  var KNOWN_SKILL_NAMES = new Set(Object.keys(SKILL_ATTRIBUTION));
7736
7742
  var COMMAND_ATTRIBUTION = commandAttribution([
7737
7743
  ["cli", "troubleshoot", ["uip.feedback"]],
7744
+ ["llm-gateway", "operate", ["uip.llm-gateway"]],
7738
7745
  ["llm-gateway", "operate", ["uip.llm-configuration", "uip.model-hub"]],
7739
7746
  ["context-grounding", "build", ["uip.context-grounding"]],
7740
7747
  ["api-workflow", "build", ["uip.api-workflow"]],
@@ -26944,6 +26951,7 @@ var resolveConfigAsync = async ({
26944
26951
  customAuthority,
26945
26952
  customClientId,
26946
26953
  customClientSecret,
26954
+ customClientAssertion,
26947
26955
  customScopes
26948
26956
  } = {}) => {
26949
26957
  const fileAuth = getAuthFileConfig();
@@ -26969,7 +26977,7 @@ var resolveConfigAsync = async ({
26969
26977
  if (!clientSecret && fileAuth.clientSecret) {
26970
26978
  clientSecret = fileAuth.clientSecret;
26971
26979
  }
26972
- const isExternalAppAuth = clientId !== DEFAULT_CLIENT_ID && Boolean(clientSecret);
26980
+ const isExternalAppAuth = clientId !== DEFAULT_CLIENT_ID && (Boolean(clientSecret) || Boolean(customClientAssertion));
26973
26981
  const scopes = resolveScopes(isExternalAppAuth, customScopes, fileAuth.scopes);
26974
26982
  return {
26975
26983
  clientId,
@@ -28246,6 +28254,7 @@ function connectorsSupportingFlavors(flavors, connectorApiFlavors) {
28246
28254
  }
28247
28255
 
28248
28256
  // src/commands/byo-connections/internal/helpers.ts
28257
+ import { InvalidArgumentError as InvalidArgumentError2 } from "commander";
28249
28258
  var MAPPING_REQUIRED_KEYS = [
28250
28259
  "llm-name",
28251
28260
  "llm-identifier",
@@ -28271,30 +28280,30 @@ function parseMapping(raw) {
28271
28280
  const seenKebab = new Set;
28272
28281
  const segments = raw.split(",").map((s) => s.trim()).filter((s) => s.length > 0);
28273
28282
  if (segments.length === 0) {
28274
- throw new Error("Empty --mapping. Expected key=value,key=value,... with required keys: " + MAPPING_REQUIRED_KEYS.join(", "));
28283
+ throw new InvalidArgumentError2("Empty --mapping. Expected key=value,key=value,... with required keys: " + MAPPING_REQUIRED_KEYS.join(", "));
28275
28284
  }
28276
28285
  for (const segment of segments) {
28277
28286
  const eq = segment.indexOf("=");
28278
28287
  if (eq <= 0) {
28279
- throw new Error(`Malformed --mapping entry '${segment}'. Each segment must be 'key=value'.`);
28288
+ throw new InvalidArgumentError2(`Malformed --mapping entry '${segment}'. Each segment must be 'key=value'.`);
28280
28289
  }
28281
28290
  const key = segment.slice(0, eq).trim();
28282
28291
  const value = segment.slice(eq + 1).trim();
28283
28292
  if (!MAPPING_ALL_KEYS.has(key)) {
28284
- throw new Error(`Unknown --mapping key '${key}'. Allowed: ${[...MAPPING_REQUIRED_KEYS, ...MAPPING_OPTIONAL_KEYS].join(", ")}.`);
28293
+ throw new InvalidArgumentError2(`Unknown --mapping key '${key}'. Allowed: ${[...MAPPING_REQUIRED_KEYS, ...MAPPING_OPTIONAL_KEYS].join(", ")}.`);
28285
28294
  }
28286
28295
  if (seenKebab.has(key)) {
28287
- throw new Error(`Duplicate --mapping key '${key}'.`);
28296
+ throw new InvalidArgumentError2(`Duplicate --mapping key '${key}'.`);
28288
28297
  }
28289
28298
  if (!value) {
28290
- throw new Error(`--mapping key '${key}' has empty value.`);
28299
+ throw new InvalidArgumentError2(`--mapping key '${key}' has empty value.`);
28291
28300
  }
28292
28301
  seenKebab.add(key);
28293
28302
  seen[KEBAB_TO_CAMEL[key]] = value;
28294
28303
  }
28295
28304
  const missing = MAPPING_REQUIRED_KEYS.filter((k) => !seenKebab.has(k));
28296
28305
  if (missing.length) {
28297
- throw new Error(`--mapping is missing required keys: ${missing.join(", ")}. Got: '${raw}'.`);
28306
+ throw new InvalidArgumentError2(`--mapping is missing required keys: ${missing.join(", ")}. Got: '${raw}'.`);
28298
28307
  }
28299
28308
  return {
28300
28309
  llmName: seen.llmName,
@@ -29422,4 +29431,4 @@ export {
29422
29431
  metadata
29423
29432
  };
29424
29433
 
29425
- //# debugId=A1DAC8568A8C7B0964756E2164756E21
29434
+ //# debugId=EBDE3B536CCA448364756E2164756E21
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@uipath/llmgw-tool",
3
3
  "license": "MIT",
4
- "version": "1.198.0-preview.87",
4
+ "version": "1.199.0-preview.91",
5
5
  "description": "CLI plugin for UiPath AI Trust Layer Bring-Your-Own LLM connections.",
6
6
  "private": false,
7
7
  "repository": {
@@ -23,5 +23,5 @@
23
23
  "files": [
24
24
  "dist"
25
25
  ],
26
- "gitHead": "b84a7a78e1a325c3dd3b39efd3018c49b38c789f"
26
+ "gitHead": "f428cb1e61ba89ad18394b0c6106784055699f02"
27
27
  }