@qlik/api 1.25.0 → 1.27.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 (84) hide show
  1. package/api-keys.d.ts +12 -12
  2. package/api-keys.js +2 -2
  3. package/apps.d.ts +69 -69
  4. package/apps.js +2 -2
  5. package/audits.d.ts +37 -15
  6. package/audits.js +2 -2
  7. package/auth.js +2 -2
  8. package/automations.d.ts +37 -37
  9. package/automations.js +2 -2
  10. package/brands.d.ts +24 -24
  11. package/brands.js +2 -2
  12. package/chunks/{3DYV7KOJ.js → 2BRBIRM2.js} +2 -2
  13. package/chunks/{7BDAXGID.js → 3RGGGGAR.js} +6 -9
  14. package/chunks/{6DEESTGF.js → 4D5NADHK.js} +4 -4
  15. package/chunks/{VX3MQBE7.js → 4K3CNR7C.js} +1 -1
  16. package/chunks/{OIQ5ELGS.js → 55SZVSAG.js} +1 -1
  17. package/chunks/{BL5PJM4B.js → EOGHK2R4.js} +1 -1
  18. package/chunks/{N3ZFICDU.js → MGXEGSJC.js} +3 -3
  19. package/chunks/{I5UOE4ZZ.js → NBW6PHZU.js} +120 -44
  20. package/chunks/{6QRR5VUM.js → QOOCP2TS.js} +4 -3
  21. package/chunks/{CZC7KEJN.js → V3TZ54UE.js} +3 -3
  22. package/chunks/{UA6BE3VB.js → WY7IOA3Q.js} +2 -2
  23. package/collections.d.ts +23 -23
  24. package/collections.js +2 -2
  25. package/csp-origins.d.ts +25 -25
  26. package/csp-origins.js +2 -2
  27. package/data-assets.d.ts +12 -12
  28. package/data-assets.js +2 -2
  29. package/data-connections.d.ts +19 -19
  30. package/data-connections.js +2 -2
  31. package/data-credentials.d.ts +11 -11
  32. package/data-credentials.js +2 -2
  33. package/data-files.d.ts +25 -25
  34. package/data-files.js +2 -2
  35. package/docs/authentication.md +1 -1
  36. package/docs/qix.md +28 -8
  37. package/extensions.d.ts +12 -12
  38. package/extensions.js +2 -2
  39. package/glossaries.d.ts +49 -49
  40. package/glossaries.js +2 -2
  41. package/groups.d.ts +17 -17
  42. package/groups.js +2 -2
  43. package/identity-providers.d.ts +43 -18
  44. package/identity-providers.js +2 -2
  45. package/index.d.ts +1 -1
  46. package/index.js +5 -5
  47. package/interceptors.d.ts +1 -1
  48. package/interceptors.js +1 -1
  49. package/{invoke-fetch-types-BLrpeZOL.d.ts → invoke-fetch-types-BXn-uSF5.d.ts} +27 -1
  50. package/items.d.ts +17 -17
  51. package/items.js +2 -2
  52. package/licenses.d.ts +19 -19
  53. package/licenses.js +2 -2
  54. package/package.json +3 -3
  55. package/qix.d.ts +2 -2
  56. package/qix.js +2 -2
  57. package/quotas.d.ts +5 -5
  58. package/quotas.js +2 -2
  59. package/reload-tasks.d.ts +11 -11
  60. package/reload-tasks.js +2 -2
  61. package/reloads.d.ts +9 -9
  62. package/reloads.js +2 -2
  63. package/reports.d.ts +13 -11
  64. package/reports.js +2 -2
  65. package/roles.d.ts +12 -12
  66. package/roles.js +2 -2
  67. package/spaces.d.ts +60 -26
  68. package/spaces.js +2 -2
  69. package/temp-contents.d.ts +7 -7
  70. package/temp-contents.js +2 -2
  71. package/tenants.d.ts +10 -10
  72. package/tenants.js +2 -2
  73. package/themes.d.ts +12 -12
  74. package/themes.js +2 -2
  75. package/transports.d.ts +18 -18
  76. package/transports.js +2 -2
  77. package/users.d.ts +20 -20
  78. package/users.js +2 -2
  79. package/web-integrations.d.ts +10 -10
  80. package/web-integrations.js +2 -2
  81. package/web-notifications.d.ts +13 -13
  82. package/web-notifications.js +2 -2
  83. package/webhooks.d.ts +21 -21
  84. package/webhooks.js +2 -2
package/data-files.d.ts CHANGED
@@ -1,4 +1,4 @@
1
- import { A as ApiCallOptions } from './invoke-fetch-types-BLrpeZOL.js';
1
+ import { A as ApiCallOptions } from './invoke-fetch-types-BXn-uSF5.js';
2
2
  import './auth-types-PkN9CAF_.js';
3
3
 
4
4
  type BatchChangeSpaceItem = {
@@ -313,14 +313,14 @@ declare const getDataFiles: (query: {
313
313
  type GetDataFilesHttpResponse = {
314
314
  data: GetDataFileInfosResponse;
315
315
  headers: Headers;
316
- status: number;
316
+ status: 200;
317
317
  prev?: (options?: ApiCallOptions) => Promise<GetDataFilesHttpResponse>;
318
318
  next?: (options?: ApiCallOptions) => Promise<GetDataFilesHttpResponse>;
319
319
  };
320
320
  type GetDataFilesHttpError = {
321
321
  data: ErrorResponse;
322
322
  headers: Headers;
323
- status: number;
323
+ status: 400 | 403;
324
324
  };
325
325
  /**
326
326
  * Upload a new data file or create a new folder.
@@ -370,12 +370,12 @@ declare const uploadDataFile: (body: {
370
370
  type UploadDataFileHttpResponse = {
371
371
  data: DataFileUploadResponse;
372
372
  headers: Headers;
373
- status: number;
373
+ status: 201;
374
374
  };
375
375
  type UploadDataFileHttpError = {
376
376
  data: ErrorResponse;
377
377
  headers: Headers;
378
- status: number;
378
+ status: 400 | 403 | 409 | 413 | 423 | 501;
379
379
  };
380
380
  /**
381
381
  * This is to allow for a separate admin type of operation that is more global in terms of access in cases
@@ -390,12 +390,12 @@ declare const moveDataFiles: (body: DataFileBatchChangeSpaceRequest, options?: A
390
390
  type MoveDataFilesHttpResponse = {
391
391
  data: MultiStatusResponse;
392
392
  headers: Headers;
393
- status: number;
393
+ status: 207;
394
394
  };
395
395
  type MoveDataFilesHttpError = {
396
396
  data: ErrorResponse;
397
397
  headers: Headers;
398
- status: number;
398
+ status: 400;
399
399
  };
400
400
  /**
401
401
  * Delete the specified set of data files and/or folders as a single batch.
@@ -407,12 +407,12 @@ declare const deleteDataFiles: (body: DataFileBatchDeleteRequest, options?: ApiC
407
407
  type DeleteDataFilesHttpResponse = {
408
408
  data: MultiStatusResponse;
409
409
  headers: Headers;
410
- status: number;
410
+ status: 207;
411
411
  };
412
412
  type DeleteDataFilesHttpError = {
413
413
  data: ErrorResponse;
414
414
  headers: Headers;
415
- status: number;
415
+ status: 400;
416
416
  };
417
417
  /**
418
418
  * The non-filtered list contains a set of hardcoded connections, along with one connection per team space that
@@ -444,14 +444,14 @@ declare const getDataFilesConnections: (query: {
444
444
  type GetDataFilesConnectionsHttpResponse = {
445
445
  data: GetConnectionsResponse;
446
446
  headers: Headers;
447
- status: number;
447
+ status: 200;
448
448
  prev?: (options?: ApiCallOptions) => Promise<GetDataFilesConnectionsHttpResponse>;
449
449
  next?: (options?: ApiCallOptions) => Promise<GetDataFilesConnectionsHttpResponse>;
450
450
  };
451
451
  type GetDataFilesConnectionsHttpError = {
452
452
  data: ErrorResponse;
453
453
  headers: Headers;
454
- status: number;
454
+ status: 400 | 403;
455
455
  };
456
456
  /**
457
457
  * Get the built-in connection used by the engine to load/write data files given a connection ID.
@@ -463,12 +463,12 @@ declare const getDataFileConnection: (id: string, options?: ApiCallOptions) => P
463
463
  type GetDataFileConnectionHttpResponse = {
464
464
  data: ConnectionsResponse;
465
465
  headers: Headers;
466
- status: number;
466
+ status: 200;
467
467
  };
468
468
  type GetDataFileConnectionHttpError = {
469
469
  data: ErrorResponse;
470
470
  headers: Headers;
471
- status: number;
471
+ status: 403 | 404;
472
472
  };
473
473
  /**
474
474
  * Get quota information for the calling user.
@@ -479,12 +479,12 @@ declare const getDataFilesQuotas: (options?: ApiCallOptions) => Promise<GetDataF
479
479
  type GetDataFilesQuotasHttpResponse = {
480
480
  data: QuotaResponse;
481
481
  headers: Headers;
482
- status: number;
482
+ status: 200;
483
483
  };
484
484
  type GetDataFilesQuotasHttpError = {
485
485
  data: ErrorResponse;
486
486
  headers: Headers;
487
- status: number;
487
+ status: 400 | 403;
488
488
  };
489
489
  /**
490
490
  * Delete the specified data file or folder. Deleting a folder will also recursively delete all files and
@@ -497,12 +497,12 @@ declare const deleteDataFile: (id: string, options?: ApiCallOptions) => Promise<
497
497
  type DeleteDataFileHttpResponse = {
498
498
  data: void;
499
499
  headers: Headers;
500
- status: number;
500
+ status: 204;
501
501
  };
502
502
  type DeleteDataFileHttpError = {
503
503
  data: ErrorResponse;
504
504
  headers: Headers;
505
- status: number;
505
+ status: 400 | 403 | 404;
506
506
  };
507
507
  /**
508
508
  * Get descriptive info for the specified data file.
@@ -514,12 +514,12 @@ declare const getDataFile: (id: string, options?: ApiCallOptions) => Promise<Get
514
514
  type GetDataFileHttpResponse = {
515
515
  data: DataFileUploadResponse;
516
516
  headers: Headers;
517
- status: number;
517
+ status: 200;
518
518
  };
519
519
  type GetDataFileHttpError = {
520
520
  data: ErrorResponse;
521
521
  headers: Headers;
522
- status: number;
522
+ status: 400 | 403 | 404;
523
523
  };
524
524
  /**
525
525
  * Re-upload an existing data file or update an existing folder.
@@ -582,12 +582,12 @@ declare const reuploadDataFile: (id: string, body: {
582
582
  type ReuploadDataFileHttpResponse = {
583
583
  data: DataFileUploadResponse;
584
584
  headers: Headers;
585
- status: number;
585
+ status: 201;
586
586
  };
587
587
  type ReuploadDataFileHttpError = {
588
588
  data: ErrorResponse;
589
589
  headers: Headers;
590
- status: number;
590
+ status: 400 | 403 | 404 | 409 | 413 | 423;
591
591
  };
592
592
  /**
593
593
  * This is primarily an admin type of operation. In general, the owner of a data file or folder is implicitly
@@ -606,12 +606,12 @@ declare const changeDataFileOwner: (id: string, body: ChangeDataFileOwnerRequest
606
606
  type ChangeDataFileOwnerHttpResponse = {
607
607
  data: void;
608
608
  headers: Headers;
609
- status: number;
609
+ status: 204;
610
610
  };
611
611
  type ChangeDataFileOwnerHttpError = {
612
612
  data: ErrorResponse;
613
613
  headers: Headers;
614
- status: number;
614
+ status: 400 | 403 | 404 | 409 | 423;
615
615
  };
616
616
  /**
617
617
  * This is to allow for a separate admin type of operation that is more global in terms of access in cases
@@ -631,12 +631,12 @@ declare const moveDataFile: (id: string, body: ChangeDataFileSpaceRequest, optio
631
631
  type MoveDataFileHttpResponse = {
632
632
  data: void;
633
633
  headers: Headers;
634
- status: number;
634
+ status: 204;
635
635
  };
636
636
  type MoveDataFileHttpError = {
637
637
  data: ErrorResponse;
638
638
  headers: Headers;
639
- status: number;
639
+ status: 400 | 403 | 404 | 409 | 423;
640
640
  };
641
641
  /**
642
642
  * Clears the cache for data-files api requests.
package/data-files.js CHANGED
@@ -1,8 +1,8 @@
1
1
  import {
2
2
  clearApiCache,
3
3
  invokeFetch
4
- } from "./chunks/UA6BE3VB.js";
5
- import "./chunks/CZC7KEJN.js";
4
+ } from "./chunks/WY7IOA3Q.js";
5
+ import "./chunks/V3TZ54UE.js";
6
6
  import "./chunks/2ZQ3ZX7F.js";
7
7
 
8
8
  // src/public/rest/data-files.ts
@@ -52,7 +52,7 @@ As an alternative to the methods above it is also possible to create an instance
52
52
  Example:
53
53
 
54
54
  ```ts
55
- import { createQlikApi } from "@qlik-trial/qmfe-api";
55
+ import { createQlikApi } from "@qlik/api";
56
56
 
57
57
  const api = createQlikApi({
58
58
  authType: "apikey"
package/docs/qix.md CHANGED
@@ -62,15 +62,36 @@ const sheetlist = await app.getSheetList();
62
62
  React example of getting the sheet list from a Qlik Sense app.
63
63
 
64
64
  ```tsx
65
+ import { type HostConfig } from "@qlik/api/auth";
66
+ import { openAppSession, type Doc } from "@qlik/api/qix";
65
67
  import React from "react";
66
68
  import usePromise from "react-use-promise";
67
- import { useAppHook } from "@qlik/api/qix";
68
- import { setDefaultHostConfig } from "@qlik/api/auth";
69
69
 
70
- setDefaultHostConfig({ ... });
70
+ const hostConfig: HostConfig = {
71
+ ..., // add host config values here
72
+ };
71
73
 
72
- // send in the react instance (avoid unnecessary dependencies to react in @qlik/api)
73
- const useApp = useAppHook(React);
74
+
75
+ /**
76
+ * Use App Hook
77
+ */
78
+ function useApp(appId: string): Doc | undefined {
79
+ const [app, setApp] = React.useState<Doc | undefined>(undefined);
80
+ React.useEffect(() => {
81
+ // open a websocket using the specified hostConfig. If `setDefaultHostConfig` has been used,
82
+ // passing host config here is not needed here.
83
+ const appSession = openAppSession({ appId, hostConfig });
84
+ appSession.getDoc().then((x) => {
85
+ setApp(x);
86
+ });
87
+ return () => {
88
+ if (appSession) {
89
+ appSession.close();
90
+ }
91
+ };
92
+ }, [appId]);
93
+ return app;
94
+ }
74
95
 
75
96
  type SheetListProps = {
76
97
  appId: string;
@@ -79,10 +100,9 @@ type SheetListProps = {
79
100
  const SheetList = ({ appId }: SheetListProps): JSX.Element | null => {
80
101
  const app = useApp(appId);
81
102
 
82
- // this could be nicely wrapped in your own local getSheetList hook
103
+ // this could be nicely wrapped in your own local getSheetList hook similar to the useApp hook above
83
104
  const [sheetList] = usePromise(async () => app && app.getSheetList(), [app]);
84
105
  // getSheetList above is coming from mixins, fully typed
85
-
86
106
  if (!sheetList) {
87
107
  return <div>Loading</div>;
88
108
  }
@@ -90,7 +110,7 @@ const SheetList = ({ appId }: SheetListProps): JSX.Element | null => {
90
110
  <div>
91
111
  <div>Sheets:</div>
92
112
  {sheetList.map((item) => (
93
- <div key={item.qInfo?.qId}>{item.qData.title}</div>
113
+ <div key={item.qInfo?.qId}>{item.qData?.title}</div>
94
114
  ))}
95
115
  </div>
96
116
  );
package/extensions.d.ts CHANGED
@@ -1,4 +1,4 @@
1
- import { A as ApiCallOptions } from './invoke-fetch-types-BLrpeZOL.js';
1
+ import { A as ApiCallOptions } from './invoke-fetch-types-BXn-uSF5.js';
2
2
  import './auth-types-PkN9CAF_.js';
3
3
 
4
4
  /**
@@ -104,7 +104,7 @@ declare const getExtensions: (options?: ApiCallOptions) => Promise<GetExtensions
104
104
  type GetExtensionsHttpResponse = {
105
105
  data: Extensions;
106
106
  headers: Headers;
107
- status: number;
107
+ status: 200;
108
108
  };
109
109
  type GetExtensionsHttpError = {
110
110
  data: unknown;
@@ -126,7 +126,7 @@ declare const uploadExtension: (body: {
126
126
  type UploadExtensionHttpResponse = {
127
127
  data: Extension;
128
128
  headers: Headers;
129
- status: number;
129
+ status: 201;
130
130
  };
131
131
  type UploadExtensionHttpError = {
132
132
  data: Error;
@@ -143,12 +143,12 @@ declare const deleteExtension: (id: string, options?: ApiCallOptions) => Promise
143
143
  type DeleteExtensionHttpResponse = {
144
144
  data: void;
145
145
  headers: Headers;
146
- status: number;
146
+ status: 204;
147
147
  };
148
148
  type DeleteExtensionHttpError = {
149
149
  data: Error;
150
150
  headers: Headers;
151
- status: number;
151
+ status: 403 | 404 | 410;
152
152
  };
153
153
  /**
154
154
  * Returns a specific extension matching either extension ID or extension name.
@@ -160,12 +160,12 @@ declare const getExtension: (id: string, options?: ApiCallOptions) => Promise<Ge
160
160
  type GetExtensionHttpResponse = {
161
161
  data: Extension;
162
162
  headers: Headers;
163
- status: number;
163
+ status: 200;
164
164
  };
165
165
  type GetExtensionHttpError = {
166
166
  data: Error;
167
167
  headers: Headers;
168
- status: number;
168
+ status: 403 | 404 | 410;
169
169
  };
170
170
  /**
171
171
  * Updates a specific extension matching either extension ID or extension name. Accepts either provided file or data object.
@@ -183,7 +183,7 @@ declare const patchExtension: (id: string, body: {
183
183
  type PatchExtensionHttpResponse = {
184
184
  data: Extension;
185
185
  headers: Headers;
186
- status: number;
186
+ status: 200;
187
187
  };
188
188
  type PatchExtensionHttpError = {
189
189
  data: Error;
@@ -200,12 +200,12 @@ declare const downloadExtension: (id: string, options?: ApiCallOptions) => Promi
200
200
  type DownloadExtensionHttpResponse = {
201
201
  data: void;
202
202
  headers: Headers;
203
- status: number;
203
+ status: 200;
204
204
  };
205
205
  type DownloadExtensionHttpError = {
206
206
  data: Error;
207
207
  headers: Headers;
208
- status: number;
208
+ status: 403 | 404 | 410;
209
209
  };
210
210
  /**
211
211
  * Downloads a specific file from the extension matching either extension ID or extension name, identified by the file path within the imported extension.
@@ -218,12 +218,12 @@ declare const downloadFileFromExtension: (id: string, filepath: string, options?
218
218
  type DownloadFileFromExtensionHttpResponse = {
219
219
  data: void;
220
220
  headers: Headers;
221
- status: number;
221
+ status: 200;
222
222
  };
223
223
  type DownloadFileFromExtensionHttpError = {
224
224
  data: Error;
225
225
  headers: Headers;
226
- status: number;
226
+ status: 403 | 404 | 410;
227
227
  };
228
228
  /**
229
229
  * Clears the cache for extensions api requests.
package/extensions.js CHANGED
@@ -1,8 +1,8 @@
1
1
  import {
2
2
  clearApiCache,
3
3
  invokeFetch
4
- } from "./chunks/UA6BE3VB.js";
5
- import "./chunks/CZC7KEJN.js";
4
+ } from "./chunks/WY7IOA3Q.js";
5
+ import "./chunks/V3TZ54UE.js";
6
6
  import "./chunks/2ZQ3ZX7F.js";
7
7
 
8
8
  // src/public/rest/extensions.ts