@openfilz-sdk/typescript-ee 1.3.5 → 1.4.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/.openapi-generator/FILES +32 -6
- package/.openapi-generator/openfilz-api-generate-typescript-sdk.sha256 +1 -1
- package/README.md +36 -7
- package/api/{audit-controller-api.ts → collaboration-audit-controller-api.ts} +42 -42
- package/api/delegated-browse-grants-admin-api.ts +452 -0
- package/api/delegated-browse-grants-end-user-api.ts +426 -0
- package/api/upload-token-controller-api.ts +219 -0
- package/api/user-privacy-api.ts +196 -0
- package/api/webhook-proxy-controller-api.ts +523 -0
- package/api.ts +6 -1
- package/dist/api/{audit-controller-api.d.ts → collaboration-audit-controller-api.d.ts} +35 -35
- package/dist/api/{audit-controller-api.js → collaboration-audit-controller-api.js} +41 -41
- package/dist/api/delegated-browse-grants-admin-api.d.ts +215 -0
- package/dist/api/delegated-browse-grants-admin-api.js +434 -0
- package/dist/api/delegated-browse-grants-end-user-api.d.ts +204 -0
- package/dist/api/delegated-browse-grants-end-user-api.js +416 -0
- package/dist/api/upload-token-controller-api.d.ts +105 -0
- package/dist/api/upload-token-controller-api.js +214 -0
- package/dist/api/user-privacy-api.d.ts +96 -0
- package/dist/api/user-privacy-api.js +195 -0
- package/dist/api/webhook-proxy-controller-api.d.ts +230 -0
- package/dist/api/webhook-proxy-controller-api.js +511 -0
- package/dist/api.d.ts +6 -1
- package/dist/api.js +6 -1
- package/dist/esm/api/{audit-controller-api.d.ts → collaboration-audit-controller-api.d.ts} +35 -35
- package/dist/esm/api/{audit-controller-api.js → collaboration-audit-controller-api.js} +36 -36
- package/dist/esm/api/delegated-browse-grants-admin-api.d.ts +215 -0
- package/dist/esm/api/delegated-browse-grants-admin-api.js +427 -0
- package/dist/esm/api/delegated-browse-grants-end-user-api.d.ts +204 -0
- package/dist/esm/api/delegated-browse-grants-end-user-api.js +409 -0
- package/dist/esm/api/upload-token-controller-api.d.ts +105 -0
- package/dist/esm/api/upload-token-controller-api.js +207 -0
- package/dist/esm/api/user-privacy-api.d.ts +96 -0
- package/dist/esm/api/user-privacy-api.js +188 -0
- package/dist/esm/api/webhook-proxy-controller-api.d.ts +230 -0
- package/dist/esm/api/webhook-proxy-controller-api.js +504 -0
- package/dist/esm/api.d.ts +6 -1
- package/dist/esm/api.js +6 -1
- package/dist/esm/models/consume-delegated-grant-request.d.ts +15 -0
- package/dist/esm/models/create-delegated-grant-request.d.ts +21 -0
- package/dist/esm/models/create-delegated-grant-request.js +16 -0
- package/dist/esm/models/delegated-folder-node.d.ts +16 -0
- package/dist/esm/models/delegated-folder-node.js +14 -0
- package/dist/esm/models/delegated-grant-dto.d.ts +43 -0
- package/dist/esm/models/delegated-grant-dto.js +24 -0
- package/dist/esm/models/{audit-log-details-one-of.d.ts → enriched-audit-log-details.d.ts} +2 -2
- package/dist/esm/models/enriched-audit-log-details.js +14 -0
- package/dist/esm/models/{audit-log.d.ts → enriched-audit-log.d.ts} +27 -16
- package/dist/{models/audit-log.js → esm/models/enriched-audit-log.js} +17 -11
- package/dist/esm/models/index.d.ts +10 -2
- package/dist/esm/models/index.js +10 -2
- package/dist/esm/models/mint-upload-token-request.d.ts +17 -0
- package/dist/esm/models/mint-upload-token-request.js +14 -0
- package/dist/esm/models/notification-dto.d.ts +3 -0
- package/dist/esm/models/notification-dto.js +4 -1
- package/dist/esm/models/search-by-audit-log-request.d.ts +15 -6
- package/dist/esm/models/search-by-audit-log-request.js +15 -6
- package/dist/esm/models/update-user-privacy-request.d.ts +14 -0
- package/dist/esm/models/update-user-privacy-request.js +14 -0
- package/dist/esm/models/upload-token-response.d.ts +18 -0
- package/dist/esm/models/upload-token-response.js +14 -0
- package/dist/esm/models/user-privacy-dto.d.ts +14 -0
- package/dist/esm/models/user-privacy-dto.js +14 -0
- package/dist/models/consume-delegated-grant-request.d.ts +15 -0
- package/dist/models/create-delegated-grant-request.d.ts +21 -0
- package/dist/models/create-delegated-grant-request.js +19 -0
- package/dist/models/delegated-folder-node.d.ts +16 -0
- package/dist/models/delegated-folder-node.js +15 -0
- package/dist/models/delegated-grant-dto.d.ts +43 -0
- package/dist/models/delegated-grant-dto.js +27 -0
- package/dist/models/{audit-log-details-one-of.d.ts → enriched-audit-log-details.d.ts} +2 -2
- package/dist/models/enriched-audit-log-details.js +15 -0
- package/dist/models/{audit-log.d.ts → enriched-audit-log.d.ts} +27 -16
- package/dist/{esm/models/audit-log.js → models/enriched-audit-log.js} +20 -8
- package/dist/models/index.d.ts +10 -2
- package/dist/models/index.js +10 -2
- package/dist/models/mint-upload-token-request.d.ts +17 -0
- package/dist/models/mint-upload-token-request.js +15 -0
- package/dist/models/notification-dto.d.ts +3 -0
- package/dist/models/notification-dto.js +4 -1
- package/dist/models/search-by-audit-log-request.d.ts +15 -6
- package/dist/models/search-by-audit-log-request.js +15 -6
- package/dist/models/update-user-privacy-request.d.ts +14 -0
- package/dist/models/update-user-privacy-request.js +15 -0
- package/dist/models/upload-token-response.d.ts +18 -0
- package/dist/models/upload-token-response.js +15 -0
- package/dist/models/user-privacy-dto.d.ts +14 -0
- package/dist/models/user-privacy-dto.js +15 -0
- package/docs/{AuditControllerApi.md → CollaborationAuditControllerApi.md} +16 -16
- package/docs/ConsumeDelegatedGrantRequest.md +22 -0
- package/docs/CreateDelegatedGrantRequest.md +26 -0
- package/docs/DelegatedBrowseGrantsAdminApi.md +275 -0
- package/docs/DelegatedBrowseGrantsEndUserApi.md +266 -0
- package/docs/DelegatedFolderNode.md +24 -0
- package/docs/DelegatedGrantDTO.md +52 -0
- package/docs/{AuditLog.md → EnrichedAuditLog.md} +9 -5
- package/docs/{AuditLogDetailsOneOf.md → EnrichedAuditLogDetails.md} +3 -3
- package/docs/MintUploadTokenRequest.md +26 -0
- package/docs/UpdateUserPrivacyRequest.md +20 -0
- package/docs/UploadTokenControllerApi.md +115 -0
- package/docs/UploadTokenResponse.md +28 -0
- package/docs/UserPrivacyApi.md +104 -0
- package/docs/UserPrivacyDTO.md +20 -0
- package/docs/WebhookProxyControllerApi.md +364 -0
- package/models/consume-delegated-grant-request.ts +21 -0
- package/models/create-delegated-grant-request.ts +30 -0
- package/models/delegated-folder-node.ts +22 -0
- package/models/delegated-grant-dto.ts +53 -0
- package/models/{audit-log-details-one-of.ts → enriched-audit-log-details.ts} +2 -20
- package/models/{audit-log.ts → enriched-audit-log.ts} +27 -16
- package/models/index.ts +10 -2
- package/models/mint-upload-token-request.ts +23 -0
- package/models/notification-dto.ts +4 -1
- package/models/search-by-audit-log-request.ts +15 -6
- package/models/update-user-privacy-request.ts +20 -0
- package/models/upload-token-response.ts +24 -0
- package/models/user-privacy-dto.ts +20 -0
- package/package.json +1 -1
- /package/dist/esm/models/{audit-log-details-one-of.js → consume-delegated-grant-request.js} +0 -0
- /package/dist/models/{audit-log-details-one-of.js → consume-delegated-grant-request.js} +0 -0
|
@@ -0,0 +1,207 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* openfilz-api
|
|
5
|
+
* API for Document Management System
|
|
6
|
+
*
|
|
7
|
+
* The version of the OpenAPI document: 1.0.0
|
|
8
|
+
*
|
|
9
|
+
*
|
|
10
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
11
|
+
* https://openapi-generator.tech
|
|
12
|
+
* Do not edit the class manually.
|
|
13
|
+
*/
|
|
14
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
15
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
16
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
17
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
18
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
19
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
20
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
21
|
+
});
|
|
22
|
+
};
|
|
23
|
+
import globalAxios from 'axios';
|
|
24
|
+
// Some imports not used depending on template conditions
|
|
25
|
+
// @ts-ignore
|
|
26
|
+
import { DUMMY_BASE_URL, assertParamExists, setBearerAuthToObject, setSearchParams, serializeDataIfNeeded, toPathString, createRequestFunction } from '../common';
|
|
27
|
+
// @ts-ignore
|
|
28
|
+
import { BASE_PATH, BaseAPI, operationServerMap } from '../base';
|
|
29
|
+
/**
|
|
30
|
+
* UploadTokenControllerApi - axios parameter creator
|
|
31
|
+
*/
|
|
32
|
+
export const UploadTokenControllerApiAxiosParamCreator = function (configuration) {
|
|
33
|
+
return {
|
|
34
|
+
/**
|
|
35
|
+
* Issues a one-shot HS256 JWT scoped to a single upload into a single folder. Caller must hold the UPLOAD_TOKEN_ISSUER realm role.
|
|
36
|
+
* @summary Mint a scoped upload token
|
|
37
|
+
* @param {MintUploadTokenRequest} mintUploadTokenRequest
|
|
38
|
+
* @param {*} [options] Override http request option.
|
|
39
|
+
* @throws {RequiredError}
|
|
40
|
+
*/
|
|
41
|
+
mintUploadToken: (mintUploadTokenRequest_1, ...args_1) => __awaiter(this, [mintUploadTokenRequest_1, ...args_1], void 0, function* (mintUploadTokenRequest, options = {}) {
|
|
42
|
+
// verify required parameter 'mintUploadTokenRequest' is not null or undefined
|
|
43
|
+
assertParamExists('mintUploadToken', 'mintUploadTokenRequest', mintUploadTokenRequest);
|
|
44
|
+
const localVarPath = `/api/v1/upload-tokens`;
|
|
45
|
+
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
46
|
+
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
47
|
+
let baseOptions;
|
|
48
|
+
if (configuration) {
|
|
49
|
+
baseOptions = configuration.baseOptions;
|
|
50
|
+
}
|
|
51
|
+
const localVarRequestOptions = Object.assign(Object.assign({ method: 'POST' }, baseOptions), options);
|
|
52
|
+
const localVarHeaderParameter = {};
|
|
53
|
+
const localVarQueryParameter = {};
|
|
54
|
+
// authentication keycloak_auth required
|
|
55
|
+
// http bearer authentication required
|
|
56
|
+
yield setBearerAuthToObject(localVarHeaderParameter, configuration);
|
|
57
|
+
localVarHeaderParameter['Content-Type'] = 'application/json';
|
|
58
|
+
localVarHeaderParameter['Accept'] = '*/*';
|
|
59
|
+
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
60
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
61
|
+
localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
|
|
62
|
+
localVarRequestOptions.data = serializeDataIfNeeded(mintUploadTokenRequest, localVarRequestOptions, configuration);
|
|
63
|
+
return {
|
|
64
|
+
url: toPathString(localVarUrlObj),
|
|
65
|
+
options: localVarRequestOptions,
|
|
66
|
+
};
|
|
67
|
+
}),
|
|
68
|
+
/**
|
|
69
|
+
* Anonymous-callable endpoint authenticated by the scoped JWT minted via POST /api/v1/upload-tokens. Forces the target folder to the one baked into the token. One-shot — replays return 401.
|
|
70
|
+
* @summary Upload a single document with a scoped upload token
|
|
71
|
+
* @param {File} file
|
|
72
|
+
* @param {string} [metadata]
|
|
73
|
+
* @param {*} [options] Override http request option.
|
|
74
|
+
* @throws {RequiredError}
|
|
75
|
+
*/
|
|
76
|
+
uploadWithToken: (file_1, metadata_1, ...args_1) => __awaiter(this, [file_1, metadata_1, ...args_1], void 0, function* (file, metadata, options = {}) {
|
|
77
|
+
// verify required parameter 'file' is not null or undefined
|
|
78
|
+
assertParamExists('uploadWithToken', 'file', file);
|
|
79
|
+
const localVarPath = `/api/v1/upload-tokens/upload`;
|
|
80
|
+
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
81
|
+
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
82
|
+
let baseOptions;
|
|
83
|
+
if (configuration) {
|
|
84
|
+
baseOptions = configuration.baseOptions;
|
|
85
|
+
}
|
|
86
|
+
const localVarRequestOptions = Object.assign(Object.assign({ method: 'POST' }, baseOptions), options);
|
|
87
|
+
const localVarHeaderParameter = {};
|
|
88
|
+
const localVarQueryParameter = {};
|
|
89
|
+
const localVarFormParams = new ((configuration && configuration.formDataCtor) || FormData)();
|
|
90
|
+
// authentication keycloak_auth required
|
|
91
|
+
// http bearer authentication required
|
|
92
|
+
yield setBearerAuthToObject(localVarHeaderParameter, configuration);
|
|
93
|
+
if (file !== undefined) {
|
|
94
|
+
localVarFormParams.append('file', file);
|
|
95
|
+
}
|
|
96
|
+
if (metadata !== undefined) {
|
|
97
|
+
localVarFormParams.append('metadata', metadata);
|
|
98
|
+
}
|
|
99
|
+
localVarHeaderParameter['Content-Type'] = 'multipart/form-data';
|
|
100
|
+
localVarHeaderParameter['Accept'] = '*/*';
|
|
101
|
+
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
102
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
103
|
+
localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
|
|
104
|
+
localVarRequestOptions.data = localVarFormParams;
|
|
105
|
+
return {
|
|
106
|
+
url: toPathString(localVarUrlObj),
|
|
107
|
+
options: localVarRequestOptions,
|
|
108
|
+
};
|
|
109
|
+
}),
|
|
110
|
+
};
|
|
111
|
+
};
|
|
112
|
+
/**
|
|
113
|
+
* UploadTokenControllerApi - functional programming interface
|
|
114
|
+
*/
|
|
115
|
+
export const UploadTokenControllerApiFp = function (configuration) {
|
|
116
|
+
const localVarAxiosParamCreator = UploadTokenControllerApiAxiosParamCreator(configuration);
|
|
117
|
+
return {
|
|
118
|
+
/**
|
|
119
|
+
* Issues a one-shot HS256 JWT scoped to a single upload into a single folder. Caller must hold the UPLOAD_TOKEN_ISSUER realm role.
|
|
120
|
+
* @summary Mint a scoped upload token
|
|
121
|
+
* @param {MintUploadTokenRequest} mintUploadTokenRequest
|
|
122
|
+
* @param {*} [options] Override http request option.
|
|
123
|
+
* @throws {RequiredError}
|
|
124
|
+
*/
|
|
125
|
+
mintUploadToken(mintUploadTokenRequest, options) {
|
|
126
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
127
|
+
var _a, _b, _c;
|
|
128
|
+
const localVarAxiosArgs = yield localVarAxiosParamCreator.mintUploadToken(mintUploadTokenRequest, options);
|
|
129
|
+
const localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
|
|
130
|
+
const localVarOperationServerBasePath = (_c = (_b = operationServerMap['UploadTokenControllerApi.mintUploadToken']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
|
|
131
|
+
return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
132
|
+
});
|
|
133
|
+
},
|
|
134
|
+
/**
|
|
135
|
+
* Anonymous-callable endpoint authenticated by the scoped JWT minted via POST /api/v1/upload-tokens. Forces the target folder to the one baked into the token. One-shot — replays return 401.
|
|
136
|
+
* @summary Upload a single document with a scoped upload token
|
|
137
|
+
* @param {File} file
|
|
138
|
+
* @param {string} [metadata]
|
|
139
|
+
* @param {*} [options] Override http request option.
|
|
140
|
+
* @throws {RequiredError}
|
|
141
|
+
*/
|
|
142
|
+
uploadWithToken(file, metadata, options) {
|
|
143
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
144
|
+
var _a, _b, _c;
|
|
145
|
+
const localVarAxiosArgs = yield localVarAxiosParamCreator.uploadWithToken(file, metadata, options);
|
|
146
|
+
const localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
|
|
147
|
+
const localVarOperationServerBasePath = (_c = (_b = operationServerMap['UploadTokenControllerApi.uploadWithToken']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
|
|
148
|
+
return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
149
|
+
});
|
|
150
|
+
},
|
|
151
|
+
};
|
|
152
|
+
};
|
|
153
|
+
/**
|
|
154
|
+
* UploadTokenControllerApi - factory interface
|
|
155
|
+
*/
|
|
156
|
+
export const UploadTokenControllerApiFactory = function (configuration, basePath, axios) {
|
|
157
|
+
const localVarFp = UploadTokenControllerApiFp(configuration);
|
|
158
|
+
return {
|
|
159
|
+
/**
|
|
160
|
+
* Issues a one-shot HS256 JWT scoped to a single upload into a single folder. Caller must hold the UPLOAD_TOKEN_ISSUER realm role.
|
|
161
|
+
* @summary Mint a scoped upload token
|
|
162
|
+
* @param {MintUploadTokenRequest} mintUploadTokenRequest
|
|
163
|
+
* @param {*} [options] Override http request option.
|
|
164
|
+
* @throws {RequiredError}
|
|
165
|
+
*/
|
|
166
|
+
mintUploadToken(mintUploadTokenRequest, options) {
|
|
167
|
+
return localVarFp.mintUploadToken(mintUploadTokenRequest, options).then((request) => request(axios, basePath));
|
|
168
|
+
},
|
|
169
|
+
/**
|
|
170
|
+
* Anonymous-callable endpoint authenticated by the scoped JWT minted via POST /api/v1/upload-tokens. Forces the target folder to the one baked into the token. One-shot — replays return 401.
|
|
171
|
+
* @summary Upload a single document with a scoped upload token
|
|
172
|
+
* @param {File} file
|
|
173
|
+
* @param {string} [metadata]
|
|
174
|
+
* @param {*} [options] Override http request option.
|
|
175
|
+
* @throws {RequiredError}
|
|
176
|
+
*/
|
|
177
|
+
uploadWithToken(file, metadata, options) {
|
|
178
|
+
return localVarFp.uploadWithToken(file, metadata, options).then((request) => request(axios, basePath));
|
|
179
|
+
},
|
|
180
|
+
};
|
|
181
|
+
};
|
|
182
|
+
/**
|
|
183
|
+
* UploadTokenControllerApi - object-oriented interface
|
|
184
|
+
*/
|
|
185
|
+
export class UploadTokenControllerApi extends BaseAPI {
|
|
186
|
+
/**
|
|
187
|
+
* Issues a one-shot HS256 JWT scoped to a single upload into a single folder. Caller must hold the UPLOAD_TOKEN_ISSUER realm role.
|
|
188
|
+
* @summary Mint a scoped upload token
|
|
189
|
+
* @param {MintUploadTokenRequest} mintUploadTokenRequest
|
|
190
|
+
* @param {*} [options] Override http request option.
|
|
191
|
+
* @throws {RequiredError}
|
|
192
|
+
*/
|
|
193
|
+
mintUploadToken(mintUploadTokenRequest, options) {
|
|
194
|
+
return UploadTokenControllerApiFp(this.configuration).mintUploadToken(mintUploadTokenRequest, options).then((request) => request(this.axios, this.basePath));
|
|
195
|
+
}
|
|
196
|
+
/**
|
|
197
|
+
* Anonymous-callable endpoint authenticated by the scoped JWT minted via POST /api/v1/upload-tokens. Forces the target folder to the one baked into the token. One-shot — replays return 401.
|
|
198
|
+
* @summary Upload a single document with a scoped upload token
|
|
199
|
+
* @param {File} file
|
|
200
|
+
* @param {string} [metadata]
|
|
201
|
+
* @param {*} [options] Override http request option.
|
|
202
|
+
* @throws {RequiredError}
|
|
203
|
+
*/
|
|
204
|
+
uploadWithToken(file, metadata, options) {
|
|
205
|
+
return UploadTokenControllerApiFp(this.configuration).uploadWithToken(file, metadata, options).then((request) => request(this.axios, this.basePath));
|
|
206
|
+
}
|
|
207
|
+
}
|
|
@@ -0,0 +1,96 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* openfilz-api
|
|
3
|
+
* API for Document Management System
|
|
4
|
+
*
|
|
5
|
+
* The version of the OpenAPI document: 1.0.0
|
|
6
|
+
*
|
|
7
|
+
*
|
|
8
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
9
|
+
* https://openapi-generator.tech
|
|
10
|
+
* Do not edit the class manually.
|
|
11
|
+
*/
|
|
12
|
+
import type { Configuration } from '../configuration';
|
|
13
|
+
import type { AxiosPromise, AxiosInstance, RawAxiosRequestConfig } from 'axios';
|
|
14
|
+
import { type RequestArgs, BaseAPI } from '../base';
|
|
15
|
+
import type { UpdateUserPrivacyRequest } from '../models';
|
|
16
|
+
import type { UserPrivacyDTO } from '../models';
|
|
17
|
+
/**
|
|
18
|
+
* UserPrivacyApi - axios parameter creator
|
|
19
|
+
*/
|
|
20
|
+
export declare const UserPrivacyApiAxiosParamCreator: (configuration?: Configuration) => {
|
|
21
|
+
/**
|
|
22
|
+
*
|
|
23
|
+
* @summary Read my privacy preferences
|
|
24
|
+
* @param {*} [options] Override http request option.
|
|
25
|
+
* @throws {RequiredError}
|
|
26
|
+
*/
|
|
27
|
+
get: (options?: RawAxiosRequestConfig) => Promise<RequestArgs>;
|
|
28
|
+
/**
|
|
29
|
+
* Idempotent. Audits ADMIN_MONITORING_OPT_OUT_CHANGED only when the value actually changes — repeated PUTs with the same flag are silent.
|
|
30
|
+
* @summary Update my privacy preferences
|
|
31
|
+
* @param {UpdateUserPrivacyRequest} updateUserPrivacyRequest
|
|
32
|
+
* @param {*} [options] Override http request option.
|
|
33
|
+
* @throws {RequiredError}
|
|
34
|
+
*/
|
|
35
|
+
update: (updateUserPrivacyRequest: UpdateUserPrivacyRequest, options?: RawAxiosRequestConfig) => Promise<RequestArgs>;
|
|
36
|
+
};
|
|
37
|
+
/**
|
|
38
|
+
* UserPrivacyApi - functional programming interface
|
|
39
|
+
*/
|
|
40
|
+
export declare const UserPrivacyApiFp: (configuration?: Configuration) => {
|
|
41
|
+
/**
|
|
42
|
+
*
|
|
43
|
+
* @summary Read my privacy preferences
|
|
44
|
+
* @param {*} [options] Override http request option.
|
|
45
|
+
* @throws {RequiredError}
|
|
46
|
+
*/
|
|
47
|
+
get(options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<UserPrivacyDTO>>;
|
|
48
|
+
/**
|
|
49
|
+
* Idempotent. Audits ADMIN_MONITORING_OPT_OUT_CHANGED only when the value actually changes — repeated PUTs with the same flag are silent.
|
|
50
|
+
* @summary Update my privacy preferences
|
|
51
|
+
* @param {UpdateUserPrivacyRequest} updateUserPrivacyRequest
|
|
52
|
+
* @param {*} [options] Override http request option.
|
|
53
|
+
* @throws {RequiredError}
|
|
54
|
+
*/
|
|
55
|
+
update(updateUserPrivacyRequest: UpdateUserPrivacyRequest, options?: RawAxiosRequestConfig): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<UserPrivacyDTO>>;
|
|
56
|
+
};
|
|
57
|
+
/**
|
|
58
|
+
* UserPrivacyApi - factory interface
|
|
59
|
+
*/
|
|
60
|
+
export declare const UserPrivacyApiFactory: (configuration?: Configuration, basePath?: string, axios?: AxiosInstance) => {
|
|
61
|
+
/**
|
|
62
|
+
*
|
|
63
|
+
* @summary Read my privacy preferences
|
|
64
|
+
* @param {*} [options] Override http request option.
|
|
65
|
+
* @throws {RequiredError}
|
|
66
|
+
*/
|
|
67
|
+
get(options?: RawAxiosRequestConfig): AxiosPromise<UserPrivacyDTO>;
|
|
68
|
+
/**
|
|
69
|
+
* Idempotent. Audits ADMIN_MONITORING_OPT_OUT_CHANGED only when the value actually changes — repeated PUTs with the same flag are silent.
|
|
70
|
+
* @summary Update my privacy preferences
|
|
71
|
+
* @param {UpdateUserPrivacyRequest} updateUserPrivacyRequest
|
|
72
|
+
* @param {*} [options] Override http request option.
|
|
73
|
+
* @throws {RequiredError}
|
|
74
|
+
*/
|
|
75
|
+
update(updateUserPrivacyRequest: UpdateUserPrivacyRequest, options?: RawAxiosRequestConfig): AxiosPromise<UserPrivacyDTO>;
|
|
76
|
+
};
|
|
77
|
+
/**
|
|
78
|
+
* UserPrivacyApi - object-oriented interface
|
|
79
|
+
*/
|
|
80
|
+
export declare class UserPrivacyApi extends BaseAPI {
|
|
81
|
+
/**
|
|
82
|
+
*
|
|
83
|
+
* @summary Read my privacy preferences
|
|
84
|
+
* @param {*} [options] Override http request option.
|
|
85
|
+
* @throws {RequiredError}
|
|
86
|
+
*/
|
|
87
|
+
get(options?: RawAxiosRequestConfig): Promise<import("axios").AxiosResponse<UserPrivacyDTO, any, {}>>;
|
|
88
|
+
/**
|
|
89
|
+
* Idempotent. Audits ADMIN_MONITORING_OPT_OUT_CHANGED only when the value actually changes — repeated PUTs with the same flag are silent.
|
|
90
|
+
* @summary Update my privacy preferences
|
|
91
|
+
* @param {UpdateUserPrivacyRequest} updateUserPrivacyRequest
|
|
92
|
+
* @param {*} [options] Override http request option.
|
|
93
|
+
* @throws {RequiredError}
|
|
94
|
+
*/
|
|
95
|
+
update(updateUserPrivacyRequest: UpdateUserPrivacyRequest, options?: RawAxiosRequestConfig): Promise<import("axios").AxiosResponse<UserPrivacyDTO, any, {}>>;
|
|
96
|
+
}
|
|
@@ -0,0 +1,188 @@
|
|
|
1
|
+
/* tslint:disable */
|
|
2
|
+
/* eslint-disable */
|
|
3
|
+
/**
|
|
4
|
+
* openfilz-api
|
|
5
|
+
* API for Document Management System
|
|
6
|
+
*
|
|
7
|
+
* The version of the OpenAPI document: 1.0.0
|
|
8
|
+
*
|
|
9
|
+
*
|
|
10
|
+
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
11
|
+
* https://openapi-generator.tech
|
|
12
|
+
* Do not edit the class manually.
|
|
13
|
+
*/
|
|
14
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
15
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
16
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
17
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
18
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
19
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
20
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
21
|
+
});
|
|
22
|
+
};
|
|
23
|
+
import globalAxios from 'axios';
|
|
24
|
+
// Some imports not used depending on template conditions
|
|
25
|
+
// @ts-ignore
|
|
26
|
+
import { DUMMY_BASE_URL, assertParamExists, setBearerAuthToObject, setSearchParams, serializeDataIfNeeded, toPathString, createRequestFunction } from '../common';
|
|
27
|
+
// @ts-ignore
|
|
28
|
+
import { BASE_PATH, BaseAPI, operationServerMap } from '../base';
|
|
29
|
+
/**
|
|
30
|
+
* UserPrivacyApi - axios parameter creator
|
|
31
|
+
*/
|
|
32
|
+
export const UserPrivacyApiAxiosParamCreator = function (configuration) {
|
|
33
|
+
return {
|
|
34
|
+
/**
|
|
35
|
+
*
|
|
36
|
+
* @summary Read my privacy preferences
|
|
37
|
+
* @param {*} [options] Override http request option.
|
|
38
|
+
* @throws {RequiredError}
|
|
39
|
+
*/
|
|
40
|
+
get: (...args_1) => __awaiter(this, [...args_1], void 0, function* (options = {}) {
|
|
41
|
+
const localVarPath = `/api/v1/users/me/privacy`;
|
|
42
|
+
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
43
|
+
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
44
|
+
let baseOptions;
|
|
45
|
+
if (configuration) {
|
|
46
|
+
baseOptions = configuration.baseOptions;
|
|
47
|
+
}
|
|
48
|
+
const localVarRequestOptions = Object.assign(Object.assign({ method: 'GET' }, baseOptions), options);
|
|
49
|
+
const localVarHeaderParameter = {};
|
|
50
|
+
const localVarQueryParameter = {};
|
|
51
|
+
// authentication keycloak_auth required
|
|
52
|
+
// http bearer authentication required
|
|
53
|
+
yield setBearerAuthToObject(localVarHeaderParameter, configuration);
|
|
54
|
+
localVarHeaderParameter['Accept'] = 'application/json';
|
|
55
|
+
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
56
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
57
|
+
localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
|
|
58
|
+
return {
|
|
59
|
+
url: toPathString(localVarUrlObj),
|
|
60
|
+
options: localVarRequestOptions,
|
|
61
|
+
};
|
|
62
|
+
}),
|
|
63
|
+
/**
|
|
64
|
+
* Idempotent. Audits ADMIN_MONITORING_OPT_OUT_CHANGED only when the value actually changes — repeated PUTs with the same flag are silent.
|
|
65
|
+
* @summary Update my privacy preferences
|
|
66
|
+
* @param {UpdateUserPrivacyRequest} updateUserPrivacyRequest
|
|
67
|
+
* @param {*} [options] Override http request option.
|
|
68
|
+
* @throws {RequiredError}
|
|
69
|
+
*/
|
|
70
|
+
update: (updateUserPrivacyRequest_1, ...args_1) => __awaiter(this, [updateUserPrivacyRequest_1, ...args_1], void 0, function* (updateUserPrivacyRequest, options = {}) {
|
|
71
|
+
// verify required parameter 'updateUserPrivacyRequest' is not null or undefined
|
|
72
|
+
assertParamExists('update', 'updateUserPrivacyRequest', updateUserPrivacyRequest);
|
|
73
|
+
const localVarPath = `/api/v1/users/me/privacy`;
|
|
74
|
+
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
75
|
+
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
76
|
+
let baseOptions;
|
|
77
|
+
if (configuration) {
|
|
78
|
+
baseOptions = configuration.baseOptions;
|
|
79
|
+
}
|
|
80
|
+
const localVarRequestOptions = Object.assign(Object.assign({ method: 'PUT' }, baseOptions), options);
|
|
81
|
+
const localVarHeaderParameter = {};
|
|
82
|
+
const localVarQueryParameter = {};
|
|
83
|
+
// authentication keycloak_auth required
|
|
84
|
+
// http bearer authentication required
|
|
85
|
+
yield setBearerAuthToObject(localVarHeaderParameter, configuration);
|
|
86
|
+
localVarHeaderParameter['Content-Type'] = 'application/json';
|
|
87
|
+
localVarHeaderParameter['Accept'] = 'application/json';
|
|
88
|
+
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
89
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
90
|
+
localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
|
|
91
|
+
localVarRequestOptions.data = serializeDataIfNeeded(updateUserPrivacyRequest, localVarRequestOptions, configuration);
|
|
92
|
+
return {
|
|
93
|
+
url: toPathString(localVarUrlObj),
|
|
94
|
+
options: localVarRequestOptions,
|
|
95
|
+
};
|
|
96
|
+
}),
|
|
97
|
+
};
|
|
98
|
+
};
|
|
99
|
+
/**
|
|
100
|
+
* UserPrivacyApi - functional programming interface
|
|
101
|
+
*/
|
|
102
|
+
export const UserPrivacyApiFp = function (configuration) {
|
|
103
|
+
const localVarAxiosParamCreator = UserPrivacyApiAxiosParamCreator(configuration);
|
|
104
|
+
return {
|
|
105
|
+
/**
|
|
106
|
+
*
|
|
107
|
+
* @summary Read my privacy preferences
|
|
108
|
+
* @param {*} [options] Override http request option.
|
|
109
|
+
* @throws {RequiredError}
|
|
110
|
+
*/
|
|
111
|
+
get(options) {
|
|
112
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
113
|
+
var _a, _b, _c;
|
|
114
|
+
const localVarAxiosArgs = yield localVarAxiosParamCreator.get(options);
|
|
115
|
+
const localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
|
|
116
|
+
const localVarOperationServerBasePath = (_c = (_b = operationServerMap['UserPrivacyApi.get']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
|
|
117
|
+
return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
118
|
+
});
|
|
119
|
+
},
|
|
120
|
+
/**
|
|
121
|
+
* Idempotent. Audits ADMIN_MONITORING_OPT_OUT_CHANGED only when the value actually changes — repeated PUTs with the same flag are silent.
|
|
122
|
+
* @summary Update my privacy preferences
|
|
123
|
+
* @param {UpdateUserPrivacyRequest} updateUserPrivacyRequest
|
|
124
|
+
* @param {*} [options] Override http request option.
|
|
125
|
+
* @throws {RequiredError}
|
|
126
|
+
*/
|
|
127
|
+
update(updateUserPrivacyRequest, options) {
|
|
128
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
129
|
+
var _a, _b, _c;
|
|
130
|
+
const localVarAxiosArgs = yield localVarAxiosParamCreator.update(updateUserPrivacyRequest, options);
|
|
131
|
+
const localVarOperationServerIndex = (_a = configuration === null || configuration === void 0 ? void 0 : configuration.serverIndex) !== null && _a !== void 0 ? _a : 0;
|
|
132
|
+
const localVarOperationServerBasePath = (_c = (_b = operationServerMap['UserPrivacyApi.update']) === null || _b === void 0 ? void 0 : _b[localVarOperationServerIndex]) === null || _c === void 0 ? void 0 : _c.url;
|
|
133
|
+
return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
134
|
+
});
|
|
135
|
+
},
|
|
136
|
+
};
|
|
137
|
+
};
|
|
138
|
+
/**
|
|
139
|
+
* UserPrivacyApi - factory interface
|
|
140
|
+
*/
|
|
141
|
+
export const UserPrivacyApiFactory = function (configuration, basePath, axios) {
|
|
142
|
+
const localVarFp = UserPrivacyApiFp(configuration);
|
|
143
|
+
return {
|
|
144
|
+
/**
|
|
145
|
+
*
|
|
146
|
+
* @summary Read my privacy preferences
|
|
147
|
+
* @param {*} [options] Override http request option.
|
|
148
|
+
* @throws {RequiredError}
|
|
149
|
+
*/
|
|
150
|
+
get(options) {
|
|
151
|
+
return localVarFp.get(options).then((request) => request(axios, basePath));
|
|
152
|
+
},
|
|
153
|
+
/**
|
|
154
|
+
* Idempotent. Audits ADMIN_MONITORING_OPT_OUT_CHANGED only when the value actually changes — repeated PUTs with the same flag are silent.
|
|
155
|
+
* @summary Update my privacy preferences
|
|
156
|
+
* @param {UpdateUserPrivacyRequest} updateUserPrivacyRequest
|
|
157
|
+
* @param {*} [options] Override http request option.
|
|
158
|
+
* @throws {RequiredError}
|
|
159
|
+
*/
|
|
160
|
+
update(updateUserPrivacyRequest, options) {
|
|
161
|
+
return localVarFp.update(updateUserPrivacyRequest, options).then((request) => request(axios, basePath));
|
|
162
|
+
},
|
|
163
|
+
};
|
|
164
|
+
};
|
|
165
|
+
/**
|
|
166
|
+
* UserPrivacyApi - object-oriented interface
|
|
167
|
+
*/
|
|
168
|
+
export class UserPrivacyApi extends BaseAPI {
|
|
169
|
+
/**
|
|
170
|
+
*
|
|
171
|
+
* @summary Read my privacy preferences
|
|
172
|
+
* @param {*} [options] Override http request option.
|
|
173
|
+
* @throws {RequiredError}
|
|
174
|
+
*/
|
|
175
|
+
get(options) {
|
|
176
|
+
return UserPrivacyApiFp(this.configuration).get(options).then((request) => request(this.axios, this.basePath));
|
|
177
|
+
}
|
|
178
|
+
/**
|
|
179
|
+
* Idempotent. Audits ADMIN_MONITORING_OPT_OUT_CHANGED only when the value actually changes — repeated PUTs with the same flag are silent.
|
|
180
|
+
* @summary Update my privacy preferences
|
|
181
|
+
* @param {UpdateUserPrivacyRequest} updateUserPrivacyRequest
|
|
182
|
+
* @param {*} [options] Override http request option.
|
|
183
|
+
* @throws {RequiredError}
|
|
184
|
+
*/
|
|
185
|
+
update(updateUserPrivacyRequest, options) {
|
|
186
|
+
return UserPrivacyApiFp(this.configuration).update(updateUserPrivacyRequest, options).then((request) => request(this.axios, this.basePath));
|
|
187
|
+
}
|
|
188
|
+
}
|