@qlik/api 0.0.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/LICENSE +17 -0
- package/README.md +8 -0
- package/api-keys.d.mts +313 -0
- package/api-keys.d.ts +313 -0
- package/api-keys.js +76 -0
- package/api-keys.mjs +76 -0
- package/apps.d.mts +1921 -0
- package/apps.d.ts +1921 -0
- package/apps.js +331 -0
- package/apps.mjs +331 -0
- package/audits.d.mts +262 -0
- package/audits.d.ts +262 -0
- package/audits.js +63 -0
- package/audits.mjs +63 -0
- package/auth-CSVTXOZX.js +36 -0
- package/auth-TE272Q34.mjs +36 -0
- package/auth-types-nnUcWhuU.d.mts +98 -0
- package/auth-types-nnUcWhuU.d.ts +98 -0
- package/auth.d.mts +26 -0
- package/auth.d.ts +26 -0
- package/auth.js +13 -0
- package/auth.mjs +13 -0
- package/automations.d.mts +638 -0
- package/automations.d.ts +638 -0
- package/automations.js +166 -0
- package/automations.mjs +166 -0
- package/brands.d.mts +614 -0
- package/brands.d.ts +614 -0
- package/brands.js +118 -0
- package/brands.mjs +118 -0
- package/chunk-3YE7EI7I.mjs +17 -0
- package/chunk-4ES65KO3.js +57 -0
- package/chunk-4FLMND6T.js +25 -0
- package/chunk-4OMEH5SW.mjs +1337 -0
- package/chunk-CKPJE4IA.mjs +57 -0
- package/chunk-GUQBHY3H.mjs +25 -0
- package/chunk-OULT3V2U.js +17 -0
- package/chunk-WM7FQU2U.mjs +21 -0
- package/chunk-XASXL2NC.js +1337 -0
- package/chunk-ZT4C7KCQ.js +21 -0
- package/collections.d.mts +535 -0
- package/collections.d.ts +535 -0
- package/collections.js +100 -0
- package/collections.mjs +100 -0
- package/csp-origins.d.mts +258 -0
- package/csp-origins.d.ts +258 -0
- package/csp-origins.js +66 -0
- package/csp-origins.mjs +66 -0
- package/data-assets.d.mts +195 -0
- package/data-assets.d.ts +195 -0
- package/data-assets.js +61 -0
- package/data-assets.mjs +61 -0
- package/data-connections.d.mts +527 -0
- package/data-connections.d.ts +527 -0
- package/data-connections.js +96 -0
- package/data-connections.mjs +96 -0
- package/data-credentials.d.mts +188 -0
- package/data-credentials.d.ts +188 -0
- package/data-credentials.js +56 -0
- package/data-credentials.mjs +56 -0
- package/data-files.d.mts +471 -0
- package/data-files.d.ts +471 -0
- package/data-files.js +116 -0
- package/data-files.mjs +116 -0
- package/docs/examples.md +4 -0
- package/enigma-session-4L373ALV.mjs +10196 -0
- package/enigma-session-TEB53FAF.js +10196 -0
- package/esm-4X3DKK5D.js +63 -0
- package/esm-SOWVJKOQ.mjs +63 -0
- package/extensions.d.mts +257 -0
- package/extensions.d.ts +257 -0
- package/extensions.js +74 -0
- package/extensions.mjs +74 -0
- package/global.types-Eto4uYwy.d.mts +102 -0
- package/global.types-hIvp-WdX.d.ts +102 -0
- package/glossaries.d.mts +1041 -0
- package/glossaries.d.ts +1041 -0
- package/glossaries.js +225 -0
- package/glossaries.mjs +225 -0
- package/groups.d.mts +379 -0
- package/groups.d.ts +379 -0
- package/groups.js +83 -0
- package/groups.mjs +83 -0
- package/identity-providers.d.mts +492 -0
- package/identity-providers.d.ts +492 -0
- package/identity-providers.js +80 -0
- package/identity-providers.mjs +80 -0
- package/index.d.mts +142 -0
- package/index.d.ts +142 -0
- package/index.js +678 -0
- package/index.mjs +678 -0
- package/invoke-fetch-MSSJAZ7K.mjs +14 -0
- package/invoke-fetch-PEI54KZO.js +14 -0
- package/items.d.mts +501 -0
- package/items.d.ts +501 -0
- package/items.js +84 -0
- package/items.mjs +84 -0
- package/licenses.d.mts +436 -0
- package/licenses.d.ts +436 -0
- package/licenses.js +87 -0
- package/licenses.mjs +87 -0
- package/package.json +264 -0
- package/qix-EU7PXRZ6.mjs +573 -0
- package/qix-RLTISYTB.js +573 -0
- package/qix.d.mts +11543 -0
- package/qix.d.ts +11543 -0
- package/qix.js +9 -0
- package/qix.mjs +9 -0
- package/quotas.d.mts +105 -0
- package/quotas.d.ts +105 -0
- package/quotas.js +31 -0
- package/quotas.mjs +31 -0
- package/reload-tasks.d.mts +222 -0
- package/reload-tasks.d.ts +222 -0
- package/reload-tasks.js +59 -0
- package/reload-tasks.mjs +59 -0
- package/reloads.d.mts +189 -0
- package/reloads.d.ts +189 -0
- package/reloads.js +44 -0
- package/reloads.mjs +44 -0
- package/roles.d.mts +150 -0
- package/roles.d.ts +150 -0
- package/roles.js +30 -0
- package/roles.mjs +30 -0
- package/spaces.d.mts +524 -0
- package/spaces.d.ts +524 -0
- package/spaces.js +118 -0
- package/spaces.mjs +118 -0
- package/temp-contents.d.mts +222 -0
- package/temp-contents.d.ts +222 -0
- package/temp-contents.js +60 -0
- package/temp-contents.mjs +60 -0
- package/tenants.d.mts +276 -0
- package/tenants.d.ts +276 -0
- package/tenants.js +68 -0
- package/tenants.mjs +68 -0
- package/themes.d.mts +235 -0
- package/themes.d.ts +235 -0
- package/themes.js +74 -0
- package/themes.mjs +74 -0
- package/transports.d.mts +298 -0
- package/transports.d.ts +298 -0
- package/transports.js +62 -0
- package/transports.mjs +62 -0
- package/users.d.mts +544 -0
- package/users.d.ts +544 -0
- package/users.js +99 -0
- package/users.mjs +99 -0
- package/web-integrations.d.mts +246 -0
- package/web-integrations.d.ts +246 -0
- package/web-integrations.js +59 -0
- package/web-integrations.mjs +59 -0
- package/web-notifications.d.mts +220 -0
- package/web-notifications.d.ts +220 -0
- package/web-notifications.js +66 -0
- package/web-notifications.mjs +66 -0
- package/webhooks.d.mts +422 -0
- package/webhooks.d.ts +422 -0
- package/webhooks.js +100 -0
- package/webhooks.mjs +100 -0
package/reloads.d.ts
ADDED
|
@@ -0,0 +1,189 @@
|
|
|
1
|
+
import { A as ApiCallOptions } from './global.types-hIvp-WdX.js';
|
|
2
|
+
import './auth-types-nnUcWhuU.js';
|
|
3
|
+
|
|
4
|
+
type Error = {
|
|
5
|
+
/** The error code is in form of 'RELOADS-xxx'. ranges from 'RELOADS-001' to 'RELOADS-013'. */
|
|
6
|
+
code: string;
|
|
7
|
+
detail?: string;
|
|
8
|
+
title: string;
|
|
9
|
+
};
|
|
10
|
+
type Errors = {
|
|
11
|
+
errors?: Error[];
|
|
12
|
+
};
|
|
13
|
+
type Href = {
|
|
14
|
+
href?: string;
|
|
15
|
+
};
|
|
16
|
+
type Partial = boolean;
|
|
17
|
+
type Reload = {
|
|
18
|
+
/** The ID of the app. */
|
|
19
|
+
appId: string;
|
|
20
|
+
/** The time the reload job was created. */
|
|
21
|
+
creationTime: string;
|
|
22
|
+
/** The time the reload job finished. */
|
|
23
|
+
endTime?: string;
|
|
24
|
+
/** The timestamp returned from the Sense engine upon successful reload. */
|
|
25
|
+
engineTime?: string;
|
|
26
|
+
/** The ID of the reload. */
|
|
27
|
+
id: string;
|
|
28
|
+
links?: ReloadLinks;
|
|
29
|
+
/** The log describing the result of the latest reload execution from the request. */
|
|
30
|
+
log?: string;
|
|
31
|
+
/** The boolean value used to present the reload is partial or not. */
|
|
32
|
+
partial?: Partial;
|
|
33
|
+
/** The time the reload job was consumed from the queue. */
|
|
34
|
+
startTime?: string;
|
|
35
|
+
/** The status of the reload. There are seven statuses. `QUEUED`, `RELOADING`, `CANCELING` are the active statuses. `SUCCEEDED`, `FAILED`, `CANCELED`, `EXCEEDED_LIMIT` are the end statuses. */
|
|
36
|
+
status: Status;
|
|
37
|
+
/** The ID of the tenant who owns the reload. */
|
|
38
|
+
tenantId: string;
|
|
39
|
+
/** What initiated the reload: hub = one-time reload manually triggered in hub, chronos = time based scheduled reload triggered by chronos, external = reload triggered via external API request, automations = reload triggered in automation, data-refresh = reload triggered by refresh of data. */
|
|
40
|
+
type: "hub" | "chronos" | "external" | "automations" | "data-refresh";
|
|
41
|
+
/** The ID of the user who created the reload. */
|
|
42
|
+
userId: string;
|
|
43
|
+
};
|
|
44
|
+
type ReloadLinks = {
|
|
45
|
+
self?: Href;
|
|
46
|
+
};
|
|
47
|
+
type ReloadRequest = {
|
|
48
|
+
/** The ID of the app to be reloaded. */
|
|
49
|
+
appId: string;
|
|
50
|
+
/** The boolean value used to present the reload is partial or not */
|
|
51
|
+
partial?: boolean;
|
|
52
|
+
};
|
|
53
|
+
type Reloads = {
|
|
54
|
+
data: Reload[];
|
|
55
|
+
links: ReloadsLinks;
|
|
56
|
+
};
|
|
57
|
+
type ReloadsLinks = ReloadLinks & {
|
|
58
|
+
next?: Href;
|
|
59
|
+
prev?: Href;
|
|
60
|
+
};
|
|
61
|
+
type Status = "QUEUED" | "RELOADING" | "CANCELING" | "SUCCEEDED" | "FAILED" | "CANCELED" | "EXCEEDED_LIMIT";
|
|
62
|
+
/**
|
|
63
|
+
* Finds and returns the reloads that the user has access to.
|
|
64
|
+
* @param query an object with query parameters
|
|
65
|
+
* @throws GetReloadsHttpError
|
|
66
|
+
*/
|
|
67
|
+
declare const getReloads: (query: {
|
|
68
|
+
/** The UUID formatted string used to search for an app's reload history entries. TenantAdmin users may omit this parameter to list all reload history in the tenant. */
|
|
69
|
+
appId?: string;
|
|
70
|
+
/** SCIM filter expression used to search for reloads.
|
|
71
|
+
// The filter syntax is defined in RFC 7644 section 3.4.2.2
|
|
72
|
+
//
|
|
73
|
+
// Supported attributes:
|
|
74
|
+
// - status: see #schemas/Status
|
|
75
|
+
// - partial: see #schemas/Partial
|
|
76
|
+
//
|
|
77
|
+
// Supported operators:
|
|
78
|
+
// - eq
|
|
79
|
+
// */
|
|
80
|
+
filter?: string;
|
|
81
|
+
/** The maximum number of resources to return for a request. The limit must be an integer between 1 and 100 (inclusive). */
|
|
82
|
+
limit?: number;
|
|
83
|
+
/** The boolean value used to include the log field or not, default is included, set log=false to exclude the log field. */
|
|
84
|
+
log?: boolean;
|
|
85
|
+
/** The cursor to the next page of resources. Provide either the next or prev cursor, but not both. */
|
|
86
|
+
next?: string;
|
|
87
|
+
/** The boolean value used to search for a reload is partial or not. */
|
|
88
|
+
partial?: boolean;
|
|
89
|
+
/** The cursor to the previous page of resources. Provide either the next or prev cursor, but not both. */
|
|
90
|
+
prev?: string;
|
|
91
|
+
}, options?: ApiCallOptions) => Promise<GetReloadsHttpResponse>;
|
|
92
|
+
type GetReloadsHttpResponse = {
|
|
93
|
+
data: Reloads;
|
|
94
|
+
headers: Headers;
|
|
95
|
+
status: number;
|
|
96
|
+
};
|
|
97
|
+
type GetReloadsHttpError = {
|
|
98
|
+
data: Errors;
|
|
99
|
+
headers: Headers;
|
|
100
|
+
status: number;
|
|
101
|
+
};
|
|
102
|
+
/**
|
|
103
|
+
* Reloads an app specified by an app ID.
|
|
104
|
+
* @param body an object with the body content
|
|
105
|
+
* @throws QueueReloadHttpError
|
|
106
|
+
*/
|
|
107
|
+
declare const queueReload: (body: ReloadRequest, options?: ApiCallOptions) => Promise<QueueReloadHttpResponse>;
|
|
108
|
+
type QueueReloadHttpResponse = {
|
|
109
|
+
data: Reload;
|
|
110
|
+
headers: Headers;
|
|
111
|
+
status: number;
|
|
112
|
+
};
|
|
113
|
+
type QueueReloadHttpError = {
|
|
114
|
+
data: Errors;
|
|
115
|
+
headers: Headers;
|
|
116
|
+
status: number;
|
|
117
|
+
};
|
|
118
|
+
/**
|
|
119
|
+
* Finds and returns a reload record
|
|
120
|
+
* @param reloadId The unique identifier of the reload.
|
|
121
|
+
* @throws GetReloadHttpError
|
|
122
|
+
*/
|
|
123
|
+
declare const getReload: (reloadId: string, options?: ApiCallOptions) => Promise<GetReloadHttpResponse>;
|
|
124
|
+
type GetReloadHttpResponse = {
|
|
125
|
+
data: Reload;
|
|
126
|
+
headers: Headers;
|
|
127
|
+
status: number;
|
|
128
|
+
};
|
|
129
|
+
type GetReloadHttpError = {
|
|
130
|
+
data: Errors;
|
|
131
|
+
headers: Headers;
|
|
132
|
+
status: number;
|
|
133
|
+
};
|
|
134
|
+
/**
|
|
135
|
+
* Cancels a reload that is in progress or has been queued
|
|
136
|
+
* @param reloadId The unique identifier of the reload.
|
|
137
|
+
* @throws CancelReloadHttpError
|
|
138
|
+
*/
|
|
139
|
+
declare const cancelReload: (reloadId: string, options?: ApiCallOptions) => Promise<CancelReloadHttpResponse>;
|
|
140
|
+
type CancelReloadHttpResponse = {
|
|
141
|
+
data: void;
|
|
142
|
+
headers: Headers;
|
|
143
|
+
status: number;
|
|
144
|
+
};
|
|
145
|
+
type CancelReloadHttpError = {
|
|
146
|
+
data: Errors;
|
|
147
|
+
headers: Headers;
|
|
148
|
+
status: number;
|
|
149
|
+
};
|
|
150
|
+
/**
|
|
151
|
+
* Clears the cache for reloads api requests.
|
|
152
|
+
*/
|
|
153
|
+
declare function clearCache(): void;
|
|
154
|
+
interface ReloadsAPI {
|
|
155
|
+
/**
|
|
156
|
+
* Finds and returns the reloads that the user has access to.
|
|
157
|
+
* @param query an object with query parameters
|
|
158
|
+
* @throws GetReloadsHttpError
|
|
159
|
+
*/
|
|
160
|
+
getReloads: typeof getReloads;
|
|
161
|
+
/**
|
|
162
|
+
* Reloads an app specified by an app ID.
|
|
163
|
+
* @param body an object with the body content
|
|
164
|
+
* @throws QueueReloadHttpError
|
|
165
|
+
*/
|
|
166
|
+
queueReload: typeof queueReload;
|
|
167
|
+
/**
|
|
168
|
+
* Finds and returns a reload record
|
|
169
|
+
* @param reloadId The unique identifier of the reload.
|
|
170
|
+
* @throws GetReloadHttpError
|
|
171
|
+
*/
|
|
172
|
+
getReload: typeof getReload;
|
|
173
|
+
/**
|
|
174
|
+
* Cancels a reload that is in progress or has been queued
|
|
175
|
+
* @param reloadId The unique identifier of the reload.
|
|
176
|
+
* @throws CancelReloadHttpError
|
|
177
|
+
*/
|
|
178
|
+
cancelReload: typeof cancelReload;
|
|
179
|
+
/**
|
|
180
|
+
* Clears the cache for reloads api requests.
|
|
181
|
+
*/
|
|
182
|
+
clearCache: typeof clearCache;
|
|
183
|
+
}
|
|
184
|
+
/**
|
|
185
|
+
* Functions for the reloads api
|
|
186
|
+
*/
|
|
187
|
+
declare const reloadsExport: ReloadsAPI;
|
|
188
|
+
|
|
189
|
+
export { type CancelReloadHttpError, type CancelReloadHttpResponse, type Error, type Errors, type GetReloadHttpError, type GetReloadHttpResponse, type GetReloadsHttpError, type GetReloadsHttpResponse, type Href, type Partial, type QueueReloadHttpError, type QueueReloadHttpResponse, type Reload, type ReloadLinks, type ReloadRequest, type Reloads, type ReloadsAPI, type ReloadsLinks, type Status, cancelReload, clearCache, reloadsExport as default, getReload, getReloads, queueReload };
|
package/reloads.js
ADDED
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports, "__esModule", {value: true});
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
var _chunkOULT3V2Ujs = require('./chunk-OULT3V2U.js');
|
|
5
|
+
require('./chunk-ZT4C7KCQ.js');
|
|
6
|
+
|
|
7
|
+
// src/public/rest/reloads.ts
|
|
8
|
+
var getReloads = async (query, options) => _chunkOULT3V2Ujs.invokeFetch.call(void 0, "reloads", {
|
|
9
|
+
method: "get",
|
|
10
|
+
pathTemplate: "/api/v1/reloads",
|
|
11
|
+
query,
|
|
12
|
+
options
|
|
13
|
+
});
|
|
14
|
+
var queueReload = async (body, options) => _chunkOULT3V2Ujs.invokeFetch.call(void 0, "reloads", {
|
|
15
|
+
method: "post",
|
|
16
|
+
pathTemplate: "/api/v1/reloads",
|
|
17
|
+
body,
|
|
18
|
+
options
|
|
19
|
+
});
|
|
20
|
+
var getReload = async (reloadId, options) => _chunkOULT3V2Ujs.invokeFetch.call(void 0, "reloads", {
|
|
21
|
+
method: "get",
|
|
22
|
+
pathTemplate: "/api/v1/reloads/{reloadId}",
|
|
23
|
+
pathVariables: { reloadId },
|
|
24
|
+
options
|
|
25
|
+
});
|
|
26
|
+
var cancelReload = async (reloadId, options) => _chunkOULT3V2Ujs.invokeFetch.call(void 0, "reloads", {
|
|
27
|
+
method: "post",
|
|
28
|
+
pathTemplate: "/api/v1/reloads/{reloadId}/actions/cancel",
|
|
29
|
+
pathVariables: { reloadId },
|
|
30
|
+
options
|
|
31
|
+
});
|
|
32
|
+
function clearCache() {
|
|
33
|
+
return _chunkOULT3V2Ujs.clearApiCache.call(void 0, "reloads");
|
|
34
|
+
}
|
|
35
|
+
var reloadsExport = { getReloads, queueReload, getReload, cancelReload, clearCache };
|
|
36
|
+
var reloads_default = reloadsExport;
|
|
37
|
+
|
|
38
|
+
|
|
39
|
+
|
|
40
|
+
|
|
41
|
+
|
|
42
|
+
|
|
43
|
+
|
|
44
|
+
exports.cancelReload = cancelReload; exports.clearCache = clearCache; exports.default = reloads_default; exports.getReload = getReload; exports.getReloads = getReloads; exports.queueReload = queueReload;
|
package/reloads.mjs
ADDED
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
import {
|
|
2
|
+
clearApiCache,
|
|
3
|
+
invokeFetch
|
|
4
|
+
} from "./chunk-3YE7EI7I.mjs";
|
|
5
|
+
import "./chunk-WM7FQU2U.mjs";
|
|
6
|
+
|
|
7
|
+
// src/public/rest/reloads.ts
|
|
8
|
+
var getReloads = async (query, options) => invokeFetch("reloads", {
|
|
9
|
+
method: "get",
|
|
10
|
+
pathTemplate: "/api/v1/reloads",
|
|
11
|
+
query,
|
|
12
|
+
options
|
|
13
|
+
});
|
|
14
|
+
var queueReload = async (body, options) => invokeFetch("reloads", {
|
|
15
|
+
method: "post",
|
|
16
|
+
pathTemplate: "/api/v1/reloads",
|
|
17
|
+
body,
|
|
18
|
+
options
|
|
19
|
+
});
|
|
20
|
+
var getReload = async (reloadId, options) => invokeFetch("reloads", {
|
|
21
|
+
method: "get",
|
|
22
|
+
pathTemplate: "/api/v1/reloads/{reloadId}",
|
|
23
|
+
pathVariables: { reloadId },
|
|
24
|
+
options
|
|
25
|
+
});
|
|
26
|
+
var cancelReload = async (reloadId, options) => invokeFetch("reloads", {
|
|
27
|
+
method: "post",
|
|
28
|
+
pathTemplate: "/api/v1/reloads/{reloadId}/actions/cancel",
|
|
29
|
+
pathVariables: { reloadId },
|
|
30
|
+
options
|
|
31
|
+
});
|
|
32
|
+
function clearCache() {
|
|
33
|
+
return clearApiCache("reloads");
|
|
34
|
+
}
|
|
35
|
+
var reloadsExport = { getReloads, queueReload, getReload, cancelReload, clearCache };
|
|
36
|
+
var reloads_default = reloadsExport;
|
|
37
|
+
export {
|
|
38
|
+
cancelReload,
|
|
39
|
+
clearCache,
|
|
40
|
+
reloads_default as default,
|
|
41
|
+
getReload,
|
|
42
|
+
getReloads,
|
|
43
|
+
queueReload
|
|
44
|
+
};
|
package/roles.d.mts
ADDED
|
@@ -0,0 +1,150 @@
|
|
|
1
|
+
import { A as ApiCallOptions } from './global.types-Eto4uYwy.mjs';
|
|
2
|
+
import './auth-types-nnUcWhuU.mjs';
|
|
3
|
+
|
|
4
|
+
type Error = {
|
|
5
|
+
/** The error code. */
|
|
6
|
+
code: string;
|
|
7
|
+
/** A human-readable explanation specific to this occurrence of the problem. */
|
|
8
|
+
detail?: string;
|
|
9
|
+
/** Additional properties relating to the error. */
|
|
10
|
+
meta?: unknown;
|
|
11
|
+
/** References to the source of the error. */
|
|
12
|
+
source?: {
|
|
13
|
+
/** The URI query parameter that caused the error. */
|
|
14
|
+
parameter?: string;
|
|
15
|
+
/** A JSON Pointer to the property that caused the error. */
|
|
16
|
+
pointer?: string;
|
|
17
|
+
};
|
|
18
|
+
/** Summary of the problem. */
|
|
19
|
+
title: string;
|
|
20
|
+
};
|
|
21
|
+
type Errors = {
|
|
22
|
+
/** An array of errors related to the operation. */
|
|
23
|
+
errors?: Error[];
|
|
24
|
+
/** A unique identifier for tracing the error. */
|
|
25
|
+
traceId?: string;
|
|
26
|
+
};
|
|
27
|
+
type Links = {
|
|
28
|
+
/** Link to the next page of items */
|
|
29
|
+
next?: {
|
|
30
|
+
href: string;
|
|
31
|
+
};
|
|
32
|
+
/** Link to the previous page of items */
|
|
33
|
+
prev?: {
|
|
34
|
+
href: string;
|
|
35
|
+
};
|
|
36
|
+
/** Link to the current page of items */
|
|
37
|
+
self: {
|
|
38
|
+
href: string;
|
|
39
|
+
};
|
|
40
|
+
};
|
|
41
|
+
type ListRolesResult = {
|
|
42
|
+
/** An array of roles. */
|
|
43
|
+
data: Role[];
|
|
44
|
+
/** Contains pagination links */
|
|
45
|
+
links: Links;
|
|
46
|
+
/** Indicates the total number of matching documents. Will only be returned if the query parameter "totalResults" is true. */
|
|
47
|
+
totalResults?: number;
|
|
48
|
+
};
|
|
49
|
+
type Role = {
|
|
50
|
+
/** The timestamp for when the role was created. */
|
|
51
|
+
createdAt: string;
|
|
52
|
+
/** Descriptive text for the role. */
|
|
53
|
+
description: string;
|
|
54
|
+
/** The unique identifier for the role. */
|
|
55
|
+
readonly id: string;
|
|
56
|
+
/** The timestamp for when the role was last updated. */
|
|
57
|
+
lastUpdatedAt: string;
|
|
58
|
+
/** The level of access associated to the role. */
|
|
59
|
+
level?: "admin" | "user";
|
|
60
|
+
/** Contains links for the role. */
|
|
61
|
+
links: {
|
|
62
|
+
self: {
|
|
63
|
+
/** Link to the role. */
|
|
64
|
+
href: string;
|
|
65
|
+
};
|
|
66
|
+
};
|
|
67
|
+
/** The name of the role. */
|
|
68
|
+
name: string;
|
|
69
|
+
/** An array of permissions associated with the role. */
|
|
70
|
+
permissions?: string[];
|
|
71
|
+
/** The tenant unique identifier associated with the given Role. */
|
|
72
|
+
tenantId: string;
|
|
73
|
+
/** The type of role. */
|
|
74
|
+
type: "default";
|
|
75
|
+
};
|
|
76
|
+
/**
|
|
77
|
+
* Returns a list of roles using cursor-based pagination.
|
|
78
|
+
* @param query an object with query parameters
|
|
79
|
+
* @throws GetRolesHttpError
|
|
80
|
+
*/
|
|
81
|
+
declare const getRoles: (query: {
|
|
82
|
+
/** The advanced filtering to use for the query. Refer to [RFC 7644](https://datatracker.ietf.org/doc/rfc7644/) for the syntax. All conditional statements within this query parameter are case insensitive. */
|
|
83
|
+
filter?: string;
|
|
84
|
+
/** The number of roles to retrieve. */
|
|
85
|
+
limit?: number;
|
|
86
|
+
/** The next page cursor. */
|
|
87
|
+
next?: string;
|
|
88
|
+
/** The previous page cursor. */
|
|
89
|
+
prev?: string;
|
|
90
|
+
/** Optional resource field name to sort on, eg. name. Can be prefixed with +/- to determine order, defaults to (+) ascending. */
|
|
91
|
+
sort?: string;
|
|
92
|
+
/** Determines wether to return a count of the total records matched in the query. Defaults to false. */
|
|
93
|
+
totalResults?: boolean;
|
|
94
|
+
}, options?: ApiCallOptions) => Promise<GetRolesHttpResponse>;
|
|
95
|
+
type GetRolesHttpResponse = {
|
|
96
|
+
data: ListRolesResult;
|
|
97
|
+
headers: Headers;
|
|
98
|
+
status: number;
|
|
99
|
+
prev?: (options?: ApiCallOptions) => Promise<GetRolesHttpResponse>;
|
|
100
|
+
next?: (options?: ApiCallOptions) => Promise<GetRolesHttpResponse>;
|
|
101
|
+
};
|
|
102
|
+
type GetRolesHttpError = {
|
|
103
|
+
data: Errors;
|
|
104
|
+
headers: Headers;
|
|
105
|
+
status: number;
|
|
106
|
+
};
|
|
107
|
+
/**
|
|
108
|
+
* Returns the requested role.
|
|
109
|
+
* @param id The role's unique identifier
|
|
110
|
+
* @throws GetRoleHttpError
|
|
111
|
+
*/
|
|
112
|
+
declare const getRole: (id: string, options?: ApiCallOptions) => Promise<GetRoleHttpResponse>;
|
|
113
|
+
type GetRoleHttpResponse = {
|
|
114
|
+
data: Role;
|
|
115
|
+
headers: Headers;
|
|
116
|
+
status: number;
|
|
117
|
+
};
|
|
118
|
+
type GetRoleHttpError = {
|
|
119
|
+
data: Errors;
|
|
120
|
+
headers: Headers;
|
|
121
|
+
status: number;
|
|
122
|
+
};
|
|
123
|
+
/**
|
|
124
|
+
* Clears the cache for roles api requests.
|
|
125
|
+
*/
|
|
126
|
+
declare function clearCache(): void;
|
|
127
|
+
interface RolesAPI {
|
|
128
|
+
/**
|
|
129
|
+
* Returns a list of roles using cursor-based pagination.
|
|
130
|
+
* @param query an object with query parameters
|
|
131
|
+
* @throws GetRolesHttpError
|
|
132
|
+
*/
|
|
133
|
+
getRoles: typeof getRoles;
|
|
134
|
+
/**
|
|
135
|
+
* Returns the requested role.
|
|
136
|
+
* @param id The role's unique identifier
|
|
137
|
+
* @throws GetRoleHttpError
|
|
138
|
+
*/
|
|
139
|
+
getRole: typeof getRole;
|
|
140
|
+
/**
|
|
141
|
+
* Clears the cache for roles api requests.
|
|
142
|
+
*/
|
|
143
|
+
clearCache: typeof clearCache;
|
|
144
|
+
}
|
|
145
|
+
/**
|
|
146
|
+
* Functions for the roles api
|
|
147
|
+
*/
|
|
148
|
+
declare const rolesExport: RolesAPI;
|
|
149
|
+
|
|
150
|
+
export { type Error, type Errors, type GetRoleHttpError, type GetRoleHttpResponse, type GetRolesHttpError, type GetRolesHttpResponse, type Links, type ListRolesResult, type Role, type RolesAPI, clearCache, rolesExport as default, getRole, getRoles };
|
package/roles.d.ts
ADDED
|
@@ -0,0 +1,150 @@
|
|
|
1
|
+
import { A as ApiCallOptions } from './global.types-hIvp-WdX.js';
|
|
2
|
+
import './auth-types-nnUcWhuU.js';
|
|
3
|
+
|
|
4
|
+
type Error = {
|
|
5
|
+
/** The error code. */
|
|
6
|
+
code: string;
|
|
7
|
+
/** A human-readable explanation specific to this occurrence of the problem. */
|
|
8
|
+
detail?: string;
|
|
9
|
+
/** Additional properties relating to the error. */
|
|
10
|
+
meta?: unknown;
|
|
11
|
+
/** References to the source of the error. */
|
|
12
|
+
source?: {
|
|
13
|
+
/** The URI query parameter that caused the error. */
|
|
14
|
+
parameter?: string;
|
|
15
|
+
/** A JSON Pointer to the property that caused the error. */
|
|
16
|
+
pointer?: string;
|
|
17
|
+
};
|
|
18
|
+
/** Summary of the problem. */
|
|
19
|
+
title: string;
|
|
20
|
+
};
|
|
21
|
+
type Errors = {
|
|
22
|
+
/** An array of errors related to the operation. */
|
|
23
|
+
errors?: Error[];
|
|
24
|
+
/** A unique identifier for tracing the error. */
|
|
25
|
+
traceId?: string;
|
|
26
|
+
};
|
|
27
|
+
type Links = {
|
|
28
|
+
/** Link to the next page of items */
|
|
29
|
+
next?: {
|
|
30
|
+
href: string;
|
|
31
|
+
};
|
|
32
|
+
/** Link to the previous page of items */
|
|
33
|
+
prev?: {
|
|
34
|
+
href: string;
|
|
35
|
+
};
|
|
36
|
+
/** Link to the current page of items */
|
|
37
|
+
self: {
|
|
38
|
+
href: string;
|
|
39
|
+
};
|
|
40
|
+
};
|
|
41
|
+
type ListRolesResult = {
|
|
42
|
+
/** An array of roles. */
|
|
43
|
+
data: Role[];
|
|
44
|
+
/** Contains pagination links */
|
|
45
|
+
links: Links;
|
|
46
|
+
/** Indicates the total number of matching documents. Will only be returned if the query parameter "totalResults" is true. */
|
|
47
|
+
totalResults?: number;
|
|
48
|
+
};
|
|
49
|
+
type Role = {
|
|
50
|
+
/** The timestamp for when the role was created. */
|
|
51
|
+
createdAt: string;
|
|
52
|
+
/** Descriptive text for the role. */
|
|
53
|
+
description: string;
|
|
54
|
+
/** The unique identifier for the role. */
|
|
55
|
+
readonly id: string;
|
|
56
|
+
/** The timestamp for when the role was last updated. */
|
|
57
|
+
lastUpdatedAt: string;
|
|
58
|
+
/** The level of access associated to the role. */
|
|
59
|
+
level?: "admin" | "user";
|
|
60
|
+
/** Contains links for the role. */
|
|
61
|
+
links: {
|
|
62
|
+
self: {
|
|
63
|
+
/** Link to the role. */
|
|
64
|
+
href: string;
|
|
65
|
+
};
|
|
66
|
+
};
|
|
67
|
+
/** The name of the role. */
|
|
68
|
+
name: string;
|
|
69
|
+
/** An array of permissions associated with the role. */
|
|
70
|
+
permissions?: string[];
|
|
71
|
+
/** The tenant unique identifier associated with the given Role. */
|
|
72
|
+
tenantId: string;
|
|
73
|
+
/** The type of role. */
|
|
74
|
+
type: "default";
|
|
75
|
+
};
|
|
76
|
+
/**
|
|
77
|
+
* Returns a list of roles using cursor-based pagination.
|
|
78
|
+
* @param query an object with query parameters
|
|
79
|
+
* @throws GetRolesHttpError
|
|
80
|
+
*/
|
|
81
|
+
declare const getRoles: (query: {
|
|
82
|
+
/** The advanced filtering to use for the query. Refer to [RFC 7644](https://datatracker.ietf.org/doc/rfc7644/) for the syntax. All conditional statements within this query parameter are case insensitive. */
|
|
83
|
+
filter?: string;
|
|
84
|
+
/** The number of roles to retrieve. */
|
|
85
|
+
limit?: number;
|
|
86
|
+
/** The next page cursor. */
|
|
87
|
+
next?: string;
|
|
88
|
+
/** The previous page cursor. */
|
|
89
|
+
prev?: string;
|
|
90
|
+
/** Optional resource field name to sort on, eg. name. Can be prefixed with +/- to determine order, defaults to (+) ascending. */
|
|
91
|
+
sort?: string;
|
|
92
|
+
/** Determines wether to return a count of the total records matched in the query. Defaults to false. */
|
|
93
|
+
totalResults?: boolean;
|
|
94
|
+
}, options?: ApiCallOptions) => Promise<GetRolesHttpResponse>;
|
|
95
|
+
type GetRolesHttpResponse = {
|
|
96
|
+
data: ListRolesResult;
|
|
97
|
+
headers: Headers;
|
|
98
|
+
status: number;
|
|
99
|
+
prev?: (options?: ApiCallOptions) => Promise<GetRolesHttpResponse>;
|
|
100
|
+
next?: (options?: ApiCallOptions) => Promise<GetRolesHttpResponse>;
|
|
101
|
+
};
|
|
102
|
+
type GetRolesHttpError = {
|
|
103
|
+
data: Errors;
|
|
104
|
+
headers: Headers;
|
|
105
|
+
status: number;
|
|
106
|
+
};
|
|
107
|
+
/**
|
|
108
|
+
* Returns the requested role.
|
|
109
|
+
* @param id The role's unique identifier
|
|
110
|
+
* @throws GetRoleHttpError
|
|
111
|
+
*/
|
|
112
|
+
declare const getRole: (id: string, options?: ApiCallOptions) => Promise<GetRoleHttpResponse>;
|
|
113
|
+
type GetRoleHttpResponse = {
|
|
114
|
+
data: Role;
|
|
115
|
+
headers: Headers;
|
|
116
|
+
status: number;
|
|
117
|
+
};
|
|
118
|
+
type GetRoleHttpError = {
|
|
119
|
+
data: Errors;
|
|
120
|
+
headers: Headers;
|
|
121
|
+
status: number;
|
|
122
|
+
};
|
|
123
|
+
/**
|
|
124
|
+
* Clears the cache for roles api requests.
|
|
125
|
+
*/
|
|
126
|
+
declare function clearCache(): void;
|
|
127
|
+
interface RolesAPI {
|
|
128
|
+
/**
|
|
129
|
+
* Returns a list of roles using cursor-based pagination.
|
|
130
|
+
* @param query an object with query parameters
|
|
131
|
+
* @throws GetRolesHttpError
|
|
132
|
+
*/
|
|
133
|
+
getRoles: typeof getRoles;
|
|
134
|
+
/**
|
|
135
|
+
* Returns the requested role.
|
|
136
|
+
* @param id The role's unique identifier
|
|
137
|
+
* @throws GetRoleHttpError
|
|
138
|
+
*/
|
|
139
|
+
getRole: typeof getRole;
|
|
140
|
+
/**
|
|
141
|
+
* Clears the cache for roles api requests.
|
|
142
|
+
*/
|
|
143
|
+
clearCache: typeof clearCache;
|
|
144
|
+
}
|
|
145
|
+
/**
|
|
146
|
+
* Functions for the roles api
|
|
147
|
+
*/
|
|
148
|
+
declare const rolesExport: RolesAPI;
|
|
149
|
+
|
|
150
|
+
export { type Error, type Errors, type GetRoleHttpError, type GetRoleHttpResponse, type GetRolesHttpError, type GetRolesHttpResponse, type Links, type ListRolesResult, type Role, type RolesAPI, clearCache, rolesExport as default, getRole, getRoles };
|
package/roles.js
ADDED
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports, "__esModule", {value: true});
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
var _chunkOULT3V2Ujs = require('./chunk-OULT3V2U.js');
|
|
5
|
+
require('./chunk-ZT4C7KCQ.js');
|
|
6
|
+
|
|
7
|
+
// src/public/rest/roles.ts
|
|
8
|
+
var getRoles = async (query, options) => _chunkOULT3V2Ujs.invokeFetch.call(void 0, "roles", {
|
|
9
|
+
method: "get",
|
|
10
|
+
pathTemplate: "/api/v1/roles",
|
|
11
|
+
query,
|
|
12
|
+
options
|
|
13
|
+
});
|
|
14
|
+
var getRole = async (id, options) => _chunkOULT3V2Ujs.invokeFetch.call(void 0, "roles", {
|
|
15
|
+
method: "get",
|
|
16
|
+
pathTemplate: "/api/v1/roles/{id}",
|
|
17
|
+
pathVariables: { id },
|
|
18
|
+
options
|
|
19
|
+
});
|
|
20
|
+
function clearCache() {
|
|
21
|
+
return _chunkOULT3V2Ujs.clearApiCache.call(void 0, "roles");
|
|
22
|
+
}
|
|
23
|
+
var rolesExport = { getRoles, getRole, clearCache };
|
|
24
|
+
var roles_default = rolesExport;
|
|
25
|
+
|
|
26
|
+
|
|
27
|
+
|
|
28
|
+
|
|
29
|
+
|
|
30
|
+
exports.clearCache = clearCache; exports.default = roles_default; exports.getRole = getRole; exports.getRoles = getRoles;
|
package/roles.mjs
ADDED
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import {
|
|
2
|
+
clearApiCache,
|
|
3
|
+
invokeFetch
|
|
4
|
+
} from "./chunk-3YE7EI7I.mjs";
|
|
5
|
+
import "./chunk-WM7FQU2U.mjs";
|
|
6
|
+
|
|
7
|
+
// src/public/rest/roles.ts
|
|
8
|
+
var getRoles = async (query, options) => invokeFetch("roles", {
|
|
9
|
+
method: "get",
|
|
10
|
+
pathTemplate: "/api/v1/roles",
|
|
11
|
+
query,
|
|
12
|
+
options
|
|
13
|
+
});
|
|
14
|
+
var getRole = async (id, options) => invokeFetch("roles", {
|
|
15
|
+
method: "get",
|
|
16
|
+
pathTemplate: "/api/v1/roles/{id}",
|
|
17
|
+
pathVariables: { id },
|
|
18
|
+
options
|
|
19
|
+
});
|
|
20
|
+
function clearCache() {
|
|
21
|
+
return clearApiCache("roles");
|
|
22
|
+
}
|
|
23
|
+
var rolesExport = { getRoles, getRole, clearCache };
|
|
24
|
+
var roles_default = rolesExport;
|
|
25
|
+
export {
|
|
26
|
+
clearCache,
|
|
27
|
+
roles_default as default,
|
|
28
|
+
getRole,
|
|
29
|
+
getRoles
|
|
30
|
+
};
|