@agravity/private 5.3.0 → 5.3.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (117) hide show
  1. package/README.md +2 -2
  2. package/api/api.ts +101 -67
  3. package/api/assetIconRuleManagement.agravity.ts +434 -400
  4. package/api/assetManagement.agravity.ts +856 -737
  5. package/api/assetOperations.agravity.ts +1415 -1309
  6. package/api/assetPublishing.agravity.ts +549 -511
  7. package/api/assetVersioning.agravity.ts +707 -657
  8. package/api/authenticationManagement.agravity.ts +473 -502
  9. package/api/collectionManagement.agravity.ts +731 -618
  10. package/api/collectionSharing.agravity.ts +359 -329
  11. package/api/collectionTypeItemBlueprintManagement.agravity.ts +373 -340
  12. package/api/collectionTypeManagement.agravity.ts +609 -533
  13. package/api/configurationManagement.agravity.ts +316 -311
  14. package/api/downloadFormatManagement.agravity.ts +440 -400
  15. package/api/downloadZip.agravity.ts +149 -151
  16. package/api/generalManagement.agravity.ts +328 -348
  17. package/api/helperTools.agravity.ts +619 -682
  18. package/api/historyEntryManagement.agravity.ts +149 -139
  19. package/api/iccProfileManagement.agravity.ts +123 -134
  20. package/api/listBlobs.agravity.ts +168 -185
  21. package/api/listQueues.agravity.ts +123 -134
  22. package/api/permissionsManagement.agravity.ts +276 -262
  23. package/api/publishing.agravity.ts +160 -148
  24. package/api/quickshareManagement.agravity.ts +378 -385
  25. package/api/savedSearchManagement.agravity.ts +293 -271
  26. package/api/searchManagement.agravity.ts +365 -345
  27. package/api/secureUpload.agravity.ts +375 -371
  28. package/api/signalRConnectionManagement.agravity.ts +200 -218
  29. package/api/staticDefinedListManagement.agravity.ts +457 -408
  30. package/api/stockImport.agravity.ts +242 -221
  31. package/api/structureImport.agravity.ts +126 -137
  32. package/api/translationManagement.agravity.ts +490 -404
  33. package/api/webAppData.agravity.ts +274 -300
  34. package/api/wordpressManagement.agravity.ts +326 -282
  35. package/api/workspaceManagement.agravity.ts +543 -513
  36. package/api.module.ts +61 -63
  37. package/configuration.ts +125 -130
  38. package/encoder.ts +20 -20
  39. package/index.ts +5 -5
  40. package/model/agravityErrorResponse.agravity.ts +17 -19
  41. package/model/agravityInfoResponse.agravity.ts +17 -19
  42. package/model/agravityUser.agravity.ts +35 -37
  43. package/model/agravityVersion.agravity.ts +22 -24
  44. package/model/allWebAppData.agravity.ts +22 -24
  45. package/model/apiKeyResponse.agravity.ts +16 -18
  46. package/model/appConfigTableEntity.agravity.ts +23 -25
  47. package/model/artificialIntelligenceGroup.agravity.ts +18 -20
  48. package/model/asset.agravity.ts +45 -47
  49. package/model/assetAvailability.agravity.ts +17 -19
  50. package/model/assetBlob.agravity.ts +79 -82
  51. package/model/assetBulkUpdate.agravity.ts +18 -20
  52. package/model/assetCollectionLink.agravity.ts +16 -18
  53. package/model/assetIconRule.agravity.ts +33 -35
  54. package/model/assetIdFormat.agravity.ts +17 -19
  55. package/model/assetPageResult.agravity.ts +21 -23
  56. package/model/assetsOperationBody.agravity.ts +18 -20
  57. package/model/azSearchOptions.agravity.ts +23 -25
  58. package/model/azureIdentity.agravity.ts +27 -30
  59. package/model/blobInfoObj.agravity.ts +21 -23
  60. package/model/collTypeItem.agravity.ts +36 -38
  61. package/model/collTypeItemBlueprint.agravity.ts +29 -31
  62. package/model/collection.agravity.ts +33 -35
  63. package/model/collectionType.agravity.ts +33 -35
  64. package/model/collectionUDL.agravity.ts +19 -21
  65. package/model/createSftpUserResult.agravity.ts +16 -18
  66. package/model/dataResult.agravity.ts +20 -22
  67. package/model/distZipResponse.agravity.ts +17 -19
  68. package/model/downloadFormat.agravity.ts +32 -34
  69. package/model/downloadObject.agravity.ts +30 -32
  70. package/model/downloadZipRequest.agravity.ts +23 -25
  71. package/model/dynamicImageOperation.agravity.ts +16 -18
  72. package/model/emailAddress.agravity.ts +16 -18
  73. package/model/entityId.agravity.ts +15 -17
  74. package/model/entityIdName.agravity.ts +17 -19
  75. package/model/entityTranslations.agravity.ts +16 -18
  76. package/model/frontendAppConfig.agravity.ts +19 -21
  77. package/model/groupAllAppData.agravity.ts +24 -26
  78. package/model/historyEntry.agravity.ts +40 -43
  79. package/model/infoEntitySkillEnhanced.agravity.ts +23 -25
  80. package/model/metadata.agravity.ts +17 -19
  81. package/model/models.ts +73 -73
  82. package/model/moveCollectionBody.agravity.ts +17 -19
  83. package/model/permissionChange.agravity.ts +26 -29
  84. package/model/permissionSetting.agravity.ts +25 -27
  85. package/model/publishEntity.agravity.ts +26 -28
  86. package/model/publishedAsset.agravity.ts +23 -25
  87. package/model/quickShare.agravity.ts +30 -32
  88. package/model/quickShareFull.agravity.ts +35 -37
  89. package/model/sasToken.agravity.ts +20 -22
  90. package/model/savedSearch.agravity.ts +29 -31
  91. package/model/searchAdminDataSourceStatus.agravity.ts +16 -18
  92. package/model/searchAdminIndexStatus.agravity.ts +18 -20
  93. package/model/searchAdminIndexerLastRun.agravity.ts +19 -21
  94. package/model/searchAdminIndexerStatus.agravity.ts +18 -20
  95. package/model/searchAdminSkillStatus.agravity.ts +16 -18
  96. package/model/searchAdminStatistics.agravity.ts +16 -18
  97. package/model/searchAdminStatus.agravity.ts +22 -24
  98. package/model/searchFacet.agravity.ts +17 -19
  99. package/model/searchFacetEntity.agravity.ts +17 -19
  100. package/model/searchResult.agravity.ts +21 -23
  101. package/model/searchableItem.agravity.ts +24 -26
  102. package/model/secureUploadEntity.agravity.ts +25 -27
  103. package/model/sharedAsset.agravity.ts +23 -25
  104. package/model/sharedCollection.agravity.ts +22 -24
  105. package/model/sharedCollectionFull.agravity.ts +27 -29
  106. package/model/signalRConnectionInfo.agravity.ts +16 -18
  107. package/model/simpleAsset.agravity.ts +24 -26
  108. package/model/staticDefinedList.agravity.ts +28 -30
  109. package/model/uiTutorials.agravity.ts +23 -26
  110. package/model/versionEntity.agravity.ts +26 -28
  111. package/model/versionedAsset.agravity.ts +18 -20
  112. package/model/whereParam.agravity.ts +40 -43
  113. package/model/workspace.agravity.ts +32 -34
  114. package/ng-package.json +6 -6
  115. package/package.json +45 -45
  116. package/tsconfig.json +20 -28
  117. package/variables.ts +9 -9
@@ -1,311 +1,316 @@
1
- /**
2
- * Agravity OpenAPI Documentation - Private Functions
3
- * <h1>Agravity API Reference</h1>This is the full 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>Assets versioning</li> <li>Sharing collection</li> <li>Secure upload to collection</li> <li>Download ZIP</li> <li>Search</li> <li>General management</li> <li>Authentication management</li> <li>Blob management</li> <li>Queue management</li> <li>Structure management</li> <li>Bulk get all data from collection / collection type</li></ul><h2> Operations</h2>Agravity API performs the following operations:<ul> <li>Create / update / list / delete collection types</li> <li>Create / update / list / delete collections</li> <li>Create / update / list / delete assets</li> <li>Operations on assets like: move to collection, renew asset(through queue pipe), rotate, resize, etc.</li> <li>Publish / de-publish an asset or specific variants of an asset</li> <li>Create / delete version of asset</li> <li>Bulk download of Assets</li> <li>Search for assets or collections</li> <li>Authenticated access like e.g. getting access to blobs directly (for upload on folder or generate SAS token)</li> <li>List / delete blobs</li> <li>Create structures based on blob storage input</li></ul><br/>Copyright © Agravity GmbH 2023. All Rights Reserved
4
- *
5
- * The version of the OpenAPI document: 5.3.0
6
- * Contact: office@agravity.io
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
- /* tslint:disable:no-unused-variable member-ordering */
13
-
14
- import { Inject, Injectable, Optional } from '@angular/core';
15
- import { HttpClient, HttpHeaders, HttpParams,
16
- HttpResponse, HttpEvent, HttpParameterCodec } from '@angular/common/http';
17
- import { CustomHttpParameterCodec } from '../encoder';
18
- import { Observable } from 'rxjs';
19
-
20
- import { AppConfigTableEntity } from '../model/models';
21
- import { FrontendAppConfig } from '../model/models';
22
-
23
- import { BASE_PATH, COLLECTION_FORMATS } from '../variables';
24
- import { AgravityConfiguration } from '../configuration';
25
-
26
-
27
-
28
- @Injectable({
29
- providedIn: 'root'
30
- })
31
- export class ConfigurationManagementService {
32
-
33
- protected basePath = 'http://localhost:7071/api';
34
- public defaultHeaders = new HttpHeaders();
35
- public configuration = new AgravityConfiguration();
36
- public encoder: HttpParameterCodec;
37
-
38
- constructor(protected httpClient: HttpClient, @Optional()@Inject(BASE_PATH) basePath: string, @Optional() configuration: AgravityConfiguration) {
39
- if (configuration) {
40
- this.configuration = configuration;
41
- }
42
- if (typeof this.configuration.basePath !== 'string') {
43
- if (typeof basePath !== 'string') {
44
- basePath = this.basePath;
45
- }
46
- this.configuration.basePath = basePath;
47
- }
48
- this.encoder = this.configuration.encoder || new CustomHttpParameterCodec();
49
- }
50
-
51
-
52
- private addToHttpParams(httpParams: HttpParams, value: any, key?: string): HttpParams {
53
- if (typeof value === "object" && value instanceof Date === false) {
54
- httpParams = this.addToHttpParamsRecursive(httpParams, value);
55
- } else {
56
- httpParams = this.addToHttpParamsRecursive(httpParams, value, key);
57
- }
58
- return httpParams;
59
- }
60
-
61
- private addToHttpParamsRecursive(httpParams: HttpParams, value?: any, key?: string): HttpParams {
62
- if (value == null) {
63
- return httpParams;
64
- }
65
-
66
- if (typeof value === "object") {
67
- if (Array.isArray(value)) {
68
- (value as any[]).forEach( elem => httpParams = this.addToHttpParamsRecursive(httpParams, elem, key));
69
- } else if (value instanceof Date) {
70
- if (key != null) {
71
- httpParams = httpParams.append(key,
72
- (value as Date).toISOString().substr(0, 10));
73
- } else {
74
- throw Error("key may not be null if value is Date");
75
- }
76
- } else {
77
- Object.keys(value).forEach( k => httpParams = this.addToHttpParamsRecursive(
78
- httpParams, value[k], key != null ? `${key}.${k}` : k));
79
- }
80
- } else if (key != null) {
81
- httpParams = httpParams.append(key, value);
82
- } else {
83
- throw Error("key may not be null if value is not object or array");
84
- }
85
- return httpParams;
86
- }
87
-
88
- /**
89
- * Lists all config values stored in config table
90
- * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body.
91
- * @param reportProgress flag to report request and response progress.
92
- */
93
- public httpConfigGetAll(observe?: 'body', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json'}): Observable<Array<AppConfigTableEntity>>;
94
- public httpConfigGetAll(observe?: 'response', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json'}): Observable<HttpResponse<Array<AppConfigTableEntity>>>;
95
- public httpConfigGetAll(observe?: 'events', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json'}): Observable<HttpEvent<Array<AppConfigTableEntity>>>;
96
- public httpConfigGetAll(observe: any = 'body', reportProgress: boolean = false, options?: {httpHeaderAccept?: 'application/json'}): Observable<any> {
97
-
98
- let headers = this.defaultHeaders;
99
-
100
- let credential: string | undefined;
101
- // authentication (msal_auth) required
102
- credential = this.configuration.lookupCredential('msal_auth');
103
- if (credential) {
104
- headers = headers.set('Authorization', 'Bearer ' + credential);
105
- }
106
-
107
- let httpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept;
108
- if (httpHeaderAcceptSelected === undefined) {
109
- // to determine the Accept header
110
- const httpHeaderAccepts: string[] = [
111
- 'application/json'
112
- ];
113
- httpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts);
114
- }
115
- if (httpHeaderAcceptSelected !== undefined) {
116
- headers = headers.set('Accept', httpHeaderAcceptSelected);
117
- }
118
-
119
-
120
- let responseType_: 'text' | 'json' = 'json';
121
- if(httpHeaderAcceptSelected && httpHeaderAcceptSelected.startsWith('text')) {
122
- responseType_ = 'text';
123
- }
124
-
125
- return this.httpClient.get<Array<AppConfigTableEntity>>(`${this.configuration.basePath}/config`,
126
- {
127
- responseType: <any>responseType_,
128
- withCredentials: this.configuration.withCredentials,
129
- headers: headers,
130
- observe: observe,
131
- reportProgress: reportProgress
132
- }
133
- );
134
- }
135
-
136
- /**
137
- * Lists config value only for frontend stored in config table
138
- * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body.
139
- * @param reportProgress flag to report request and response progress.
140
- */
141
- public httpConfigGetFrontendAll(observe?: 'body', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json'}): Observable<Array<FrontendAppConfig>>;
142
- public httpConfigGetFrontendAll(observe?: 'response', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json'}): Observable<HttpResponse<Array<FrontendAppConfig>>>;
143
- public httpConfigGetFrontendAll(observe?: 'events', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json'}): Observable<HttpEvent<Array<FrontendAppConfig>>>;
144
- public httpConfigGetFrontendAll(observe: any = 'body', reportProgress: boolean = false, options?: {httpHeaderAccept?: 'application/json'}): Observable<any> {
145
-
146
- let headers = this.defaultHeaders;
147
-
148
- let credential: string | undefined;
149
- // authentication (msal_auth) required
150
- credential = this.configuration.lookupCredential('msal_auth');
151
- if (credential) {
152
- headers = headers.set('Authorization', 'Bearer ' + credential);
153
- }
154
-
155
- let httpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept;
156
- if (httpHeaderAcceptSelected === undefined) {
157
- // to determine the Accept header
158
- const httpHeaderAccepts: string[] = [
159
- 'application/json'
160
- ];
161
- httpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts);
162
- }
163
- if (httpHeaderAcceptSelected !== undefined) {
164
- headers = headers.set('Accept', httpHeaderAcceptSelected);
165
- }
166
-
167
-
168
- let responseType_: 'text' | 'json' = 'json';
169
- if(httpHeaderAcceptSelected && httpHeaderAcceptSelected.startsWith('text')) {
170
- responseType_ = 'text';
171
- }
172
-
173
- return this.httpClient.get<Array<FrontendAppConfig>>(`${this.configuration.basePath}/config/frontend`,
174
- {
175
- responseType: <any>responseType_,
176
- withCredentials: this.configuration.withCredentials,
177
- headers: headers,
178
- observe: observe,
179
- reportProgress: reportProgress
180
- }
181
- );
182
- }
183
-
184
- /**
185
- * This initializes all configurations and write them into appconfig table.
186
- * @param key The key of the configuration.
187
- * @param addconfigqueues Comma separated queue-names (have to start with \&#39;setup-\&#39;).
188
- * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body.
189
- * @param reportProgress flag to report request and response progress.
190
- */
191
- public httpConfigUpdate(key: string, addconfigqueues?: string, observe?: 'body', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json'}): Observable<AppConfigTableEntity>;
192
- public httpConfigUpdate(key: string, addconfigqueues?: string, observe?: 'response', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json'}): Observable<HttpResponse<AppConfigTableEntity>>;
193
- public httpConfigUpdate(key: string, addconfigqueues?: string, observe?: 'events', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json'}): Observable<HttpEvent<AppConfigTableEntity>>;
194
- public httpConfigUpdate(key: string, addconfigqueues?: string, observe: any = 'body', reportProgress: boolean = false, options?: {httpHeaderAccept?: 'application/json'}): Observable<any> {
195
- if (key === null || key === undefined) {
196
- throw new Error('Required parameter key was null or undefined when calling httpConfigUpdate.');
197
- }
198
-
199
- let queryParameters = new HttpParams({encoder: this.encoder});
200
- if (addconfigqueues !== undefined && addconfigqueues !== null) {
201
- queryParameters = this.addToHttpParams(queryParameters,
202
- <any>addconfigqueues, 'addconfigqueues');
203
- }
204
-
205
- let headers = this.defaultHeaders;
206
-
207
- let credential: string | undefined;
208
- // authentication (msal_auth) required
209
- credential = this.configuration.lookupCredential('msal_auth');
210
- if (credential) {
211
- headers = headers.set('Authorization', 'Bearer ' + credential);
212
- }
213
-
214
- let httpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept;
215
- if (httpHeaderAcceptSelected === undefined) {
216
- // to determine the Accept header
217
- const httpHeaderAccepts: string[] = [
218
- 'application/json'
219
- ];
220
- httpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts);
221
- }
222
- if (httpHeaderAcceptSelected !== undefined) {
223
- headers = headers.set('Accept', httpHeaderAcceptSelected);
224
- }
225
-
226
-
227
- let responseType_: 'text' | 'json' = 'json';
228
- if(httpHeaderAcceptSelected && httpHeaderAcceptSelected.startsWith('text')) {
229
- responseType_ = 'text';
230
- }
231
-
232
- return this.httpClient.post<AppConfigTableEntity>(`${this.configuration.basePath}/config`,
233
- null,
234
- {
235
- params: queryParameters,
236
- responseType: <any>responseType_,
237
- withCredentials: this.configuration.withCredentials,
238
- headers: headers,
239
- observe: observe,
240
- reportProgress: reportProgress
241
- }
242
- );
243
- }
244
-
245
- /**
246
- * Update an existing config value with the given key. (Only value, content-type and description)
247
- * @param key The key of the configuration.
248
- * @param appConfigTableEntity The body has just to contain: value, content_type and/or description
249
- * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body.
250
- * @param reportProgress flag to report request and response progress.
251
- */
252
- public httpConfigUpdateSingle(key: string, appConfigTableEntity: AppConfigTableEntity, observe?: 'body', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json'}): Observable<AppConfigTableEntity>;
253
- public httpConfigUpdateSingle(key: string, appConfigTableEntity: AppConfigTableEntity, observe?: 'response', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json'}): Observable<HttpResponse<AppConfigTableEntity>>;
254
- public httpConfigUpdateSingle(key: string, appConfigTableEntity: AppConfigTableEntity, observe?: 'events', reportProgress?: boolean, options?: {httpHeaderAccept?: 'application/json'}): Observable<HttpEvent<AppConfigTableEntity>>;
255
- public httpConfigUpdateSingle(key: string, appConfigTableEntity: AppConfigTableEntity, observe: any = 'body', reportProgress: boolean = false, options?: {httpHeaderAccept?: 'application/json'}): Observable<any> {
256
- if (key === null || key === undefined) {
257
- throw new Error('Required parameter key was null or undefined when calling httpConfigUpdateSingle.');
258
- }
259
- if (appConfigTableEntity === null || appConfigTableEntity === undefined) {
260
- throw new Error('Required parameter appConfigTableEntity was null or undefined when calling httpConfigUpdateSingle.');
261
- }
262
-
263
- let headers = this.defaultHeaders;
264
-
265
- let credential: string | undefined;
266
- // authentication (msal_auth) required
267
- credential = this.configuration.lookupCredential('msal_auth');
268
- if (credential) {
269
- headers = headers.set('Authorization', 'Bearer ' + credential);
270
- }
271
-
272
- let httpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept;
273
- if (httpHeaderAcceptSelected === undefined) {
274
- // to determine the Accept header
275
- const httpHeaderAccepts: string[] = [
276
- 'application/json'
277
- ];
278
- httpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts);
279
- }
280
- if (httpHeaderAcceptSelected !== undefined) {
281
- headers = headers.set('Accept', httpHeaderAcceptSelected);
282
- }
283
-
284
-
285
- // to determine the Content-Type header
286
- const consumes: string[] = [
287
- 'application/json'
288
- ];
289
- const httpContentTypeSelected: string | undefined = this.configuration.selectHeaderContentType(consumes);
290
- if (httpContentTypeSelected !== undefined) {
291
- headers = headers.set('Content-Type', httpContentTypeSelected);
292
- }
293
-
294
- let responseType_: 'text' | 'json' = 'json';
295
- if(httpHeaderAcceptSelected && httpHeaderAcceptSelected.startsWith('text')) {
296
- responseType_ = 'text';
297
- }
298
-
299
- return this.httpClient.post<AppConfigTableEntity>(`${this.configuration.basePath}/config/${encodeURIComponent(String(key))}`,
300
- appConfigTableEntity,
301
- {
302
- responseType: <any>responseType_,
303
- withCredentials: this.configuration.withCredentials,
304
- headers: headers,
305
- observe: observe,
306
- reportProgress: reportProgress
307
- }
308
- );
309
- }
310
-
311
- }
1
+ /**
2
+ * Agravity OpenAPI Documentation - Private Functions
3
+ * <h1>Agravity API Reference</h1>This is the full 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>Assets versioning</li> <li>Sharing collection</li> <li>Secure upload to collection</li> <li>Download ZIP</li> <li>Search</li> <li>General management</li> <li>Authentication management</li> <li>Blob management</li> <li>Queue management</li> <li>Structure management</li> <li>Bulk get all data from collection / collection type</li></ul><h2> Operations</h2>Agravity API performs the following operations:<ul> <li>Create / update / list / delete collection types</li> <li>Create / update / list / delete collections</li> <li>Create / update / list / delete assets</li> <li>Operations on assets like: move to collection, renew asset(through queue pipe), rotate, resize, etc.</li> <li>Publish / de-publish an asset or specific variants of an asset</li> <li>Create / delete version of asset</li> <li>Bulk download of Assets</li> <li>Search for assets or collections</li> <li>Authenticated access like e.g. getting access to blobs directly (for upload on folder or generate SAS token)</li> <li>List / delete blobs</li> <li>Create structures based on blob storage input</li></ul><br/>Copyright © Agravity GmbH 2023. All Rights Reserved
4
+ *
5
+ * The version of the OpenAPI document: 5.3.2
6
+ * Contact: office@agravity.io
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
+ /* tslint:disable:no-unused-variable member-ordering */
13
+
14
+ import { Inject, Injectable, Optional } from '@angular/core';
15
+ import { HttpClient, HttpHeaders, HttpParams, HttpResponse, HttpEvent, HttpParameterCodec } from '@angular/common/http';
16
+ import { CustomHttpParameterCodec } from '../encoder';
17
+ import { Observable } from 'rxjs';
18
+
19
+ import { AppConfigTableEntity } from '../model/models';
20
+ import { FrontendAppConfig } from '../model/models';
21
+
22
+ import { BASE_PATH, COLLECTION_FORMATS } from '../variables';
23
+ import { AgravityConfiguration } from '../configuration';
24
+
25
+ @Injectable({
26
+ providedIn: 'root'
27
+ })
28
+ export class ConfigurationManagementService {
29
+ protected basePath = 'http://localhost:7071/api';
30
+ public defaultHeaders = new HttpHeaders();
31
+ public configuration = new AgravityConfiguration();
32
+ public encoder: HttpParameterCodec;
33
+
34
+ constructor(
35
+ protected httpClient: HttpClient,
36
+ @Optional() @Inject(BASE_PATH) basePath: string,
37
+ @Optional() configuration: AgravityConfiguration
38
+ ) {
39
+ if (configuration) {
40
+ this.configuration = configuration;
41
+ }
42
+ if (typeof this.configuration.basePath !== 'string') {
43
+ if (typeof basePath !== 'string') {
44
+ basePath = this.basePath;
45
+ }
46
+ this.configuration.basePath = basePath;
47
+ }
48
+ this.encoder = this.configuration.encoder || new CustomHttpParameterCodec();
49
+ }
50
+
51
+ private addToHttpParams(httpParams: HttpParams, value: any, key?: string): HttpParams {
52
+ if (typeof value === 'object' && value instanceof Date === false) {
53
+ httpParams = this.addToHttpParamsRecursive(httpParams, value);
54
+ } else {
55
+ httpParams = this.addToHttpParamsRecursive(httpParams, value, key);
56
+ }
57
+ return httpParams;
58
+ }
59
+
60
+ private addToHttpParamsRecursive(httpParams: HttpParams, value?: any, key?: string): HttpParams {
61
+ if (value == null) {
62
+ return httpParams;
63
+ }
64
+
65
+ if (typeof value === 'object') {
66
+ if (Array.isArray(value)) {
67
+ (value as any[]).forEach((elem) => (httpParams = this.addToHttpParamsRecursive(httpParams, elem, key)));
68
+ } else if (value instanceof Date) {
69
+ if (key != null) {
70
+ httpParams = httpParams.append(key, (value as Date).toISOString().substr(0, 10));
71
+ } else {
72
+ throw Error('key may not be null if value is Date');
73
+ }
74
+ } else {
75
+ Object.keys(value).forEach((k) => (httpParams = this.addToHttpParamsRecursive(httpParams, value[k], key != null ? `${key}.${k}` : k)));
76
+ }
77
+ } else if (key != null) {
78
+ httpParams = httpParams.append(key, value);
79
+ } else {
80
+ throw Error('key may not be null if value is not object or array');
81
+ }
82
+ return httpParams;
83
+ }
84
+
85
+ /**
86
+ * Lists all config values stored in config table
87
+ * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body.
88
+ * @param reportProgress flag to report request and response progress.
89
+ */
90
+ public httpConfigGetAll(observe?: 'body', reportProgress?: boolean, options?: { httpHeaderAccept?: 'application/json' }): Observable<Array<AppConfigTableEntity>>;
91
+ public httpConfigGetAll(observe?: 'response', reportProgress?: boolean, options?: { httpHeaderAccept?: 'application/json' }): Observable<HttpResponse<Array<AppConfigTableEntity>>>;
92
+ public httpConfigGetAll(observe?: 'events', reportProgress?: boolean, options?: { httpHeaderAccept?: 'application/json' }): Observable<HttpEvent<Array<AppConfigTableEntity>>>;
93
+ public httpConfigGetAll(observe: any = 'body', reportProgress: boolean = false, options?: { httpHeaderAccept?: 'application/json' }): Observable<any> {
94
+ let headers = this.defaultHeaders;
95
+
96
+ let credential: string | undefined;
97
+ // authentication (msal_auth) required
98
+ credential = this.configuration.lookupCredential('msal_auth');
99
+ if (credential) {
100
+ headers = headers.set('Authorization', 'Bearer ' + credential);
101
+ }
102
+
103
+ let httpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept;
104
+ if (httpHeaderAcceptSelected === undefined) {
105
+ // to determine the Accept header
106
+ const httpHeaderAccepts: string[] = ['application/json'];
107
+ httpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts);
108
+ }
109
+ if (httpHeaderAcceptSelected !== undefined) {
110
+ headers = headers.set('Accept', httpHeaderAcceptSelected);
111
+ }
112
+
113
+ let responseType_: 'text' | 'json' = 'json';
114
+ if (httpHeaderAcceptSelected && httpHeaderAcceptSelected.startsWith('text')) {
115
+ responseType_ = 'text';
116
+ }
117
+
118
+ return this.httpClient.get<Array<AppConfigTableEntity>>(`${this.configuration.basePath}/config`, {
119
+ responseType: <any>responseType_,
120
+ withCredentials: this.configuration.withCredentials,
121
+ headers: headers,
122
+ observe: observe,
123
+ reportProgress: reportProgress
124
+ });
125
+ }
126
+
127
+ /**
128
+ * Lists config value only for frontend stored in config table
129
+ * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body.
130
+ * @param reportProgress flag to report request and response progress.
131
+ */
132
+ public httpConfigGetFrontendAll(observe?: 'body', reportProgress?: boolean, options?: { httpHeaderAccept?: 'application/json' }): Observable<Array<FrontendAppConfig>>;
133
+ public httpConfigGetFrontendAll(observe?: 'response', reportProgress?: boolean, options?: { httpHeaderAccept?: 'application/json' }): Observable<HttpResponse<Array<FrontendAppConfig>>>;
134
+ public httpConfigGetFrontendAll(observe?: 'events', reportProgress?: boolean, options?: { httpHeaderAccept?: 'application/json' }): Observable<HttpEvent<Array<FrontendAppConfig>>>;
135
+ public httpConfigGetFrontendAll(observe: any = 'body', reportProgress: boolean = false, options?: { httpHeaderAccept?: 'application/json' }): Observable<any> {
136
+ let headers = this.defaultHeaders;
137
+
138
+ let credential: string | undefined;
139
+ // authentication (msal_auth) required
140
+ credential = this.configuration.lookupCredential('msal_auth');
141
+ if (credential) {
142
+ headers = headers.set('Authorization', 'Bearer ' + credential);
143
+ }
144
+
145
+ let httpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept;
146
+ if (httpHeaderAcceptSelected === undefined) {
147
+ // to determine the Accept header
148
+ const httpHeaderAccepts: string[] = ['application/json'];
149
+ httpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts);
150
+ }
151
+ if (httpHeaderAcceptSelected !== undefined) {
152
+ headers = headers.set('Accept', httpHeaderAcceptSelected);
153
+ }
154
+
155
+ let responseType_: 'text' | 'json' = 'json';
156
+ if (httpHeaderAcceptSelected && httpHeaderAcceptSelected.startsWith('text')) {
157
+ responseType_ = 'text';
158
+ }
159
+
160
+ return this.httpClient.get<Array<FrontendAppConfig>>(`${this.configuration.basePath}/config/frontend`, {
161
+ responseType: <any>responseType_,
162
+ withCredentials: this.configuration.withCredentials,
163
+ headers: headers,
164
+ observe: observe,
165
+ reportProgress: reportProgress
166
+ });
167
+ }
168
+
169
+ /**
170
+ * This initializes all configurations and write them into appconfig table.
171
+ * @param key The key of the configuration.
172
+ * @param addconfigqueues Comma separated queue-names (have to start with \&#39;setup-\&#39;).
173
+ * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body.
174
+ * @param reportProgress flag to report request and response progress.
175
+ */
176
+ public httpConfigUpdate(key: string, addconfigqueues?: string, observe?: 'body', reportProgress?: boolean, options?: { httpHeaderAccept?: 'application/json' }): Observable<AppConfigTableEntity>;
177
+ public httpConfigUpdate(
178
+ key: string,
179
+ addconfigqueues?: string,
180
+ observe?: 'response',
181
+ reportProgress?: boolean,
182
+ options?: { httpHeaderAccept?: 'application/json' }
183
+ ): Observable<HttpResponse<AppConfigTableEntity>>;
184
+ public httpConfigUpdate(
185
+ key: string,
186
+ addconfigqueues?: string,
187
+ observe?: 'events',
188
+ reportProgress?: boolean,
189
+ options?: { httpHeaderAccept?: 'application/json' }
190
+ ): Observable<HttpEvent<AppConfigTableEntity>>;
191
+ public httpConfigUpdate(key: string, addconfigqueues?: string, observe: any = 'body', reportProgress: boolean = false, options?: { httpHeaderAccept?: 'application/json' }): Observable<any> {
192
+ if (key === null || key === undefined) {
193
+ throw new Error('Required parameter key was null or undefined when calling httpConfigUpdate.');
194
+ }
195
+
196
+ let queryParameters = new HttpParams({ encoder: this.encoder });
197
+ if (addconfigqueues !== undefined && addconfigqueues !== null) {
198
+ queryParameters = this.addToHttpParams(queryParameters, <any>addconfigqueues, 'addconfigqueues');
199
+ }
200
+
201
+ let headers = this.defaultHeaders;
202
+
203
+ let credential: string | undefined;
204
+ // authentication (msal_auth) required
205
+ credential = this.configuration.lookupCredential('msal_auth');
206
+ if (credential) {
207
+ headers = headers.set('Authorization', 'Bearer ' + credential);
208
+ }
209
+
210
+ let httpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept;
211
+ if (httpHeaderAcceptSelected === undefined) {
212
+ // to determine the Accept header
213
+ const httpHeaderAccepts: string[] = ['application/json'];
214
+ httpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts);
215
+ }
216
+ if (httpHeaderAcceptSelected !== undefined) {
217
+ headers = headers.set('Accept', httpHeaderAcceptSelected);
218
+ }
219
+
220
+ let responseType_: 'text' | 'json' = 'json';
221
+ if (httpHeaderAcceptSelected && httpHeaderAcceptSelected.startsWith('text')) {
222
+ responseType_ = 'text';
223
+ }
224
+
225
+ return this.httpClient.post<AppConfigTableEntity>(`${this.configuration.basePath}/config`, null, {
226
+ params: queryParameters,
227
+ responseType: <any>responseType_,
228
+ withCredentials: this.configuration.withCredentials,
229
+ headers: headers,
230
+ observe: observe,
231
+ reportProgress: reportProgress
232
+ });
233
+ }
234
+
235
+ /**
236
+ * Update an existing config value with the given key. (Only value, content-type and description)
237
+ * @param key The key of the configuration.
238
+ * @param appConfigTableEntity The body has just to contain: value, content_type and/or description
239
+ * @param observe set whether or not to return the data Observable as the body, response or events. defaults to returning the body.
240
+ * @param reportProgress flag to report request and response progress.
241
+ */
242
+ public httpConfigUpdateSingle(
243
+ key: string,
244
+ appConfigTableEntity: AppConfigTableEntity,
245
+ observe?: 'body',
246
+ reportProgress?: boolean,
247
+ options?: { httpHeaderAccept?: 'application/json' }
248
+ ): Observable<AppConfigTableEntity>;
249
+ public httpConfigUpdateSingle(
250
+ key: string,
251
+ appConfigTableEntity: AppConfigTableEntity,
252
+ observe?: 'response',
253
+ reportProgress?: boolean,
254
+ options?: { httpHeaderAccept?: 'application/json' }
255
+ ): Observable<HttpResponse<AppConfigTableEntity>>;
256
+ public httpConfigUpdateSingle(
257
+ key: string,
258
+ appConfigTableEntity: AppConfigTableEntity,
259
+ observe?: 'events',
260
+ reportProgress?: boolean,
261
+ options?: { httpHeaderAccept?: 'application/json' }
262
+ ): Observable<HttpEvent<AppConfigTableEntity>>;
263
+ public httpConfigUpdateSingle(
264
+ key: string,
265
+ appConfigTableEntity: AppConfigTableEntity,
266
+ observe: any = 'body',
267
+ reportProgress: boolean = false,
268
+ options?: { httpHeaderAccept?: 'application/json' }
269
+ ): Observable<any> {
270
+ if (key === null || key === undefined) {
271
+ throw new Error('Required parameter key was null or undefined when calling httpConfigUpdateSingle.');
272
+ }
273
+ if (appConfigTableEntity === null || appConfigTableEntity === undefined) {
274
+ throw new Error('Required parameter appConfigTableEntity was null or undefined when calling httpConfigUpdateSingle.');
275
+ }
276
+
277
+ let headers = this.defaultHeaders;
278
+
279
+ let credential: string | undefined;
280
+ // authentication (msal_auth) required
281
+ credential = this.configuration.lookupCredential('msal_auth');
282
+ if (credential) {
283
+ headers = headers.set('Authorization', 'Bearer ' + credential);
284
+ }
285
+
286
+ let httpHeaderAcceptSelected: string | undefined = options && options.httpHeaderAccept;
287
+ if (httpHeaderAcceptSelected === undefined) {
288
+ // to determine the Accept header
289
+ const httpHeaderAccepts: string[] = ['application/json'];
290
+ httpHeaderAcceptSelected = this.configuration.selectHeaderAccept(httpHeaderAccepts);
291
+ }
292
+ if (httpHeaderAcceptSelected !== undefined) {
293
+ headers = headers.set('Accept', httpHeaderAcceptSelected);
294
+ }
295
+
296
+ // to determine the Content-Type header
297
+ const consumes: string[] = ['application/json'];
298
+ const httpContentTypeSelected: string | undefined = this.configuration.selectHeaderContentType(consumes);
299
+ if (httpContentTypeSelected !== undefined) {
300
+ headers = headers.set('Content-Type', httpContentTypeSelected);
301
+ }
302
+
303
+ let responseType_: 'text' | 'json' = 'json';
304
+ if (httpHeaderAcceptSelected && httpHeaderAcceptSelected.startsWith('text')) {
305
+ responseType_ = 'text';
306
+ }
307
+
308
+ return this.httpClient.post<AppConfigTableEntity>(`${this.configuration.basePath}/config/${encodeURIComponent(String(key))}`, appConfigTableEntity, {
309
+ responseType: <any>responseType_,
310
+ withCredentials: this.configuration.withCredentials,
311
+ headers: headers,
312
+ observe: observe,
313
+ reportProgress: reportProgress
314
+ });
315
+ }
316
+ }