@qlik/api 2.4.1 → 2.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.
Files changed (170) hide show
  1. package/analytics/change-stores.d.ts +1 -4
  2. package/analytics/change-stores.js +2 -2
  3. package/analytics.d.ts +0 -1
  4. package/analytics.js +2 -2
  5. package/api-keys.d.ts +1 -3
  6. package/api-keys.js +2 -2
  7. package/apps.d.ts +1 -3
  8. package/apps.js +2 -2
  9. package/assistants.d.ts +35 -37
  10. package/assistants.js +2 -2
  11. package/audits.d.ts +1 -3
  12. package/audits.js +2 -2
  13. package/auth-types.d.ts +1 -110
  14. package/auth.d.ts +1 -1
  15. package/auth.js +1 -1
  16. package/automation-connections.d.ts +6 -7
  17. package/automation-connections.js +3 -3
  18. package/automation-connectors.d.ts +9 -7
  19. package/automation-connectors.js +2 -2
  20. package/automations.d.ts +144 -125
  21. package/automations.js +41 -26
  22. package/automl-deployments.d.ts +1 -3
  23. package/automl-deployments.js +2 -2
  24. package/automl-predictions.d.ts +1 -3
  25. package/automl-predictions.js +2 -2
  26. package/banners.d.ts +1 -3
  27. package/banners.js +2 -2
  28. package/brands.d.ts +1 -3
  29. package/brands.js +2 -2
  30. package/chunks/{auth-B8lJw7rm.js → auth-Cfg2Smt8.js} +1 -1
  31. package/chunks/auth-types-DVvka7Hz.d.ts +385 -0
  32. package/chunks/{boot-interceptors-DqRxTczb.js → interceptors-DMiDeqEz.js} +178 -52
  33. package/chunks/{invoke-fetch-pMN6iqup.js → invoke-fetch-CwBXAsw4.js} +1 -1
  34. package/chunks/{invoke-fetch-DMAi6Fg3.js → invoke-fetch-DxtIsSVQ.js} +3 -3
  35. package/chunks/{public-runtime-modules-2KfyI2qM.js → public-runtime-modules-mBjjPn7I.js} +5 -5
  36. package/chunks/{qix-BdNrIA4s.js → qix-BPCl6Bmh.js} +5 -5
  37. package/chunks/{qix-types-Bjha7sch.d.ts → qix-CJntvLix.d.ts} +46 -3
  38. package/chunks/{qix-chunk-entrypoint-L9RpWwLK.js → qix-chunk-entrypoint-CyQYGyl2.js} +16 -3
  39. package/collections.d.ts +2 -5
  40. package/collections.js +3 -4
  41. package/conditions.d.ts +1 -3
  42. package/conditions.js +2 -2
  43. package/consumption.d.ts +1 -3
  44. package/consumption.js +2 -2
  45. package/core/ip-policies.d.ts +1 -4
  46. package/core/ip-policies.js +2 -2
  47. package/core.d.ts +0 -1
  48. package/core.js +2 -2
  49. package/csp-origins.d.ts +1 -3
  50. package/csp-origins.js +2 -2
  51. package/csrf-token.d.ts +1 -3
  52. package/csrf-token.js +2 -2
  53. package/data-alerts.d.ts +1 -3
  54. package/data-alerts.js +2 -2
  55. package/data-assets.d.ts +1 -3
  56. package/data-assets.js +2 -2
  57. package/data-connections.d.ts +1 -3
  58. package/data-connections.js +2 -2
  59. package/data-credentials.d.ts +1 -3
  60. package/data-credentials.js +2 -2
  61. package/data-files.d.ts +1 -3
  62. package/data-files.js +2 -2
  63. package/data-governance/data-products.d.ts +1 -4
  64. package/data-governance/data-products.js +2 -2
  65. package/data-governance.d.ts +0 -1
  66. package/data-governance.js +2 -2
  67. package/data-qualities.d.ts +1 -3
  68. package/data-qualities.js +2 -2
  69. package/data-sets.d.ts +1 -3
  70. package/data-sets.js +2 -2
  71. package/data-sources.d.ts +1 -3
  72. package/data-sources.js +2 -2
  73. package/data-stores.d.ts +1 -3
  74. package/data-stores.js +2 -2
  75. package/dcaas.d.ts +1 -3
  76. package/dcaas.js +2 -2
  77. package/di-projects.d.ts +28 -8
  78. package/di-projects.js +2 -2
  79. package/direct-access-agents.d.ts +1 -3
  80. package/direct-access-agents.js +2 -2
  81. package/encryption.d.ts +1 -3
  82. package/encryption.js +2 -2
  83. package/extensions.d.ts +1 -3
  84. package/extensions.js +2 -2
  85. package/global-types.d.ts +2 -140
  86. package/glossaries.d.ts +1 -3
  87. package/glossaries.js +2 -2
  88. package/groups.d.ts +1 -3
  89. package/groups.js +2 -2
  90. package/identity-providers.d.ts +1 -3
  91. package/identity-providers.js +2 -2
  92. package/index.d.ts +18 -5
  93. package/index.js +63 -6
  94. package/interceptors.d.ts +1 -3
  95. package/interceptors.js +1 -103
  96. package/invoke-fetch-types.d.ts +1 -97
  97. package/items.d.ts +1 -3
  98. package/items.js +2 -2
  99. package/knowledgebases.d.ts +27 -50
  100. package/knowledgebases.js +2 -2
  101. package/licenses.d.ts +1 -3
  102. package/licenses.js +2 -2
  103. package/lineage-graphs.d.ts +1 -3
  104. package/lineage-graphs.js +2 -2
  105. package/ml.d.ts +1 -3
  106. package/ml.js +2 -2
  107. package/notes.d.ts +9 -3
  108. package/notes.js +6 -2
  109. package/notifications.d.ts +1 -3
  110. package/notifications.js +2 -2
  111. package/oauth-clients.d.ts +1 -3
  112. package/oauth-clients.js +2 -2
  113. package/oauth-tokens.d.ts +1 -3
  114. package/oauth-tokens.js +2 -2
  115. package/package.json +6 -2
  116. package/qix.d.ts +1 -47
  117. package/qix.js +1 -1
  118. package/questions.d.ts +1 -3
  119. package/questions.js +2 -2
  120. package/quotas.d.ts +1 -3
  121. package/quotas.js +2 -2
  122. package/reload-tasks.d.ts +1 -3
  123. package/reload-tasks.js +2 -2
  124. package/reloads.d.ts +1 -3
  125. package/reloads.js +2 -2
  126. package/report-templates.d.ts +3 -4
  127. package/report-templates.js +2 -2
  128. package/reports.d.ts +1 -3
  129. package/reports.js +2 -2
  130. package/roles.d.ts +1 -3
  131. package/roles.js +2 -2
  132. package/sharing-tasks.d.ts +1 -3
  133. package/sharing-tasks.js +2 -2
  134. package/spaces.d.ts +1 -3
  135. package/spaces.js +2 -2
  136. package/tasks.d.ts +1 -3
  137. package/tasks.js +2 -2
  138. package/temp-contents.d.ts +1 -3
  139. package/temp-contents.js +2 -2
  140. package/tenant-settings.d.ts +1 -3
  141. package/tenant-settings.js +2 -2
  142. package/tenants.d.ts +2 -4
  143. package/tenants.js +2 -2
  144. package/themes.d.ts +1 -3
  145. package/themes.js +2 -2
  146. package/transports.d.ts +1 -3
  147. package/transports.js +2 -2
  148. package/ui-config.d.ts +1 -3
  149. package/ui-config.js +2 -2
  150. package/users.d.ts +1 -3
  151. package/users.js +2 -2
  152. package/web-integrations.d.ts +1 -3
  153. package/web-integrations.js +2 -2
  154. package/web-notifications.d.ts +1 -3
  155. package/web-notifications.js +2 -2
  156. package/webhooks.d.ts +7 -9
  157. package/webhooks.js +2 -2
  158. package/workflows/automation-connections.d.ts +317 -0
  159. package/workflows/automation-connections.js +164 -0
  160. package/workflows/automation-connectors.d.ts +79 -0
  161. package/workflows/automation-connectors.js +40 -0
  162. package/workflows/automations.d.ts +790 -0
  163. package/workflows/automations.js +421 -0
  164. package/workflows.d.ts +16 -0
  165. package/workflows.js +18 -0
  166. package/chunks/platform-types-CECrZkOF.d.ts +0 -29
  167. /package/chunks/{dist-DR758NU5.js → dist-BcgFfLgM.js} +0 -0
  168. /package/chunks/{invoke-fetch-DFc3yzaj.d.ts → invoke-fetch-DcuB8t5I.d.ts} +0 -0
  169. /package/chunks/{utils-jkpLuYZR.js → utils-B7chC9_U.js} +0 -0
  170. /package/chunks/{websocket-errors-C5U1tba-.js → websocket-errors-C6cw1uQN.js} +0 -0
@@ -1,6 +1,5 @@
1
- import { a as sortKeys, i as isNode, r as isBrowser, t as cleanFalsyValues } from "./utils-jkpLuYZR.js";
1
+ import { a as sortKeys, i as isNode, r as isBrowser, t as cleanFalsyValues } from "./utils-B7chC9_U.js";
2
2
  import { authTypesThatCanBeOmitted, hostConfigCommonProperties } from "../auth-types.js";
3
- import { getInterceptors } from "../interceptors.js";
4
3
 
5
4
  //#region src/platform/platform-functions.ts
6
5
  const getPlatform = async (options = {}) => {
@@ -353,11 +352,17 @@ function saveInLocalStorage(topic, name, value) {
353
352
  function saveInSessionStorage(topic, name, value) {
354
353
  sessionStorage.setItem(`${storagePrefix}-${topic}-${name}`, value);
355
354
  }
355
+ function saveInCustomSecretStorage(storage, topic, name, value) {
356
+ return storage.store(`${storagePrefix}-${topic}-${name}`, value);
357
+ }
356
358
  function loadFromLocalStorage(topic, name) {
357
- return localStorage.getItem(`${storagePrefix}-${topic}-${name}`) || void 0;
359
+ return localStorage.getItem(`${"qlik-qmfe-api"}-${topic}-${name}`) || void 0;
358
360
  }
359
361
  function loadFromSessionStorage(topic, name) {
360
- return sessionStorage.getItem(`${storagePrefix}-${topic}-${name}`) || void 0;
362
+ return sessionStorage.getItem(`${"qlik-qmfe-api"}-${topic}-${name}`) || void 0;
363
+ }
364
+ function loadFromCustomSecretStorage(storage, topic, name) {
365
+ return storage.get(`${storagePrefix}-${topic}-${name}`);
361
366
  }
362
367
  function deleteFromLocalStorage(topic, names) {
363
368
  names.forEach((name) => localStorage.removeItem(`${storagePrefix}-${topic}-${name}`));
@@ -365,13 +370,22 @@ function deleteFromLocalStorage(topic, names) {
365
370
  function deleteFromSessionStorage(topic, names) {
366
371
  names.forEach((name) => sessionStorage.removeItem(`${storagePrefix}-${topic}-${name}`));
367
372
  }
373
+ function deleteFromCustomSecretStorage(storage, topic, names) {
374
+ return Promise.all(names.map((name) => storage.delete(`${storagePrefix}-${topic}-${name}`)));
375
+ }
368
376
  function loadAndDeleteFromSessionStorage(topic, name) {
369
377
  const id = `${storagePrefix}-${topic}-${name}`;
370
378
  const result = sessionStorage.getItem(id) || void 0;
371
379
  sessionStorage.removeItem(id);
372
380
  return result;
373
381
  }
374
- function loadOauthTokensFromStorage(topic, accessTokenStorage) {
382
+ /**
383
+ * Returns true if the provided storage object implements the SecretStorage interface, false otherwise.
384
+ */
385
+ function isCustomSecretStorage(storage) {
386
+ return typeof storage === "object" && storage !== null && typeof storage.store === "function" && typeof storage.get === "function" && typeof storage.delete === "function";
387
+ }
388
+ async function loadOauthTokensFromStorage(topic, accessTokenStorage) {
375
389
  let accessToken;
376
390
  let refreshToken;
377
391
  if (accessTokenStorage === "local") {
@@ -380,6 +394,9 @@ function loadOauthTokensFromStorage(topic, accessTokenStorage) {
380
394
  } else if (accessTokenStorage === "session") {
381
395
  accessToken = loadFromSessionStorage(topic, "access-token");
382
396
  refreshToken = loadFromSessionStorage(topic, "refresh-token");
397
+ } else if (isCustomSecretStorage(accessTokenStorage)) {
398
+ accessToken = await loadFromCustomSecretStorage(accessTokenStorage, topic, "access-token");
399
+ refreshToken = await loadFromCustomSecretStorage(accessTokenStorage, topic, "refresh-token");
383
400
  }
384
401
  if (accessToken) return {
385
402
  accessToken,
@@ -399,25 +416,23 @@ async function loadOrAcquireAccessTokenAnon(hostConfig, acquireTokens) {
399
416
  }
400
417
  async function loadOrAcquireAccessToken(topic, acquireTokens, noCache, accessTokenStorage) {
401
418
  if (noCache) return acquireTokens();
402
- const mayUseStorage = isBrowser();
403
- const storedOauthTokens = cachedTokens[topic] || (mayUseStorage ? loadOauthTokensFromStorage(topic, accessTokenStorage) : void 0);
404
- if (storedOauthTokens) {
405
- cachedTokens[topic] = storedOauthTokens;
406
- return Promise.resolve(storedOauthTokens);
407
- }
408
- const tokensPromise = acquireTokens();
409
- cachedTokens[topic] = tokensPromise;
410
- if (mayUseStorage) {
411
- const tokens = await tokensPromise;
419
+ cachedTokens[topic] = cachedTokens[topic] || (async () => {
420
+ let tokens = await loadOauthTokensFromStorage(topic, accessTokenStorage);
421
+ if (tokens) return tokens;
422
+ tokens = await acquireTokens();
412
423
  if (accessTokenStorage === "local" && tokens) {
413
424
  if (tokens.accessToken) saveInLocalStorage(topic, "access-token", tokens.accessToken);
414
425
  if (tokens.refreshToken) saveInLocalStorage(topic, "refresh-token", tokens.refreshToken);
415
426
  } else if (accessTokenStorage === "session" && tokens) {
416
427
  if (tokens.accessToken) saveInSessionStorage(topic, "access-token", tokens.accessToken);
417
428
  if (tokens.refreshToken) saveInSessionStorage(topic, "refresh-token", tokens.refreshToken);
429
+ } else if (isCustomSecretStorage(accessTokenStorage) && tokens) {
430
+ if (tokens.accessToken) await saveInCustomSecretStorage(accessTokenStorage, topic, "access-token", tokens.accessToken);
431
+ if (tokens.refreshToken) await saveInCustomSecretStorage(accessTokenStorage, topic, "refresh-token", tokens.refreshToken);
418
432
  }
419
- }
420
- return tokensPromise;
433
+ return tokens;
434
+ })();
435
+ return cachedTokens[topic];
421
436
  }
422
437
  function clearStoredOauthTokens(hostConfig) {
423
438
  const topic = getTopicFromOauthHostConfig(hostConfig);
@@ -426,6 +441,7 @@ function clearStoredOauthTokens(hostConfig) {
426
441
  deleteFromLocalStorage(topic, ["access-token", "refresh-token"]);
427
442
  deleteFromSessionStorage(topic, ["access-token", "refresh-token"]);
428
443
  }
444
+ if (isCustomSecretStorage(hostConfig.accessTokenStorage)) deleteFromCustomSecretStorage(hostConfig.accessTokenStorage, topic, ["access-token", "refresh-token"]);
429
445
  }
430
446
  function clearStoredAnonymousTokens(hostConfig) {
431
447
  const topic = getTopicFromAnonHostConfig(hostConfig);
@@ -624,9 +640,10 @@ async function getAnonymousOauthAccessToken(baseUrl, accessCode, clientId, track
624
640
  * This code is intended to run in a node environment
625
641
  */
626
642
  async function getOAuthTokensForNode(hostConfig) {
627
- const { clientId, clientSecret } = hostConfig;
628
- if (!clientId || !clientSecret) throw new InvalidHostConfigError("A host config with authType set to \"oauth2\" has to provide a clientId and a clientSecret");
643
+ const { clientId, clientSecret, performInteractiveLogin } = hostConfig;
644
+ if (!clientId || !clientSecret && !performInteractiveLogin) throw new InvalidHostConfigError("A host config with authType set to \"oauth2\" has to provide a clientId and a clientSecret or a performInteractiveLogin function");
629
645
  return await loadOrAcquireAccessTokenOauth(hostConfig, async () => {
646
+ if (hostConfig.performInteractiveLogin) return getOauthTokensWithInteractiveLogin(hostConfig);
630
647
  if (!hostConfig.clientId || !hostConfig.clientSecret) throw new InvalidHostConfigError("A host config with authType set to \"oauth2\" has to provide a clientId and a clientSecret");
631
648
  return getOauthTokensWithCredentials(toValidLocationUrl(hostConfig), hostConfig.clientId, hostConfig.clientSecret, hostConfig.scope, hostConfig.subject, hostConfig.userId);
632
649
  });
@@ -648,32 +665,7 @@ async function getOAuthTokensForBrowser(hostConfig) {
648
665
  } catch {
649
666
  return errorMessageToAuthData("Could not fetch access token using custom function");
650
667
  }
651
- if (hostConfig.performInteractiveLogin) {
652
- let usedRedirectUri;
653
- try {
654
- const verifier = generateRandomString(128);
655
- const originalState = generateRandomString(43);
656
- const { code, state } = extractCodeAndState(await toPerformInteractiveLoginFunction(hostConfig.performInteractiveLogin)({ getLoginUrl: async ({ redirectUri }) => {
657
- usedRedirectUri = redirectUri;
658
- return createInteractiveLoginUrl(hostConfig, redirectUri, originalState, verifier);
659
- } }));
660
- if (!usedRedirectUri) return errorMessageToAuthData("No redirect uri provided");
661
- if (originalState !== state) return errorMessageToAuthData("State returned by custom interactive login function does not match original");
662
- if (!code) return errorMessageToAuthData("No code found in response from custom interactive login function");
663
- return await exchangeCodeAndVerifierForAccessTokenData(hostConfig, code, verifier, usedRedirectUri);
664
- } catch (error) {
665
- return {
666
- accessToken: void 0,
667
- refreshToken: void 0,
668
- errors: [{
669
- code: "",
670
- status: 401,
671
- title: "Could not perform custom interactive login",
672
- detail: `${error}`
673
- }]
674
- };
675
- }
676
- }
668
+ if (hostConfig.performInteractiveLogin) return getOauthTokensWithInteractiveLogin(hostConfig);
677
669
  const topic = getTopicFromOauthHostConfig(hostConfig);
678
670
  const code = loadAndDeleteFromSessionStorage(topic, "code");
679
671
  const verifier = loadAndDeleteFromSessionStorage(topic, "verifier");
@@ -688,6 +680,33 @@ async function getOAuthTokensForBrowser(hostConfig) {
688
680
  startFullPageLoginFlow(hostConfig);
689
681
  return new Promise(() => {});
690
682
  }
683
+ async function getOauthTokensWithInteractiveLogin(hostConfig) {
684
+ if (!hostConfig.performInteractiveLogin) return errorMessageToAuthData("No performInteractiveLogin function in hostConfig");
685
+ let usedRedirectUri;
686
+ try {
687
+ const verifier = generateRandomString(128);
688
+ const originalState = generateRandomString(43);
689
+ const { code, state } = extractCodeAndState(await toPerformInteractiveLoginFunction(hostConfig.performInteractiveLogin)({ getLoginUrl: async ({ redirectUri }) => {
690
+ usedRedirectUri = redirectUri;
691
+ return createInteractiveLoginUrl(hostConfig, redirectUri, originalState, verifier);
692
+ } }));
693
+ if (!usedRedirectUri) return errorMessageToAuthData("No redirect uri provided");
694
+ if (originalState !== state) return errorMessageToAuthData("State returned by custom interactive login function does not match original");
695
+ if (!code) return errorMessageToAuthData("No code found in response from custom interactive login function");
696
+ return await exchangeCodeAndVerifierForAccessTokenData(hostConfig, code, verifier, usedRedirectUri);
697
+ } catch (error) {
698
+ return {
699
+ accessToken: void 0,
700
+ refreshToken: void 0,
701
+ errors: [{
702
+ code: "",
703
+ status: 401,
704
+ title: "Could not perform custom interactive login",
705
+ detail: `${error}`
706
+ }]
707
+ };
708
+ }
709
+ }
691
710
  let lastOauthTokensCall = Promise.resolve("");
692
711
  async function getOAuthAccessToken(hostConfig) {
693
712
  if (isNode()) {
@@ -721,7 +740,13 @@ async function refreshAccessToken(hostConfig) {
721
740
  }
722
741
  function extractCodeAndState(input) {
723
742
  if (typeof input === "string") {
724
- const queryParams = new URLSearchParams(new URL(input).search);
743
+ let parsedUrl;
744
+ try {
745
+ parsedUrl = new URL(input);
746
+ } catch {
747
+ parsedUrl = new URL(input, "http://localhost");
748
+ }
749
+ const queryParams = new URLSearchParams(parsedUrl.search);
725
750
  return {
726
751
  code: queryParams.get("code") || "",
727
752
  state: queryParams.get("state") || ""
@@ -1149,7 +1174,7 @@ function toCacheKey({ url, query, headers, serializedHostConfig }) {
1149
1174
  function getPossibleCaches(api) {
1150
1175
  const caches = [];
1151
1176
  if (responseCaches[api]) caches.push(responseCaches[api]);
1152
- if (responseCaches[globalCacheNamespace]) caches.push(responseCaches[globalCacheNamespace]);
1177
+ if (responseCaches[".global"]) caches.push(responseCaches[globalCacheNamespace]);
1153
1178
  return caches;
1154
1179
  }
1155
1180
  /**
@@ -1857,11 +1882,11 @@ async function handleAuthenticationError$4({ hostConfig }) {
1857
1882
  retry: true
1858
1883
  };
1859
1884
  }
1885
+ if (hostConfig.performInteractiveLogin) {
1886
+ clearStoredOauthTokens(hostConfig);
1887
+ return { retry: true };
1888
+ }
1860
1889
  if (isBrowser()) {
1861
- if (hostConfig.performInteractiveLogin) {
1862
- clearStoredOauthTokens(hostConfig);
1863
- return { retry: true };
1864
- }
1865
1890
  await requestRedirect(hostConfig);
1866
1891
  startFullPageLoginFlow(hostConfig);
1867
1892
  return { preventDefault: true };
@@ -2663,4 +2688,105 @@ function populateCacheFrom(responses, pathsToInclude, serializedHostConfig, loca
2663
2688
  }
2664
2689
 
2665
2690
  //#endregion
2666
- export { appendQueryToUrl as A, AuthorizationError as C, clearApiCache as D, UnexpectedAuthTypeError as E, getPlatform as F, InvokeFetchError as M, exposeInternalApiOnWindow as N, invokeFetch as O, generateRandomString as P, unregisterHostConfig as S, InvalidHostConfigError as T, registerHostConfig as _, getRestCallAuthParams as a, toValidLocationUrl as b, handleAuthenticationError as c, logout as d, normalizeHostConfig as f, registerAuthModule as g, onPageRedirectStarted as h, getDefaultHostConfig as i, EncodingError as j, parseFetchResponse as k, isHostCrossOrigin as l, onPageRedirectRequested as m, determineAuthType as n, getWebResourceAuthParams as o, onFatalAuthError as p, getAccessToken as r, getWebSocketAuthParams as s, coreBootInterceptor as t, isWindows as u, serializeHostConfig as v, InvalidAuthTypeError as w, toValidWebsocketLocationUrl as x, setDefaultHostConfig as y };
2691
+ //#region src/interceptors/interceptors.ts
2692
+ let GLOBAL_INTERCEPTORS;
2693
+ function createInterceptors() {
2694
+ const interceptors = [...GLOBAL_INTERCEPTORS?.getInterceptors() || []];
2695
+ return {
2696
+ addInterceptor: (interceptor) => {
2697
+ interceptors.push(interceptor);
2698
+ return interceptor;
2699
+ },
2700
+ removeInterceptor: (interceptor) => {
2701
+ const index = interceptors.indexOf(interceptor);
2702
+ let removed;
2703
+ if (index !== -1) removed = interceptors.splice(index, 1)[0];
2704
+ return removed || null;
2705
+ },
2706
+ getInterceptors: () => interceptors
2707
+ };
2708
+ }
2709
+ let addDefaultInterceptorsRun = false;
2710
+ function addDefaultInterceptors() {
2711
+ if (addDefaultInterceptorsRun) return;
2712
+ if (isBrowser()) {
2713
+ const readFlagsFromUrlQuery = () => {
2714
+ const featuresParam = new URLSearchParams(window.location.search).get("features");
2715
+ if (!featuresParam) return {};
2716
+ return featuresParam.split(",").map((item) => item.trim()).reduce((map, obj) => {
2717
+ const value = !obj.startsWith("!");
2718
+ const key = value ? obj : obj.substring(1);
2719
+ map[key] = value;
2720
+ return map;
2721
+ }, {});
2722
+ };
2723
+ const readFlagsFromLocalStorage = () => {
2724
+ try {
2725
+ const featuresParam = localStorage.getItem("qcs-features");
2726
+ if (featuresParam) return JSON.parse(featuresParam);
2727
+ return {};
2728
+ } catch {
2729
+ return {};
2730
+ }
2731
+ };
2732
+ const flagsFromUrl = readFlagsFromUrlQuery();
2733
+ const flagsFromLocalStorage = readFlagsFromLocalStorage();
2734
+ const featuresInterceptor = async (request, proceed) => {
2735
+ let resultPromise;
2736
+ if (request.pathTemplate === "/api/v1/features") {
2737
+ resultPromise = proceed(request);
2738
+ const result = await resultPromise;
2739
+ return {
2740
+ ...result,
2741
+ data: {
2742
+ ...result.data || {},
2743
+ ...flagsFromLocalStorage,
2744
+ ...flagsFromUrl
2745
+ }
2746
+ };
2747
+ }
2748
+ return proceed(request);
2749
+ };
2750
+ GLOBAL_INTERCEPTORS.addInterceptor(featuresInterceptor);
2751
+ GLOBAL_INTERCEPTORS.addInterceptor(coreBootInterceptor);
2752
+ }
2753
+ addDefaultInterceptorsRun = true;
2754
+ }
2755
+ /**
2756
+ * The global interceptor stack
2757
+ */
2758
+ GLOBAL_INTERCEPTORS = createInterceptors();
2759
+ /**
2760
+ * Adds an interceptor to the global interceptor stack
2761
+ * Returns the newly added interceptor
2762
+ * @param interceptor the interceptor to add
2763
+ * @returns the newly added interceptor
2764
+ */
2765
+ function addInterceptor(interceptor) {
2766
+ return GLOBAL_INTERCEPTORS.addInterceptor(interceptor);
2767
+ }
2768
+ /**
2769
+ * Removes an interceptor from the global interceptor stack
2770
+ * @param interceptor the interceptor remove
2771
+ */
2772
+ function removeInterceptor(interceptor) {
2773
+ return GLOBAL_INTERCEPTORS.removeInterceptor(interceptor);
2774
+ }
2775
+ /**
2776
+ * Gets all registered interceptors
2777
+ */
2778
+ function getInterceptors() {
2779
+ return GLOBAL_INTERCEPTORS.getInterceptors();
2780
+ }
2781
+ /**
2782
+ * The interceptors API
2783
+ */
2784
+ const interceptors = {
2785
+ addInterceptor,
2786
+ removeInterceptor,
2787
+ getInterceptors,
2788
+ createInterceptors
2789
+ };
2790
+
2791
+ //#endregion
2792
+ export { InvalidHostConfigError as A, getPlatform as B, serializeHostConfig as C, unregisterHostConfig as D, toValidWebsocketLocationUrl as E, appendQueryToUrl as F, EncodingError as I, InvokeFetchError as L, clearApiCache as M, invokeFetch as N, AuthorizationError as O, parseFetchResponse as P, exposeInternalApiOnWindow as R, registerHostConfig as S, toValidLocationUrl as T, normalizeHostConfig as _, interceptors as a, onPageRedirectStarted as b, getAccessToken as c, getWebResourceAuthParams as d, getWebSocketAuthParams as f, logout as g, isWindows as h, getInterceptors as i, UnexpectedAuthTypeError as j, InvalidAuthTypeError as k, getDefaultHostConfig as l, isHostCrossOrigin as m, addInterceptor as n, removeInterceptor as o, handleAuthenticationError as p, createInterceptors as r, determineAuthType as s, addDefaultInterceptors as t, getRestCallAuthParams as u, onFatalAuthError as v, setDefaultHostConfig as w, registerAuthModule as x, onPageRedirectRequested as y, generateRandomString as z };
@@ -1,4 +1,4 @@
1
- import { D as clearApiCache, M as InvokeFetchError, O as invokeFetch, j as EncodingError, k as parseFetchResponse } from "./boot-interceptors-DqRxTczb.js";
1
+ import { I as EncodingError, L as InvokeFetchError, M as clearApiCache, N as invokeFetch, P as parseFetchResponse } from "./interceptors-DMiDeqEz.js";
2
2
 
3
3
  //#region src/invoke-fetch/invoke-fetch.ts
4
4
  /**
@@ -1,8 +1,8 @@
1
- import { r as isBrowser } from "./utils-jkpLuYZR.js";
2
- import { n as getInvokeFetchRuntimeModule } from "./public-runtime-modules-2KfyI2qM.js";
1
+ import { r as isBrowser } from "./utils-B7chC9_U.js";
2
+ import { n as getInvokeFetchRuntimeModule } from "./public-runtime-modules-mBjjPn7I.js";
3
3
 
4
4
  //#region src/public/invoke-fetch.ts
5
- const defaultUserAgent = "qlik-api/2.4.1";
5
+ const defaultUserAgent = "qlik-api/2.5.0";
6
6
  async function invokeFetch(api, props) {
7
7
  const hostConfig = props.options?.hostConfig;
8
8
  let userAgent;
@@ -1,4 +1,4 @@
1
- import { i as isNode$1 } from "./utils-jkpLuYZR.js";
1
+ import { i as isNode$1 } from "./utils-B7chC9_U.js";
2
2
 
3
3
  //#region src/public/public-runtime-modules.ts
4
4
  const isNode = isNode$1();
@@ -6,24 +6,24 @@ const importRuntimeModulePromise = (async () => {
6
6
  if (isNode) return () => {
7
7
  throw new Error("importRuntimeModule cannot be used in a Node.js context");
8
8
  };
9
- return (await import("./dist-DR758NU5.js")).importRuntimeModule;
9
+ return (await import("./dist-BcgFfLgM.js")).importRuntimeModule;
10
10
  })();
11
11
  /**
12
12
  * @param hostConfig
13
13
  * @returns
14
14
  */
15
15
  async function getAuthRuntimeModule(hostConfig) {
16
- if (isNode) return import("./auth-B8lJw7rm.js");
16
+ if (isNode) return import("./auth-Cfg2Smt8.js");
17
17
  return (await importRuntimeModulePromise)("auth@v1", hostConfig);
18
18
  }
19
19
  async function getQixRuntimeModule(hostConfig) {
20
20
  await getAuthRuntimeModule(hostConfig);
21
- if (isNode) return import("./qix-BdNrIA4s.js");
21
+ if (isNode) return import("./qix-BPCl6Bmh.js");
22
22
  return (await importRuntimeModulePromise)("qix@v1", hostConfig);
23
23
  }
24
24
  async function getInvokeFetchRuntimeModule(hostConfig) {
25
25
  await getAuthRuntimeModule(hostConfig);
26
- if (isNode) return import("./invoke-fetch-pMN6iqup.js");
26
+ if (isNode) return import("./invoke-fetch-CwBXAsw4.js");
27
27
  return (await importRuntimeModulePromise)("invoke-fetch@v1", hostConfig);
28
28
  }
29
29
 
@@ -1,6 +1,6 @@
1
- import { r as isBrowser } from "./utils-jkpLuYZR.js";
2
- import { F as getPlatform, O as invokeFetch, c as handleAuthenticationError, u as isWindows, x as toValidWebsocketLocationUrl } from "./boot-interceptors-DqRxTczb.js";
3
- import { t as getHumanReadableSocketClosedErrorMessage } from "./websocket-errors-C5U1tba-.js";
1
+ import { r as isBrowser } from "./utils-B7chC9_U.js";
2
+ import { B as getPlatform, E as toValidWebsocketLocationUrl, N as invokeFetch, h as isWindows, p as handleAuthenticationError } from "./interceptors-DMiDeqEz.js";
3
+ import { t as getHumanReadableSocketClosedErrorMessage } from "./websocket-errors-C6cw1uQN.js";
4
4
 
5
5
  //#region src/qix/app-session.ts
6
6
  const isBrowserEnvironment = isBrowser();
@@ -199,7 +199,7 @@ function listenForWindowsAuthenticationInformation(session) {
199
199
  * Opens the websocket and handles a few windows authentication details
200
200
  */
201
201
  async function createAndSetupEnigmaSession(props, canRetry, onWebSocketEvent) {
202
- const { createEnigmaSessionEntrypoint } = await import("./qix-chunk-entrypoint-L9RpWwLK.js");
202
+ const { createEnigmaSessionEntrypoint } = await import("./qix-chunk-entrypoint-CyQYGyl2.js");
203
203
  const session = await createEnigmaSessionEntrypoint(props);
204
204
  setupSessionListeners(session, props, onWebSocketEvent);
205
205
  let global;
@@ -445,7 +445,7 @@ function createSharedPhoenixSession(props, { onClose, onWebSocketEvent: onWebSoc
445
445
  onWebSocketEventGlobal(event);
446
446
  for (const client of clients) client.onWebSocketEvent(event);
447
447
  };
448
- const phoenixConnectionPromise = import("./qix-chunk-entrypoint-L9RpWwLK.js").then((module) => {
448
+ const phoenixConnectionPromise = import("./qix-chunk-entrypoint-CyQYGyl2.js").then((module) => {
449
449
  return module.createPhoenixConnectionEntrypoint(props, {
450
450
  onWebSocketEvent,
451
451
  getInitialAppActions
@@ -1,7 +1,7 @@
1
- import { HostConfig } from "../auth-types.js";
1
+ import { d as HostConfig } from "./auth-types-DVvka7Hz.js";
2
2
 
3
3
  //#region src/qix/types/engine-schema.d.ts
4
- declare const QIX_SCHEMA_VERSION = "12.2703.0";
4
+ declare const QIX_SCHEMA_VERSION = "12.2731.0";
5
5
  type AlfaNumString = {
6
6
  /**
7
7
  * Calculated value.
@@ -12315,4 +12315,47 @@ type NativeReactHooks = {
12315
12315
  */
12316
12316
  type UseAppHook = (appIdOrProps: string | OpenAppSessionProps) => Doc | undefined;
12317
12317
  //#endregion
12318
- export { MeasureListData as $, OleDbProvider as $a, NxListObjectExpressionDef as $i, GenericObjectEntry as $n, StateEnumType as $o, NxCalcCond as $r, DataTableEx as $t, GenericObjectLayoutNodeLevel4 as A, NxSortIndicatorType as Aa, NxFieldSelectionMode as Ai, FieldList as An, SearchGroupItem as Ao, MediaListItem as Ar, VariableListDef as As, BookmarkFieldPage as At, UndoInfoObject as B, NxTreeMultiRangeSelectInfo as Ba, NxHighlightRanges as Bi, FolderItem as Bn, SearchResult as Bo, NativeVariableFunctions as Br, CharRange as Bt, GenericDimension as C, NxRange as Ca, NxExportFileType as Ci, FailureData as Cn, SearchFieldDictionary as Co, ListObject as Cr, TreeDataDef as Cs, BNFDef as Ct, GenericObjectLayoutNode as D, NxSelectionInfo as Da, NxFieldProperties as Di, FieldDescription as Dn, SearchFieldSelectionMode as Do, MeasureList as Dr, ValueExpr as Ds, Bookmark as Dt, GenericObject as E, NxSelectionCellType as Ea, NxFieldDescription as Ei, FieldDefEx as En, SearchFieldMatchesItem as Eo, LogOnType as Er, UsageEnum as Es, Blob as Et, GenericObjectPropertiesNodeLevel3 as F, NxTempBookmarkOptions as Fa, NxGroupDef as Fi, FieldValue as Fn, SearchGroupType as Fo, NativeGenericDimensionFunctions as Fr, BookmarkListDef as Ft, DimensionListItem as G, NxTrendlineDef as Ga, NxLTrendlineType as Gi, GenericBookmarkLayout as Gn, SearchValuePage as Go, NxAttrExprDef as Gr, Connection as Gt, BookmarkListData as H, NxTreeRangeSelectInfo as Ha, NxInfo as Hi, FrequencyDistributionData as Hn, SearchSuggestionResult as Ho, NxAppProperties as Hr, ChildListDef as Ht, GenericObjectPropertiesNodeLevel4 as I, NxTickCell as Ia, NxGroupMemberClass as Ii, FileDataFormat as In, SearchMatchCombination as Io, NativeGenericMeasureFunctions as Ir, BookmarkStateFieldPages as It, ExpandedFieldListItem as J, NxVariableListItem as Ja, NxLibraryDimensionDef as Ji, GenericDimensionInfo as Jn, SelectionObject as Jo, NxAttributeExpressionValues as Jr, CustomConnector as Jt, DynamicAppViewListData as K, NxTrendlineMode as Ka, NxLayoutErrors as Ki, GenericBookmarkProperties as Kn, SearchValueResult as Ko, NxAttrExprInfo as Kr, ContentLibraryList as Kt, GenericObjectPropertiesNodeLevel5 as L, NxTreeDataOption as La, NxGroupObjectId as Li, FileType as Ln, SearchMatchCombinations as Lo, NativeGenericObjectFunctions as Lr, BookmarkVariableItem as Lt, GenericObjectLayoutNodeRec as M, NxStackedPivotCell as Ma, NxFrequencyMode as Mi, FieldOrColumn as Mn, SearchGroupItemOptions as Mo, NativeDocFunctions as Mr, BookmarkFieldVerifyResultState as Mt, GenericObjectPropertiesNode as N, NxStateCounts as Na, NxGetBookmarkOptions as Ni, FieldScores as Nn, SearchGroupItemType as No, NativeFieldFunctions as Nr, BookmarkFieldVerifyWarning as Nt, GenericObjectLayoutNodeLevel2 as O, NxSimpleDimValue as Oa, NxFieldResourceId as Oi, FieldInTableData as On, SearchFieldValueItem as Oo, MeasureListDef as Or, ValueExpression as Os, BookmarkApplyAndVerifyResult as Ot, GenericObjectPropertiesNodeLevel2 as P, NxStreamListEntry as Pa, NxGetObjectOptions as Pi, FieldType as Pn, SearchGroupOptions as Po, NativeGenericBookmarkFunctions as Pr, BookmarkList as Pt, MasterObjectListItem as Q, OdbcDsn as Qa, NxListObjectExpression as Qi, GenericMeasureProperties as Qn, SourceKeyRecord as Qo, NxBookmark as Qr, DataTable as Qt, GenericObjectPropertiesNodeRec as R, NxTreeDimensionDef as Ra, NxGroupTail as Ri, FilterInfo as Rn, SearchObjectOptions as Ro, NativeGenericVariableFunctions as Rr, CalendarStrings as Rt, GenericBookmark as S, NxPivotValuePoint as Sa, NxEngineVersion as Si, ExtensionListDef as Sn, SearchContextType as So, LineageInfo as Sr, TreeData as Ss, AssociationScore as St, GenericMeasure as T, NxSelectionCell as Ta, NxFeature as Ti, FieldAttributes as Tn, SearchFieldMatchType as To, LocaleInfo as Tr, UndoInfoDef as Ts, BNFType as Tt, BookmarkListItem as U, NxTreeValue as Ua, NxInlineDimensionDef as Ui, FunctionGroup as Un, SearchTermResult as Uo, NxAttrDimDef as Ur, CodePage as Ut, RpcObject as V, NxTreeNode as Va, NxHypercubeMode as Vi, FolderItemType as Vn, SearchSuggestItem as Vo, NxAppLayout as Vr, ChildList as Vt, DimensionListData as W, NxTrendline as Wa, NxInlineMeasureDef as Wi, GenericBookmarkEntry as Wn, SearchValueOptions as Wo, NxAttrDimInfo as Wr, CondDef as Wt, ListItem as X, NxViewPort as Xa, NxLibraryMeasureDef as Xi, GenericDimensionProperties as Xn, Size as Xo, NxAxisData as Xr, DataField as Xt, ListBoxProperties as Y, NxVariableProperties as Ya, NxLibraryMeasure as Yi, GenericDimensionLayout as Yn, SelectionObjectDef as Yo, NxAutoSortByStateDef as Yr, CyclicGroupPosition as Yt, MasterObjectListData as Z, ObjectInterface as Za, NxLinkedObjectInfo as Zi, GenericMeasureLayout as Zn, SortCriteria as Zo, NxAxisTicks as Zr, DataRecord as Zt, AnyGenericObjectLayout as _, NxPatch as _a, NxDimension as _i, ErrorDataCode as _n, ScrollPosition as _o, InteractType as _r, TableViewTableWinSaveInfo as _s, AppScriptMeta as _t, OpenAppSessionProps as a, NxMeasureInfo as aa, NxContinuousDataOptions as ai, DimensionList as an, PositionMark as ao, GenericVariableLayout as ar, StringExpr as as, SheetListDataCellBounds as at, Field as b, NxPivotDimensionCell as ba, NxDownloadInfo as bi, ExtendedPivotStateData as bn, SearchCharRange as bo, LayoutExclude as br, TransformAppParameters as bs, ApplyGroupStatesResult as bt, CombinedWebSocketStateEvent as c, NxMiniChart as ca, NxCurrentSelectionItem as ci, DoReloadExParams as cn, QFunction as co, GraphMode as cr, SymbolValue as cs, StoryListItem as ct, ListFunctions as d, NxMiniChartDef as da, NxDataReductionMode as di, DriveInfo as dn, QRange as do, GroupStateInfo as dr, TableRow as ds, AlfaNumString as dt, NxLocalizedErrorCode as ea, NxCardinalities as ei, Database as en, OtherLimitMode as eo, GenericObjectLayout as er, StateFieldValues as es, MeasureListItem as et, ModalFunctions as f, NxMiniChartRows as fa, NxDerivedField as fi, DriveType as fn, RangeSelectInfo as fo, HyperCube as fr, TableViewBroomPointSaveInfo as fs, AlternateStateData as ft, Global as g, NxPageTreeNode as ga, NxDimCellType as gi, ErrorData as gn, ScriptSyntaxError as go, InteractDef as gr, TableViewSaveInfo as gs, AppScript as gt, StandardFunctions as h, NxPageTreeLevel as ha, NxDerivedGroup as hi, EmbeddedSnapshotDef as hn, SampleResult as ho, InterFieldSortData as hr, TableViewDlgSaveInfo as hs, AppObjectListDef as ht, NativeReactHooks as i, NxMeasure as ia, NxContainerEntry as ii, DerivedFieldsInTableData as in, Point as io, GenericVariableConstraints as ir, StaticContentUrlDef as is, SheetListDataCell as it, GenericObjectLayoutNodeLevel5 as j, NxStackPage as ja, NxFieldTableResourceId as ji, FieldListDef as jn, SearchGroupItemMatch as jo, MetaData as jr, BookmarkFieldPageEx as jt, GenericObjectLayoutNodeLevel3 as k, NxSimpleValue as ka, NxFieldSelectionInfo as ki, FieldInTableProfilingData as kn, SearchGroup as ko, MediaListDef as kr, VariableList as ks, BookmarkFieldItem as kt, WebSocketEvent as l, NxMiniChartCell as la, NxDataAreaPage as li, DoReloadExResult as ln, QIX_SCHEMA_VERSION as lo, GroupBookmarkData as lr, TableProfilingData as ls, VariableListData as lt, SpecialObjectFunctions as m, NxPage as ma, NxDerivedFieldsData as mi, EmbeddedSnapshot as mn, ReloadError as mo, InputFieldItem as mr, TableViewCtlSaveInfo as ms, AppObjectList as mt, CloseProps as n, NxMatchingFieldInfo as na, NxCellPosition as ni, DatabaseOwner as nn, OtherSortMode as no, GenericObjectProperties as nr, StaticContentListItem as ns, ODAGAppLinkListItem as nt, UseAppHook as o, NxMeta as oa, NxContinuousMode as oi, DimensionListDef as on, ProgressData as oo, GenericVariableProperties as or, StringExpression as os, SheetListItem as ot, ObjectHelperFunctions as p, NxMultiRangeSelectInfo as pa, NxDerivedFieldDescriptionList as pi, EditorBreakpoint as pn, Rect as po, HyperCubeDef as pr, TableViewConnectionPointSaveInfo as ps, AppEntry as pt, DynamicAppViewListItem as q, NxValidationError as qa, NxLibraryDimension as qi, GenericConnectMachine as qn, SelectInfo as qo, NxAttributeDimValues as qr, ContentLibraryListItem as qt, DocAction as r, NxMatchingFieldMode as ra, NxCellRows as ri, DelimiterInfo as rn, OtherTotalSpecProp as ro, GenericObjectPropertiesAdditionalProperties as rr, StaticContentUrl as rs, SheetListData as rt, WorkloadType as s, NxMetaDef as sa, NxContinuousRangeSelectInfo as si, DimensionReference as sn, ProgressMessage as so, GenericVariableType as sr, SymbolFrequency as ss, StoryListData as st, AppSession as t, NxLocalizedWarningCode as ta, NxCell as ti, DatabaseInfo as tn, OtherMode as to, GenericObjectLayoutAdditionalProperties as tr, StaticContentList as ts, ODAGAppLinkListData as tt, Doc as u, NxMiniChartData as ua, NxDataPage as ui, DocListEntry as un, QMediaList as uo, GroupState as ur, TableRecord as us, VariableListItem as ut, AnyGenericObjectProperties as v, NxPatchOperationType as va, NxDimensionInfo as vi, ExpansionData as vn, SearchAssociationResult as vo, KeyType as vr, TextMacro as vs, ApplyGroupStateWarning as vt, GenericListObject as w, NxRangeSelectInfo as wa, NxExportState as wi, FieldAttrType as wn, SearchFieldMatch as wo, ListObjectDef as wr, UndoInfo as ws, BNFDefMetaType as wt, FieldListObject as x, NxPivotPage as xa, NxDownloadOptions as xi, ExtensionList as xn, SearchCombinationOptions as xo, LayoutFieldInfo as xr, TransformAppResult as xs, ArrayOfNxValuePoint as xt, CurrentSelections as y, NxPatches as ya, NxDimensionType as yi, ExtendedLayoutBookmarkData as yn, SearchAttribute as yo, LayoutBookmarkData as yr, TotalMode as ys, ApplyGroupStateWarningType as yt, GenericVariable as z, NxTreeDimensionInfo as za, NxGrpType as zi, FilterType as zn, SearchPage as zo, NativeGlobalFunctions as zr, CharEncodingType as zt };
12318
+ //#region src/public/qix.d.ts
12319
+ declare function openAppSession(appSessionProps: OpenAppSessionProps): {
12320
+ /**
12321
+ * Returns a promise of the Qix Doc object with a set of client-side Api extensions.
12322
+ * Note that while the AppSession object is returned immediately this promise might take a while
12323
+ * to resolve for bigger apps.
12324
+ */
12325
+ getDoc(): Promise<Doc>;
12326
+ /**
12327
+ * @experimental
12328
+ * Add an event-listener for this app-session.
12329
+ */
12330
+ onWebSocketEvent(listener: (event: WebSocketEvent) => void): () => void;
12331
+ /**
12332
+ * @experimental
12333
+ * Resume a suspended session. This will resume exactly
12334
+ * once if the session is currently suspended, otherwise
12335
+ * nothing will be done.
12336
+ */
12337
+ resume(): Promise<void>;
12338
+ /**
12339
+ * When the app session is no longer in use it must be closed using this function.
12340
+ * If the same underlying enigma websocket is used somewhere else in the browser
12341
+ * this is basically a no op, but if this is the last/only usage
12342
+ * of the underlying enigma websocket that websocket will be closed.
12343
+ */
12344
+ close(props?: CloseProps): Promise<void>;
12345
+ };
12346
+ interface QixAPI {
12347
+ /**
12348
+ * Open a qix session in engine on the current domain for the supplied appId. If the same app is opened multiple times
12349
+ * only a single enigma websocket session is opened and shared.
12350
+ * When all open sessions are closed again the shared enigma websocket session is also closed.
12351
+ * @param appId The resource id of the app to open
12352
+ * @param host Configuration of what host to connect to
12353
+ */
12354
+ openAppSession: typeof openAppSession;
12355
+ }
12356
+ declare function withHostConfig(hostConfig: HostConfig | undefined): QixAPI;
12357
+ declare const qix: QixAPI & {
12358
+ withHostConfig: (hostConfig: HostConfig | undefined) => QixAPI;
12359
+ };
12360
+ //#endregion
12361
+ export { ListBoxProperties as $, NxVariableProperties as $a, NxLibraryMeasure as $i, GenericDimensionLayout as $n, SelectionObjectDef as $o, NxAutoSortByStateDef as $r, CyclicGroupPosition as $t, GenericObject as A, NxSelectionCellType as Aa, NxFieldDescription as Ai, FieldDefEx as An, SearchFieldMatchesItem as Ao, LogOnType as Ar, UsageEnum as As, Blob as At, GenericObjectPropertiesNodeLevel4 as B, NxTickCell as Ba, NxGroupMemberClass as Bi, FileDataFormat as Bn, SearchMatchCombination as Bo, NativeGenericMeasureFunctions as Br, BookmarkStateFieldPages as Bt, CurrentSelections as C, NxPatches as Ca, NxDimensionType as Ci, ExtendedLayoutBookmarkData as Cn, SearchAttribute as Co, LayoutBookmarkData as Cr, TotalMode as Cs, ApplyGroupStateWarningType as Ct, GenericDimension as D, NxRange as Da, NxExportFileType as Di, FailureData as Dn, SearchFieldDictionary as Do, ListObject as Dr, TreeDataDef as Ds, BNFDef as Dt, GenericBookmark as E, NxPivotValuePoint as Ea, NxEngineVersion as Ei, ExtensionListDef as En, SearchContextType as Eo, LineageInfo as Er, TreeData as Es, AssociationScore as Et, GenericObjectLayoutNodeLevel5 as F, NxStackPage as Fa, NxFieldTableResourceId as Fi, FieldListDef as Fn, SearchGroupItemMatch as Fo, MetaData as Fr, BookmarkFieldPageEx as Ft, RpcObject as G, NxTreeNode as Ga, NxHypercubeMode as Gi, FolderItemType as Gn, SearchSuggestItem as Go, NxAppLayout as Gr, ChildList as Gt, GenericObjectPropertiesNodeRec as H, NxTreeDimensionDef as Ha, NxGroupTail as Hi, FilterInfo as Hn, SearchObjectOptions as Ho, NativeGenericVariableFunctions as Hr, CalendarStrings as Ht, GenericObjectLayoutNodeRec as I, NxStackedPivotCell as Ia, NxFrequencyMode as Ii, FieldOrColumn as In, SearchGroupItemOptions as Io, NativeDocFunctions as Ir, BookmarkFieldVerifyResultState as It, DimensionListData as J, NxTrendline as Ja, NxInlineMeasureDef as Ji, GenericBookmarkEntry as Jn, SearchValueOptions as Jo, NxAttrDimInfo as Jr, CondDef as Jt, BookmarkListData as K, NxTreeRangeSelectInfo as Ka, NxInfo as Ki, FrequencyDistributionData as Kn, SearchSuggestionResult as Ko, NxAppProperties as Kr, ChildListDef as Kt, GenericObjectPropertiesNode as L, NxStateCounts as La, NxGetBookmarkOptions as Li, FieldScores as Ln, SearchGroupItemType as Lo, NativeFieldFunctions as Lr, BookmarkFieldVerifyWarning as Lt, GenericObjectLayoutNodeLevel2 as M, NxSimpleDimValue as Ma, NxFieldResourceId as Mi, FieldInTableData as Mn, SearchFieldValueItem as Mo, MeasureListDef as Mr, ValueExpression as Ms, BookmarkApplyAndVerifyResult as Mt, GenericObjectLayoutNodeLevel3 as N, NxSimpleValue as Na, NxFieldSelectionInfo as Ni, FieldInTableProfilingData as Nn, SearchGroup as No, MediaListDef as Nr, VariableList as Ns, BookmarkFieldItem as Nt, GenericListObject as O, NxRangeSelectInfo as Oa, NxExportState as Oi, FieldAttrType as On, SearchFieldMatch as Oo, ListObjectDef as Or, UndoInfo as Os, BNFDefMetaType as Ot, GenericObjectLayoutNodeLevel4 as P, NxSortIndicatorType as Pa, NxFieldSelectionMode as Pi, FieldList as Pn, SearchGroupItem as Po, MediaListItem as Pr, VariableListDef as Ps, BookmarkFieldPage as Pt, ExpandedFieldListItem as Q, NxVariableListItem as Qa, NxLibraryDimensionDef as Qi, GenericDimensionInfo as Qn, SelectionObject as Qo, NxAttributeExpressionValues as Qr, CustomConnector as Qt, GenericObjectPropertiesNodeLevel2 as R, NxStreamListEntry as Ra, NxGetObjectOptions as Ri, FieldType as Rn, SearchGroupOptions as Ro, NativeGenericBookmarkFunctions as Rr, BookmarkList as Rt, AnyGenericObjectProperties as S, NxPatchOperationType as Sa, NxDimensionInfo as Si, ExpansionData as Sn, SearchAssociationResult as So, KeyType as Sr, TextMacro as Ss, ApplyGroupStateWarning as St, FieldListObject as T, NxPivotPage as Ta, NxDownloadOptions as Ti, ExtensionList as Tn, SearchCombinationOptions as To, LayoutFieldInfo as Tr, TransformAppResult as Ts, ArrayOfNxValuePoint as Tt, GenericVariable as U, NxTreeDimensionInfo as Ua, NxGrpType as Ui, FilterType as Un, SearchPage as Uo, NativeGlobalFunctions as Ur, CharEncodingType as Ut, GenericObjectPropertiesNodeLevel5 as V, NxTreeDataOption as Va, NxGroupObjectId as Vi, FileType as Vn, SearchMatchCombinations as Vo, NativeGenericObjectFunctions as Vr, BookmarkVariableItem as Vt, UndoInfoObject as W, NxTreeMultiRangeSelectInfo as Wa, NxHighlightRanges as Wi, FolderItem as Wn, SearchResult as Wo, NativeVariableFunctions as Wr, CharRange as Wt, DynamicAppViewListData as X, NxTrendlineMode as Xa, NxLayoutErrors as Xi, GenericBookmarkProperties as Xn, SearchValueResult as Xo, NxAttrExprInfo as Xr, ContentLibraryList as Xt, DimensionListItem as Y, NxTrendlineDef as Ya, NxLTrendlineType as Yi, GenericBookmarkLayout as Yn, SearchValuePage as Yo, NxAttrExprDef as Yr, Connection as Yt, DynamicAppViewListItem as Z, NxValidationError as Za, NxLibraryDimension as Zi, GenericConnectMachine as Zn, SelectInfo as Zo, NxAttributeDimValues as Zr, ContentLibraryListItem as Zt, ObjectHelperFunctions as _, NxMultiRangeSelectInfo as _a, NxDerivedFieldDescriptionList as _i, EditorBreakpoint as _n, Rect as _o, HyperCubeDef as _r, TableViewConnectionPointSaveInfo as _s, AppEntry as _t, AppSession as a, NxLocalizedWarningCode as aa, NxCell as ai, DatabaseInfo as an, OtherMode as ao, GenericObjectLayoutAdditionalProperties as ar, StaticContentList as as, ODAGAppLinkListData as at, Global as b, NxPageTreeNode as ba, NxDimCellType as bi, ErrorData as bn, ScriptSyntaxError as bo, InteractDef as br, TableViewSaveInfo as bs, AppScript as bt, NativeReactHooks as c, NxMeasure as ca, NxContainerEntry as ci, DerivedFieldsInTableData as cn, Point as co, GenericVariableConstraints as cr, StaticContentUrlDef as cs, SheetListDataCell as ct, WorkloadType as d, NxMetaDef as da, NxContinuousRangeSelectInfo as di, DimensionReference as dn, ProgressMessage as do, GenericVariableType as dr, SymbolFrequency as ds, StoryListData as dt, NxLibraryMeasureDef as ea, NxAxisData as ei, DataField as en, NxViewPort as eo, GenericDimensionProperties as er, Size as es, ListItem as et, CombinedWebSocketStateEvent as f, NxMiniChart as fa, NxCurrentSelectionItem as fi, DoReloadExParams as fn, QFunction as fo, GraphMode as fr, SymbolValue as fs, StoryListItem as ft, ModalFunctions as g, NxMiniChartRows as ga, NxDerivedField as gi, DriveType as gn, RangeSelectInfo as go, HyperCube as gr, TableViewBroomPointSaveInfo as gs, AlternateStateData as gt, ListFunctions as h, NxMiniChartDef as ha, NxDataReductionMode as hi, DriveInfo as hn, QRange as ho, GroupStateInfo as hr, TableRow as hs, AlfaNumString as ht, withHostConfig as i, NxLocalizedErrorCode as ia, NxCardinalities as ii, Database as in, OtherLimitMode as io, GenericObjectLayout as ir, StateFieldValues as is, MeasureListItem as it, GenericObjectLayoutNode as j, NxSelectionInfo as ja, NxFieldProperties as ji, FieldDescription as jn, SearchFieldSelectionMode as jo, MeasureList as jr, ValueExpr as js, Bookmark as jt, GenericMeasure as k, NxSelectionCell as ka, NxFeature as ki, FieldAttributes as kn, SearchFieldMatchType as ko, LocaleInfo as kr, UndoInfoDef as ks, BNFType as kt, OpenAppSessionProps as l, NxMeasureInfo as la, NxContinuousDataOptions as li, DimensionList as ln, PositionMark as lo, GenericVariableLayout as lr, StringExpr as ls, SheetListDataCellBounds as lt, Doc as m, NxMiniChartData as ma, NxDataPage as mi, DocListEntry as mn, QMediaList as mo, GroupState as mr, TableRecord as ms, VariableListItem as mt, openAppSession as n, NxListObjectExpression as na, NxBookmark as ni, DataTable as nn, OdbcDsn as no, GenericMeasureProperties as nr, SourceKeyRecord as ns, MasterObjectListItem as nt, CloseProps as o, NxMatchingFieldInfo as oa, NxCellPosition as oi, DatabaseOwner as on, OtherSortMode as oo, GenericObjectProperties as or, StaticContentListItem as os, ODAGAppLinkListItem as ot, WebSocketEvent as p, NxMiniChartCell as pa, NxDataAreaPage as pi, DoReloadExResult as pn, QIX_SCHEMA_VERSION as po, GroupBookmarkData as pr, TableProfilingData as ps, VariableListData as pt, BookmarkListItem as q, NxTreeValue as qa, NxInlineDimensionDef as qi, FunctionGroup as qn, SearchTermResult as qo, NxAttrDimDef as qr, CodePage as qt, qix as r, NxListObjectExpressionDef as ra, NxCalcCond as ri, DataTableEx as rn, OleDbProvider as ro, GenericObjectEntry as rr, StateEnumType as rs, MeasureListData as rt, DocAction as s, NxMatchingFieldMode as sa, NxCellRows as si, DelimiterInfo as sn, OtherTotalSpecProp as so, GenericObjectPropertiesAdditionalProperties as sr, StaticContentUrl as ss, SheetListData as st, QixAPI as t, NxLinkedObjectInfo as ta, NxAxisTicks as ti, DataRecord as tn, ObjectInterface as to, GenericMeasureLayout as tr, SortCriteria as ts, MasterObjectListData as tt, UseAppHook as u, NxMeta as ua, NxContinuousMode as ui, DimensionListDef as un, ProgressData as uo, GenericVariableProperties as ur, StringExpression as us, SheetListItem as ut, SpecialObjectFunctions as v, NxPage as va, NxDerivedFieldsData as vi, EmbeddedSnapshot as vn, ReloadError as vo, InputFieldItem as vr, TableViewCtlSaveInfo as vs, AppObjectList as vt, Field as w, NxPivotDimensionCell as wa, NxDownloadInfo as wi, ExtendedPivotStateData as wn, SearchCharRange as wo, LayoutExclude as wr, TransformAppParameters as ws, ApplyGroupStatesResult as wt, AnyGenericObjectLayout as x, NxPatch as xa, NxDimension as xi, ErrorDataCode as xn, ScrollPosition as xo, InteractType as xr, TableViewTableWinSaveInfo as xs, AppScriptMeta as xt, StandardFunctions as y, NxPageTreeLevel as ya, NxDerivedGroup as yi, EmbeddedSnapshotDef as yn, SampleResult as yo, InterFieldSortData as yr, TableViewDlgSaveInfo as ys, AppObjectListDef as yt, GenericObjectPropertiesNodeLevel3 as z, NxTempBookmarkOptions as za, NxGroupDef as zi, FieldValue as zn, SearchGroupType as zo, NativeGenericDimensionFunctions as zr, BookmarkListDef as zt };
@@ -1,6 +1,6 @@
1
- import { i as isNode, n as createResolvablePromise$1 } from "./utils-jkpLuYZR.js";
2
- import { A as appendQueryToUrl, N as exposeInternalApiOnWindow, P as generateRandomString, c as handleAuthenticationError, s as getWebSocketAuthParams, u as isWindows, x as toValidWebsocketLocationUrl } from "./boot-interceptors-DqRxTczb.js";
3
- import { t as getHumanReadableSocketClosedErrorMessage$1 } from "./websocket-errors-C5U1tba-.js";
1
+ import { i as isNode, n as createResolvablePromise$1 } from "./utils-B7chC9_U.js";
2
+ import { E as toValidWebsocketLocationUrl, F as appendQueryToUrl, R as exposeInternalApiOnWindow, f as getWebSocketAuthParams, h as isWindows, p as handleAuthenticationError, z as generateRandomString } from "./interceptors-DMiDeqEz.js";
3
+ import { t as getHumanReadableSocketClosedErrorMessage$1 } from "./websocket-errors-C6cw1uQN.js";
4
4
  import isPlainObject from "lodash/isPlainObject.js";
5
5
  import merge from "lodash/merge.js";
6
6
  import originalExtend from "extend";
@@ -15166,6 +15166,12 @@ function normalizeObjectRef(response) {
15166
15166
  function isQixObjectRef(ref) {
15167
15167
  return typeof ref === "object" && ref.qHandle && ref.qType;
15168
15168
  }
15169
+ /**
15170
+ * Returns true if the supplied parameter is an object with a qReturn with a null qHandle
15171
+ */
15172
+ function isQixObjectNotFoundError(result) {
15173
+ return typeof result === "object" && typeof result.qReturn === "object" && result.qReturn.qHandle === null;
15174
+ }
15169
15175
  function getHandleOfRef(response) {
15170
15176
  return response.qHandle ?? response.handle;
15171
15177
  }
@@ -15939,6 +15945,13 @@ async function createQixConnection(props, listener) {
15939
15945
  logResponse(handleOrObject, websocketRequest, errorResponse);
15940
15946
  throw new QixError(response.error, isCancelled);
15941
15947
  }
15948
+ if (isQixObjectNotFoundError(response.result)) {
15949
+ const isCancelled = requestWasCanceled(websocketRequest.id);
15950
+ throw new QixError({
15951
+ code: engine_api_default.enums.LocalizedErrorCode.LOCERR_GENERIC_NOT_FOUND,
15952
+ message: "Object not found"
15953
+ }, isCancelled);
15954
+ }
15942
15955
  let resultObject = response.result || {};
15943
15956
  if (response.delta) resultObject = unwrapDeltas(resultObject, deltaState, handle, request.method);
15944
15957
  const result = extractResult({
package/collections.d.ts CHANGED
@@ -1,6 +1,4 @@
1
- import { ApiCallOptions } from "./invoke-fetch-types.js";
2
- import "./chunks/invoke-fetch-DFc3yzaj.js";
3
-
1
+ import { b as ApiCallOptions } from "./chunks/auth-types-DVvka7Hz.js";
4
2
  //#region src/public/rest/collections.d.ts
5
3
  type CollectionByIdPatch = {
6
4
  /** The operation to be performed. */op: "replace"; /** Field of collection to be patched. */
@@ -322,7 +320,6 @@ type UpdateCollectionHttpError = {
322
320
  * Retrieves items from a collection that the user has access to.
323
321
  *
324
322
  * @param collectionId The collection's unique identifier. (This query also supports 'favorites' as the collectionID).
325
-
326
323
  * @param query an object with query parameters
327
324
  * @throws GetCollectionItemsHttpError
328
325
  */
@@ -465,7 +462,7 @@ type CollectionsAPI = {
465
462
  * Retrieves items from a collection that the user has access to.
466
463
  *
467
464
  * @param collectionId The collection's unique identifier. (This query also supports 'favorites' as the collectionID).
468
- * @param query an object with query parameters
465
+ * @param query an object with query parameters
469
466
  * @throws GetCollectionItemsHttpError
470
467
  */
471
468
  getCollectionItems: typeof getCollectionItems;
package/collections.js CHANGED
@@ -1,5 +1,5 @@
1
- import "./chunks/public-runtime-modules-2KfyI2qM.js";
2
- import { n as invokeFetch, t as clearApiCache } from "./chunks/invoke-fetch-DMAi6Fg3.js";
1
+ import "./chunks/public-runtime-modules-mBjjPn7I.js";
2
+ import { n as invokeFetch, t as clearApiCache } from "./chunks/invoke-fetch-DxtIsSVQ.js";
3
3
 
4
4
  //#region src/public/rest/collections.ts
5
5
  /**
@@ -107,9 +107,8 @@ async function updateCollection(collectionId, body, options) {
107
107
  }
108
108
  /**
109
109
  * Retrieves items from a collection that the user has access to.
110
- *
110
+ *
111
111
  * @param collectionId The collection's unique identifier. (This query also supports 'favorites' as the collectionID).
112
-
113
112
  * @param query an object with query parameters
114
113
  * @throws GetCollectionItemsHttpError
115
114
  */
package/conditions.d.ts CHANGED
@@ -1,6 +1,4 @@
1
- import { ApiCallOptions } from "./invoke-fetch-types.js";
2
- import "./chunks/invoke-fetch-DFc3yzaj.js";
3
-
1
+ import { b as ApiCallOptions } from "./chunks/auth-types-DVvka7Hz.js";
4
2
  //#region src/public/rest/conditions.d.ts
5
3
  type APISettings = {
6
4
  /** Whether API endpoints for condition manager are enabled */"enable-conditions": boolean; /** These persisted api settings are only available for this tenant. Extracted from request JWT. */
package/conditions.js CHANGED
@@ -1,5 +1,5 @@
1
- import "./chunks/public-runtime-modules-2KfyI2qM.js";
2
- import { n as invokeFetch, t as clearApiCache } from "./chunks/invoke-fetch-DMAi6Fg3.js";
1
+ import "./chunks/public-runtime-modules-mBjjPn7I.js";
2
+ import { n as invokeFetch, t as clearApiCache } from "./chunks/invoke-fetch-DxtIsSVQ.js";
3
3
 
4
4
  //#region src/public/rest/conditions.ts
5
5
  /**
package/consumption.d.ts CHANGED
@@ -1,6 +1,4 @@
1
- import { ApiCallOptions } from "./invoke-fetch-types.js";
2
- import "./chunks/invoke-fetch-DFc3yzaj.js";
3
-
1
+ import { b as ApiCallOptions } from "./chunks/auth-types-DVvka7Hz.js";
4
2
  //#region src/public/rest/consumption.d.ts
5
3
  type Enforcement = {
6
4
  /** Resource action type to be blocked */actionToBlock?: string; /** Resource type to be blocked */
package/consumption.js CHANGED
@@ -1,5 +1,5 @@
1
- import "./chunks/public-runtime-modules-2KfyI2qM.js";
2
- import { n as invokeFetch, t as clearApiCache } from "./chunks/invoke-fetch-DMAi6Fg3.js";
1
+ import "./chunks/public-runtime-modules-mBjjPn7I.js";
2
+ import { n as invokeFetch, t as clearApiCache } from "./chunks/invoke-fetch-DxtIsSVQ.js";
3
3
 
4
4
  //#region src/public/rest/consumption.ts
5
5
  /**
@@ -1,7 +1,4 @@
1
- import { ApiCallOptions } from "../invoke-fetch-types.js";
2
- import "../chunks/invoke-fetch-DFc3yzaj.js";
3
-
4
- //#region src/public/rest/core/ip-policies.d.ts
1
+ import { b as ApiCallOptions } from "../chunks/auth-types-DVvka7Hz.js";
5
2
  declare namespace ip_policies_d_exports {
6
3
  export { CreateIPPolicy, CreateIpPolicyHttpError, CreateIpPolicyHttpResponse, DeleteIpPolicyHttpError, DeleteIpPolicyHttpResponse, Error, Errors, GetIpPoliciesHttpError, GetIpPoliciesHttpResponse, GetIpPolicyHttpError, GetIpPolicyHttpResponse, IPPolicyListItem, IPPolicyResource, IpPoliciesAPI, JSONPatch, JSONPatchArray, Link, Links, ListIPPoliciesResult, PatchIpPolicyHttpError, PatchIpPolicyHttpResponse, clearCache, createIpPolicy, ipPoliciesExport as default, deleteIpPolicy, getIpPolicies, getIpPolicy, patchIpPolicy };
7
4
  }