@agravity/public 7.3.1 → 8.0.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.
- package/.openapi-generator/FILES +2 -3
- package/.openapi-generator/VERSION +1 -1
- package/README.md +29 -4
- package/api/publicAssetManagement.pub.agravity.ts +389 -265
- package/api/publicAssetOperations.pub.agravity.ts +636 -425
- package/api/publicAssetPublishing.pub.agravity.ts +195 -82
- package/api/publicAssetVersioning.pub.agravity.ts +469 -239
- package/api/publicAuthenticationManagement.pub.agravity.ts +66 -24
- package/api/publicCollectionManagement.pub.agravity.ts +525 -295
- package/api/publicCollectionSecureUpload.pub.agravity.ts +142 -69
- package/api/publicCollectionTypeManagement.pub.agravity.ts +211 -95
- package/api/publicConfigurationManagement.pub.agravity.ts +69 -26
- package/api/publicDownloadFormatManagement.pub.agravity.ts +139 -53
- package/api/publicEndpoints.pub.agravity.ts +63 -43
- package/api/publicGeneralManagement.pub.agravity.ts +253 -104
- package/api/publicHelperTools.pub.agravity.ts +270 -106
- package/api/publicPortalManagement.pub.agravity.ts +323 -124
- package/api/publicPublishing.pub.agravity.ts +69 -38
- package/api/publicSavedSearch.pub.agravity.ts +75 -38
- package/api/publicSearchManagement.pub.agravity.ts +265 -194
- package/api/publicSharingManagement.pub.agravity.ts +246 -157
- package/api/publicSignalRConnectionManagement.pub.agravity.ts +68 -24
- package/api/publicStaticDefinedListManagement.pub.agravity.ts +212 -107
- package/api/publicTranslationManagement.pub.agravity.ts +189 -115
- package/api/publicWebAppData.pub.agravity.ts +146 -47
- package/api/publicWorkspaceManagement.pub.agravity.ts +158 -57
- package/api.module.ts +0 -24
- package/configuration.ts +42 -0
- package/git_push.sh +3 -4
- package/index.ts +1 -0
- package/model/agravityErrorResponse.pub.agravity.ts +3 -4
- package/model/{badRequestResult.pub.agravity.ts → agravityInfoResponse.pub.agravity.ts} +4 -3
- package/model/agravityVersion.pub.agravity.ts +8 -9
- package/model/allWebAppData.pub.agravity.ts +4 -5
- package/model/artificialIntelligenceGroup.pub.agravity.ts +3 -4
- package/model/asset.pub.agravity.ts +22 -23
- package/model/assetAvailability.pub.agravity.ts +1 -2
- package/model/assetBlob.pub.agravity.ts +27 -28
- package/model/assetIdFormat.pub.agravity.ts +3 -4
- package/model/assetPageResult.pub.agravity.ts +4 -5
- package/model/azSearchOptions.pub.agravity.ts +8 -9
- package/model/collTypeItem.pub.agravity.ts +16 -17
- package/model/collection.pub.agravity.ts +15 -16
- package/model/collectionType.pub.agravity.ts +14 -15
- package/model/collectionUDL.pub.agravity.ts +4 -5
- package/model/createSftpUserResult.pub.agravity.ts +2 -3
- package/model/dataResult.pub.agravity.ts +4 -5
- package/model/deletedEntities.pub.agravity.ts +4 -5
- package/model/distZipResponse.pub.agravity.ts +3 -4
- package/model/downloadFormat.pub.agravity.ts +18 -16
- package/model/dynamicImageOperation.pub.agravity.ts +2 -3
- package/model/entityId.pub.agravity.ts +1 -2
- package/model/entityIdName.pub.agravity.ts +3 -4
- package/model/frontendAppConfig.pub.agravity.ts +0 -1
- package/model/groupAllAppData.pub.agravity.ts +5 -6
- package/model/models.ts +1 -3
- package/model/moveCollectionBody.pub.agravity.ts +3 -4
- package/model/permissionEntity.pub.agravity.ts +1 -2
- package/model/portal.pub.agravity.ts +18 -20
- package/model/portalConfiguration.pub.agravity.ts +23 -25
- package/model/portalLinks.pub.agravity.ts +3 -4
- package/model/portalTheme.pub.agravity.ts +6 -7
- package/model/portalZipRequest.pub.agravity.ts +14 -15
- package/model/publishEntity.pub.agravity.ts +9 -10
- package/model/publishedAsset.pub.agravity.ts +12 -13
- package/model/quickShareFull.pub.agravity.ts +15 -16
- package/model/sasToken.pub.agravity.ts +6 -7
- package/model/savedSearch.pub.agravity.ts +13 -14
- package/model/searchAdminDataSourceStatus.pub.agravity.ts +2 -3
- package/model/searchAdminIndexStatus.pub.agravity.ts +3 -4
- package/model/searchAdminIndexerLastRun.pub.agravity.ts +3 -4
- package/model/searchAdminIndexerStatus.pub.agravity.ts +4 -5
- package/model/searchAdminSkillStatus.pub.agravity.ts +2 -3
- package/model/searchAdminStatistics.pub.agravity.ts +2 -3
- package/model/searchAdminStatus.pub.agravity.ts +4 -5
- package/model/searchFacet.pub.agravity.ts +2 -3
- package/model/searchFacetEntity.pub.agravity.ts +2 -3
- package/model/searchResult.pub.agravity.ts +3 -4
- package/model/searchableItem.pub.agravity.ts +3 -4
- package/model/secureUploadEntity.pub.agravity.ts +10 -11
- package/model/sharedAllowedFormat.pub.agravity.ts +2 -3
- package/model/sharedAsset.pub.agravity.ts +5 -6
- package/model/sharedCollectionFull.pub.agravity.ts +18 -19
- package/model/sharedCollectionZipRequest.pub.agravity.ts +14 -15
- package/model/signalRConnectionInfo.pub.agravity.ts +0 -1
- package/model/staticDefinedList.pub.agravity.ts +12 -13
- package/model/versionEntity.pub.agravity.ts +9 -10
- package/model/versionedAsset.pub.agravity.ts +5 -6
- package/model/whereParam.pub.agravity.ts +0 -1
- package/model/workspace.pub.agravity.ts +14 -15
- package/package.json +16 -17
- package/param.ts +44 -0
- package/model/okResult.pub.agravity.ts +0 -15
- package/model/portalLanguages.pub.agravity.ts +0 -16
|
@@ -2,7 +2,6 @@
|
|
|
2
2
|
* Agravity OpenAPI Documentation - Public Functions
|
|
3
3
|
* <h1>Agravity API Reference</h1>This is the public API description of Agravity GmbH.<br/><h2>Resources</h2><ul> <li>Collection type management</li> <li>Collections management</li> <li>Assets management</li> <li>Assets operations</li> <li>Assets publishing</li> <li>Collection Sharing (consume share)</li> <li>Secure Upload (validate + upload file)</li> <li>Download ZIP</li> <li>Search</li> <li>General management</li></ul><h2> Operations</h2>Agravity API performs the following operations:<ul> <li>List / get single collection types</li> <li>List / get single collections</li> <li>List / get single assets</li> <li>Operations on assets like: blobs, rotate, resize, similar, collections, customfields, download</li> <li>List / get single published asset</li> <li>Search for assets or collections</li> <li>Get version of deployment</li></ul><br/><b>API key is needed to access these endpoints.</b><br/><br/>Copyright © Agravity GmbH 2024. All Rights Reserved
|
|
4
4
|
*
|
|
5
|
-
* The version of the OpenAPI document: 7.3.1
|
|
6
5
|
* Contact: office@agravity.io
|
|
7
6
|
*
|
|
8
7
|
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
@@ -12,18 +11,77 @@
|
|
|
12
11
|
/* tslint:disable:no-unused-variable member-ordering */
|
|
13
12
|
|
|
14
13
|
import { Inject, Injectable, Optional } from '@angular/core';
|
|
15
|
-
import { HttpClient, HttpHeaders, HttpParams, HttpResponse, HttpEvent, HttpParameterCodec } from '@angular/common/http';
|
|
14
|
+
import { HttpClient, HttpHeaders, HttpParams, HttpResponse, HttpEvent, HttpParameterCodec, HttpContext } from '@angular/common/http';
|
|
16
15
|
import { CustomHttpParameterCodec } from '../encoder';
|
|
17
16
|
import { Observable } from 'rxjs';
|
|
18
17
|
|
|
19
|
-
|
|
20
|
-
import {
|
|
21
|
-
|
|
22
|
-
import {
|
|
18
|
+
// @ts-ignore
|
|
19
|
+
import { AgravityErrorResponse } from '../model/agravityErrorResponse.pub.agravity';
|
|
20
|
+
// @ts-ignore
|
|
21
|
+
import { AssetBlob } from '../model/assetBlob.pub.agravity';
|
|
22
|
+
// @ts-ignore
|
|
23
|
+
import { VersionEntity } from '../model/versionEntity.pub.agravity';
|
|
24
|
+
// @ts-ignore
|
|
25
|
+
import { VersionedAsset } from '../model/versionedAsset.pub.agravity';
|
|
23
26
|
|
|
27
|
+
// @ts-ignore
|
|
24
28
|
import { BASE_PATH, COLLECTION_FORMATS } from '../variables';
|
|
25
29
|
import { AgravityPublicConfiguration } from '../configuration';
|
|
26
30
|
|
|
31
|
+
export interface HttpAssetCreateUploadVersionRequestParams {
|
|
32
|
+
/** The ID of the asset. */
|
|
33
|
+
id: string;
|
|
34
|
+
name?: string;
|
|
35
|
+
collectionId?: string;
|
|
36
|
+
file?: Blob;
|
|
37
|
+
filename?: string;
|
|
38
|
+
previewof?: string;
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
export interface HttpAssetCreateVersionRequestParams {
|
|
42
|
+
/** The ID of the asset. */
|
|
43
|
+
id: string;
|
|
44
|
+
/** This VersionedAsset to create empty version (need to upload file with metadata to blob storage) */
|
|
45
|
+
versionedAsset: VersionedAsset;
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
export interface HttpDeleteVersionedAssetsByIdRequestParams {
|
|
49
|
+
/** The ID of the asset. */
|
|
50
|
+
id: string;
|
|
51
|
+
/** The version number of the asset. */
|
|
52
|
+
vNr: string;
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
export interface HttpGetVersionedAssetBlobByIdRequestParams {
|
|
56
|
+
/** The ID of the asset. */
|
|
57
|
+
id: string;
|
|
58
|
+
/** The version number of the asset. */
|
|
59
|
+
vNr: number;
|
|
60
|
+
/** \"t\" for thumbnail (default); \"o\" for optimized */
|
|
61
|
+
c?: string;
|
|
62
|
+
}
|
|
63
|
+
|
|
64
|
+
export interface HttpRestoreVersionedAssetsByIdRequestParams {
|
|
65
|
+
/** The ID of the asset. */
|
|
66
|
+
id: string;
|
|
67
|
+
/** The version number of the asset. */
|
|
68
|
+
vNr: string;
|
|
69
|
+
/** Only the version_info is used and will be added to the current version which is archived (before the old version is restored). */
|
|
70
|
+
versionedAsset: VersionedAsset;
|
|
71
|
+
}
|
|
72
|
+
|
|
73
|
+
export interface HttpUpdateVersionedAssetsByIdRequestParams {
|
|
74
|
+
/** The ID of the asset. */
|
|
75
|
+
id: string;
|
|
76
|
+
/** The version number of the asset. */
|
|
77
|
+
vNr: string;
|
|
78
|
+
}
|
|
79
|
+
|
|
80
|
+
export interface HttpVersionedAssetsGetRequestParams {
|
|
81
|
+
/** The ID of the asset. */
|
|
82
|
+
id: string;
|
|
83
|
+
}
|
|
84
|
+
|
|
27
85
|
@Injectable({
|
|
28
86
|
providedIn: 'root'
|
|
29
87
|
})
|
|
@@ -35,13 +93,18 @@ export class PublicAssetVersioningService {
|
|
|
35
93
|
|
|
36
94
|
constructor(
|
|
37
95
|
protected httpClient: HttpClient,
|
|
38
|
-
@Optional() @Inject(BASE_PATH) basePath: string,
|
|
96
|
+
@Optional() @Inject(BASE_PATH) basePath: string | string[],
|
|
39
97
|
@Optional() configuration: AgravityPublicConfiguration
|
|
40
98
|
) {
|
|
41
99
|
if (configuration) {
|
|
42
100
|
this.configuration = configuration;
|
|
43
101
|
}
|
|
44
102
|
if (typeof this.configuration.basePath !== 'string') {
|
|
103
|
+
const firstBasePath = Array.isArray(basePath) ? basePath[0] : undefined;
|
|
104
|
+
if (firstBasePath != undefined) {
|
|
105
|
+
basePath = firstBasePath;
|
|
106
|
+
}
|
|
107
|
+
|
|
45
108
|
if (typeof basePath !== 'string') {
|
|
46
109
|
basePath = this.basePath;
|
|
47
110
|
}
|
|
@@ -64,6 +127,7 @@ export class PublicAssetVersioningService {
|
|
|
64
127
|
return false;
|
|
65
128
|
}
|
|
66
129
|
|
|
130
|
+
// @ts-ignore
|
|
67
131
|
private addToHttpParams(httpParams: HttpParams, value: any, key?: string): HttpParams {
|
|
68
132
|
if (typeof value === 'object' && value instanceof Date === false) {
|
|
69
133
|
httpParams = this.addToHttpParamsRecursive(httpParams, value);
|
|
@@ -83,7 +147,7 @@ export class PublicAssetVersioningService {
|
|
|
83
147
|
(value as any[]).forEach((elem) => (httpParams = this.addToHttpParamsRecursive(httpParams, elem, key)));
|
|
84
148
|
} else if (value instanceof Date) {
|
|
85
149
|
if (key != null) {
|
|
86
|
-
httpParams = httpParams.append(key, (value as Date).toISOString().
|
|
150
|
+
httpParams = httpParams.append(key, (value as Date).toISOString().substring(0, 10));
|
|
87
151
|
} else {
|
|
88
152
|
throw Error('key may not be null if value is Date');
|
|
89
153
|
}
|
|
@@ -100,80 +164,71 @@ export class PublicAssetVersioningService {
|
|
|
100
164
|
|
|
101
165
|
/**
|
|
102
166
|
* This endpoint allows to upload one asset which replaces the asset with given id and creates a version which is returned.
|
|
103
|
-
* @param
|
|
104
|
-
* @param name
|
|
105
|
-
* @param collectionId
|
|
106
|
-
* @param file
|
|
107
|
-
* @param filename
|
|
108
|
-
* @param previewof
|
|
167
|
+
* @param requestParameters
|
|
109
168
|
* @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body.
|
|
110
169
|
* @param reportProgress flag to report request and response progress.
|
|
111
170
|
*/
|
|
112
171
|
public httpAssetCreateUploadVersion(
|
|
113
|
-
|
|
114
|
-
name?: string,
|
|
115
|
-
collectionId?: string,
|
|
116
|
-
file?: Blob,
|
|
117
|
-
filename?: string,
|
|
118
|
-
previewof?: string,
|
|
172
|
+
requestParameters?: HttpAssetCreateUploadVersionRequestParams,
|
|
119
173
|
observe?: 'body',
|
|
120
174
|
reportProgress?: boolean,
|
|
121
|
-
options?: { httpHeaderAccept?: 'application/json' }
|
|
175
|
+
options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext; transferCache?: boolean }
|
|
122
176
|
): Observable<VersionedAsset>;
|
|
123
177
|
public httpAssetCreateUploadVersion(
|
|
124
|
-
|
|
125
|
-
name?: string,
|
|
126
|
-
collectionId?: string,
|
|
127
|
-
file?: Blob,
|
|
128
|
-
filename?: string,
|
|
129
|
-
previewof?: string,
|
|
178
|
+
requestParameters?: HttpAssetCreateUploadVersionRequestParams,
|
|
130
179
|
observe?: 'response',
|
|
131
180
|
reportProgress?: boolean,
|
|
132
|
-
options?: { httpHeaderAccept?: 'application/json' }
|
|
181
|
+
options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext; transferCache?: boolean }
|
|
133
182
|
): Observable<HttpResponse<VersionedAsset>>;
|
|
134
183
|
public httpAssetCreateUploadVersion(
|
|
135
|
-
|
|
136
|
-
name?: string,
|
|
137
|
-
collectionId?: string,
|
|
138
|
-
file?: Blob,
|
|
139
|
-
filename?: string,
|
|
140
|
-
previewof?: string,
|
|
184
|
+
requestParameters?: HttpAssetCreateUploadVersionRequestParams,
|
|
141
185
|
observe?: 'events',
|
|
142
186
|
reportProgress?: boolean,
|
|
143
|
-
options?: { httpHeaderAccept?: 'application/json' }
|
|
187
|
+
options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext; transferCache?: boolean }
|
|
144
188
|
): Observable<HttpEvent<VersionedAsset>>;
|
|
145
189
|
public httpAssetCreateUploadVersion(
|
|
146
|
-
|
|
147
|
-
name?: string,
|
|
148
|
-
collectionId?: string,
|
|
149
|
-
file?: Blob,
|
|
150
|
-
filename?: string,
|
|
151
|
-
previewof?: string,
|
|
190
|
+
requestParameters?: HttpAssetCreateUploadVersionRequestParams,
|
|
152
191
|
observe: any = 'body',
|
|
153
192
|
reportProgress: boolean = false,
|
|
154
|
-
options?: { httpHeaderAccept?: 'application/json' }
|
|
193
|
+
options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext; transferCache?: boolean }
|
|
155
194
|
): Observable<any> {
|
|
195
|
+
const id = requestParameters?.id;
|
|
156
196
|
if (id === null || id === undefined) {
|
|
157
197
|
throw new Error('Required parameter id was null or undefined when calling httpAssetCreateUploadVersion.');
|
|
158
198
|
}
|
|
199
|
+
const name = requestParameters?.name;
|
|
200
|
+
const collectionId = requestParameters?.collectionId;
|
|
201
|
+
const file = requestParameters?.file;
|
|
202
|
+
const filename = requestParameters?.filename;
|
|
203
|
+
const previewof = requestParameters?.previewof;
|
|
159
204
|
|
|
160
|
-
let
|
|
205
|
+
let localVarHeaders = this.defaultHeaders;
|
|
161
206
|
|
|
162
|
-
let
|
|
207
|
+
let localVarCredential: string | undefined;
|
|
163
208
|
// authentication (function_key) required
|
|
164
|
-
|
|
165
|
-
if (
|
|
166
|
-
|
|
209
|
+
localVarCredential = this.configuration.lookupCredential('function_key');
|
|
210
|
+
if (localVarCredential) {
|
|
211
|
+
localVarHeaders = localVarHeaders.set('x-functions-key', localVarCredential);
|
|
167
212
|
}
|
|
168
213
|
|
|
169
|
-
let
|
|
170
|
-
if (
|
|
214
|
+
let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept;
|
|
215
|
+
if (localVarHttpHeaderAcceptSelected === undefined) {
|
|
171
216
|
// to determine the Accept header
|
|
172
217
|
const httpHeaderAccepts: string[] = ['application/json'];
|
|
173
|
-
|
|
218
|
+
localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts);
|
|
219
|
+
}
|
|
220
|
+
if (localVarHttpHeaderAcceptSelected !== undefined) {
|
|
221
|
+
localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected);
|
|
222
|
+
}
|
|
223
|
+
|
|
224
|
+
let localVarHttpContext: HttpContext | undefined = options && options.context;
|
|
225
|
+
if (localVarHttpContext === undefined) {
|
|
226
|
+
localVarHttpContext = new HttpContext();
|
|
174
227
|
}
|
|
175
|
-
|
|
176
|
-
|
|
228
|
+
|
|
229
|
+
let localVarTransferCache: boolean | undefined = options && options.transferCache;
|
|
230
|
+
if (localVarTransferCache === undefined) {
|
|
231
|
+
localVarTransferCache = true;
|
|
177
232
|
}
|
|
178
233
|
|
|
179
234
|
// to determine the Content-Type header
|
|
@@ -181,448 +236,623 @@ export class PublicAssetVersioningService {
|
|
|
181
236
|
|
|
182
237
|
const canConsumeForm = this.canConsumeForm(consumes);
|
|
183
238
|
|
|
184
|
-
let
|
|
185
|
-
let
|
|
186
|
-
let
|
|
239
|
+
let localVarFormParams: { append(param: string, value: any): any };
|
|
240
|
+
let localVarUseForm = false;
|
|
241
|
+
let localVarConvertFormParamsToString = false;
|
|
187
242
|
// use FormData to transmit files using content-type "multipart/form-data"
|
|
188
243
|
// see https://stackoverflow.com/questions/4007969/application-x-www-form-urlencoded-or-multipart-form-data
|
|
189
|
-
|
|
190
|
-
if (
|
|
191
|
-
|
|
244
|
+
localVarUseForm = canConsumeForm;
|
|
245
|
+
if (localVarUseForm) {
|
|
246
|
+
localVarFormParams = new FormData();
|
|
192
247
|
} else {
|
|
193
|
-
|
|
248
|
+
localVarFormParams = new HttpParams({ encoder: this.encoder });
|
|
194
249
|
}
|
|
195
250
|
|
|
196
251
|
if (name !== undefined) {
|
|
197
|
-
|
|
252
|
+
localVarFormParams = (localVarFormParams.append('name', <any>name) as any) || localVarFormParams;
|
|
198
253
|
}
|
|
199
254
|
if (collectionId !== undefined) {
|
|
200
|
-
|
|
255
|
+
localVarFormParams = (localVarFormParams.append('collectionId', <any>collectionId) as any) || localVarFormParams;
|
|
201
256
|
}
|
|
202
257
|
if (file !== undefined) {
|
|
203
|
-
|
|
258
|
+
localVarFormParams = (localVarFormParams.append('file', <any>file) as any) || localVarFormParams;
|
|
204
259
|
}
|
|
205
260
|
if (filename !== undefined) {
|
|
206
|
-
|
|
261
|
+
localVarFormParams = (localVarFormParams.append('filename', <any>filename) as any) || localVarFormParams;
|
|
207
262
|
}
|
|
208
263
|
if (previewof !== undefined) {
|
|
209
|
-
|
|
264
|
+
localVarFormParams = (localVarFormParams.append('previewof', <any>previewof) as any) || localVarFormParams;
|
|
210
265
|
}
|
|
211
266
|
|
|
212
|
-
let responseType_: 'text' | 'json' = 'json';
|
|
213
|
-
if (
|
|
214
|
-
|
|
267
|
+
let responseType_: 'text' | 'json' | 'blob' = 'json';
|
|
268
|
+
if (localVarHttpHeaderAcceptSelected) {
|
|
269
|
+
if (localVarHttpHeaderAcceptSelected.startsWith('text')) {
|
|
270
|
+
responseType_ = 'text';
|
|
271
|
+
} else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) {
|
|
272
|
+
responseType_ = 'json';
|
|
273
|
+
} else {
|
|
274
|
+
responseType_ = 'blob';
|
|
275
|
+
}
|
|
215
276
|
}
|
|
216
277
|
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
);
|
|
278
|
+
let localVarPath = `/assets/${this.configuration.encodeParam({ name: 'id', value: id, in: 'path', style: 'simple', explode: false, dataType: 'string', dataFormat: undefined })}/versionsupload`;
|
|
279
|
+
return this.httpClient.request<VersionedAsset>('post', `${this.configuration.basePath}${localVarPath}`, {
|
|
280
|
+
context: localVarHttpContext,
|
|
281
|
+
body: localVarConvertFormParamsToString ? localVarFormParams.toString() : localVarFormParams,
|
|
282
|
+
responseType: <any>responseType_,
|
|
283
|
+
withCredentials: this.configuration.withCredentials,
|
|
284
|
+
headers: localVarHeaders,
|
|
285
|
+
observe: observe,
|
|
286
|
+
transferCache: localVarTransferCache,
|
|
287
|
+
reportProgress: reportProgress
|
|
288
|
+
});
|
|
228
289
|
}
|
|
229
290
|
|
|
230
291
|
/**
|
|
231
292
|
* This endpoint allows to create empty version or upload one asset which replaces the asset with given id and creates version.
|
|
232
|
-
* @param
|
|
233
|
-
* @param versionedAsset This VersionedAsset to create empty version (need to upload file with metadata to blob storage)
|
|
293
|
+
* @param requestParameters
|
|
234
294
|
* @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body.
|
|
235
295
|
* @param reportProgress flag to report request and response progress.
|
|
236
296
|
*/
|
|
237
297
|
public httpAssetCreateVersion(
|
|
238
|
-
|
|
239
|
-
versionedAsset: VersionedAsset,
|
|
298
|
+
requestParameters?: HttpAssetCreateVersionRequestParams,
|
|
240
299
|
observe?: 'body',
|
|
241
300
|
reportProgress?: boolean,
|
|
242
|
-
options?: { httpHeaderAccept?: 'application/json' }
|
|
301
|
+
options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext; transferCache?: boolean }
|
|
243
302
|
): Observable<VersionedAsset>;
|
|
244
303
|
public httpAssetCreateVersion(
|
|
245
|
-
|
|
246
|
-
versionedAsset: VersionedAsset,
|
|
304
|
+
requestParameters?: HttpAssetCreateVersionRequestParams,
|
|
247
305
|
observe?: 'response',
|
|
248
306
|
reportProgress?: boolean,
|
|
249
|
-
options?: { httpHeaderAccept?: 'application/json' }
|
|
307
|
+
options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext; transferCache?: boolean }
|
|
250
308
|
): Observable<HttpResponse<VersionedAsset>>;
|
|
251
309
|
public httpAssetCreateVersion(
|
|
252
|
-
|
|
253
|
-
versionedAsset: VersionedAsset,
|
|
310
|
+
requestParameters?: HttpAssetCreateVersionRequestParams,
|
|
254
311
|
observe?: 'events',
|
|
255
312
|
reportProgress?: boolean,
|
|
256
|
-
options?: { httpHeaderAccept?: 'application/json' }
|
|
313
|
+
options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext; transferCache?: boolean }
|
|
257
314
|
): Observable<HttpEvent<VersionedAsset>>;
|
|
258
315
|
public httpAssetCreateVersion(
|
|
259
|
-
|
|
260
|
-
versionedAsset: VersionedAsset,
|
|
316
|
+
requestParameters?: HttpAssetCreateVersionRequestParams,
|
|
261
317
|
observe: any = 'body',
|
|
262
318
|
reportProgress: boolean = false,
|
|
263
|
-
options?: { httpHeaderAccept?: 'application/json' }
|
|
319
|
+
options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext; transferCache?: boolean }
|
|
264
320
|
): Observable<any> {
|
|
321
|
+
const id = requestParameters?.id;
|
|
265
322
|
if (id === null || id === undefined) {
|
|
266
323
|
throw new Error('Required parameter id was null or undefined when calling httpAssetCreateVersion.');
|
|
267
324
|
}
|
|
325
|
+
const versionedAsset = requestParameters?.versionedAsset;
|
|
268
326
|
if (versionedAsset === null || versionedAsset === undefined) {
|
|
269
327
|
throw new Error('Required parameter versionedAsset was null or undefined when calling httpAssetCreateVersion.');
|
|
270
328
|
}
|
|
271
329
|
|
|
272
|
-
let
|
|
330
|
+
let localVarHeaders = this.defaultHeaders;
|
|
273
331
|
|
|
274
|
-
let
|
|
332
|
+
let localVarCredential: string | undefined;
|
|
275
333
|
// authentication (function_key) required
|
|
276
|
-
|
|
277
|
-
if (
|
|
278
|
-
|
|
334
|
+
localVarCredential = this.configuration.lookupCredential('function_key');
|
|
335
|
+
if (localVarCredential) {
|
|
336
|
+
localVarHeaders = localVarHeaders.set('x-functions-key', localVarCredential);
|
|
279
337
|
}
|
|
280
338
|
|
|
281
|
-
let
|
|
282
|
-
if (
|
|
339
|
+
let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept;
|
|
340
|
+
if (localVarHttpHeaderAcceptSelected === undefined) {
|
|
283
341
|
// to determine the Accept header
|
|
284
342
|
const httpHeaderAccepts: string[] = ['application/json'];
|
|
285
|
-
|
|
343
|
+
localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts);
|
|
344
|
+
}
|
|
345
|
+
if (localVarHttpHeaderAcceptSelected !== undefined) {
|
|
346
|
+
localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected);
|
|
347
|
+
}
|
|
348
|
+
|
|
349
|
+
let localVarHttpContext: HttpContext | undefined = options && options.context;
|
|
350
|
+
if (localVarHttpContext === undefined) {
|
|
351
|
+
localVarHttpContext = new HttpContext();
|
|
286
352
|
}
|
|
287
|
-
|
|
288
|
-
|
|
353
|
+
|
|
354
|
+
let localVarTransferCache: boolean | undefined = options && options.transferCache;
|
|
355
|
+
if (localVarTransferCache === undefined) {
|
|
356
|
+
localVarTransferCache = true;
|
|
289
357
|
}
|
|
290
358
|
|
|
291
359
|
// to determine the Content-Type header
|
|
292
360
|
const consumes: string[] = ['application/json'];
|
|
293
361
|
const httpContentTypeSelected: string | undefined = this.configuration.selectHeaderContentType(consumes);
|
|
294
362
|
if (httpContentTypeSelected !== undefined) {
|
|
295
|
-
|
|
363
|
+
localVarHeaders = localVarHeaders.set('Content-Type', httpContentTypeSelected);
|
|
296
364
|
}
|
|
297
365
|
|
|
298
|
-
let responseType_: 'text' | 'json' = 'json';
|
|
299
|
-
if (
|
|
300
|
-
|
|
366
|
+
let responseType_: 'text' | 'json' | 'blob' = 'json';
|
|
367
|
+
if (localVarHttpHeaderAcceptSelected) {
|
|
368
|
+
if (localVarHttpHeaderAcceptSelected.startsWith('text')) {
|
|
369
|
+
responseType_ = 'text';
|
|
370
|
+
} else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) {
|
|
371
|
+
responseType_ = 'json';
|
|
372
|
+
} else {
|
|
373
|
+
responseType_ = 'blob';
|
|
374
|
+
}
|
|
301
375
|
}
|
|
302
376
|
|
|
303
|
-
|
|
377
|
+
let localVarPath = `/assets/${this.configuration.encodeParam({ name: 'id', value: id, in: 'path', style: 'simple', explode: false, dataType: 'string', dataFormat: undefined })}/versions`;
|
|
378
|
+
return this.httpClient.request<VersionedAsset>('post', `${this.configuration.basePath}${localVarPath}`, {
|
|
379
|
+
context: localVarHttpContext,
|
|
380
|
+
body: versionedAsset,
|
|
304
381
|
responseType: <any>responseType_,
|
|
305
382
|
withCredentials: this.configuration.withCredentials,
|
|
306
|
-
headers:
|
|
383
|
+
headers: localVarHeaders,
|
|
307
384
|
observe: observe,
|
|
385
|
+
transferCache: localVarTransferCache,
|
|
308
386
|
reportProgress: reportProgress
|
|
309
387
|
});
|
|
310
388
|
}
|
|
311
389
|
|
|
312
390
|
/**
|
|
313
391
|
* This endpoint deletes a version of an asset.
|
|
314
|
-
* @param
|
|
315
|
-
* @param vNr The version number of the asset.
|
|
392
|
+
* @param requestParameters
|
|
316
393
|
* @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body.
|
|
317
394
|
* @param reportProgress flag to report request and response progress.
|
|
318
395
|
*/
|
|
319
|
-
public httpDeleteVersionedAssetsById(
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
|
|
396
|
+
public httpDeleteVersionedAssetsById(
|
|
397
|
+
requestParameters?: HttpDeleteVersionedAssetsByIdRequestParams,
|
|
398
|
+
observe?: 'body',
|
|
399
|
+
reportProgress?: boolean,
|
|
400
|
+
options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext; transferCache?: boolean }
|
|
401
|
+
): Observable<any>;
|
|
402
|
+
public httpDeleteVersionedAssetsById(
|
|
403
|
+
requestParameters?: HttpDeleteVersionedAssetsByIdRequestParams,
|
|
404
|
+
observe?: 'response',
|
|
405
|
+
reportProgress?: boolean,
|
|
406
|
+
options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext; transferCache?: boolean }
|
|
407
|
+
): Observable<HttpResponse<any>>;
|
|
408
|
+
public httpDeleteVersionedAssetsById(
|
|
409
|
+
requestParameters?: HttpDeleteVersionedAssetsByIdRequestParams,
|
|
410
|
+
observe?: 'events',
|
|
411
|
+
reportProgress?: boolean,
|
|
412
|
+
options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext; transferCache?: boolean }
|
|
413
|
+
): Observable<HttpEvent<any>>;
|
|
414
|
+
public httpDeleteVersionedAssetsById(
|
|
415
|
+
requestParameters?: HttpDeleteVersionedAssetsByIdRequestParams,
|
|
416
|
+
observe: any = 'body',
|
|
417
|
+
reportProgress: boolean = false,
|
|
418
|
+
options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext; transferCache?: boolean }
|
|
419
|
+
): Observable<any> {
|
|
420
|
+
const id = requestParameters?.id;
|
|
323
421
|
if (id === null || id === undefined) {
|
|
324
422
|
throw new Error('Required parameter id was null or undefined when calling httpDeleteVersionedAssetsById.');
|
|
325
423
|
}
|
|
424
|
+
const vNr = requestParameters?.vNr;
|
|
326
425
|
if (vNr === null || vNr === undefined) {
|
|
327
426
|
throw new Error('Required parameter vNr was null or undefined when calling httpDeleteVersionedAssetsById.');
|
|
328
427
|
}
|
|
329
428
|
|
|
330
|
-
let
|
|
429
|
+
let localVarHeaders = this.defaultHeaders;
|
|
331
430
|
|
|
332
|
-
let
|
|
431
|
+
let localVarCredential: string | undefined;
|
|
333
432
|
// authentication (function_key) required
|
|
334
|
-
|
|
335
|
-
if (
|
|
336
|
-
|
|
433
|
+
localVarCredential = this.configuration.lookupCredential('function_key');
|
|
434
|
+
if (localVarCredential) {
|
|
435
|
+
localVarHeaders = localVarHeaders.set('x-functions-key', localVarCredential);
|
|
337
436
|
}
|
|
338
437
|
|
|
339
|
-
let
|
|
340
|
-
if (
|
|
438
|
+
let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept;
|
|
439
|
+
if (localVarHttpHeaderAcceptSelected === undefined) {
|
|
341
440
|
// to determine the Accept header
|
|
342
441
|
const httpHeaderAccepts: string[] = ['application/json'];
|
|
343
|
-
|
|
442
|
+
localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts);
|
|
344
443
|
}
|
|
345
|
-
if (
|
|
346
|
-
|
|
444
|
+
if (localVarHttpHeaderAcceptSelected !== undefined) {
|
|
445
|
+
localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected);
|
|
347
446
|
}
|
|
348
447
|
|
|
349
|
-
let
|
|
350
|
-
if (
|
|
351
|
-
|
|
448
|
+
let localVarHttpContext: HttpContext | undefined = options && options.context;
|
|
449
|
+
if (localVarHttpContext === undefined) {
|
|
450
|
+
localVarHttpContext = new HttpContext();
|
|
451
|
+
}
|
|
452
|
+
|
|
453
|
+
let localVarTransferCache: boolean | undefined = options && options.transferCache;
|
|
454
|
+
if (localVarTransferCache === undefined) {
|
|
455
|
+
localVarTransferCache = true;
|
|
456
|
+
}
|
|
457
|
+
|
|
458
|
+
let responseType_: 'text' | 'json' | 'blob' = 'json';
|
|
459
|
+
if (localVarHttpHeaderAcceptSelected) {
|
|
460
|
+
if (localVarHttpHeaderAcceptSelected.startsWith('text')) {
|
|
461
|
+
responseType_ = 'text';
|
|
462
|
+
} else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) {
|
|
463
|
+
responseType_ = 'json';
|
|
464
|
+
} else {
|
|
465
|
+
responseType_ = 'blob';
|
|
466
|
+
}
|
|
352
467
|
}
|
|
353
468
|
|
|
354
|
-
|
|
469
|
+
let localVarPath = `/assets/${this.configuration.encodeParam({ name: 'id', value: id, in: 'path', style: 'simple', explode: false, dataType: 'string', dataFormat: undefined })}/versions/${this.configuration.encodeParam({ name: 'vNr', value: vNr, in: 'path', style: 'simple', explode: false, dataType: 'string', dataFormat: undefined })}`;
|
|
470
|
+
return this.httpClient.request<any>('delete', `${this.configuration.basePath}${localVarPath}`, {
|
|
471
|
+
context: localVarHttpContext,
|
|
355
472
|
responseType: <any>responseType_,
|
|
356
473
|
withCredentials: this.configuration.withCredentials,
|
|
357
|
-
headers:
|
|
474
|
+
headers: localVarHeaders,
|
|
358
475
|
observe: observe,
|
|
476
|
+
transferCache: localVarTransferCache,
|
|
359
477
|
reportProgress: reportProgress
|
|
360
478
|
});
|
|
361
479
|
}
|
|
362
480
|
|
|
363
481
|
/**
|
|
364
482
|
* This endpoint checks if assets and version exists and returns the url for the requested blob.
|
|
365
|
-
* @param
|
|
366
|
-
* @param vNr The version number of the asset.
|
|
367
|
-
* @param c \"t\" for thumbnail (default); \"o\" for optimized
|
|
483
|
+
* @param requestParameters
|
|
368
484
|
* @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body.
|
|
369
485
|
* @param reportProgress flag to report request and response progress.
|
|
370
486
|
*/
|
|
371
|
-
public httpGetVersionedAssetBlobById(id: string, vNr: number, c?: string, observe?: 'body', reportProgress?: boolean, options?: { httpHeaderAccept?: 'application/json' }): Observable<AssetBlob>;
|
|
372
487
|
public httpGetVersionedAssetBlobById(
|
|
373
|
-
|
|
374
|
-
|
|
375
|
-
|
|
488
|
+
requestParameters?: HttpGetVersionedAssetBlobByIdRequestParams,
|
|
489
|
+
observe?: 'body',
|
|
490
|
+
reportProgress?: boolean,
|
|
491
|
+
options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext; transferCache?: boolean }
|
|
492
|
+
): Observable<AssetBlob>;
|
|
493
|
+
public httpGetVersionedAssetBlobById(
|
|
494
|
+
requestParameters?: HttpGetVersionedAssetBlobByIdRequestParams,
|
|
376
495
|
observe?: 'response',
|
|
377
496
|
reportProgress?: boolean,
|
|
378
|
-
options?: { httpHeaderAccept?: 'application/json' }
|
|
497
|
+
options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext; transferCache?: boolean }
|
|
379
498
|
): Observable<HttpResponse<AssetBlob>>;
|
|
380
499
|
public httpGetVersionedAssetBlobById(
|
|
381
|
-
|
|
382
|
-
vNr: number,
|
|
383
|
-
c?: string,
|
|
500
|
+
requestParameters?: HttpGetVersionedAssetBlobByIdRequestParams,
|
|
384
501
|
observe?: 'events',
|
|
385
502
|
reportProgress?: boolean,
|
|
386
|
-
options?: { httpHeaderAccept?: 'application/json' }
|
|
503
|
+
options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext; transferCache?: boolean }
|
|
387
504
|
): Observable<HttpEvent<AssetBlob>>;
|
|
388
505
|
public httpGetVersionedAssetBlobById(
|
|
389
|
-
|
|
390
|
-
vNr: number,
|
|
391
|
-
c?: string,
|
|
506
|
+
requestParameters?: HttpGetVersionedAssetBlobByIdRequestParams,
|
|
392
507
|
observe: any = 'body',
|
|
393
508
|
reportProgress: boolean = false,
|
|
394
|
-
options?: { httpHeaderAccept?: 'application/json' }
|
|
509
|
+
options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext; transferCache?: boolean }
|
|
395
510
|
): Observable<any> {
|
|
511
|
+
const id = requestParameters?.id;
|
|
396
512
|
if (id === null || id === undefined) {
|
|
397
513
|
throw new Error('Required parameter id was null or undefined when calling httpGetVersionedAssetBlobById.');
|
|
398
514
|
}
|
|
515
|
+
const vNr = requestParameters?.vNr;
|
|
399
516
|
if (vNr === null || vNr === undefined) {
|
|
400
517
|
throw new Error('Required parameter vNr was null or undefined when calling httpGetVersionedAssetBlobById.');
|
|
401
518
|
}
|
|
519
|
+
const c = requestParameters?.c;
|
|
402
520
|
|
|
403
|
-
let
|
|
521
|
+
let localVarQueryParameters = new HttpParams({ encoder: this.encoder });
|
|
404
522
|
if (c !== undefined && c !== null) {
|
|
405
|
-
|
|
523
|
+
localVarQueryParameters = this.addToHttpParams(localVarQueryParameters, <any>c, 'c');
|
|
406
524
|
}
|
|
407
525
|
|
|
408
|
-
let
|
|
526
|
+
let localVarHeaders = this.defaultHeaders;
|
|
409
527
|
|
|
410
|
-
let
|
|
528
|
+
let localVarCredential: string | undefined;
|
|
411
529
|
// authentication (function_key) required
|
|
412
|
-
|
|
413
|
-
if (
|
|
414
|
-
|
|
530
|
+
localVarCredential = this.configuration.lookupCredential('function_key');
|
|
531
|
+
if (localVarCredential) {
|
|
532
|
+
localVarHeaders = localVarHeaders.set('x-functions-key', localVarCredential);
|
|
415
533
|
}
|
|
416
534
|
|
|
417
|
-
let
|
|
418
|
-
if (
|
|
535
|
+
let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept;
|
|
536
|
+
if (localVarHttpHeaderAcceptSelected === undefined) {
|
|
419
537
|
// to determine the Accept header
|
|
420
538
|
const httpHeaderAccepts: string[] = ['application/json'];
|
|
421
|
-
|
|
539
|
+
localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts);
|
|
540
|
+
}
|
|
541
|
+
if (localVarHttpHeaderAcceptSelected !== undefined) {
|
|
542
|
+
localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected);
|
|
543
|
+
}
|
|
544
|
+
|
|
545
|
+
let localVarHttpContext: HttpContext | undefined = options && options.context;
|
|
546
|
+
if (localVarHttpContext === undefined) {
|
|
547
|
+
localVarHttpContext = new HttpContext();
|
|
422
548
|
}
|
|
423
|
-
|
|
424
|
-
|
|
549
|
+
|
|
550
|
+
let localVarTransferCache: boolean | undefined = options && options.transferCache;
|
|
551
|
+
if (localVarTransferCache === undefined) {
|
|
552
|
+
localVarTransferCache = true;
|
|
425
553
|
}
|
|
426
554
|
|
|
427
|
-
let responseType_: 'text' | 'json' = 'json';
|
|
428
|
-
if (
|
|
429
|
-
|
|
555
|
+
let responseType_: 'text' | 'json' | 'blob' = 'json';
|
|
556
|
+
if (localVarHttpHeaderAcceptSelected) {
|
|
557
|
+
if (localVarHttpHeaderAcceptSelected.startsWith('text')) {
|
|
558
|
+
responseType_ = 'text';
|
|
559
|
+
} else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) {
|
|
560
|
+
responseType_ = 'json';
|
|
561
|
+
} else {
|
|
562
|
+
responseType_ = 'blob';
|
|
563
|
+
}
|
|
430
564
|
}
|
|
431
565
|
|
|
432
|
-
|
|
433
|
-
|
|
566
|
+
let localVarPath = `/assets/${this.configuration.encodeParam({ name: 'id', value: id, in: 'path', style: 'simple', explode: false, dataType: 'string', dataFormat: undefined })}/versions/${this.configuration.encodeParam({ name: 'vNr', value: vNr, in: 'path', style: 'simple', explode: false, dataType: 'number', dataFormat: 'int32' })}/blobs`;
|
|
567
|
+
return this.httpClient.request<AssetBlob>('get', `${this.configuration.basePath}${localVarPath}`, {
|
|
568
|
+
context: localVarHttpContext,
|
|
569
|
+
params: localVarQueryParameters,
|
|
434
570
|
responseType: <any>responseType_,
|
|
435
571
|
withCredentials: this.configuration.withCredentials,
|
|
436
|
-
headers:
|
|
572
|
+
headers: localVarHeaders,
|
|
437
573
|
observe: observe,
|
|
574
|
+
transferCache: localVarTransferCache,
|
|
438
575
|
reportProgress: reportProgress
|
|
439
576
|
});
|
|
440
577
|
}
|
|
441
578
|
|
|
442
579
|
/**
|
|
443
580
|
* This endpoint restores a version nr to be the current version and saves the current asset as version.
|
|
444
|
-
* @param
|
|
445
|
-
* @param vNr The version number of the asset.
|
|
446
|
-
* @param versionedAsset Only the version_info is used and will be added to the current version which is archived (before the old version is restored).
|
|
581
|
+
* @param requestParameters
|
|
447
582
|
* @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body.
|
|
448
583
|
* @param reportProgress flag to report request and response progress.
|
|
449
584
|
*/
|
|
450
585
|
public httpRestoreVersionedAssetsById(
|
|
451
|
-
|
|
452
|
-
vNr: string,
|
|
453
|
-
versionedAsset: VersionedAsset,
|
|
586
|
+
requestParameters?: HttpRestoreVersionedAssetsByIdRequestParams,
|
|
454
587
|
observe?: 'body',
|
|
455
588
|
reportProgress?: boolean,
|
|
456
|
-
options?: { httpHeaderAccept?: 'application/json' }
|
|
589
|
+
options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext; transferCache?: boolean }
|
|
457
590
|
): Observable<VersionedAsset>;
|
|
458
591
|
public httpRestoreVersionedAssetsById(
|
|
459
|
-
|
|
460
|
-
vNr: string,
|
|
461
|
-
versionedAsset: VersionedAsset,
|
|
592
|
+
requestParameters?: HttpRestoreVersionedAssetsByIdRequestParams,
|
|
462
593
|
observe?: 'response',
|
|
463
594
|
reportProgress?: boolean,
|
|
464
|
-
options?: { httpHeaderAccept?: 'application/json' }
|
|
595
|
+
options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext; transferCache?: boolean }
|
|
465
596
|
): Observable<HttpResponse<VersionedAsset>>;
|
|
466
597
|
public httpRestoreVersionedAssetsById(
|
|
467
|
-
|
|
468
|
-
vNr: string,
|
|
469
|
-
versionedAsset: VersionedAsset,
|
|
598
|
+
requestParameters?: HttpRestoreVersionedAssetsByIdRequestParams,
|
|
470
599
|
observe?: 'events',
|
|
471
600
|
reportProgress?: boolean,
|
|
472
|
-
options?: { httpHeaderAccept?: 'application/json' }
|
|
601
|
+
options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext; transferCache?: boolean }
|
|
473
602
|
): Observable<HttpEvent<VersionedAsset>>;
|
|
474
603
|
public httpRestoreVersionedAssetsById(
|
|
475
|
-
|
|
476
|
-
vNr: string,
|
|
477
|
-
versionedAsset: VersionedAsset,
|
|
604
|
+
requestParameters?: HttpRestoreVersionedAssetsByIdRequestParams,
|
|
478
605
|
observe: any = 'body',
|
|
479
606
|
reportProgress: boolean = false,
|
|
480
|
-
options?: { httpHeaderAccept?: 'application/json' }
|
|
607
|
+
options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext; transferCache?: boolean }
|
|
481
608
|
): Observable<any> {
|
|
609
|
+
const id = requestParameters?.id;
|
|
482
610
|
if (id === null || id === undefined) {
|
|
483
611
|
throw new Error('Required parameter id was null or undefined when calling httpRestoreVersionedAssetsById.');
|
|
484
612
|
}
|
|
613
|
+
const vNr = requestParameters?.vNr;
|
|
485
614
|
if (vNr === null || vNr === undefined) {
|
|
486
615
|
throw new Error('Required parameter vNr was null or undefined when calling httpRestoreVersionedAssetsById.');
|
|
487
616
|
}
|
|
617
|
+
const versionedAsset = requestParameters?.versionedAsset;
|
|
488
618
|
if (versionedAsset === null || versionedAsset === undefined) {
|
|
489
619
|
throw new Error('Required parameter versionedAsset was null or undefined when calling httpRestoreVersionedAssetsById.');
|
|
490
620
|
}
|
|
491
621
|
|
|
492
|
-
let
|
|
622
|
+
let localVarHeaders = this.defaultHeaders;
|
|
493
623
|
|
|
494
|
-
let
|
|
624
|
+
let localVarCredential: string | undefined;
|
|
495
625
|
// authentication (function_key) required
|
|
496
|
-
|
|
497
|
-
if (
|
|
498
|
-
|
|
626
|
+
localVarCredential = this.configuration.lookupCredential('function_key');
|
|
627
|
+
if (localVarCredential) {
|
|
628
|
+
localVarHeaders = localVarHeaders.set('x-functions-key', localVarCredential);
|
|
499
629
|
}
|
|
500
630
|
|
|
501
|
-
let
|
|
502
|
-
if (
|
|
631
|
+
let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept;
|
|
632
|
+
if (localVarHttpHeaderAcceptSelected === undefined) {
|
|
503
633
|
// to determine the Accept header
|
|
504
634
|
const httpHeaderAccepts: string[] = ['application/json'];
|
|
505
|
-
|
|
635
|
+
localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts);
|
|
636
|
+
}
|
|
637
|
+
if (localVarHttpHeaderAcceptSelected !== undefined) {
|
|
638
|
+
localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected);
|
|
639
|
+
}
|
|
640
|
+
|
|
641
|
+
let localVarHttpContext: HttpContext | undefined = options && options.context;
|
|
642
|
+
if (localVarHttpContext === undefined) {
|
|
643
|
+
localVarHttpContext = new HttpContext();
|
|
506
644
|
}
|
|
507
|
-
|
|
508
|
-
|
|
645
|
+
|
|
646
|
+
let localVarTransferCache: boolean | undefined = options && options.transferCache;
|
|
647
|
+
if (localVarTransferCache === undefined) {
|
|
648
|
+
localVarTransferCache = true;
|
|
509
649
|
}
|
|
510
650
|
|
|
511
651
|
// to determine the Content-Type header
|
|
512
652
|
const consumes: string[] = ['application/json'];
|
|
513
653
|
const httpContentTypeSelected: string | undefined = this.configuration.selectHeaderContentType(consumes);
|
|
514
654
|
if (httpContentTypeSelected !== undefined) {
|
|
515
|
-
|
|
655
|
+
localVarHeaders = localVarHeaders.set('Content-Type', httpContentTypeSelected);
|
|
516
656
|
}
|
|
517
657
|
|
|
518
|
-
let responseType_: 'text' | 'json' = 'json';
|
|
519
|
-
if (
|
|
520
|
-
|
|
658
|
+
let responseType_: 'text' | 'json' | 'blob' = 'json';
|
|
659
|
+
if (localVarHttpHeaderAcceptSelected) {
|
|
660
|
+
if (localVarHttpHeaderAcceptSelected.startsWith('text')) {
|
|
661
|
+
responseType_ = 'text';
|
|
662
|
+
} else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) {
|
|
663
|
+
responseType_ = 'json';
|
|
664
|
+
} else {
|
|
665
|
+
responseType_ = 'blob';
|
|
666
|
+
}
|
|
521
667
|
}
|
|
522
668
|
|
|
523
|
-
|
|
669
|
+
let localVarPath = `/assets/${this.configuration.encodeParam({ name: 'id', value: id, in: 'path', style: 'simple', explode: false, dataType: 'string', dataFormat: undefined })}/versions/${this.configuration.encodeParam({ name: 'vNr', value: vNr, in: 'path', style: 'simple', explode: false, dataType: 'string', dataFormat: undefined })}/restore`;
|
|
670
|
+
return this.httpClient.request<VersionedAsset>('post', `${this.configuration.basePath}${localVarPath}`, {
|
|
671
|
+
context: localVarHttpContext,
|
|
672
|
+
body: versionedAsset,
|
|
524
673
|
responseType: <any>responseType_,
|
|
525
674
|
withCredentials: this.configuration.withCredentials,
|
|
526
|
-
headers:
|
|
675
|
+
headers: localVarHeaders,
|
|
527
676
|
observe: observe,
|
|
677
|
+
transferCache: localVarTransferCache,
|
|
528
678
|
reportProgress: reportProgress
|
|
529
679
|
});
|
|
530
680
|
}
|
|
531
681
|
|
|
532
682
|
/**
|
|
533
683
|
* This endpoint updates a version of an asset.
|
|
534
|
-
* @param
|
|
535
|
-
* @param vNr The version number of the asset.
|
|
684
|
+
* @param requestParameters
|
|
536
685
|
* @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body.
|
|
537
686
|
* @param reportProgress flag to report request and response progress.
|
|
538
687
|
*/
|
|
539
|
-
public httpUpdateVersionedAssetsById(
|
|
540
|
-
|
|
541
|
-
|
|
542
|
-
|
|
688
|
+
public httpUpdateVersionedAssetsById(
|
|
689
|
+
requestParameters?: HttpUpdateVersionedAssetsByIdRequestParams,
|
|
690
|
+
observe?: 'body',
|
|
691
|
+
reportProgress?: boolean,
|
|
692
|
+
options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext; transferCache?: boolean }
|
|
693
|
+
): Observable<VersionedAsset>;
|
|
694
|
+
public httpUpdateVersionedAssetsById(
|
|
695
|
+
requestParameters?: HttpUpdateVersionedAssetsByIdRequestParams,
|
|
696
|
+
observe?: 'response',
|
|
697
|
+
reportProgress?: boolean,
|
|
698
|
+
options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext; transferCache?: boolean }
|
|
699
|
+
): Observable<HttpResponse<VersionedAsset>>;
|
|
700
|
+
public httpUpdateVersionedAssetsById(
|
|
701
|
+
requestParameters?: HttpUpdateVersionedAssetsByIdRequestParams,
|
|
702
|
+
observe?: 'events',
|
|
703
|
+
reportProgress?: boolean,
|
|
704
|
+
options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext; transferCache?: boolean }
|
|
705
|
+
): Observable<HttpEvent<VersionedAsset>>;
|
|
706
|
+
public httpUpdateVersionedAssetsById(
|
|
707
|
+
requestParameters?: HttpUpdateVersionedAssetsByIdRequestParams,
|
|
708
|
+
observe: any = 'body',
|
|
709
|
+
reportProgress: boolean = false,
|
|
710
|
+
options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext; transferCache?: boolean }
|
|
711
|
+
): Observable<any> {
|
|
712
|
+
const id = requestParameters?.id;
|
|
543
713
|
if (id === null || id === undefined) {
|
|
544
714
|
throw new Error('Required parameter id was null or undefined when calling httpUpdateVersionedAssetsById.');
|
|
545
715
|
}
|
|
716
|
+
const vNr = requestParameters?.vNr;
|
|
546
717
|
if (vNr === null || vNr === undefined) {
|
|
547
718
|
throw new Error('Required parameter vNr was null or undefined when calling httpUpdateVersionedAssetsById.');
|
|
548
719
|
}
|
|
549
720
|
|
|
550
|
-
let
|
|
721
|
+
let localVarHeaders = this.defaultHeaders;
|
|
551
722
|
|
|
552
|
-
let
|
|
723
|
+
let localVarCredential: string | undefined;
|
|
553
724
|
// authentication (function_key) required
|
|
554
|
-
|
|
555
|
-
if (
|
|
556
|
-
|
|
725
|
+
localVarCredential = this.configuration.lookupCredential('function_key');
|
|
726
|
+
if (localVarCredential) {
|
|
727
|
+
localVarHeaders = localVarHeaders.set('x-functions-key', localVarCredential);
|
|
557
728
|
}
|
|
558
729
|
|
|
559
|
-
let
|
|
560
|
-
if (
|
|
730
|
+
let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept;
|
|
731
|
+
if (localVarHttpHeaderAcceptSelected === undefined) {
|
|
561
732
|
// to determine the Accept header
|
|
562
733
|
const httpHeaderAccepts: string[] = ['application/json'];
|
|
563
|
-
|
|
734
|
+
localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts);
|
|
735
|
+
}
|
|
736
|
+
if (localVarHttpHeaderAcceptSelected !== undefined) {
|
|
737
|
+
localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected);
|
|
738
|
+
}
|
|
739
|
+
|
|
740
|
+
let localVarHttpContext: HttpContext | undefined = options && options.context;
|
|
741
|
+
if (localVarHttpContext === undefined) {
|
|
742
|
+
localVarHttpContext = new HttpContext();
|
|
564
743
|
}
|
|
565
|
-
|
|
566
|
-
|
|
744
|
+
|
|
745
|
+
let localVarTransferCache: boolean | undefined = options && options.transferCache;
|
|
746
|
+
if (localVarTransferCache === undefined) {
|
|
747
|
+
localVarTransferCache = true;
|
|
567
748
|
}
|
|
568
749
|
|
|
569
|
-
let responseType_: 'text' | 'json' = 'json';
|
|
570
|
-
if (
|
|
571
|
-
|
|
750
|
+
let responseType_: 'text' | 'json' | 'blob' = 'json';
|
|
751
|
+
if (localVarHttpHeaderAcceptSelected) {
|
|
752
|
+
if (localVarHttpHeaderAcceptSelected.startsWith('text')) {
|
|
753
|
+
responseType_ = 'text';
|
|
754
|
+
} else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) {
|
|
755
|
+
responseType_ = 'json';
|
|
756
|
+
} else {
|
|
757
|
+
responseType_ = 'blob';
|
|
758
|
+
}
|
|
572
759
|
}
|
|
573
760
|
|
|
574
|
-
|
|
761
|
+
let localVarPath = `/assets/${this.configuration.encodeParam({ name: 'id', value: id, in: 'path', style: 'simple', explode: false, dataType: 'string', dataFormat: undefined })}/versions/${this.configuration.encodeParam({ name: 'vNr', value: vNr, in: 'path', style: 'simple', explode: false, dataType: 'string', dataFormat: undefined })}`;
|
|
762
|
+
return this.httpClient.request<VersionedAsset>('post', `${this.configuration.basePath}${localVarPath}`, {
|
|
763
|
+
context: localVarHttpContext,
|
|
575
764
|
responseType: <any>responseType_,
|
|
576
765
|
withCredentials: this.configuration.withCredentials,
|
|
577
|
-
headers:
|
|
766
|
+
headers: localVarHeaders,
|
|
578
767
|
observe: observe,
|
|
768
|
+
transferCache: localVarTransferCache,
|
|
579
769
|
reportProgress: reportProgress
|
|
580
770
|
});
|
|
581
771
|
}
|
|
582
772
|
|
|
583
773
|
/**
|
|
584
774
|
* This endpoint lists all the versioned assets which are stored in the database if asset is still valid.
|
|
585
|
-
* @param
|
|
775
|
+
* @param requestParameters
|
|
586
776
|
* @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body.
|
|
587
777
|
* @param reportProgress flag to report request and response progress.
|
|
588
778
|
*/
|
|
589
|
-
public httpVersionedAssetsGet(
|
|
590
|
-
|
|
591
|
-
|
|
592
|
-
|
|
779
|
+
public httpVersionedAssetsGet(
|
|
780
|
+
requestParameters?: HttpVersionedAssetsGetRequestParams,
|
|
781
|
+
observe?: 'body',
|
|
782
|
+
reportProgress?: boolean,
|
|
783
|
+
options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext; transferCache?: boolean }
|
|
784
|
+
): Observable<VersionEntity>;
|
|
785
|
+
public httpVersionedAssetsGet(
|
|
786
|
+
requestParameters?: HttpVersionedAssetsGetRequestParams,
|
|
787
|
+
observe?: 'response',
|
|
788
|
+
reportProgress?: boolean,
|
|
789
|
+
options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext; transferCache?: boolean }
|
|
790
|
+
): Observable<HttpResponse<VersionEntity>>;
|
|
791
|
+
public httpVersionedAssetsGet(
|
|
792
|
+
requestParameters?: HttpVersionedAssetsGetRequestParams,
|
|
793
|
+
observe?: 'events',
|
|
794
|
+
reportProgress?: boolean,
|
|
795
|
+
options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext; transferCache?: boolean }
|
|
796
|
+
): Observable<HttpEvent<VersionEntity>>;
|
|
797
|
+
public httpVersionedAssetsGet(
|
|
798
|
+
requestParameters?: HttpVersionedAssetsGetRequestParams,
|
|
799
|
+
observe: any = 'body',
|
|
800
|
+
reportProgress: boolean = false,
|
|
801
|
+
options?: { httpHeaderAccept?: 'application/json'; context?: HttpContext; transferCache?: boolean }
|
|
802
|
+
): Observable<any> {
|
|
803
|
+
const id = requestParameters?.id;
|
|
593
804
|
if (id === null || id === undefined) {
|
|
594
805
|
throw new Error('Required parameter id was null or undefined when calling httpVersionedAssetsGet.');
|
|
595
806
|
}
|
|
596
807
|
|
|
597
|
-
let
|
|
808
|
+
let localVarHeaders = this.defaultHeaders;
|
|
598
809
|
|
|
599
|
-
let
|
|
810
|
+
let localVarCredential: string | undefined;
|
|
600
811
|
// authentication (function_key) required
|
|
601
|
-
|
|
602
|
-
if (
|
|
603
|
-
|
|
812
|
+
localVarCredential = this.configuration.lookupCredential('function_key');
|
|
813
|
+
if (localVarCredential) {
|
|
814
|
+
localVarHeaders = localVarHeaders.set('x-functions-key', localVarCredential);
|
|
604
815
|
}
|
|
605
816
|
|
|
606
|
-
let
|
|
607
|
-
if (
|
|
817
|
+
let localVarHttpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept;
|
|
818
|
+
if (localVarHttpHeaderAcceptSelected === undefined) {
|
|
608
819
|
// to determine the Accept header
|
|
609
820
|
const httpHeaderAccepts: string[] = ['application/json'];
|
|
610
|
-
|
|
821
|
+
localVarHttpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts);
|
|
611
822
|
}
|
|
612
|
-
if (
|
|
613
|
-
|
|
823
|
+
if (localVarHttpHeaderAcceptSelected !== undefined) {
|
|
824
|
+
localVarHeaders = localVarHeaders.set('Accept', localVarHttpHeaderAcceptSelected);
|
|
614
825
|
}
|
|
615
826
|
|
|
616
|
-
let
|
|
617
|
-
if (
|
|
618
|
-
|
|
827
|
+
let localVarHttpContext: HttpContext | undefined = options && options.context;
|
|
828
|
+
if (localVarHttpContext === undefined) {
|
|
829
|
+
localVarHttpContext = new HttpContext();
|
|
830
|
+
}
|
|
831
|
+
|
|
832
|
+
let localVarTransferCache: boolean | undefined = options && options.transferCache;
|
|
833
|
+
if (localVarTransferCache === undefined) {
|
|
834
|
+
localVarTransferCache = true;
|
|
835
|
+
}
|
|
836
|
+
|
|
837
|
+
let responseType_: 'text' | 'json' | 'blob' = 'json';
|
|
838
|
+
if (localVarHttpHeaderAcceptSelected) {
|
|
839
|
+
if (localVarHttpHeaderAcceptSelected.startsWith('text')) {
|
|
840
|
+
responseType_ = 'text';
|
|
841
|
+
} else if (this.configuration.isJsonMime(localVarHttpHeaderAcceptSelected)) {
|
|
842
|
+
responseType_ = 'json';
|
|
843
|
+
} else {
|
|
844
|
+
responseType_ = 'blob';
|
|
845
|
+
}
|
|
619
846
|
}
|
|
620
847
|
|
|
621
|
-
|
|
848
|
+
let localVarPath = `/assets/${this.configuration.encodeParam({ name: 'id', value: id, in: 'path', style: 'simple', explode: false, dataType: 'string', dataFormat: undefined })}/versions`;
|
|
849
|
+
return this.httpClient.request<VersionEntity>('get', `${this.configuration.basePath}${localVarPath}`, {
|
|
850
|
+
context: localVarHttpContext,
|
|
622
851
|
responseType: <any>responseType_,
|
|
623
852
|
withCredentials: this.configuration.withCredentials,
|
|
624
|
-
headers:
|
|
853
|
+
headers: localVarHeaders,
|
|
625
854
|
observe: observe,
|
|
855
|
+
transferCache: localVarTransferCache,
|
|
626
856
|
reportProgress: reportProgress
|
|
627
857
|
});
|
|
628
858
|
}
|