swoop-common 2.1.50 → 2.1.52
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/dist/api/additions/templateHierarchyResolver.js +52 -49
- package/dist/api/generated/core/core/OpenAPI.js +2 -2
- package/dist/api/generated/core/index.d.ts +2 -0
- package/dist/api/generated/core/index.js +2 -0
- package/dist/api/generated/core/models/DTOSnapshotCreate.d.ts +1 -0
- package/dist/api/generated/core/models/DTOSnapshotEntity.d.ts +1 -0
- package/dist/api/generated/core/models/DTOSnapshotRead.d.ts +1 -0
- package/dist/api/generated/core/services/ComponentService.d.ts +73 -0
- package/dist/api/generated/core/services/ComponentService.js +171 -0
- package/dist/api/generated/core/services/CoreService.d.ts +48 -36
- package/dist/api/generated/core/services/CoreService.js +131 -32
- package/dist/api/generated/core/services/TemplateService.d.ts +53 -0
- package/dist/api/generated/core/services/TemplateService.js +121 -0
- package/dist/api/generated/itinerary/index.d.ts +3 -0
- package/dist/api/generated/itinerary/index.js +3 -0
- package/dist/api/generated/itinerary/models/DTOSnapshotCreate.d.ts +1 -0
- package/dist/api/generated/itinerary/models/DTOSnapshotEntity.d.ts +1 -0
- package/dist/api/generated/itinerary/models/DTOSnapshotRead.d.ts +1 -0
- package/dist/api/generated/itinerary/services/AuditService.d.ts +12 -0
- package/dist/api/generated/itinerary/services/AuditService.js +28 -0
- package/dist/api/generated/itinerary/services/ItineraryService.d.ts +2 -1
- package/dist/api/generated/itinerary/services/ItineraryService.js +3 -1
- package/dist/api/generated/itinerary/services/RegionService.d.ts +27 -0
- package/dist/api/generated/itinerary/services/RegionService.js +51 -0
- package/dist/api/generated/itinerary/services/SnapshotService.d.ts +52 -0
- package/dist/api/generated/itinerary/services/SnapshotService.js +119 -0
- package/dist/rendering/components/ComponentPicker.js +1 -1
- package/dist/rendering/renderers/TemplatePicker.js +15 -15
- package/package.json +1 -1
|
@@ -14,25 +14,35 @@ import { resolveTemplateHierarchy } from '../../../additions/templateHierarchyRe
|
|
|
14
14
|
export class CoreService {
|
|
15
15
|
/**
|
|
16
16
|
* List Templates
|
|
17
|
-
* List all templates
|
|
17
|
+
* List all available templates
|
|
18
18
|
* @param page Pagination, starting at page 1
|
|
19
|
-
* @
|
|
19
|
+
* @param limit Number of items per page
|
|
20
|
+
* @param sort List of fields to sort by
|
|
21
|
+
* @returns any The list of all templates given the parameters used
|
|
20
22
|
* @throws ApiError
|
|
21
23
|
*/
|
|
22
|
-
templateList(page) {
|
|
24
|
+
templateList(page, limit, sort) {
|
|
23
25
|
return __request(OpenAPI, {
|
|
24
26
|
method: 'GET',
|
|
25
27
|
url: '/templates',
|
|
26
28
|
query: {
|
|
27
29
|
'page': page,
|
|
30
|
+
'limit': limit,
|
|
31
|
+
'sort': sort,
|
|
32
|
+
},
|
|
33
|
+
errors: {
|
|
34
|
+
400: `If the filter options or query parameters contain invalid values`,
|
|
35
|
+
401: `Unauthorized - Missing or invalid Authorization header`,
|
|
36
|
+
403: `Forbidden - The client is authenticated but not authorized to access this resource`,
|
|
37
|
+
500: `When an internal server error occurs when listing all related templates`,
|
|
28
38
|
},
|
|
29
39
|
});
|
|
30
40
|
}
|
|
31
41
|
/**
|
|
32
|
-
* Create Template
|
|
33
|
-
*
|
|
42
|
+
* Create a Template
|
|
43
|
+
* Creates a new Template
|
|
34
44
|
* @param requestBody
|
|
35
|
-
* @returns DTOTemplateRead
|
|
45
|
+
* @returns DTOTemplateRead When a template is created
|
|
36
46
|
* @throws ApiError
|
|
37
47
|
*/
|
|
38
48
|
templateCreate(requestBody) {
|
|
@@ -41,33 +51,44 @@ export class CoreService {
|
|
|
41
51
|
url: '/templates',
|
|
42
52
|
body: requestBody,
|
|
43
53
|
mediaType: 'application/json',
|
|
54
|
+
errors: {
|
|
55
|
+
400: `If the payload is malformed`,
|
|
56
|
+
401: `Unauthorized - Missing or invalid Authorization header`,
|
|
57
|
+
403: `Forbidden - The client is authenticated but not authorized to access this resource`,
|
|
58
|
+
500: `When an internal server error occurs when creating a template entity`,
|
|
59
|
+
},
|
|
44
60
|
});
|
|
45
61
|
}
|
|
46
62
|
/**
|
|
47
|
-
* Get
|
|
48
|
-
* Get
|
|
63
|
+
* Get Itinerary
|
|
64
|
+
* Get itinerary via ID
|
|
49
65
|
* @param templateId Id of a template
|
|
50
|
-
* @returns
|
|
66
|
+
* @returns any OK
|
|
51
67
|
* @throws ApiError
|
|
52
68
|
*/
|
|
53
|
-
|
|
69
|
+
itineraryGet(templateId) {
|
|
54
70
|
return __request(OpenAPI, {
|
|
55
71
|
method: 'GET',
|
|
56
72
|
url: '/templates/{templateId}',
|
|
57
73
|
path: {
|
|
58
74
|
'templateId': templateId,
|
|
59
75
|
},
|
|
76
|
+
errors: {
|
|
77
|
+
401: `Unauthorized - Missing or invalid Authorization header`,
|
|
78
|
+
403: `Forbidden - The client is authenticated but not authorized to access this resource`,
|
|
79
|
+
404: `If the itinerary does not exist`,
|
|
80
|
+
},
|
|
60
81
|
});
|
|
61
82
|
}
|
|
62
83
|
/**
|
|
63
|
-
* Update Template
|
|
64
|
-
* Updates
|
|
84
|
+
* Update Template as New Revision
|
|
85
|
+
* Updates an template as a new revision
|
|
65
86
|
* @param templateId Id of a template
|
|
66
87
|
* @param requestBody
|
|
67
|
-
* @returns DTOTemplateRead
|
|
88
|
+
* @returns DTOTemplateRead When a new revision is created successfully
|
|
68
89
|
* @throws ApiError
|
|
69
90
|
*/
|
|
70
|
-
|
|
91
|
+
templateUpdateAsNewRevision(templateId, requestBody) {
|
|
71
92
|
return __request(OpenAPI, {
|
|
72
93
|
method: 'PATCH',
|
|
73
94
|
url: '/templates/{templateId}',
|
|
@@ -76,13 +97,20 @@ export class CoreService {
|
|
|
76
97
|
},
|
|
77
98
|
body: requestBody,
|
|
78
99
|
mediaType: 'application/json',
|
|
100
|
+
errors: {
|
|
101
|
+
400: `If the payload is malformed`,
|
|
102
|
+
401: `Unauthorized - Missing or invalid Authorization header`,
|
|
103
|
+
403: `Forbidden - The client is authenticated but not authorized to access this resource`,
|
|
104
|
+
404: `When the template id to create a new revision from is not found`,
|
|
105
|
+
500: `When an internal server error occurs updating a template as a new revision`,
|
|
106
|
+
},
|
|
79
107
|
});
|
|
80
108
|
}
|
|
81
109
|
/**
|
|
82
|
-
* Delete Template
|
|
83
|
-
*
|
|
110
|
+
* Delete Template via ID
|
|
111
|
+
* Deletes a specific template given its Id
|
|
84
112
|
* @param templateId Id of a template
|
|
85
|
-
* @returns
|
|
113
|
+
* @returns void
|
|
86
114
|
* @throws ApiError
|
|
87
115
|
*/
|
|
88
116
|
templateDelete(templateId) {
|
|
@@ -92,31 +120,46 @@ export class CoreService {
|
|
|
92
120
|
path: {
|
|
93
121
|
'templateId': templateId,
|
|
94
122
|
},
|
|
123
|
+
errors: {
|
|
124
|
+
400: `When the template doesn't exist in the first place, or when a before hook fails before deleting the item`,
|
|
125
|
+
401: `Unauthorized - Missing or invalid Authorization header`,
|
|
126
|
+
403: `Forbidden - The client is authenticated but not authorized to access this resource`,
|
|
127
|
+
404: `Not Found`,
|
|
128
|
+
500: `When the template fails to delete due to an internal server error`,
|
|
129
|
+
},
|
|
95
130
|
});
|
|
96
131
|
}
|
|
97
132
|
/**
|
|
98
|
-
* List
|
|
99
|
-
* List all
|
|
133
|
+
* List Component
|
|
134
|
+
* List all available component
|
|
100
135
|
* @param page Pagination, starting at page 1
|
|
101
136
|
* @param limit Number of items per page
|
|
102
|
-
* @
|
|
137
|
+
* @param sort List of fields to sort by
|
|
138
|
+
* @returns any The list of all component given the parameters used
|
|
103
139
|
* @throws ApiError
|
|
104
140
|
*/
|
|
105
|
-
componentList(page, limit) {
|
|
141
|
+
componentList(page, limit, sort) {
|
|
106
142
|
return __request(OpenAPI, {
|
|
107
143
|
method: 'GET',
|
|
108
144
|
url: '/components',
|
|
109
145
|
query: {
|
|
110
146
|
'page': page,
|
|
111
147
|
'limit': limit,
|
|
148
|
+
'sort': sort,
|
|
149
|
+
},
|
|
150
|
+
errors: {
|
|
151
|
+
400: `If the filter options or query parameters contain invalid values`,
|
|
152
|
+
401: `Unauthorized - Missing or invalid Authorization header`,
|
|
153
|
+
403: `Forbidden - The client is authenticated but not authorized to access this resource`,
|
|
154
|
+
500: `When an internal server error occurs when listing all related component`,
|
|
112
155
|
},
|
|
113
156
|
});
|
|
114
157
|
}
|
|
115
158
|
/**
|
|
116
|
-
* Create Component
|
|
117
|
-
*
|
|
159
|
+
* Create a Component
|
|
160
|
+
* Creates a new Component
|
|
118
161
|
* @param requestBody
|
|
119
|
-
* @returns DTOComponentRead
|
|
162
|
+
* @returns DTOComponentRead When a component is created
|
|
120
163
|
* @throws ApiError
|
|
121
164
|
*/
|
|
122
165
|
componentCreate(requestBody) {
|
|
@@ -125,13 +168,19 @@ export class CoreService {
|
|
|
125
168
|
url: '/components',
|
|
126
169
|
body: requestBody,
|
|
127
170
|
mediaType: 'application/json',
|
|
171
|
+
errors: {
|
|
172
|
+
400: `If the payload is malformed`,
|
|
173
|
+
401: `Unauthorized - Missing or invalid Authorization header`,
|
|
174
|
+
403: `Forbidden - The client is authenticated but not authorized to access this resource`,
|
|
175
|
+
500: `Internal Server Error`,
|
|
176
|
+
},
|
|
128
177
|
});
|
|
129
178
|
}
|
|
130
179
|
/**
|
|
131
180
|
* Get Component
|
|
132
|
-
* Get
|
|
181
|
+
* Get Component via ID
|
|
133
182
|
* @param componentId Id of a component
|
|
134
|
-
* @returns
|
|
183
|
+
* @returns any OK
|
|
135
184
|
* @throws ApiError
|
|
136
185
|
*/
|
|
137
186
|
componentGet(componentId) {
|
|
@@ -141,32 +190,70 @@ export class CoreService {
|
|
|
141
190
|
path: {
|
|
142
191
|
'componentId': componentId,
|
|
143
192
|
},
|
|
193
|
+
errors: {
|
|
194
|
+
401: `Unauthorized - Missing or invalid Authorization header`,
|
|
195
|
+
403: `Forbidden - The client is authenticated but not authorized to access this resource`,
|
|
196
|
+
404: `If the component does not exist`,
|
|
197
|
+
},
|
|
198
|
+
});
|
|
199
|
+
}
|
|
200
|
+
/**
|
|
201
|
+
* Update Component as New Revision
|
|
202
|
+
* Updates an component as a new revision
|
|
203
|
+
* @param componentId Id of a component
|
|
204
|
+
* @param requestBody
|
|
205
|
+
* @returns DTOComponentRead When a new component is created successfully
|
|
206
|
+
* @throws ApiError
|
|
207
|
+
*/
|
|
208
|
+
componentUpdateAsNewRevision(componentId, requestBody) {
|
|
209
|
+
return __request(OpenAPI, {
|
|
210
|
+
method: 'PATCH',
|
|
211
|
+
url: '/components/{componentId}',
|
|
212
|
+
path: {
|
|
213
|
+
'componentId': componentId,
|
|
214
|
+
},
|
|
215
|
+
body: requestBody,
|
|
216
|
+
mediaType: 'application/json',
|
|
217
|
+
errors: {
|
|
218
|
+
400: `If the payload is malformed`,
|
|
219
|
+
401: `Unauthorized - Missing or invalid Authorization header`,
|
|
220
|
+
403: `Forbidden - The client is authenticated but not authorized to access this resource`,
|
|
221
|
+
404: `When the component id to create a new revision from is not found`,
|
|
222
|
+
500: `When an internal server error occurs updating a component as a new revision`,
|
|
223
|
+
},
|
|
144
224
|
});
|
|
145
225
|
}
|
|
146
226
|
/**
|
|
147
227
|
* Update Component
|
|
148
|
-
*
|
|
228
|
+
* Updates an component
|
|
149
229
|
* @param componentId Id of a component
|
|
150
230
|
* @param requestBody
|
|
151
|
-
* @returns DTOComponentRead
|
|
231
|
+
* @returns DTOComponentRead When a component is updated successfully
|
|
152
232
|
* @throws ApiError
|
|
153
233
|
*/
|
|
154
234
|
componentUpdate(componentId, requestBody) {
|
|
155
235
|
return __request(OpenAPI, {
|
|
156
|
-
method: '
|
|
236
|
+
method: 'PUT',
|
|
157
237
|
url: '/components/{componentId}',
|
|
158
238
|
path: {
|
|
159
239
|
'componentId': componentId,
|
|
160
240
|
},
|
|
161
241
|
body: requestBody,
|
|
162
242
|
mediaType: 'application/json',
|
|
243
|
+
errors: {
|
|
244
|
+
400: `If the payload is malformed`,
|
|
245
|
+
401: `Unauthorized - Missing or invalid Authorization header`,
|
|
246
|
+
403: `Forbidden - The client is authenticated but not authorized to access this resource`,
|
|
247
|
+
404: `When the component id to update is not found`,
|
|
248
|
+
500: `When an internal server error occurs updating a component`,
|
|
249
|
+
},
|
|
163
250
|
});
|
|
164
251
|
}
|
|
165
252
|
/**
|
|
166
|
-
* Delete Component
|
|
167
|
-
*
|
|
253
|
+
* Delete Component via ID
|
|
254
|
+
* Deletes a specific component given its Id
|
|
168
255
|
* @param componentId Id of a component
|
|
169
|
-
* @returns
|
|
256
|
+
* @returns void
|
|
170
257
|
* @throws ApiError
|
|
171
258
|
*/
|
|
172
259
|
componentDelete(componentId) {
|
|
@@ -176,6 +263,13 @@ export class CoreService {
|
|
|
176
263
|
path: {
|
|
177
264
|
'componentId': componentId,
|
|
178
265
|
},
|
|
266
|
+
errors: {
|
|
267
|
+
400: `When the component doesn't exist in the first place, or when a before hook fails before deleting the item`,
|
|
268
|
+
401: `Unauthorized - Missing or invalid Authorization header`,
|
|
269
|
+
403: `Forbidden - The client is authenticated but not authorized to access this resource`,
|
|
270
|
+
404: `Not Found`,
|
|
271
|
+
500: `When the component fails to delete due to an internal server error`,
|
|
272
|
+
},
|
|
179
273
|
});
|
|
180
274
|
}
|
|
181
275
|
/**
|
|
@@ -195,6 +289,11 @@ export class CoreService {
|
|
|
195
289
|
},
|
|
196
290
|
body: requestBody,
|
|
197
291
|
mediaType: 'application/json',
|
|
292
|
+
errors: {
|
|
293
|
+
401: `Unauthorized - Missing or invalid Authorization header`,
|
|
294
|
+
403: `Forbidden - The client is authenticated but not authorized to access this resource`,
|
|
295
|
+
404: `Not Found`,
|
|
296
|
+
},
|
|
198
297
|
});
|
|
199
298
|
}
|
|
200
299
|
/**
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
import type { DTOTemplateCreate } from '../models/DTOTemplateCreate';
|
|
2
|
+
import type { DTOTemplateRead } from '../models/DTOTemplateRead';
|
|
3
|
+
import type { DTOTemplateUpdate } from '../models/DTOTemplateUpdate';
|
|
4
|
+
import type { Pagination } from '../models/Pagination';
|
|
5
|
+
import type { CancelablePromise } from '../core/CancelablePromise';
|
|
6
|
+
export declare class TemplateService {
|
|
7
|
+
/**
|
|
8
|
+
* List Templates
|
|
9
|
+
* List all available templates
|
|
10
|
+
* @param page Pagination, starting at page 1
|
|
11
|
+
* @param limit Number of items per page
|
|
12
|
+
* @param sort List of fields to sort by
|
|
13
|
+
* @returns any The list of all templates given the parameters used
|
|
14
|
+
* @throws ApiError
|
|
15
|
+
*/
|
|
16
|
+
static templateList(page?: number, limit?: number, sort?: any[]): CancelablePromise<{
|
|
17
|
+
data?: Array<DTOTemplateRead>;
|
|
18
|
+
pagination?: Pagination;
|
|
19
|
+
}>;
|
|
20
|
+
/**
|
|
21
|
+
* Create a Template
|
|
22
|
+
* Creates a new Template
|
|
23
|
+
* @param requestBody
|
|
24
|
+
* @returns DTOTemplateRead When a template is created
|
|
25
|
+
* @throws ApiError
|
|
26
|
+
*/
|
|
27
|
+
static templateCreate(requestBody: DTOTemplateCreate): CancelablePromise<DTOTemplateRead>;
|
|
28
|
+
/**
|
|
29
|
+
* Get Itinerary
|
|
30
|
+
* Get itinerary via ID
|
|
31
|
+
* @param templateId Id of a template
|
|
32
|
+
* @returns any OK
|
|
33
|
+
* @throws ApiError
|
|
34
|
+
*/
|
|
35
|
+
static itineraryGet(templateId: string): CancelablePromise<any>;
|
|
36
|
+
/**
|
|
37
|
+
* Update Template as New Revision
|
|
38
|
+
* Updates an template as a new revision
|
|
39
|
+
* @param templateId Id of a template
|
|
40
|
+
* @param requestBody
|
|
41
|
+
* @returns DTOTemplateRead When a new revision is created successfully
|
|
42
|
+
* @throws ApiError
|
|
43
|
+
*/
|
|
44
|
+
static templateUpdateAsNewRevision(templateId: string, requestBody: DTOTemplateUpdate): CancelablePromise<DTOTemplateRead>;
|
|
45
|
+
/**
|
|
46
|
+
* Delete Template via ID
|
|
47
|
+
* Deletes a specific template given its Id
|
|
48
|
+
* @param templateId Id of a template
|
|
49
|
+
* @returns void
|
|
50
|
+
* @throws ApiError
|
|
51
|
+
*/
|
|
52
|
+
static templateDelete(templateId: string): CancelablePromise<void>;
|
|
53
|
+
}
|
|
@@ -0,0 +1,121 @@
|
|
|
1
|
+
import { OpenAPI } from '../core/OpenAPI';
|
|
2
|
+
import { request as __request } from '../core/request';
|
|
3
|
+
export class TemplateService {
|
|
4
|
+
/**
|
|
5
|
+
* List Templates
|
|
6
|
+
* List all available templates
|
|
7
|
+
* @param page Pagination, starting at page 1
|
|
8
|
+
* @param limit Number of items per page
|
|
9
|
+
* @param sort List of fields to sort by
|
|
10
|
+
* @returns any The list of all templates given the parameters used
|
|
11
|
+
* @throws ApiError
|
|
12
|
+
*/
|
|
13
|
+
static templateList(page, limit, sort) {
|
|
14
|
+
return __request(OpenAPI, {
|
|
15
|
+
method: 'GET',
|
|
16
|
+
url: '/templates',
|
|
17
|
+
query: {
|
|
18
|
+
'page': page,
|
|
19
|
+
'limit': limit,
|
|
20
|
+
'sort': sort,
|
|
21
|
+
},
|
|
22
|
+
errors: {
|
|
23
|
+
400: `If the filter options or query parameters contain invalid values`,
|
|
24
|
+
401: `Unauthorized - Missing or invalid Authorization header`,
|
|
25
|
+
403: `Forbidden - The client is authenticated but not authorized to access this resource`,
|
|
26
|
+
500: `When an internal server error occurs when listing all related templates`,
|
|
27
|
+
},
|
|
28
|
+
});
|
|
29
|
+
}
|
|
30
|
+
/**
|
|
31
|
+
* Create a Template
|
|
32
|
+
* Creates a new Template
|
|
33
|
+
* @param requestBody
|
|
34
|
+
* @returns DTOTemplateRead When a template is created
|
|
35
|
+
* @throws ApiError
|
|
36
|
+
*/
|
|
37
|
+
static templateCreate(requestBody) {
|
|
38
|
+
return __request(OpenAPI, {
|
|
39
|
+
method: 'POST',
|
|
40
|
+
url: '/templates',
|
|
41
|
+
body: requestBody,
|
|
42
|
+
mediaType: 'application/json',
|
|
43
|
+
errors: {
|
|
44
|
+
400: `If the payload is malformed`,
|
|
45
|
+
401: `Unauthorized - Missing or invalid Authorization header`,
|
|
46
|
+
403: `Forbidden - The client is authenticated but not authorized to access this resource`,
|
|
47
|
+
500: `When an internal server error occurs when creating a template entity`,
|
|
48
|
+
},
|
|
49
|
+
});
|
|
50
|
+
}
|
|
51
|
+
/**
|
|
52
|
+
* Get Itinerary
|
|
53
|
+
* Get itinerary via ID
|
|
54
|
+
* @param templateId Id of a template
|
|
55
|
+
* @returns any OK
|
|
56
|
+
* @throws ApiError
|
|
57
|
+
*/
|
|
58
|
+
static itineraryGet(templateId) {
|
|
59
|
+
return __request(OpenAPI, {
|
|
60
|
+
method: 'GET',
|
|
61
|
+
url: '/templates/{templateId}',
|
|
62
|
+
path: {
|
|
63
|
+
'templateId': templateId,
|
|
64
|
+
},
|
|
65
|
+
errors: {
|
|
66
|
+
401: `Unauthorized - Missing or invalid Authorization header`,
|
|
67
|
+
403: `Forbidden - The client is authenticated but not authorized to access this resource`,
|
|
68
|
+
404: `If the itinerary does not exist`,
|
|
69
|
+
},
|
|
70
|
+
});
|
|
71
|
+
}
|
|
72
|
+
/**
|
|
73
|
+
* Update Template as New Revision
|
|
74
|
+
* Updates an template as a new revision
|
|
75
|
+
* @param templateId Id of a template
|
|
76
|
+
* @param requestBody
|
|
77
|
+
* @returns DTOTemplateRead When a new revision is created successfully
|
|
78
|
+
* @throws ApiError
|
|
79
|
+
*/
|
|
80
|
+
static templateUpdateAsNewRevision(templateId, requestBody) {
|
|
81
|
+
return __request(OpenAPI, {
|
|
82
|
+
method: 'PATCH',
|
|
83
|
+
url: '/templates/{templateId}',
|
|
84
|
+
path: {
|
|
85
|
+
'templateId': templateId,
|
|
86
|
+
},
|
|
87
|
+
body: requestBody,
|
|
88
|
+
mediaType: 'application/json',
|
|
89
|
+
errors: {
|
|
90
|
+
400: `If the payload is malformed`,
|
|
91
|
+
401: `Unauthorized - Missing or invalid Authorization header`,
|
|
92
|
+
403: `Forbidden - The client is authenticated but not authorized to access this resource`,
|
|
93
|
+
404: `When the template id to create a new revision from is not found`,
|
|
94
|
+
500: `When an internal server error occurs updating a template as a new revision`,
|
|
95
|
+
},
|
|
96
|
+
});
|
|
97
|
+
}
|
|
98
|
+
/**
|
|
99
|
+
* Delete Template via ID
|
|
100
|
+
* Deletes a specific template given its Id
|
|
101
|
+
* @param templateId Id of a template
|
|
102
|
+
* @returns void
|
|
103
|
+
* @throws ApiError
|
|
104
|
+
*/
|
|
105
|
+
static templateDelete(templateId) {
|
|
106
|
+
return __request(OpenAPI, {
|
|
107
|
+
method: 'DELETE',
|
|
108
|
+
url: '/templates/{templateId}',
|
|
109
|
+
path: {
|
|
110
|
+
'templateId': templateId,
|
|
111
|
+
},
|
|
112
|
+
errors: {
|
|
113
|
+
400: `When the template doesn't exist in the first place, or when a before hook fails before deleting the item`,
|
|
114
|
+
401: `Unauthorized - Missing or invalid Authorization header`,
|
|
115
|
+
403: `Forbidden - The client is authenticated but not authorized to access this resource`,
|
|
116
|
+
404: `Not Found`,
|
|
117
|
+
500: `When the template fails to delete due to an internal server error`,
|
|
118
|
+
},
|
|
119
|
+
});
|
|
120
|
+
}
|
|
121
|
+
}
|
|
@@ -67,4 +67,7 @@ export type { sortParam } from './models/sortParam';
|
|
|
67
67
|
export type { templateId } from './models/templateId';
|
|
68
68
|
export type { UserComponentInstanceField } from './models/UserComponentInstanceField';
|
|
69
69
|
export type { ValidationSchemas } from './models/ValidationSchemas';
|
|
70
|
+
export { AuditService } from './services/AuditService';
|
|
70
71
|
export { ItineraryService } from './services/ItineraryService';
|
|
72
|
+
export { RegionService } from './services/RegionService';
|
|
73
|
+
export { SnapshotService } from './services/SnapshotService';
|
|
@@ -11,4 +11,7 @@ export { Currency } from './models/Currency';
|
|
|
11
11
|
export { Meals } from './models/Meals';
|
|
12
12
|
export { regionParam } from './models/regionParam';
|
|
13
13
|
export { regionRequired } from './models/regionRequired';
|
|
14
|
+
export { AuditService } from './services/AuditService';
|
|
14
15
|
export { ItineraryService } from './services/ItineraryService';
|
|
16
|
+
export { RegionService } from './services/RegionService';
|
|
17
|
+
export { SnapshotService } from './services/SnapshotService';
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import type { CancelablePromise } from '../core/CancelablePromise';
|
|
2
|
+
export declare class AuditService {
|
|
3
|
+
/**
|
|
4
|
+
* Audit a Copy to Clipboard
|
|
5
|
+
* Audits when a user copies something to their clipboard
|
|
6
|
+
* @param itineraryId Itinerary id
|
|
7
|
+
* @param content Base64 encoding of the copied content
|
|
8
|
+
* @returns void
|
|
9
|
+
* @throws ApiError
|
|
10
|
+
*/
|
|
11
|
+
static auditCopyClipboard(itineraryId: string, content: string): CancelablePromise<void>;
|
|
12
|
+
}
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import { OpenAPI } from '../core/OpenAPI';
|
|
2
|
+
import { request as __request } from '../core/request';
|
|
3
|
+
export class AuditService {
|
|
4
|
+
/**
|
|
5
|
+
* Audit a Copy to Clipboard
|
|
6
|
+
* Audits when a user copies something to their clipboard
|
|
7
|
+
* @param itineraryId Itinerary id
|
|
8
|
+
* @param content Base64 encoding of the copied content
|
|
9
|
+
* @returns void
|
|
10
|
+
* @throws ApiError
|
|
11
|
+
*/
|
|
12
|
+
static auditCopyClipboard(itineraryId, content) {
|
|
13
|
+
return __request(OpenAPI, {
|
|
14
|
+
method: 'POST',
|
|
15
|
+
url: '/audit/copyClipboard/{itineraryId}',
|
|
16
|
+
path: {
|
|
17
|
+
'itineraryId': itineraryId,
|
|
18
|
+
},
|
|
19
|
+
query: {
|
|
20
|
+
'content': content,
|
|
21
|
+
},
|
|
22
|
+
errors: {
|
|
23
|
+
400: `When the content query b64 string is invalid`,
|
|
24
|
+
401: `Unauthorized - Missing or invalid Authorization header`,
|
|
25
|
+
},
|
|
26
|
+
});
|
|
27
|
+
}
|
|
28
|
+
}
|
|
@@ -28,13 +28,14 @@ export declare class ItineraryService {
|
|
|
28
28
|
/**
|
|
29
29
|
* List Snapshots
|
|
30
30
|
* List all available snapshots
|
|
31
|
+
* @param enquiryId Enquiry Id
|
|
31
32
|
* @param page Pagination, starting at page 1
|
|
32
33
|
* @param limit Number of items per page
|
|
33
34
|
* @param sort List of fields to sort by
|
|
34
35
|
* @returns any The list of all snapshots given the parameters used
|
|
35
36
|
* @throws ApiError
|
|
36
37
|
*/
|
|
37
|
-
snapshotList(page?: number, limit?: number, sort?: any[]): CancelablePromise<{
|
|
38
|
+
snapshotList(enquiryId: string, page?: number, limit?: number, sort?: any[]): CancelablePromise<{
|
|
38
39
|
data?: Array<DTOSnapshotRead>;
|
|
39
40
|
pagination?: Pagination;
|
|
40
41
|
}>;
|
|
@@ -49,13 +49,14 @@ export class ItineraryService {
|
|
|
49
49
|
/**
|
|
50
50
|
* List Snapshots
|
|
51
51
|
* List all available snapshots
|
|
52
|
+
* @param enquiryId Enquiry Id
|
|
52
53
|
* @param page Pagination, starting at page 1
|
|
53
54
|
* @param limit Number of items per page
|
|
54
55
|
* @param sort List of fields to sort by
|
|
55
56
|
* @returns any The list of all snapshots given the parameters used
|
|
56
57
|
* @throws ApiError
|
|
57
58
|
*/
|
|
58
|
-
snapshotList(page, limit, sort) {
|
|
59
|
+
snapshotList(enquiryId, page, limit, sort) {
|
|
59
60
|
return __request(OpenAPI, {
|
|
60
61
|
method: 'GET',
|
|
61
62
|
url: '/snapshots',
|
|
@@ -63,6 +64,7 @@ export class ItineraryService {
|
|
|
63
64
|
'page': page,
|
|
64
65
|
'limit': limit,
|
|
65
66
|
'sort': sort,
|
|
67
|
+
'enquiryId': enquiryId,
|
|
66
68
|
},
|
|
67
69
|
errors: {
|
|
68
70
|
400: `If the filter options or query parameters contain invalid values`,
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import type { DTORegionCreate } from '../models/DTORegionCreate';
|
|
2
|
+
import type { DTORegionRead } from '../models/DTORegionRead';
|
|
3
|
+
import type { Pagination } from '../models/Pagination';
|
|
4
|
+
import type { CancelablePromise } from '../core/CancelablePromise';
|
|
5
|
+
export declare class RegionService {
|
|
6
|
+
/**
|
|
7
|
+
* List Regions
|
|
8
|
+
* List all regions
|
|
9
|
+
* @param page Pagination, starting at page 1
|
|
10
|
+
* @param limit Number of items per page
|
|
11
|
+
* @param sort List of fields to sort by
|
|
12
|
+
* @returns any OK
|
|
13
|
+
* @throws ApiError
|
|
14
|
+
*/
|
|
15
|
+
static regionList(page?: number, limit?: number, sort?: any[]): CancelablePromise<{
|
|
16
|
+
data?: Array<DTORegionRead>;
|
|
17
|
+
pagination?: Pagination;
|
|
18
|
+
}>;
|
|
19
|
+
/**
|
|
20
|
+
* Create Region
|
|
21
|
+
* Create a region
|
|
22
|
+
* @param requestBody
|
|
23
|
+
* @returns DTORegionRead OK
|
|
24
|
+
* @throws ApiError
|
|
25
|
+
*/
|
|
26
|
+
static regionCreate(requestBody?: DTORegionCreate): CancelablePromise<DTORegionRead>;
|
|
27
|
+
}
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
import { OpenAPI } from '../core/OpenAPI';
|
|
2
|
+
import { request as __request } from '../core/request';
|
|
3
|
+
export class RegionService {
|
|
4
|
+
/**
|
|
5
|
+
* List Regions
|
|
6
|
+
* List all regions
|
|
7
|
+
* @param page Pagination, starting at page 1
|
|
8
|
+
* @param limit Number of items per page
|
|
9
|
+
* @param sort List of fields to sort by
|
|
10
|
+
* @returns any OK
|
|
11
|
+
* @throws ApiError
|
|
12
|
+
*/
|
|
13
|
+
static regionList(page, limit, sort) {
|
|
14
|
+
return __request(OpenAPI, {
|
|
15
|
+
method: 'GET',
|
|
16
|
+
url: '/regions',
|
|
17
|
+
query: {
|
|
18
|
+
'page': page,
|
|
19
|
+
'limit': limit,
|
|
20
|
+
'sort': sort,
|
|
21
|
+
},
|
|
22
|
+
errors: {
|
|
23
|
+
400: `If the filter options or query parameters contain invalid values`,
|
|
24
|
+
401: `Unauthorized - Missing or invalid Authorization header`,
|
|
25
|
+
500: `When an internal server error occurs when listing all related regions`,
|
|
26
|
+
503: `Service Unavailable - The server is temporarily unable to handle the request`,
|
|
27
|
+
},
|
|
28
|
+
});
|
|
29
|
+
}
|
|
30
|
+
/**
|
|
31
|
+
* Create Region
|
|
32
|
+
* Create a region
|
|
33
|
+
* @param requestBody
|
|
34
|
+
* @returns DTORegionRead OK
|
|
35
|
+
* @throws ApiError
|
|
36
|
+
*/
|
|
37
|
+
static regionCreate(requestBody) {
|
|
38
|
+
return __request(OpenAPI, {
|
|
39
|
+
method: 'POST',
|
|
40
|
+
url: '/regions',
|
|
41
|
+
body: requestBody,
|
|
42
|
+
mediaType: 'application/json',
|
|
43
|
+
errors: {
|
|
44
|
+
400: `If the payload is malformed`,
|
|
45
|
+
401: `Unauthorized - Missing or invalid Authorization header`,
|
|
46
|
+
500: `When an internal server error occurs when creating a region entity`,
|
|
47
|
+
503: `Service Unavailable - The server is temporarily unable to handle the request`,
|
|
48
|
+
},
|
|
49
|
+
});
|
|
50
|
+
}
|
|
51
|
+
}
|