@qlik/api 0.0.16 → 0.1.1
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.
- package/README.md +1 -1
- package/api-keys.js +25 -25
- package/apps.d.ts +9 -1
- package/apps.js +97 -97
- package/audits.js +23 -23
- package/auth.js +14 -14
- package/automations.js +47 -47
- package/brands.js +35 -35
- package/chunks/4HB3TAEO.js +4 -4
- package/chunks/{HHOVS7QC.mjs → CHNBNLXY.js} +3 -3
- package/chunks/{3YV6X7S6.mjs → FFGE2RP7.js} +1 -1
- package/chunks/{HOCTJESP.mjs → JEGN7XQV.js} +3 -3
- package/chunks/{6WX5AGKQ.mjs → L2BJNKLV.js} +2 -2
- package/chunks/OPRGGO4C.js +8 -8
- package/chunks/{O4EAKEIN.mjs → RHF624NQ.js} +1 -1
- package/chunks/{BYD63JCG.mjs → SIU6HO6B.js} +5 -3
- package/chunks/{EHAANYDL.mjs → TT66UJZY.js} +3 -3
- package/chunks/{UKVTBYP6.mjs → XOVMZWDC.js} +2 -2
- package/chunks/{6AD3HYSF.mjs → XZQNE4HH.js} +1 -1
- package/collections.js +33 -33
- package/csp-origins.js +23 -23
- package/data-assets.js +21 -21
- package/data-connections.js +29 -29
- package/data-credentials.js +19 -19
- package/data-files.js +35 -35
- package/docs/authentication.md +5 -5
- package/docs/examples/fetch-spaces.md +1 -15
- package/docs/examples/show-sheet-list.md +1 -1
- package/docs/features.md +1 -1
- package/extensions.js +25 -25
- package/glossaries.js +59 -59
- package/groups.d.ts +0 -3
- package/groups.js +27 -27
- package/identity-providers.d.ts +144 -10
- package/identity-providers.js +27 -27
- package/index.js +53 -53
- package/items.js +27 -27
- package/licenses.js +29 -29
- package/package.json +36 -232
- package/qix.d.ts +1 -1
- package/qix.js +10 -10
- package/quotas.js +15 -15
- package/reload-tasks.js +21 -21
- package/reloads.js +19 -19
- package/roles.js +15 -15
- package/spaces.js +35 -35
- package/temp-contents.js +17 -17
- package/tenants.js +23 -23
- package/themes.js +25 -25
- package/transports.js +23 -23
- package/users.d.ts +1 -3
- package/users.js +31 -31
- package/web-integrations.js +21 -21
- package/web-notifications.js +23 -23
- package/webhooks.js +31 -31
- package/api-keys.d.mts +0 -336
- package/api-keys.mjs +0 -80
- package/apps.d.mts +0 -2431
- package/apps.mjs +0 -398
- package/audits.d.mts +0 -286
- package/audits.mjs +0 -64
- package/auth-types-nnUcWhuU.d.mts +0 -98
- package/auth.d.mts +0 -26
- package/auth.mjs +0 -14
- package/automations.d.mts +0 -682
- package/automations.mjs +0 -173
- package/brands.d.mts +0 -670
- package/brands.mjs +0 -123
- package/chunks/2YWCEGTS.js +0 -21
- package/chunks/34ZKUFEA.js +0 -41
- package/chunks/4WHZ4EIW.js +0 -57
- package/chunks/B4VPD3ZT.js +0 -574
- package/chunks/BM4OSDRZ.js +0 -17
- package/chunks/DCXUEDOW.mjs +0 -67
- package/chunks/MTAQE4WC.js +0 -10411
- package/chunks/PLOSYUG2.js +0 -25
- package/chunks/URIW2U5M.js +0 -17
- package/chunks/VSY5YIQY.mjs +0 -11
- package/chunks/WOYJLK4Y.js +0 -1623
- package/collections.d.mts +0 -581
- package/collections.mjs +0 -114
- package/csp-origins.d.mts +0 -273
- package/csp-origins.mjs +0 -69
- package/data-assets.d.mts +0 -205
- package/data-assets.mjs +0 -66
- package/data-connections.d.mts +0 -594
- package/data-connections.mjs +0 -103
- package/data-credentials.d.mts +0 -204
- package/data-credentials.mjs +0 -59
- package/data-files.d.mts +0 -562
- package/data-files.mjs +0 -123
- package/extensions.d.mts +0 -293
- package/extensions.mjs +0 -77
- package/global.types-5iFvFJvX.d.mts +0 -115
- package/glossaries.d.mts +0 -1173
- package/glossaries.mjs +0 -237
- package/groups.d.mts +0 -434
- package/groups.mjs +0 -88
- package/identity-providers.d.mts +0 -550
- package/identity-providers.mjs +0 -83
- package/index.d.mts +0 -142
- package/index.mjs +0 -716
- package/items.d.mts +0 -535
- package/items.mjs +0 -87
- package/licenses.d.mts +0 -459
- package/licenses.mjs +0 -92
- package/qix.d.mts +0 -11629
- package/qix.mjs +0 -10
- package/quotas.d.mts +0 -112
- package/quotas.mjs +0 -32
- package/reload-tasks.d.mts +0 -227
- package/reload-tasks.mjs +0 -62
- package/reloads.d.mts +0 -207
- package/reloads.mjs +0 -46
- package/roles.d.mts +0 -175
- package/roles.mjs +0 -31
- package/spaces.d.mts +0 -562
- package/spaces.mjs +0 -124
- package/temp-contents.d.mts +0 -167
- package/temp-contents.mjs +0 -41
- package/tenants.d.mts +0 -300
- package/tenants.mjs +0 -73
- package/themes.d.mts +0 -268
- package/themes.mjs +0 -77
- package/transports.d.mts +0 -319
- package/transports.mjs +0 -65
- package/users.d.mts +0 -631
- package/users.mjs +0 -104
- package/web-integrations.d.mts +0 -274
- package/web-integrations.mjs +0 -62
- package/web-notifications.d.mts +0 -250
- package/web-notifications.mjs +0 -69
- package/webhooks.d.mts +0 -445
- package/webhooks.mjs +0 -104
package/audits.mjs
DELETED
|
@@ -1,64 +0,0 @@
|
|
|
1
|
-
import {
|
|
2
|
-
clearApiCache,
|
|
3
|
-
invokeFetch
|
|
4
|
-
} from "./chunks/3YV6X7S6.mjs";
|
|
5
|
-
import "./chunks/EHAANYDL.mjs";
|
|
6
|
-
import "./chunks/VSY5YIQY.mjs";
|
|
7
|
-
|
|
8
|
-
// src/public/rest/audits.ts
|
|
9
|
-
var getAudits = async (query, options) => invokeFetch("audits", {
|
|
10
|
-
method: "get",
|
|
11
|
-
pathTemplate: "/api/v1/audits",
|
|
12
|
-
query,
|
|
13
|
-
options
|
|
14
|
-
});
|
|
15
|
-
var getArchivedAudits = async (query, options) => invokeFetch("audits", {
|
|
16
|
-
method: "get",
|
|
17
|
-
pathTemplate: "/api/v1/audits/archive",
|
|
18
|
-
query,
|
|
19
|
-
options
|
|
20
|
-
});
|
|
21
|
-
var getAuditsSettings = async (options) => invokeFetch("audits", {
|
|
22
|
-
method: "get",
|
|
23
|
-
pathTemplate: "/api/v1/audits/settings",
|
|
24
|
-
options
|
|
25
|
-
});
|
|
26
|
-
var getAuditSources = async (options) => invokeFetch("audits", {
|
|
27
|
-
method: "get",
|
|
28
|
-
pathTemplate: "/api/v1/audits/sources",
|
|
29
|
-
options
|
|
30
|
-
});
|
|
31
|
-
var getAuditTypes = async (options) => invokeFetch("audits", {
|
|
32
|
-
method: "get",
|
|
33
|
-
pathTemplate: "/api/v1/audits/types",
|
|
34
|
-
options
|
|
35
|
-
});
|
|
36
|
-
var getAudit = async (id, options) => invokeFetch("audits", {
|
|
37
|
-
method: "get",
|
|
38
|
-
pathTemplate: "/api/v1/audits/{id}",
|
|
39
|
-
pathVariables: { id },
|
|
40
|
-
options
|
|
41
|
-
});
|
|
42
|
-
function clearCache() {
|
|
43
|
-
return clearApiCache("audits");
|
|
44
|
-
}
|
|
45
|
-
var auditsExport = {
|
|
46
|
-
getAudits,
|
|
47
|
-
getArchivedAudits,
|
|
48
|
-
getAuditsSettings,
|
|
49
|
-
getAuditSources,
|
|
50
|
-
getAuditTypes,
|
|
51
|
-
getAudit,
|
|
52
|
-
clearCache
|
|
53
|
-
};
|
|
54
|
-
var audits_default = auditsExport;
|
|
55
|
-
export {
|
|
56
|
-
clearCache,
|
|
57
|
-
audits_default as default,
|
|
58
|
-
getArchivedAudits,
|
|
59
|
-
getAudit,
|
|
60
|
-
getAuditSources,
|
|
61
|
-
getAuditTypes,
|
|
62
|
-
getAudits,
|
|
63
|
-
getAuditsSettings
|
|
64
|
-
};
|
|
@@ -1,98 +0,0 @@
|
|
|
1
|
-
/** Credentials setting for http requests */
|
|
2
|
-
type Credentials = "include" | "same-origin" | "omit";
|
|
3
|
-
/** Props for function getRestCallAuthParams */
|
|
4
|
-
type GetRestCallAuthParamsProps<A extends AuthType = AuthType> = {
|
|
5
|
-
hostConfig: HostConfig<A>;
|
|
6
|
-
/** The HTTP method in the outgoing REST call */
|
|
7
|
-
method: string;
|
|
8
|
-
};
|
|
9
|
-
/** Http reqeust parameters for auth to use when making a rest call based on a host config */
|
|
10
|
-
type RestCallAuthParams = {
|
|
11
|
-
headers: Record<string, string>;
|
|
12
|
-
queryParams: Record<string, string>;
|
|
13
|
-
credentials: Credentials;
|
|
14
|
-
};
|
|
15
|
-
/** Props for function getWebsocketAuthParams */
|
|
16
|
-
type GetWebSocketAuthParamsProps<A extends AuthType = AuthType> = {
|
|
17
|
-
hostConfig: HostConfig<A>;
|
|
18
|
-
};
|
|
19
|
-
/** Websocket auth parameters to use when setting up a websocket based on a host config */
|
|
20
|
-
type WebSocketAuthParams = {
|
|
21
|
-
queryParams: Record<string, string>;
|
|
22
|
-
};
|
|
23
|
-
/** Props for function getWebResourceAuthParams */
|
|
24
|
-
type GetWebResourceAuthParamsProps<A extends AuthType = AuthType> = {
|
|
25
|
-
hostConfig: HostConfig<A>;
|
|
26
|
-
};
|
|
27
|
-
/** Webresource auth parameters to use when fetching a web resource with a host config */
|
|
28
|
-
type WebResourceAuthParams = {
|
|
29
|
-
queryParams: Record<string, string>;
|
|
30
|
-
};
|
|
31
|
-
/** Props for function handleAuthenticationError */
|
|
32
|
-
type HandleAuthenticationErrorProps<A extends AuthType = AuthType> = {
|
|
33
|
-
/** host conifg for connecting to a host */
|
|
34
|
-
hostConfig: HostConfig<A>;
|
|
35
|
-
/** HTTP status of the response */
|
|
36
|
-
status: number;
|
|
37
|
-
/** Body of the error response */
|
|
38
|
-
errorBody?: Record<string, unknown>;
|
|
39
|
-
/** HTTP response headers */
|
|
40
|
-
headers: Headers;
|
|
41
|
-
/** Set to true if it is possible to perform a retry. This will be true for the first call, and false if the call is actually a retry */
|
|
42
|
-
canRetry: boolean;
|
|
43
|
-
};
|
|
44
|
-
/** Action to take when error occurs during authentication */
|
|
45
|
-
type AuthenticationErrorAction = {
|
|
46
|
-
/**
|
|
47
|
-
* If set to true the request will be retried and its AuthParams will be fetched again
|
|
48
|
-
*/
|
|
49
|
-
retry?: boolean;
|
|
50
|
-
/**
|
|
51
|
-
* Set to true to prevent the api call result promise from ever resolving.
|
|
52
|
-
* Typically used when redirecting the window to a login page to prevent
|
|
53
|
-
* transient errors from happening in the page while the browser is loading the login page.
|
|
54
|
-
*/
|
|
55
|
-
preventDefault?: boolean;
|
|
56
|
-
};
|
|
57
|
-
/** An authentication module for a specific authentication format, like oauth, cookies etc */
|
|
58
|
-
type AuthModule<A extends AuthType = AuthType> = {
|
|
59
|
-
/** Get auth params for rest api calls */
|
|
60
|
-
getRestCallAuthParams: (props: GetRestCallAuthParamsProps<A>) => Promise<RestCallAuthParams>;
|
|
61
|
-
/** Get auth params for websocket api calls */
|
|
62
|
-
getWebSocketAuthParams: (props: GetWebSocketAuthParamsProps<A>) => Promise<WebSocketAuthParams>;
|
|
63
|
-
/** Get auth params for web resource request */
|
|
64
|
-
getWebResourceAuthParams?: (props: GetWebResourceAuthParamsProps<A>) => Promise<WebResourceAuthParams>;
|
|
65
|
-
/** Callback for when auth error happens */
|
|
66
|
-
handleAuthenticationError: (props: HandleAuthenticationErrorProps<A>) => Promise<AuthenticationErrorAction>;
|
|
67
|
-
/** Runtime check for validating host config */
|
|
68
|
-
validateHostConfig?: (hostConfig: Record<string, unknown>) => boolean;
|
|
69
|
-
};
|
|
70
|
-
/** Valid strings for known authentication types */
|
|
71
|
-
type AuthType = keyof QlikAuthModules;
|
|
72
|
-
/** Configuration object for connecting and authenticating with Qlik platform(s) */
|
|
73
|
-
type HostConfig<A extends AuthType = AuthType> = {
|
|
74
|
-
[K in keyof QlikAuthModules]: QlikAuthModuleConfigUnion<K> & HostConfigCommon;
|
|
75
|
-
}[A];
|
|
76
|
-
/** The keys in this interface are used to determine what auth types that are allowed to be set to undefined */
|
|
77
|
-
interface ImplicitQlikAuthModules {
|
|
78
|
-
apikey: object;
|
|
79
|
-
oauth2: object;
|
|
80
|
-
cookie: object;
|
|
81
|
-
}
|
|
82
|
-
type QlikAuthModuleConfigUnion<K extends keyof QlikAuthModules> = (K extends keyof ImplicitQlikAuthModules ? {
|
|
83
|
-
authType?: K;
|
|
84
|
-
} : {
|
|
85
|
-
authType: K;
|
|
86
|
-
}) & QlikAuthModules[K]["config"];
|
|
87
|
-
type HostConfigCommon = {
|
|
88
|
-
/** The URL to the cloud tenant or windows server. If scheme is excluded https is used. May include a virtual proxy prefix on windows. Any trailing slashes are stripped. */
|
|
89
|
-
host?: string;
|
|
90
|
-
autoRedirect?: boolean;
|
|
91
|
-
authRedirectUserConfirmation?: () => Promise<void>;
|
|
92
|
-
/**
|
|
93
|
-
* Optional parameter that can be used to point to a Qlik Cloud tenant domain from which the embed runtime should be loaded. If omitted the host parameter will be used.
|
|
94
|
-
*/
|
|
95
|
-
embedRuntimeUrl?: string;
|
|
96
|
-
};
|
|
97
|
-
|
|
98
|
-
export type { AuthType as A, Credentials as C, GetRestCallAuthParamsProps as G, HostConfig as H, RestCallAuthParams as R, WebSocketAuthParams as W, AuthModule as a, GetWebSocketAuthParamsProps as b, GetWebResourceAuthParamsProps as c, WebResourceAuthParams as d, HandleAuthenticationErrorProps as e, AuthenticationErrorAction as f };
|
package/auth.d.mts
DELETED
|
@@ -1,26 +0,0 @@
|
|
|
1
|
-
import { A as AuthType, a as AuthModule, H as HostConfig } from './auth-types-nnUcWhuU.mjs';
|
|
2
|
-
export { f as AuthenticationErrorAction, C as Credentials, G as GetRestCallAuthParamsProps, c as GetWebResourceAuthParamsProps, b as GetWebSocketAuthParamsProps, e as HandleAuthenticationErrorProps, R as RestCallAuthParams, d as WebResourceAuthParams, W as WebSocketAuthParams } from './auth-types-nnUcWhuU.mjs';
|
|
3
|
-
|
|
4
|
-
/**
|
|
5
|
-
* Registers an auth module that can handle authentication. An auth module is used by specifying its name as authType in the HostConfig passed in to api calls.
|
|
6
|
-
* @param name the name of the module
|
|
7
|
-
* @param authModule the implementation of the AuthModule interface
|
|
8
|
-
*/
|
|
9
|
-
declare function registerAuthModule<A extends AuthType>(name: A, authModule: AuthModule<A>): void;
|
|
10
|
-
/**
|
|
11
|
-
* Logs out the user and sets `global.loggingOut` to true.
|
|
12
|
-
*
|
|
13
|
-
* **NOTE**: Does not abort pending requests.
|
|
14
|
-
*/
|
|
15
|
-
declare function logout(): void;
|
|
16
|
-
/**
|
|
17
|
-
* Sets the default host config that will be used for all qmfe api calls that do not inclue a HostConfig
|
|
18
|
-
* @param hostConfig the default HostConfig to use
|
|
19
|
-
*/
|
|
20
|
-
declare function setDefaultHostConfig(hostConfig: HostConfig | undefined): void;
|
|
21
|
-
declare const _default: {
|
|
22
|
-
registerAuthModule: typeof registerAuthModule;
|
|
23
|
-
setDefaultHostConfig: typeof setDefaultHostConfig;
|
|
24
|
-
};
|
|
25
|
-
|
|
26
|
-
export { AuthModule, AuthType, HostConfig, _default as default, logout, registerAuthModule, setDefaultHostConfig };
|
package/auth.mjs
DELETED
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
import {
|
|
2
|
-
auth_default,
|
|
3
|
-
logout,
|
|
4
|
-
registerAuthModule,
|
|
5
|
-
setDefaultHostConfig
|
|
6
|
-
} from "./chunks/6AD3HYSF.mjs";
|
|
7
|
-
import "./chunks/EHAANYDL.mjs";
|
|
8
|
-
import "./chunks/VSY5YIQY.mjs";
|
|
9
|
-
export {
|
|
10
|
-
auth_default as default,
|
|
11
|
-
logout,
|
|
12
|
-
registerAuthModule,
|
|
13
|
-
setDefaultHostConfig
|
|
14
|
-
};
|