@wix/auto_sdk_pro-gallery_pro-gallery 1.0.20 → 1.0.22
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/build/{index.d.ts → cjs/index.d.ts} +20 -15
- package/build/{internal → cjs}/index.js +1 -0
- package/build/cjs/index.js.map +1 -0
- package/build/{pro-gallery-v2-gallery-pro-gallery.universal-CExTgtbV.d.mts → cjs/index.typings.d.ts} +327 -3
- package/build/cjs/index.typings.js +1467 -0
- package/build/cjs/index.typings.js.map +1 -0
- package/build/{internal → cjs}/meta.d.ts +2 -1
- package/build/{index.d.mts → es/index.d.mts} +20 -15
- package/build/{index.mjs → es/index.mjs} +1 -0
- package/build/es/index.mjs.map +1 -0
- package/build/{internal/pro-gallery-v2-gallery-pro-gallery.universal-CExTgtbV.d.ts → es/index.typings.d.mts} +327 -3
- package/build/es/index.typings.mjs +1422 -0
- package/build/es/index.typings.mjs.map +1 -0
- package/build/{internal → es}/meta.d.mts +2 -1
- package/build/internal/{index.d.ts → cjs/index.d.ts} +20 -15
- package/build/{index.js → internal/cjs/index.js} +1 -0
- package/build/internal/cjs/index.js.map +1 -0
- package/build/{pro-gallery-v2-gallery-pro-gallery.universal-CExTgtbV.d.ts → internal/cjs/index.typings.d.ts} +327 -3
- package/build/internal/cjs/index.typings.js +1467 -0
- package/build/internal/cjs/index.typings.js.map +1 -0
- package/build/{meta.d.ts → internal/cjs/meta.d.ts} +2 -1
- package/build/internal/cjs/meta.js.map +1 -0
- package/build/internal/{index.d.mts → es/index.d.mts} +20 -15
- package/build/internal/{index.mjs → es/index.mjs} +1 -0
- package/build/internal/es/index.mjs.map +1 -0
- package/build/internal/{pro-gallery-v2-gallery-pro-gallery.universal-CExTgtbV.d.mts → es/index.typings.d.mts} +327 -3
- package/build/internal/es/index.typings.mjs +1422 -0
- package/build/internal/{index.js.map → es/index.typings.mjs.map} +1 -1
- package/build/{meta.d.mts → internal/es/meta.d.mts} +2 -1
- package/build/internal/es/meta.mjs.map +1 -0
- package/package.json +12 -11
- package/build/index.js.map +0 -1
- package/build/index.mjs.map +0 -1
- package/build/internal/index.mjs.map +0 -1
- package/build/meta.js.map +0 -1
- package/build/meta.mjs.map +0 -1
- /package/build/{internal → cjs}/meta.js +0 -0
- /package/build/{internal → cjs}/meta.js.map +0 -0
- /package/build/{internal → es}/meta.mjs +0 -0
- /package/build/{internal → es}/meta.mjs.map +0 -0
- /package/build/{meta.js → internal/cjs/meta.js} +0 -0
- /package/build/{meta.mjs → internal/es/meta.mjs} +0 -0
@@ -0,0 +1,1467 @@
|
|
1
|
+
"use strict";
|
2
|
+
var __defProp = Object.defineProperty;
|
3
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
4
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
5
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
6
|
+
var __export = (target, all) => {
|
7
|
+
for (var name in all)
|
8
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
9
|
+
};
|
10
|
+
var __copyProps = (to, from, except, desc) => {
|
11
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
12
|
+
for (let key of __getOwnPropNames(from))
|
13
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
14
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
15
|
+
}
|
16
|
+
return to;
|
17
|
+
};
|
18
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
19
|
+
|
20
|
+
// index.typings.ts
|
21
|
+
var index_typings_exports = {};
|
22
|
+
__export(index_typings_exports, {
|
23
|
+
Enum: () => Enum,
|
24
|
+
ImageType: () => ImageType,
|
25
|
+
LinkRel: () => LinkRel,
|
26
|
+
LinkType: () => LinkType,
|
27
|
+
RCLabel: () => RCLabel,
|
28
|
+
SearchIndexingNotificationState: () => SearchIndexingNotificationState,
|
29
|
+
State: () => State,
|
30
|
+
Type: () => Type,
|
31
|
+
VideoType: () => VideoType,
|
32
|
+
WebhookIdentityType: () => WebhookIdentityType,
|
33
|
+
bulkDeleteGalleryItems: () => bulkDeleteGalleryItems2,
|
34
|
+
createGallery: () => createGallery2,
|
35
|
+
createGalleryItem: () => createGalleryItem2,
|
36
|
+
deleteGallery: () => deleteGallery2,
|
37
|
+
deleteGalleryItem: () => deleteGalleryItem2,
|
38
|
+
deleteGalleryItems: () => deleteGalleryItems2,
|
39
|
+
getGallery: () => getGallery2,
|
40
|
+
getGalleryItem: () => getGalleryItem2,
|
41
|
+
listGalleries: () => listGalleries2,
|
42
|
+
listGalleryItems: () => listGalleryItems2,
|
43
|
+
updateGallery: () => updateGallery2,
|
44
|
+
updateGalleryItem: () => updateGalleryItem2
|
45
|
+
});
|
46
|
+
module.exports = __toCommonJS(index_typings_exports);
|
47
|
+
|
48
|
+
// src/pro-gallery-v2-gallery-pro-gallery.universal.ts
|
49
|
+
var import_transform_error = require("@wix/sdk-runtime/transform-error");
|
50
|
+
var import_rename_all_nested_keys = require("@wix/sdk-runtime/rename-all-nested-keys");
|
51
|
+
|
52
|
+
// src/pro-gallery-v2-gallery-pro-gallery.http.ts
|
53
|
+
var import_rest_modules = require("@wix/sdk-runtime/rest-modules");
|
54
|
+
var import_float = require("@wix/sdk-runtime/transformations/float");
|
55
|
+
var import_float2 = require("@wix/sdk-runtime/transformations/float");
|
56
|
+
var import_timestamp = require("@wix/sdk-runtime/transformations/timestamp");
|
57
|
+
var import_timestamp2 = require("@wix/sdk-runtime/transformations/timestamp");
|
58
|
+
var import_field_mask = require("@wix/sdk-runtime/transformations/field-mask");
|
59
|
+
var import_transform_paths = require("@wix/sdk-runtime/transformations/transform-paths");
|
60
|
+
var import_rest_modules2 = require("@wix/sdk-runtime/rest-modules");
|
61
|
+
function resolveComWixpressExposureProgalleryProGalleryUrl(opts) {
|
62
|
+
const domainToMappings = {
|
63
|
+
_: [
|
64
|
+
{
|
65
|
+
srcPath: "/_api/pro-gallery-server",
|
66
|
+
destPath: ""
|
67
|
+
}
|
68
|
+
],
|
69
|
+
"manage._base_domain_": [
|
70
|
+
{
|
71
|
+
srcPath: "/_api/pro-gallery-server",
|
72
|
+
destPath: ""
|
73
|
+
}
|
74
|
+
],
|
75
|
+
"www._base_domain_": [
|
76
|
+
{
|
77
|
+
srcPath: "/_api/pro-gallery-server",
|
78
|
+
destPath: ""
|
79
|
+
}
|
80
|
+
],
|
81
|
+
"editor._base_domain_": [
|
82
|
+
{
|
83
|
+
srcPath: "/_api/pro-gallery-server",
|
84
|
+
destPath: ""
|
85
|
+
}
|
86
|
+
],
|
87
|
+
"blocks._base_domain_": [
|
88
|
+
{
|
89
|
+
srcPath: "/_api/pro-gallery-server",
|
90
|
+
destPath: ""
|
91
|
+
}
|
92
|
+
],
|
93
|
+
"create.editorx": [
|
94
|
+
{
|
95
|
+
srcPath: "/_api/pro-gallery-server",
|
96
|
+
destPath: ""
|
97
|
+
}
|
98
|
+
],
|
99
|
+
"progallery.wixapps.net": [
|
100
|
+
{
|
101
|
+
srcPath: "/_api/pro-gallery-server",
|
102
|
+
destPath: ""
|
103
|
+
}
|
104
|
+
],
|
105
|
+
"www.wixapis.com": [
|
106
|
+
{
|
107
|
+
srcPath: "/progallery",
|
108
|
+
destPath: ""
|
109
|
+
},
|
110
|
+
{
|
111
|
+
srcPath: "/pro-gallery/v2/galleries",
|
112
|
+
destPath: "/v2/galleries"
|
113
|
+
}
|
114
|
+
],
|
115
|
+
"*.dev.wix-code.com": [
|
116
|
+
{
|
117
|
+
srcPath: "/_api/pro-gallery-server",
|
118
|
+
destPath: ""
|
119
|
+
}
|
120
|
+
],
|
121
|
+
"api._api_base_domain_": [
|
122
|
+
{
|
123
|
+
srcPath: "/prime-server-proxy",
|
124
|
+
destPath: ""
|
125
|
+
}
|
126
|
+
]
|
127
|
+
};
|
128
|
+
return (0, import_rest_modules2.resolveUrl)(Object.assign(opts, { domainToMappings }));
|
129
|
+
}
|
130
|
+
var PACKAGE_NAME = "@wix/auto_sdk_pro-gallery_pro-gallery";
|
131
|
+
function listGalleries(payload) {
|
132
|
+
function __listGalleries({ host }) {
|
133
|
+
const serializedData = (0, import_transform_paths.transformPaths)(payload, [
|
134
|
+
{
|
135
|
+
transformFn: import_field_mask.transformSDKFieldMaskToRESTFieldMask,
|
136
|
+
paths: [{ path: "fields" }]
|
137
|
+
}
|
138
|
+
]);
|
139
|
+
const metadata = {
|
140
|
+
entityFqdn: "wix.pro_gallery.v2.gallery",
|
141
|
+
method: "GET",
|
142
|
+
methodFqn: "com.wixpress.exposure.progallery.ProGallery.ListGalleries",
|
143
|
+
packageName: PACKAGE_NAME,
|
144
|
+
url: resolveComWixpressExposureProgalleryProGalleryUrl({
|
145
|
+
protoPath: "/v2/galleries",
|
146
|
+
data: serializedData,
|
147
|
+
host
|
148
|
+
}),
|
149
|
+
params: (0, import_rest_modules.toURLSearchParams)(serializedData),
|
150
|
+
transformResponse: (payload2) => (0, import_transform_paths.transformPaths)(payload2, [
|
151
|
+
{
|
152
|
+
transformFn: import_float2.transformRESTFloatToSDKFloat,
|
153
|
+
paths: [
|
154
|
+
{ path: "galleries.sortOrder" },
|
155
|
+
{ path: "galleries.items.sortOrder" },
|
156
|
+
{ path: "galleries.items.image.focalPoint.x" },
|
157
|
+
{ path: "galleries.items.image.focalPoint.y" },
|
158
|
+
{ path: "galleries.items.secondaryMedia.image.focalPoint.x" },
|
159
|
+
{ path: "galleries.items.secondaryMedia.image.focalPoint.y" },
|
160
|
+
{ path: "galleries.items.image.unsharpMasking.amount" },
|
161
|
+
{ path: "galleries.items.image.unsharpMasking.radius" },
|
162
|
+
{ path: "galleries.items.image.unsharpMasking.threshold" },
|
163
|
+
{
|
164
|
+
path: "galleries.items.secondaryMedia.image.unsharpMasking.amount"
|
165
|
+
},
|
166
|
+
{
|
167
|
+
path: "galleries.items.secondaryMedia.image.unsharpMasking.radius"
|
168
|
+
},
|
169
|
+
{
|
170
|
+
path: "galleries.items.secondaryMedia.image.unsharpMasking.threshold"
|
171
|
+
}
|
172
|
+
]
|
173
|
+
},
|
174
|
+
{
|
175
|
+
transformFn: import_timestamp2.transformRESTTimestampToSDKTimestamp,
|
176
|
+
paths: [
|
177
|
+
{ path: "galleries.createdDate" },
|
178
|
+
{ path: "galleries.items.createdDate" },
|
179
|
+
{ path: "galleries.items.updatedDate" },
|
180
|
+
{ path: "galleries.items.image.imageInfo.urlExpirationDate" },
|
181
|
+
{ path: "galleries.items.video.videoInfo.urlExpirationDate" },
|
182
|
+
{
|
183
|
+
path: "galleries.items.video.videoInfo.resolutions.poster.urlExpirationDate"
|
184
|
+
},
|
185
|
+
{
|
186
|
+
path: "galleries.items.video.videoInfo.posters.urlExpirationDate"
|
187
|
+
},
|
188
|
+
{
|
189
|
+
path: "galleries.items.secondaryMedia.image.imageInfo.urlExpirationDate"
|
190
|
+
}
|
191
|
+
]
|
192
|
+
}
|
193
|
+
])
|
194
|
+
};
|
195
|
+
return metadata;
|
196
|
+
}
|
197
|
+
return __listGalleries;
|
198
|
+
}
|
199
|
+
function getGallery(payload) {
|
200
|
+
function __getGallery({ host }) {
|
201
|
+
const metadata = {
|
202
|
+
entityFqdn: "wix.pro_gallery.v2.gallery",
|
203
|
+
method: "GET",
|
204
|
+
methodFqn: "com.wixpress.exposure.progallery.ProGallery.GetGallery",
|
205
|
+
packageName: PACKAGE_NAME,
|
206
|
+
url: resolveComWixpressExposureProgalleryProGalleryUrl({
|
207
|
+
protoPath: "/v2/galleries/{galleryId}",
|
208
|
+
data: payload,
|
209
|
+
host
|
210
|
+
}),
|
211
|
+
params: (0, import_rest_modules.toURLSearchParams)(payload),
|
212
|
+
transformResponse: (payload2) => (0, import_transform_paths.transformPaths)(payload2, [
|
213
|
+
{
|
214
|
+
transformFn: import_float2.transformRESTFloatToSDKFloat,
|
215
|
+
paths: [
|
216
|
+
{ path: "gallery.sortOrder" },
|
217
|
+
{ path: "gallery.items.sortOrder" },
|
218
|
+
{ path: "gallery.items.image.focalPoint.x" },
|
219
|
+
{ path: "gallery.items.image.focalPoint.y" },
|
220
|
+
{ path: "gallery.items.secondaryMedia.image.focalPoint.x" },
|
221
|
+
{ path: "gallery.items.secondaryMedia.image.focalPoint.y" },
|
222
|
+
{ path: "gallery.items.image.unsharpMasking.amount" },
|
223
|
+
{ path: "gallery.items.image.unsharpMasking.radius" },
|
224
|
+
{ path: "gallery.items.image.unsharpMasking.threshold" },
|
225
|
+
{
|
226
|
+
path: "gallery.items.secondaryMedia.image.unsharpMasking.amount"
|
227
|
+
},
|
228
|
+
{
|
229
|
+
path: "gallery.items.secondaryMedia.image.unsharpMasking.radius"
|
230
|
+
},
|
231
|
+
{
|
232
|
+
path: "gallery.items.secondaryMedia.image.unsharpMasking.threshold"
|
233
|
+
}
|
234
|
+
]
|
235
|
+
},
|
236
|
+
{
|
237
|
+
transformFn: import_timestamp2.transformRESTTimestampToSDKTimestamp,
|
238
|
+
paths: [
|
239
|
+
{ path: "gallery.createdDate" },
|
240
|
+
{ path: "gallery.items.createdDate" },
|
241
|
+
{ path: "gallery.items.updatedDate" },
|
242
|
+
{ path: "gallery.items.image.imageInfo.urlExpirationDate" },
|
243
|
+
{ path: "gallery.items.video.videoInfo.urlExpirationDate" },
|
244
|
+
{
|
245
|
+
path: "gallery.items.video.videoInfo.resolutions.poster.urlExpirationDate"
|
246
|
+
},
|
247
|
+
{
|
248
|
+
path: "gallery.items.video.videoInfo.posters.urlExpirationDate"
|
249
|
+
},
|
250
|
+
{
|
251
|
+
path: "gallery.items.secondaryMedia.image.imageInfo.urlExpirationDate"
|
252
|
+
}
|
253
|
+
]
|
254
|
+
}
|
255
|
+
])
|
256
|
+
};
|
257
|
+
return metadata;
|
258
|
+
}
|
259
|
+
return __getGallery;
|
260
|
+
}
|
261
|
+
function listGalleryItems(payload) {
|
262
|
+
function __listGalleryItems({ host }) {
|
263
|
+
const metadata = {
|
264
|
+
entityFqdn: "wix.pro_gallery.v2.gallery",
|
265
|
+
method: "GET",
|
266
|
+
methodFqn: "com.wixpress.exposure.progallery.ProGallery.ListGalleryItems",
|
267
|
+
packageName: PACKAGE_NAME,
|
268
|
+
url: resolveComWixpressExposureProgalleryProGalleryUrl({
|
269
|
+
protoPath: "/v2/galleries/{galleryId}/items",
|
270
|
+
data: payload,
|
271
|
+
host
|
272
|
+
}),
|
273
|
+
params: (0, import_rest_modules.toURLSearchParams)(payload),
|
274
|
+
transformResponse: (payload2) => (0, import_transform_paths.transformPaths)(payload2, [
|
275
|
+
{
|
276
|
+
transformFn: import_float2.transformRESTFloatToSDKFloat,
|
277
|
+
paths: [
|
278
|
+
{ path: "items.sortOrder" },
|
279
|
+
{ path: "items.image.focalPoint.x" },
|
280
|
+
{ path: "items.image.focalPoint.y" },
|
281
|
+
{ path: "items.secondaryMedia.image.focalPoint.x" },
|
282
|
+
{ path: "items.secondaryMedia.image.focalPoint.y" },
|
283
|
+
{ path: "items.image.unsharpMasking.amount" },
|
284
|
+
{ path: "items.image.unsharpMasking.radius" },
|
285
|
+
{ path: "items.image.unsharpMasking.threshold" },
|
286
|
+
{ path: "items.secondaryMedia.image.unsharpMasking.amount" },
|
287
|
+
{ path: "items.secondaryMedia.image.unsharpMasking.radius" },
|
288
|
+
{ path: "items.secondaryMedia.image.unsharpMasking.threshold" }
|
289
|
+
]
|
290
|
+
},
|
291
|
+
{
|
292
|
+
transformFn: import_timestamp2.transformRESTTimestampToSDKTimestamp,
|
293
|
+
paths: [
|
294
|
+
{ path: "items.createdDate" },
|
295
|
+
{ path: "items.updatedDate" },
|
296
|
+
{ path: "items.image.imageInfo.urlExpirationDate" },
|
297
|
+
{ path: "items.video.videoInfo.urlExpirationDate" },
|
298
|
+
{
|
299
|
+
path: "items.video.videoInfo.resolutions.poster.urlExpirationDate"
|
300
|
+
},
|
301
|
+
{ path: "items.video.videoInfo.posters.urlExpirationDate" },
|
302
|
+
{
|
303
|
+
path: "items.secondaryMedia.image.imageInfo.urlExpirationDate"
|
304
|
+
}
|
305
|
+
]
|
306
|
+
}
|
307
|
+
])
|
308
|
+
};
|
309
|
+
return metadata;
|
310
|
+
}
|
311
|
+
return __listGalleryItems;
|
312
|
+
}
|
313
|
+
function getGalleryItem(payload) {
|
314
|
+
function __getGalleryItem({ host }) {
|
315
|
+
const metadata = {
|
316
|
+
entityFqdn: "wix.pro_gallery.v2.gallery",
|
317
|
+
method: "GET",
|
318
|
+
methodFqn: "com.wixpress.exposure.progallery.ProGallery.GetGalleryItem",
|
319
|
+
packageName: PACKAGE_NAME,
|
320
|
+
url: resolveComWixpressExposureProgalleryProGalleryUrl({
|
321
|
+
protoPath: "/v2/galleries/{galleryId}/items/{itemId}",
|
322
|
+
data: payload,
|
323
|
+
host
|
324
|
+
}),
|
325
|
+
params: (0, import_rest_modules.toURLSearchParams)(payload),
|
326
|
+
transformResponse: (payload2) => (0, import_transform_paths.transformPaths)(payload2, [
|
327
|
+
{
|
328
|
+
transformFn: import_float2.transformRESTFloatToSDKFloat,
|
329
|
+
paths: [
|
330
|
+
{ path: "item.sortOrder" },
|
331
|
+
{ path: "item.image.focalPoint.x" },
|
332
|
+
{ path: "item.image.focalPoint.y" },
|
333
|
+
{ path: "item.secondaryMedia.image.focalPoint.x" },
|
334
|
+
{ path: "item.secondaryMedia.image.focalPoint.y" },
|
335
|
+
{ path: "item.image.unsharpMasking.amount" },
|
336
|
+
{ path: "item.image.unsharpMasking.radius" },
|
337
|
+
{ path: "item.image.unsharpMasking.threshold" },
|
338
|
+
{ path: "item.secondaryMedia.image.unsharpMasking.amount" },
|
339
|
+
{ path: "item.secondaryMedia.image.unsharpMasking.radius" },
|
340
|
+
{ path: "item.secondaryMedia.image.unsharpMasking.threshold" }
|
341
|
+
]
|
342
|
+
},
|
343
|
+
{
|
344
|
+
transformFn: import_timestamp2.transformRESTTimestampToSDKTimestamp,
|
345
|
+
paths: [
|
346
|
+
{ path: "item.createdDate" },
|
347
|
+
{ path: "item.updatedDate" },
|
348
|
+
{ path: "item.image.imageInfo.urlExpirationDate" },
|
349
|
+
{ path: "item.video.videoInfo.urlExpirationDate" },
|
350
|
+
{
|
351
|
+
path: "item.video.videoInfo.resolutions.poster.urlExpirationDate"
|
352
|
+
},
|
353
|
+
{ path: "item.video.videoInfo.posters.urlExpirationDate" },
|
354
|
+
{ path: "item.secondaryMedia.image.imageInfo.urlExpirationDate" }
|
355
|
+
]
|
356
|
+
}
|
357
|
+
])
|
358
|
+
};
|
359
|
+
return metadata;
|
360
|
+
}
|
361
|
+
return __getGalleryItem;
|
362
|
+
}
|
363
|
+
function createGallery(payload) {
|
364
|
+
function __createGallery({ host }) {
|
365
|
+
const serializedData = (0, import_transform_paths.transformPaths)(payload, [
|
366
|
+
{
|
367
|
+
transformFn: import_float.transformSDKFloatToRESTFloat,
|
368
|
+
paths: [
|
369
|
+
{ path: "gallery.sortOrder" },
|
370
|
+
{ path: "gallery.items.sortOrder" },
|
371
|
+
{ path: "gallery.items.image.focalPoint.x" },
|
372
|
+
{ path: "gallery.items.image.focalPoint.y" },
|
373
|
+
{ path: "gallery.items.secondaryMedia.image.focalPoint.x" },
|
374
|
+
{ path: "gallery.items.secondaryMedia.image.focalPoint.y" },
|
375
|
+
{ path: "gallery.items.image.unsharpMasking.amount" },
|
376
|
+
{ path: "gallery.items.image.unsharpMasking.radius" },
|
377
|
+
{ path: "gallery.items.image.unsharpMasking.threshold" },
|
378
|
+
{ path: "gallery.items.secondaryMedia.image.unsharpMasking.amount" },
|
379
|
+
{ path: "gallery.items.secondaryMedia.image.unsharpMasking.radius" },
|
380
|
+
{
|
381
|
+
path: "gallery.items.secondaryMedia.image.unsharpMasking.threshold"
|
382
|
+
}
|
383
|
+
]
|
384
|
+
},
|
385
|
+
{
|
386
|
+
transformFn: import_timestamp.transformSDKTimestampToRESTTimestamp,
|
387
|
+
paths: [
|
388
|
+
{ path: "gallery.createdDate" },
|
389
|
+
{ path: "gallery.items.createdDate" },
|
390
|
+
{ path: "gallery.items.updatedDate" },
|
391
|
+
{ path: "gallery.items.image.imageInfo.urlExpirationDate" },
|
392
|
+
{ path: "gallery.items.video.videoInfo.urlExpirationDate" },
|
393
|
+
{
|
394
|
+
path: "gallery.items.video.videoInfo.resolutions.poster.urlExpirationDate"
|
395
|
+
},
|
396
|
+
{ path: "gallery.items.video.videoInfo.posters.urlExpirationDate" },
|
397
|
+
{
|
398
|
+
path: "gallery.items.secondaryMedia.image.imageInfo.urlExpirationDate"
|
399
|
+
}
|
400
|
+
]
|
401
|
+
}
|
402
|
+
]);
|
403
|
+
const metadata = {
|
404
|
+
entityFqdn: "wix.pro_gallery.v2.gallery",
|
405
|
+
method: "POST",
|
406
|
+
methodFqn: "com.wixpress.exposure.progallery.ProGallery.CreateGallery",
|
407
|
+
packageName: PACKAGE_NAME,
|
408
|
+
url: resolveComWixpressExposureProgalleryProGalleryUrl({
|
409
|
+
protoPath: "/v2/galleries",
|
410
|
+
data: serializedData,
|
411
|
+
host
|
412
|
+
}),
|
413
|
+
data: serializedData,
|
414
|
+
transformResponse: (payload2) => (0, import_transform_paths.transformPaths)(payload2, [
|
415
|
+
{
|
416
|
+
transformFn: import_float2.transformRESTFloatToSDKFloat,
|
417
|
+
paths: [
|
418
|
+
{ path: "gallery.sortOrder" },
|
419
|
+
{ path: "gallery.items.sortOrder" },
|
420
|
+
{ path: "gallery.items.image.focalPoint.x" },
|
421
|
+
{ path: "gallery.items.image.focalPoint.y" },
|
422
|
+
{ path: "gallery.items.secondaryMedia.image.focalPoint.x" },
|
423
|
+
{ path: "gallery.items.secondaryMedia.image.focalPoint.y" },
|
424
|
+
{ path: "gallery.items.image.unsharpMasking.amount" },
|
425
|
+
{ path: "gallery.items.image.unsharpMasking.radius" },
|
426
|
+
{ path: "gallery.items.image.unsharpMasking.threshold" },
|
427
|
+
{
|
428
|
+
path: "gallery.items.secondaryMedia.image.unsharpMasking.amount"
|
429
|
+
},
|
430
|
+
{
|
431
|
+
path: "gallery.items.secondaryMedia.image.unsharpMasking.radius"
|
432
|
+
},
|
433
|
+
{
|
434
|
+
path: "gallery.items.secondaryMedia.image.unsharpMasking.threshold"
|
435
|
+
}
|
436
|
+
]
|
437
|
+
},
|
438
|
+
{
|
439
|
+
transformFn: import_timestamp2.transformRESTTimestampToSDKTimestamp,
|
440
|
+
paths: [
|
441
|
+
{ path: "gallery.createdDate" },
|
442
|
+
{ path: "gallery.items.createdDate" },
|
443
|
+
{ path: "gallery.items.updatedDate" },
|
444
|
+
{ path: "gallery.items.image.imageInfo.urlExpirationDate" },
|
445
|
+
{ path: "gallery.items.video.videoInfo.urlExpirationDate" },
|
446
|
+
{
|
447
|
+
path: "gallery.items.video.videoInfo.resolutions.poster.urlExpirationDate"
|
448
|
+
},
|
449
|
+
{
|
450
|
+
path: "gallery.items.video.videoInfo.posters.urlExpirationDate"
|
451
|
+
},
|
452
|
+
{
|
453
|
+
path: "gallery.items.secondaryMedia.image.imageInfo.urlExpirationDate"
|
454
|
+
}
|
455
|
+
]
|
456
|
+
}
|
457
|
+
])
|
458
|
+
};
|
459
|
+
return metadata;
|
460
|
+
}
|
461
|
+
return __createGallery;
|
462
|
+
}
|
463
|
+
function updateGallery(payload) {
|
464
|
+
function __updateGallery({ host }) {
|
465
|
+
const serializedData = (0, import_transform_paths.transformPaths)(payload, [
|
466
|
+
{
|
467
|
+
transformFn: import_float.transformSDKFloatToRESTFloat,
|
468
|
+
paths: [
|
469
|
+
{ path: "gallery.sortOrder" },
|
470
|
+
{ path: "gallery.items.sortOrder" },
|
471
|
+
{ path: "gallery.items.image.focalPoint.x" },
|
472
|
+
{ path: "gallery.items.image.focalPoint.y" },
|
473
|
+
{ path: "gallery.items.secondaryMedia.image.focalPoint.x" },
|
474
|
+
{ path: "gallery.items.secondaryMedia.image.focalPoint.y" },
|
475
|
+
{ path: "gallery.items.image.unsharpMasking.amount" },
|
476
|
+
{ path: "gallery.items.image.unsharpMasking.radius" },
|
477
|
+
{ path: "gallery.items.image.unsharpMasking.threshold" },
|
478
|
+
{ path: "gallery.items.secondaryMedia.image.unsharpMasking.amount" },
|
479
|
+
{ path: "gallery.items.secondaryMedia.image.unsharpMasking.radius" },
|
480
|
+
{
|
481
|
+
path: "gallery.items.secondaryMedia.image.unsharpMasking.threshold"
|
482
|
+
}
|
483
|
+
]
|
484
|
+
},
|
485
|
+
{
|
486
|
+
transformFn: import_timestamp.transformSDKTimestampToRESTTimestamp,
|
487
|
+
paths: [
|
488
|
+
{ path: "gallery.createdDate" },
|
489
|
+
{ path: "gallery.items.createdDate" },
|
490
|
+
{ path: "gallery.items.updatedDate" },
|
491
|
+
{ path: "gallery.items.image.imageInfo.urlExpirationDate" },
|
492
|
+
{ path: "gallery.items.video.videoInfo.urlExpirationDate" },
|
493
|
+
{
|
494
|
+
path: "gallery.items.video.videoInfo.resolutions.poster.urlExpirationDate"
|
495
|
+
},
|
496
|
+
{ path: "gallery.items.video.videoInfo.posters.urlExpirationDate" },
|
497
|
+
{
|
498
|
+
path: "gallery.items.secondaryMedia.image.imageInfo.urlExpirationDate"
|
499
|
+
}
|
500
|
+
]
|
501
|
+
}
|
502
|
+
]);
|
503
|
+
const metadata = {
|
504
|
+
entityFqdn: "wix.pro_gallery.v2.gallery",
|
505
|
+
method: "PATCH",
|
506
|
+
methodFqn: "com.wixpress.exposure.progallery.ProGallery.UpdateGallery",
|
507
|
+
packageName: PACKAGE_NAME,
|
508
|
+
url: resolveComWixpressExposureProgalleryProGalleryUrl({
|
509
|
+
protoPath: "/v2/galleries/{gallery.id}",
|
510
|
+
data: serializedData,
|
511
|
+
host
|
512
|
+
}),
|
513
|
+
data: serializedData,
|
514
|
+
transformResponse: (payload2) => (0, import_transform_paths.transformPaths)(payload2, [
|
515
|
+
{
|
516
|
+
transformFn: import_float2.transformRESTFloatToSDKFloat,
|
517
|
+
paths: [
|
518
|
+
{ path: "gallery.sortOrder" },
|
519
|
+
{ path: "gallery.items.sortOrder" },
|
520
|
+
{ path: "gallery.items.image.focalPoint.x" },
|
521
|
+
{ path: "gallery.items.image.focalPoint.y" },
|
522
|
+
{ path: "gallery.items.secondaryMedia.image.focalPoint.x" },
|
523
|
+
{ path: "gallery.items.secondaryMedia.image.focalPoint.y" },
|
524
|
+
{ path: "gallery.items.image.unsharpMasking.amount" },
|
525
|
+
{ path: "gallery.items.image.unsharpMasking.radius" },
|
526
|
+
{ path: "gallery.items.image.unsharpMasking.threshold" },
|
527
|
+
{
|
528
|
+
path: "gallery.items.secondaryMedia.image.unsharpMasking.amount"
|
529
|
+
},
|
530
|
+
{
|
531
|
+
path: "gallery.items.secondaryMedia.image.unsharpMasking.radius"
|
532
|
+
},
|
533
|
+
{
|
534
|
+
path: "gallery.items.secondaryMedia.image.unsharpMasking.threshold"
|
535
|
+
}
|
536
|
+
]
|
537
|
+
},
|
538
|
+
{
|
539
|
+
transformFn: import_timestamp2.transformRESTTimestampToSDKTimestamp,
|
540
|
+
paths: [
|
541
|
+
{ path: "gallery.createdDate" },
|
542
|
+
{ path: "gallery.items.createdDate" },
|
543
|
+
{ path: "gallery.items.updatedDate" },
|
544
|
+
{ path: "gallery.items.image.imageInfo.urlExpirationDate" },
|
545
|
+
{ path: "gallery.items.video.videoInfo.urlExpirationDate" },
|
546
|
+
{
|
547
|
+
path: "gallery.items.video.videoInfo.resolutions.poster.urlExpirationDate"
|
548
|
+
},
|
549
|
+
{
|
550
|
+
path: "gallery.items.video.videoInfo.posters.urlExpirationDate"
|
551
|
+
},
|
552
|
+
{
|
553
|
+
path: "gallery.items.secondaryMedia.image.imageInfo.urlExpirationDate"
|
554
|
+
}
|
555
|
+
]
|
556
|
+
}
|
557
|
+
])
|
558
|
+
};
|
559
|
+
return metadata;
|
560
|
+
}
|
561
|
+
return __updateGallery;
|
562
|
+
}
|
563
|
+
function deleteGallery(payload) {
|
564
|
+
function __deleteGallery({ host }) {
|
565
|
+
const metadata = {
|
566
|
+
entityFqdn: "wix.pro_gallery.v2.gallery",
|
567
|
+
method: "DELETE",
|
568
|
+
methodFqn: "com.wixpress.exposure.progallery.ProGallery.DeleteGallery",
|
569
|
+
packageName: PACKAGE_NAME,
|
570
|
+
url: resolveComWixpressExposureProgalleryProGalleryUrl({
|
571
|
+
protoPath: "/v2/galleries/{galleryId}",
|
572
|
+
data: payload,
|
573
|
+
host
|
574
|
+
}),
|
575
|
+
params: (0, import_rest_modules.toURLSearchParams)(payload)
|
576
|
+
};
|
577
|
+
return metadata;
|
578
|
+
}
|
579
|
+
return __deleteGallery;
|
580
|
+
}
|
581
|
+
function deleteGalleryItems(payload) {
|
582
|
+
function __deleteGalleryItems({ host }) {
|
583
|
+
const metadata = {
|
584
|
+
entityFqdn: "wix.pro_gallery.v2.gallery",
|
585
|
+
method: "DELETE",
|
586
|
+
methodFqn: "com.wixpress.exposure.progallery.ProGallery.DeleteGalleryItems",
|
587
|
+
packageName: PACKAGE_NAME,
|
588
|
+
url: resolveComWixpressExposureProgalleryProGalleryUrl({
|
589
|
+
protoPath: "/v2/galleries/{galleryId}/items",
|
590
|
+
data: payload,
|
591
|
+
host
|
592
|
+
}),
|
593
|
+
params: (0, import_rest_modules.toURLSearchParams)(payload),
|
594
|
+
transformResponse: (payload2) => (0, import_transform_paths.transformPaths)(payload2, [
|
595
|
+
{
|
596
|
+
transformFn: import_float2.transformRESTFloatToSDKFloat,
|
597
|
+
paths: [
|
598
|
+
{ path: "gallery.sortOrder" },
|
599
|
+
{ path: "gallery.items.sortOrder" },
|
600
|
+
{ path: "gallery.items.image.focalPoint.x" },
|
601
|
+
{ path: "gallery.items.image.focalPoint.y" },
|
602
|
+
{ path: "gallery.items.secondaryMedia.image.focalPoint.x" },
|
603
|
+
{ path: "gallery.items.secondaryMedia.image.focalPoint.y" },
|
604
|
+
{ path: "gallery.items.image.unsharpMasking.amount" },
|
605
|
+
{ path: "gallery.items.image.unsharpMasking.radius" },
|
606
|
+
{ path: "gallery.items.image.unsharpMasking.threshold" },
|
607
|
+
{
|
608
|
+
path: "gallery.items.secondaryMedia.image.unsharpMasking.amount"
|
609
|
+
},
|
610
|
+
{
|
611
|
+
path: "gallery.items.secondaryMedia.image.unsharpMasking.radius"
|
612
|
+
},
|
613
|
+
{
|
614
|
+
path: "gallery.items.secondaryMedia.image.unsharpMasking.threshold"
|
615
|
+
}
|
616
|
+
]
|
617
|
+
},
|
618
|
+
{
|
619
|
+
transformFn: import_timestamp2.transformRESTTimestampToSDKTimestamp,
|
620
|
+
paths: [
|
621
|
+
{ path: "gallery.createdDate" },
|
622
|
+
{ path: "gallery.items.createdDate" },
|
623
|
+
{ path: "gallery.items.updatedDate" },
|
624
|
+
{ path: "gallery.items.image.imageInfo.urlExpirationDate" },
|
625
|
+
{ path: "gallery.items.video.videoInfo.urlExpirationDate" },
|
626
|
+
{
|
627
|
+
path: "gallery.items.video.videoInfo.resolutions.poster.urlExpirationDate"
|
628
|
+
},
|
629
|
+
{
|
630
|
+
path: "gallery.items.video.videoInfo.posters.urlExpirationDate"
|
631
|
+
},
|
632
|
+
{
|
633
|
+
path: "gallery.items.secondaryMedia.image.imageInfo.urlExpirationDate"
|
634
|
+
}
|
635
|
+
]
|
636
|
+
}
|
637
|
+
])
|
638
|
+
};
|
639
|
+
return metadata;
|
640
|
+
}
|
641
|
+
return __deleteGalleryItems;
|
642
|
+
}
|
643
|
+
function bulkDeleteGalleryItems(payload) {
|
644
|
+
function __bulkDeleteGalleryItems({ host }) {
|
645
|
+
const metadata = {
|
646
|
+
entityFqdn: "wix.pro_gallery.v2.gallery",
|
647
|
+
method: "POST",
|
648
|
+
methodFqn: "com.wixpress.exposure.progallery.ProGallery.BulkDeleteGalleryItems",
|
649
|
+
packageName: PACKAGE_NAME,
|
650
|
+
url: resolveComWixpressExposureProgalleryProGalleryUrl({
|
651
|
+
protoPath: "/v2/galleries/{galleryId}/items/delete",
|
652
|
+
data: payload,
|
653
|
+
host
|
654
|
+
}),
|
655
|
+
data: payload
|
656
|
+
};
|
657
|
+
return metadata;
|
658
|
+
}
|
659
|
+
return __bulkDeleteGalleryItems;
|
660
|
+
}
|
661
|
+
function createGalleryItem(payload) {
|
662
|
+
function __createGalleryItem({ host }) {
|
663
|
+
const serializedData = (0, import_transform_paths.transformPaths)(payload, [
|
664
|
+
{
|
665
|
+
transformFn: import_float.transformSDKFloatToRESTFloat,
|
666
|
+
paths: [
|
667
|
+
{ path: "item.sortOrder" },
|
668
|
+
{ path: "item.image.focalPoint.x" },
|
669
|
+
{ path: "item.image.focalPoint.y" },
|
670
|
+
{ path: "item.secondaryMedia.image.focalPoint.x" },
|
671
|
+
{ path: "item.secondaryMedia.image.focalPoint.y" },
|
672
|
+
{ path: "item.image.unsharpMasking.amount" },
|
673
|
+
{ path: "item.image.unsharpMasking.radius" },
|
674
|
+
{ path: "item.image.unsharpMasking.threshold" },
|
675
|
+
{ path: "item.secondaryMedia.image.unsharpMasking.amount" },
|
676
|
+
{ path: "item.secondaryMedia.image.unsharpMasking.radius" },
|
677
|
+
{ path: "item.secondaryMedia.image.unsharpMasking.threshold" }
|
678
|
+
]
|
679
|
+
},
|
680
|
+
{
|
681
|
+
transformFn: import_timestamp.transformSDKTimestampToRESTTimestamp,
|
682
|
+
paths: [
|
683
|
+
{ path: "item.createdDate" },
|
684
|
+
{ path: "item.updatedDate" },
|
685
|
+
{ path: "item.image.imageInfo.urlExpirationDate" },
|
686
|
+
{ path: "item.video.videoInfo.urlExpirationDate" },
|
687
|
+
{ path: "item.video.videoInfo.resolutions.poster.urlExpirationDate" },
|
688
|
+
{ path: "item.video.videoInfo.posters.urlExpirationDate" },
|
689
|
+
{ path: "item.secondaryMedia.image.imageInfo.urlExpirationDate" }
|
690
|
+
]
|
691
|
+
}
|
692
|
+
]);
|
693
|
+
const metadata = {
|
694
|
+
entityFqdn: "wix.pro_gallery.v2.gallery",
|
695
|
+
method: "POST",
|
696
|
+
methodFqn: "com.wixpress.exposure.progallery.ProGallery.CreateGalleryItem",
|
697
|
+
packageName: PACKAGE_NAME,
|
698
|
+
url: resolveComWixpressExposureProgalleryProGalleryUrl({
|
699
|
+
protoPath: "/v2/galleries/{galleryId}/items",
|
700
|
+
data: serializedData,
|
701
|
+
host
|
702
|
+
}),
|
703
|
+
data: serializedData,
|
704
|
+
transformResponse: (payload2) => (0, import_transform_paths.transformPaths)(payload2, [
|
705
|
+
{
|
706
|
+
transformFn: import_float2.transformRESTFloatToSDKFloat,
|
707
|
+
paths: [
|
708
|
+
{ path: "item.sortOrder" },
|
709
|
+
{ path: "item.image.focalPoint.x" },
|
710
|
+
{ path: "item.image.focalPoint.y" },
|
711
|
+
{ path: "item.secondaryMedia.image.focalPoint.x" },
|
712
|
+
{ path: "item.secondaryMedia.image.focalPoint.y" },
|
713
|
+
{ path: "item.image.unsharpMasking.amount" },
|
714
|
+
{ path: "item.image.unsharpMasking.radius" },
|
715
|
+
{ path: "item.image.unsharpMasking.threshold" },
|
716
|
+
{ path: "item.secondaryMedia.image.unsharpMasking.amount" },
|
717
|
+
{ path: "item.secondaryMedia.image.unsharpMasking.radius" },
|
718
|
+
{ path: "item.secondaryMedia.image.unsharpMasking.threshold" }
|
719
|
+
]
|
720
|
+
},
|
721
|
+
{
|
722
|
+
transformFn: import_timestamp2.transformRESTTimestampToSDKTimestamp,
|
723
|
+
paths: [
|
724
|
+
{ path: "item.createdDate" },
|
725
|
+
{ path: "item.updatedDate" },
|
726
|
+
{ path: "item.image.imageInfo.urlExpirationDate" },
|
727
|
+
{ path: "item.video.videoInfo.urlExpirationDate" },
|
728
|
+
{
|
729
|
+
path: "item.video.videoInfo.resolutions.poster.urlExpirationDate"
|
730
|
+
},
|
731
|
+
{ path: "item.video.videoInfo.posters.urlExpirationDate" },
|
732
|
+
{ path: "item.secondaryMedia.image.imageInfo.urlExpirationDate" }
|
733
|
+
]
|
734
|
+
}
|
735
|
+
])
|
736
|
+
};
|
737
|
+
return metadata;
|
738
|
+
}
|
739
|
+
return __createGalleryItem;
|
740
|
+
}
|
741
|
+
function updateGalleryItem(payload) {
|
742
|
+
function __updateGalleryItem({ host }) {
|
743
|
+
const serializedData = (0, import_transform_paths.transformPaths)(payload, [
|
744
|
+
{
|
745
|
+
transformFn: import_float.transformSDKFloatToRESTFloat,
|
746
|
+
paths: [
|
747
|
+
{ path: "item.sortOrder" },
|
748
|
+
{ path: "item.image.focalPoint.x" },
|
749
|
+
{ path: "item.image.focalPoint.y" },
|
750
|
+
{ path: "item.secondaryMedia.image.focalPoint.x" },
|
751
|
+
{ path: "item.secondaryMedia.image.focalPoint.y" },
|
752
|
+
{ path: "item.image.unsharpMasking.amount" },
|
753
|
+
{ path: "item.image.unsharpMasking.radius" },
|
754
|
+
{ path: "item.image.unsharpMasking.threshold" },
|
755
|
+
{ path: "item.secondaryMedia.image.unsharpMasking.amount" },
|
756
|
+
{ path: "item.secondaryMedia.image.unsharpMasking.radius" },
|
757
|
+
{ path: "item.secondaryMedia.image.unsharpMasking.threshold" }
|
758
|
+
]
|
759
|
+
},
|
760
|
+
{
|
761
|
+
transformFn: import_timestamp.transformSDKTimestampToRESTTimestamp,
|
762
|
+
paths: [
|
763
|
+
{ path: "item.createdDate" },
|
764
|
+
{ path: "item.updatedDate" },
|
765
|
+
{ path: "item.image.imageInfo.urlExpirationDate" },
|
766
|
+
{ path: "item.video.videoInfo.urlExpirationDate" },
|
767
|
+
{ path: "item.video.videoInfo.resolutions.poster.urlExpirationDate" },
|
768
|
+
{ path: "item.video.videoInfo.posters.urlExpirationDate" },
|
769
|
+
{ path: "item.secondaryMedia.image.imageInfo.urlExpirationDate" }
|
770
|
+
]
|
771
|
+
}
|
772
|
+
]);
|
773
|
+
const metadata = {
|
774
|
+
entityFqdn: "wix.pro_gallery.v2.gallery",
|
775
|
+
method: "PATCH",
|
776
|
+
methodFqn: "com.wixpress.exposure.progallery.ProGallery.UpdateGalleryItem",
|
777
|
+
packageName: PACKAGE_NAME,
|
778
|
+
url: resolveComWixpressExposureProgalleryProGalleryUrl({
|
779
|
+
protoPath: "/v2/galleries/{galleryId}/items/{item.id}",
|
780
|
+
data: serializedData,
|
781
|
+
host
|
782
|
+
}),
|
783
|
+
data: serializedData,
|
784
|
+
transformResponse: (payload2) => (0, import_transform_paths.transformPaths)(payload2, [
|
785
|
+
{
|
786
|
+
transformFn: import_float2.transformRESTFloatToSDKFloat,
|
787
|
+
paths: [
|
788
|
+
{ path: "item.sortOrder" },
|
789
|
+
{ path: "item.image.focalPoint.x" },
|
790
|
+
{ path: "item.image.focalPoint.y" },
|
791
|
+
{ path: "item.secondaryMedia.image.focalPoint.x" },
|
792
|
+
{ path: "item.secondaryMedia.image.focalPoint.y" },
|
793
|
+
{ path: "item.image.unsharpMasking.amount" },
|
794
|
+
{ path: "item.image.unsharpMasking.radius" },
|
795
|
+
{ path: "item.image.unsharpMasking.threshold" },
|
796
|
+
{ path: "item.secondaryMedia.image.unsharpMasking.amount" },
|
797
|
+
{ path: "item.secondaryMedia.image.unsharpMasking.radius" },
|
798
|
+
{ path: "item.secondaryMedia.image.unsharpMasking.threshold" }
|
799
|
+
]
|
800
|
+
},
|
801
|
+
{
|
802
|
+
transformFn: import_timestamp2.transformRESTTimestampToSDKTimestamp,
|
803
|
+
paths: [
|
804
|
+
{ path: "item.createdDate" },
|
805
|
+
{ path: "item.updatedDate" },
|
806
|
+
{ path: "item.image.imageInfo.urlExpirationDate" },
|
807
|
+
{ path: "item.video.videoInfo.urlExpirationDate" },
|
808
|
+
{
|
809
|
+
path: "item.video.videoInfo.resolutions.poster.urlExpirationDate"
|
810
|
+
},
|
811
|
+
{ path: "item.video.videoInfo.posters.urlExpirationDate" },
|
812
|
+
{ path: "item.secondaryMedia.image.imageInfo.urlExpirationDate" }
|
813
|
+
]
|
814
|
+
}
|
815
|
+
])
|
816
|
+
};
|
817
|
+
return metadata;
|
818
|
+
}
|
819
|
+
return __updateGalleryItem;
|
820
|
+
}
|
821
|
+
function deleteGalleryItem(payload) {
|
822
|
+
function __deleteGalleryItem({ host }) {
|
823
|
+
const metadata = {
|
824
|
+
entityFqdn: "wix.pro_gallery.v2.gallery",
|
825
|
+
method: "DELETE",
|
826
|
+
methodFqn: "com.wixpress.exposure.progallery.ProGallery.DeleteGalleryItem",
|
827
|
+
packageName: PACKAGE_NAME,
|
828
|
+
url: resolveComWixpressExposureProgalleryProGalleryUrl({
|
829
|
+
protoPath: "/v2/galleries/{galleryId}/items/{itemId}",
|
830
|
+
data: payload,
|
831
|
+
host
|
832
|
+
}),
|
833
|
+
params: (0, import_rest_modules.toURLSearchParams)(payload)
|
834
|
+
};
|
835
|
+
return metadata;
|
836
|
+
}
|
837
|
+
return __deleteGalleryItem;
|
838
|
+
}
|
839
|
+
|
840
|
+
// src/pro-gallery-v2-gallery-pro-gallery.universal.ts
|
841
|
+
var import_image = require("@wix/sdk-runtime/transformations/image");
|
842
|
+
var import_image2 = require("@wix/sdk-runtime/transformations/image");
|
843
|
+
var import_video_v2 = require("@wix/sdk-runtime/transformations/video-v2");
|
844
|
+
var import_video_v22 = require("@wix/sdk-runtime/transformations/video-v2");
|
845
|
+
var import_transform_paths2 = require("@wix/sdk-runtime/transformations/transform-paths");
|
846
|
+
var LinkType = /* @__PURE__ */ ((LinkType2) => {
|
847
|
+
LinkType2["UNDEFINED"] = "UNDEFINED";
|
848
|
+
LinkType2["EXTERNAL"] = "EXTERNAL";
|
849
|
+
LinkType2["INTERNAL"] = "INTERNAL";
|
850
|
+
return LinkType2;
|
851
|
+
})(LinkType || {});
|
852
|
+
var LinkRel = /* @__PURE__ */ ((LinkRel2) => {
|
853
|
+
LinkRel2["unknown_link_rel"] = "unknown_link_rel";
|
854
|
+
LinkRel2["nofollow"] = "nofollow";
|
855
|
+
LinkRel2["noopener"] = "noopener";
|
856
|
+
LinkRel2["noreferrer"] = "noreferrer";
|
857
|
+
LinkRel2["sponsored"] = "sponsored";
|
858
|
+
return LinkRel2;
|
859
|
+
})(LinkRel || {});
|
860
|
+
var Type = /* @__PURE__ */ ((Type2) => {
|
861
|
+
Type2["UNDEFINED"] = "UNDEFINED";
|
862
|
+
Type2["IMAGE"] = "IMAGE";
|
863
|
+
Type2["VIDEO"] = "VIDEO";
|
864
|
+
Type2["TEXT"] = "TEXT";
|
865
|
+
return Type2;
|
866
|
+
})(Type || {});
|
867
|
+
var ImageType = /* @__PURE__ */ ((ImageType2) => {
|
868
|
+
ImageType2["UNDEFINED"] = "UNDEFINED";
|
869
|
+
ImageType2["WIX_MEDIA"] = "WIX_MEDIA";
|
870
|
+
ImageType2["EXTERNAL"] = "EXTERNAL";
|
871
|
+
return ImageType2;
|
872
|
+
})(ImageType || {});
|
873
|
+
var VideoType = /* @__PURE__ */ ((VideoType2) => {
|
874
|
+
VideoType2["UNDEFINED"] = "UNDEFINED";
|
875
|
+
VideoType2["WIX_MEDIA"] = "WIX_MEDIA";
|
876
|
+
VideoType2["YOUTUBE"] = "YOUTUBE";
|
877
|
+
VideoType2["VIMEO"] = "VIMEO";
|
878
|
+
return VideoType2;
|
879
|
+
})(VideoType || {});
|
880
|
+
var RCLabel = /* @__PURE__ */ ((RCLabel2) => {
|
881
|
+
RCLabel2["UNKNOWN"] = "UNKNOWN";
|
882
|
+
RCLabel2["RELEASE_MANAGER"] = "RELEASE_MANAGER";
|
883
|
+
RCLabel2["BLOCKS"] = "BLOCKS";
|
884
|
+
RCLabel2["WIX_CLI"] = "WIX_CLI";
|
885
|
+
RCLabel2["MOBILE_APP_BUILDER"] = "MOBILE_APP_BUILDER";
|
886
|
+
RCLabel2["SEO"] = "SEO";
|
887
|
+
RCLabel2["FEEDBACK"] = "FEEDBACK";
|
888
|
+
RCLabel2["ACCESSIBILITY"] = "ACCESSIBILITY";
|
889
|
+
RCLabel2["ENTERPRISE_APPROVALS"] = "ENTERPRISE_APPROVALS";
|
890
|
+
return RCLabel2;
|
891
|
+
})(RCLabel || {});
|
892
|
+
var WebhookIdentityType = /* @__PURE__ */ ((WebhookIdentityType2) => {
|
893
|
+
WebhookIdentityType2["UNKNOWN"] = "UNKNOWN";
|
894
|
+
WebhookIdentityType2["ANONYMOUS_VISITOR"] = "ANONYMOUS_VISITOR";
|
895
|
+
WebhookIdentityType2["MEMBER"] = "MEMBER";
|
896
|
+
WebhookIdentityType2["WIX_USER"] = "WIX_USER";
|
897
|
+
WebhookIdentityType2["APP"] = "APP";
|
898
|
+
return WebhookIdentityType2;
|
899
|
+
})(WebhookIdentityType || {});
|
900
|
+
var State = /* @__PURE__ */ ((State2) => {
|
901
|
+
State2["UNDEFINED"] = "UNDEFINED";
|
902
|
+
State2["SAVED"] = "SAVED";
|
903
|
+
State2["PUBLISHED"] = "PUBLISHED";
|
904
|
+
return State2;
|
905
|
+
})(State || {});
|
906
|
+
var Enum = /* @__PURE__ */ ((Enum2) => {
|
907
|
+
Enum2["UNKNOWN"] = "UNKNOWN";
|
908
|
+
Enum2["PROTECTED"] = "PROTECTED";
|
909
|
+
Enum2["PRIVATE"] = "PRIVATE";
|
910
|
+
Enum2["PUBLIC"] = "PUBLIC";
|
911
|
+
Enum2["UNCHANGED"] = "UNCHANGED";
|
912
|
+
Enum2["GROUP_PROTECTED"] = "GROUP_PROTECTED";
|
913
|
+
return Enum2;
|
914
|
+
})(Enum || {});
|
915
|
+
var SearchIndexingNotificationState = /* @__PURE__ */ ((SearchIndexingNotificationState2) => {
|
916
|
+
SearchIndexingNotificationState2["Unknown"] = "Unknown";
|
917
|
+
SearchIndexingNotificationState2["Off"] = "Off";
|
918
|
+
SearchIndexingNotificationState2["On"] = "On";
|
919
|
+
return SearchIndexingNotificationState2;
|
920
|
+
})(SearchIndexingNotificationState || {});
|
921
|
+
async function listGalleries2(options) {
|
922
|
+
const { httpClient, sideEffects } = arguments[1];
|
923
|
+
const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
|
924
|
+
itemLimit: options?.itemLimit,
|
925
|
+
offset: options?.offset,
|
926
|
+
limit: options?.limit
|
927
|
+
});
|
928
|
+
const reqOpts = listGalleries(payload);
|
929
|
+
sideEffects?.onSiteCall?.();
|
930
|
+
try {
|
931
|
+
const result = await httpClient.request(reqOpts);
|
932
|
+
sideEffects?.onSuccess?.(result);
|
933
|
+
return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(
|
934
|
+
(0, import_transform_paths2.transformPaths)(result.data, [
|
935
|
+
{
|
936
|
+
transformFn: import_image2.transformRESTImageToSDKImage,
|
937
|
+
paths: [
|
938
|
+
{ path: "galleries.items.image.imageInfo" },
|
939
|
+
{ path: "galleries.items.secondaryMedia.image.imageInfo" }
|
940
|
+
]
|
941
|
+
},
|
942
|
+
{
|
943
|
+
transformFn: import_video_v22.transformRESTVideoV2ToSDKVideoV2,
|
944
|
+
paths: [{ path: "galleries.items.video.videoInfo" }]
|
945
|
+
}
|
946
|
+
])
|
947
|
+
);
|
948
|
+
} catch (err) {
|
949
|
+
const transformedError = (0, import_transform_error.transformError)(
|
950
|
+
err,
|
951
|
+
{
|
952
|
+
spreadPathsToArguments: {},
|
953
|
+
explicitPathsToArguments: {
|
954
|
+
itemLimit: "$[0].itemLimit",
|
955
|
+
offset: "$[0].offset",
|
956
|
+
limit: "$[0].limit"
|
957
|
+
},
|
958
|
+
singleArgumentUnchanged: false
|
959
|
+
},
|
960
|
+
["options"]
|
961
|
+
);
|
962
|
+
sideEffects?.onError?.(err);
|
963
|
+
throw transformedError;
|
964
|
+
}
|
965
|
+
}
|
966
|
+
async function getGallery2(galleryId, options) {
|
967
|
+
const { httpClient, sideEffects } = arguments[2];
|
968
|
+
const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
|
969
|
+
galleryId,
|
970
|
+
itemOffset: options?.itemOffset,
|
971
|
+
itemLimit: options?.itemLimit
|
972
|
+
});
|
973
|
+
const reqOpts = getGallery(payload);
|
974
|
+
sideEffects?.onSiteCall?.();
|
975
|
+
try {
|
976
|
+
const result = await httpClient.request(reqOpts);
|
977
|
+
sideEffects?.onSuccess?.(result);
|
978
|
+
return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(
|
979
|
+
(0, import_transform_paths2.transformPaths)(result.data, [
|
980
|
+
{
|
981
|
+
transformFn: import_image2.transformRESTImageToSDKImage,
|
982
|
+
paths: [
|
983
|
+
{ path: "gallery.items.image.imageInfo" },
|
984
|
+
{ path: "gallery.items.secondaryMedia.image.imageInfo" }
|
985
|
+
]
|
986
|
+
},
|
987
|
+
{
|
988
|
+
transformFn: import_video_v22.transformRESTVideoV2ToSDKVideoV2,
|
989
|
+
paths: [{ path: "gallery.items.video.videoInfo" }]
|
990
|
+
}
|
991
|
+
])
|
992
|
+
)?.gallery;
|
993
|
+
} catch (err) {
|
994
|
+
const transformedError = (0, import_transform_error.transformError)(
|
995
|
+
err,
|
996
|
+
{
|
997
|
+
spreadPathsToArguments: {},
|
998
|
+
explicitPathsToArguments: {
|
999
|
+
galleryId: "$[0]",
|
1000
|
+
itemOffset: "$[1].itemOffset",
|
1001
|
+
itemLimit: "$[1].itemLimit"
|
1002
|
+
},
|
1003
|
+
singleArgumentUnchanged: false
|
1004
|
+
},
|
1005
|
+
["galleryId", "options"]
|
1006
|
+
);
|
1007
|
+
sideEffects?.onError?.(err);
|
1008
|
+
throw transformedError;
|
1009
|
+
}
|
1010
|
+
}
|
1011
|
+
async function listGalleryItems2(galleryId, options) {
|
1012
|
+
const { httpClient, sideEffects } = arguments[2];
|
1013
|
+
const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
|
1014
|
+
galleryId,
|
1015
|
+
itemOffset: options?.itemOffset,
|
1016
|
+
itemLimit: options?.itemLimit
|
1017
|
+
});
|
1018
|
+
const reqOpts = listGalleryItems(payload);
|
1019
|
+
sideEffects?.onSiteCall?.();
|
1020
|
+
try {
|
1021
|
+
const result = await httpClient.request(reqOpts);
|
1022
|
+
sideEffects?.onSuccess?.(result);
|
1023
|
+
return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(
|
1024
|
+
(0, import_transform_paths2.transformPaths)(result.data, [
|
1025
|
+
{
|
1026
|
+
transformFn: import_image2.transformRESTImageToSDKImage,
|
1027
|
+
paths: [
|
1028
|
+
{ path: "items.image.imageInfo" },
|
1029
|
+
{ path: "items.secondaryMedia.image.imageInfo" }
|
1030
|
+
]
|
1031
|
+
},
|
1032
|
+
{
|
1033
|
+
transformFn: import_video_v22.transformRESTVideoV2ToSDKVideoV2,
|
1034
|
+
paths: [{ path: "items.video.videoInfo" }]
|
1035
|
+
}
|
1036
|
+
])
|
1037
|
+
);
|
1038
|
+
} catch (err) {
|
1039
|
+
const transformedError = (0, import_transform_error.transformError)(
|
1040
|
+
err,
|
1041
|
+
{
|
1042
|
+
spreadPathsToArguments: {},
|
1043
|
+
explicitPathsToArguments: {
|
1044
|
+
galleryId: "$[0]",
|
1045
|
+
itemOffset: "$[1].itemOffset",
|
1046
|
+
itemLimit: "$[1].itemLimit"
|
1047
|
+
},
|
1048
|
+
singleArgumentUnchanged: false
|
1049
|
+
},
|
1050
|
+
["galleryId", "options"]
|
1051
|
+
);
|
1052
|
+
sideEffects?.onError?.(err);
|
1053
|
+
throw transformedError;
|
1054
|
+
}
|
1055
|
+
}
|
1056
|
+
async function getGalleryItem2(identifiers) {
|
1057
|
+
const { httpClient, sideEffects } = arguments[1];
|
1058
|
+
const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
|
1059
|
+
galleryId: identifiers?.galleryId,
|
1060
|
+
itemId: identifiers?.itemId
|
1061
|
+
});
|
1062
|
+
const reqOpts = getGalleryItem(payload);
|
1063
|
+
sideEffects?.onSiteCall?.();
|
1064
|
+
try {
|
1065
|
+
const result = await httpClient.request(reqOpts);
|
1066
|
+
sideEffects?.onSuccess?.(result);
|
1067
|
+
return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(
|
1068
|
+
(0, import_transform_paths2.transformPaths)(result.data, [
|
1069
|
+
{
|
1070
|
+
transformFn: import_image2.transformRESTImageToSDKImage,
|
1071
|
+
paths: [
|
1072
|
+
{ path: "item.image.imageInfo" },
|
1073
|
+
{ path: "item.secondaryMedia.image.imageInfo" }
|
1074
|
+
]
|
1075
|
+
},
|
1076
|
+
{
|
1077
|
+
transformFn: import_video_v22.transformRESTVideoV2ToSDKVideoV2,
|
1078
|
+
paths: [{ path: "item.video.videoInfo" }]
|
1079
|
+
}
|
1080
|
+
])
|
1081
|
+
)?.item;
|
1082
|
+
} catch (err) {
|
1083
|
+
const transformedError = (0, import_transform_error.transformError)(
|
1084
|
+
err,
|
1085
|
+
{
|
1086
|
+
spreadPathsToArguments: {},
|
1087
|
+
explicitPathsToArguments: {
|
1088
|
+
galleryId: "$[0].galleryId",
|
1089
|
+
itemId: "$[0].itemId"
|
1090
|
+
},
|
1091
|
+
singleArgumentUnchanged: false
|
1092
|
+
},
|
1093
|
+
["identifiers"]
|
1094
|
+
);
|
1095
|
+
sideEffects?.onError?.(err);
|
1096
|
+
throw transformedError;
|
1097
|
+
}
|
1098
|
+
}
|
1099
|
+
async function createGallery2(options) {
|
1100
|
+
const { httpClient, sideEffects } = arguments[1];
|
1101
|
+
const payload = (0, import_transform_paths2.transformPaths)(
|
1102
|
+
(0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
|
1103
|
+
gallery: options?.gallery,
|
1104
|
+
cloneFromGalleryId: options?.cloneFromGalleryId
|
1105
|
+
}),
|
1106
|
+
[
|
1107
|
+
{
|
1108
|
+
transformFn: import_image.transformSDKImageToRESTImage,
|
1109
|
+
paths: [
|
1110
|
+
{ path: "gallery.items.image.imageInfo" },
|
1111
|
+
{ path: "gallery.items.secondaryMedia.image.imageInfo" }
|
1112
|
+
]
|
1113
|
+
},
|
1114
|
+
{
|
1115
|
+
transformFn: import_video_v2.transformSDKVideoV2ToRESTVideoV2,
|
1116
|
+
paths: [{ path: "gallery.items.video.videoInfo" }]
|
1117
|
+
}
|
1118
|
+
]
|
1119
|
+
);
|
1120
|
+
const reqOpts = createGallery(payload);
|
1121
|
+
sideEffects?.onSiteCall?.();
|
1122
|
+
try {
|
1123
|
+
const result = await httpClient.request(reqOpts);
|
1124
|
+
sideEffects?.onSuccess?.(result);
|
1125
|
+
return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(
|
1126
|
+
(0, import_transform_paths2.transformPaths)(result.data, [
|
1127
|
+
{
|
1128
|
+
transformFn: import_image2.transformRESTImageToSDKImage,
|
1129
|
+
paths: [
|
1130
|
+
{ path: "gallery.items.image.imageInfo" },
|
1131
|
+
{ path: "gallery.items.secondaryMedia.image.imageInfo" }
|
1132
|
+
]
|
1133
|
+
},
|
1134
|
+
{
|
1135
|
+
transformFn: import_video_v22.transformRESTVideoV2ToSDKVideoV2,
|
1136
|
+
paths: [{ path: "gallery.items.video.videoInfo" }]
|
1137
|
+
}
|
1138
|
+
])
|
1139
|
+
)?.gallery;
|
1140
|
+
} catch (err) {
|
1141
|
+
const transformedError = (0, import_transform_error.transformError)(
|
1142
|
+
err,
|
1143
|
+
{
|
1144
|
+
spreadPathsToArguments: {},
|
1145
|
+
explicitPathsToArguments: {
|
1146
|
+
gallery: "$[0].gallery",
|
1147
|
+
cloneFromGalleryId: "$[0].cloneFromGalleryId"
|
1148
|
+
},
|
1149
|
+
singleArgumentUnchanged: false
|
1150
|
+
},
|
1151
|
+
["options"]
|
1152
|
+
);
|
1153
|
+
sideEffects?.onError?.(err);
|
1154
|
+
throw transformedError;
|
1155
|
+
}
|
1156
|
+
}
|
1157
|
+
async function updateGallery2(_id, gallery) {
|
1158
|
+
const { httpClient, sideEffects } = arguments[2];
|
1159
|
+
const payload = (0, import_transform_paths2.transformPaths)(
|
1160
|
+
(0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({ gallery: { ...gallery, id: _id } }),
|
1161
|
+
[
|
1162
|
+
{
|
1163
|
+
transformFn: import_image.transformSDKImageToRESTImage,
|
1164
|
+
paths: [
|
1165
|
+
{ path: "gallery.items.image.imageInfo" },
|
1166
|
+
{ path: "gallery.items.secondaryMedia.image.imageInfo" }
|
1167
|
+
]
|
1168
|
+
},
|
1169
|
+
{
|
1170
|
+
transformFn: import_video_v2.transformSDKVideoV2ToRESTVideoV2,
|
1171
|
+
paths: [{ path: "gallery.items.video.videoInfo" }]
|
1172
|
+
}
|
1173
|
+
]
|
1174
|
+
);
|
1175
|
+
const reqOpts = updateGallery(payload);
|
1176
|
+
sideEffects?.onSiteCall?.();
|
1177
|
+
try {
|
1178
|
+
const result = await httpClient.request(reqOpts);
|
1179
|
+
sideEffects?.onSuccess?.(result);
|
1180
|
+
return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(
|
1181
|
+
(0, import_transform_paths2.transformPaths)(result.data, [
|
1182
|
+
{
|
1183
|
+
transformFn: import_image2.transformRESTImageToSDKImage,
|
1184
|
+
paths: [
|
1185
|
+
{ path: "gallery.items.image.imageInfo" },
|
1186
|
+
{ path: "gallery.items.secondaryMedia.image.imageInfo" }
|
1187
|
+
]
|
1188
|
+
},
|
1189
|
+
{
|
1190
|
+
transformFn: import_video_v22.transformRESTVideoV2ToSDKVideoV2,
|
1191
|
+
paths: [{ path: "gallery.items.video.videoInfo" }]
|
1192
|
+
}
|
1193
|
+
])
|
1194
|
+
)?.gallery;
|
1195
|
+
} catch (err) {
|
1196
|
+
const transformedError = (0, import_transform_error.transformError)(
|
1197
|
+
err,
|
1198
|
+
{
|
1199
|
+
spreadPathsToArguments: { gallery: "$[1]" },
|
1200
|
+
explicitPathsToArguments: { "gallery.id": "$[0]" },
|
1201
|
+
singleArgumentUnchanged: false
|
1202
|
+
},
|
1203
|
+
["_id", "gallery"]
|
1204
|
+
);
|
1205
|
+
sideEffects?.onError?.(err);
|
1206
|
+
throw transformedError;
|
1207
|
+
}
|
1208
|
+
}
|
1209
|
+
async function deleteGallery2(galleryId) {
|
1210
|
+
const { httpClient, sideEffects } = arguments[1];
|
1211
|
+
const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
|
1212
|
+
galleryId
|
1213
|
+
});
|
1214
|
+
const reqOpts = deleteGallery(payload);
|
1215
|
+
sideEffects?.onSiteCall?.();
|
1216
|
+
try {
|
1217
|
+
const result = await httpClient.request(reqOpts);
|
1218
|
+
sideEffects?.onSuccess?.(result);
|
1219
|
+
return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(result.data);
|
1220
|
+
} catch (err) {
|
1221
|
+
const transformedError = (0, import_transform_error.transformError)(
|
1222
|
+
err,
|
1223
|
+
{
|
1224
|
+
spreadPathsToArguments: {},
|
1225
|
+
explicitPathsToArguments: { galleryId: "$[0]" },
|
1226
|
+
singleArgumentUnchanged: false
|
1227
|
+
},
|
1228
|
+
["galleryId"]
|
1229
|
+
);
|
1230
|
+
sideEffects?.onError?.(err);
|
1231
|
+
throw transformedError;
|
1232
|
+
}
|
1233
|
+
}
|
1234
|
+
async function deleteGalleryItems2(galleryId, options) {
|
1235
|
+
const { httpClient, sideEffects } = arguments[2];
|
1236
|
+
const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
|
1237
|
+
galleryId,
|
1238
|
+
itemsIds: options?.itemsIds
|
1239
|
+
});
|
1240
|
+
const reqOpts = deleteGalleryItems(payload);
|
1241
|
+
sideEffects?.onSiteCall?.();
|
1242
|
+
try {
|
1243
|
+
const result = await httpClient.request(reqOpts);
|
1244
|
+
sideEffects?.onSuccess?.(result);
|
1245
|
+
return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(
|
1246
|
+
(0, import_transform_paths2.transformPaths)(result.data, [
|
1247
|
+
{
|
1248
|
+
transformFn: import_image2.transformRESTImageToSDKImage,
|
1249
|
+
paths: [
|
1250
|
+
{ path: "gallery.items.image.imageInfo" },
|
1251
|
+
{ path: "gallery.items.secondaryMedia.image.imageInfo" }
|
1252
|
+
]
|
1253
|
+
},
|
1254
|
+
{
|
1255
|
+
transformFn: import_video_v22.transformRESTVideoV2ToSDKVideoV2,
|
1256
|
+
paths: [{ path: "gallery.items.video.videoInfo" }]
|
1257
|
+
}
|
1258
|
+
])
|
1259
|
+
);
|
1260
|
+
} catch (err) {
|
1261
|
+
const transformedError = (0, import_transform_error.transformError)(
|
1262
|
+
err,
|
1263
|
+
{
|
1264
|
+
spreadPathsToArguments: {},
|
1265
|
+
explicitPathsToArguments: {
|
1266
|
+
galleryId: "$[0]",
|
1267
|
+
itemsIds: "$[1].itemsIds"
|
1268
|
+
},
|
1269
|
+
singleArgumentUnchanged: false
|
1270
|
+
},
|
1271
|
+
["galleryId", "options"]
|
1272
|
+
);
|
1273
|
+
sideEffects?.onError?.(err);
|
1274
|
+
throw transformedError;
|
1275
|
+
}
|
1276
|
+
}
|
1277
|
+
async function bulkDeleteGalleryItems2(galleryId, itemIds) {
|
1278
|
+
const { httpClient, sideEffects } = arguments[2];
|
1279
|
+
const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
|
1280
|
+
galleryId,
|
1281
|
+
itemIds
|
1282
|
+
});
|
1283
|
+
const reqOpts = bulkDeleteGalleryItems(payload);
|
1284
|
+
sideEffects?.onSiteCall?.();
|
1285
|
+
try {
|
1286
|
+
const result = await httpClient.request(reqOpts);
|
1287
|
+
sideEffects?.onSuccess?.(result);
|
1288
|
+
return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(result.data);
|
1289
|
+
} catch (err) {
|
1290
|
+
const transformedError = (0, import_transform_error.transformError)(
|
1291
|
+
err,
|
1292
|
+
{
|
1293
|
+
spreadPathsToArguments: {},
|
1294
|
+
explicitPathsToArguments: { galleryId: "$[0]", itemIds: "$[1]" },
|
1295
|
+
singleArgumentUnchanged: false
|
1296
|
+
},
|
1297
|
+
["galleryId", "itemIds"]
|
1298
|
+
);
|
1299
|
+
sideEffects?.onError?.(err);
|
1300
|
+
throw transformedError;
|
1301
|
+
}
|
1302
|
+
}
|
1303
|
+
async function createGalleryItem2(galleryId, item) {
|
1304
|
+
const { httpClient, sideEffects } = arguments[2];
|
1305
|
+
const payload = (0, import_transform_paths2.transformPaths)(
|
1306
|
+
(0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({ galleryId, item }),
|
1307
|
+
[
|
1308
|
+
{
|
1309
|
+
transformFn: import_image.transformSDKImageToRESTImage,
|
1310
|
+
paths: [
|
1311
|
+
{ path: "item.image.imageInfo" },
|
1312
|
+
{ path: "item.secondaryMedia.image.imageInfo" }
|
1313
|
+
]
|
1314
|
+
},
|
1315
|
+
{
|
1316
|
+
transformFn: import_video_v2.transformSDKVideoV2ToRESTVideoV2,
|
1317
|
+
paths: [{ path: "item.video.videoInfo" }]
|
1318
|
+
}
|
1319
|
+
]
|
1320
|
+
);
|
1321
|
+
const reqOpts = createGalleryItem(payload);
|
1322
|
+
sideEffects?.onSiteCall?.();
|
1323
|
+
try {
|
1324
|
+
const result = await httpClient.request(reqOpts);
|
1325
|
+
sideEffects?.onSuccess?.(result);
|
1326
|
+
return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(
|
1327
|
+
(0, import_transform_paths2.transformPaths)(result.data, [
|
1328
|
+
{
|
1329
|
+
transformFn: import_image2.transformRESTImageToSDKImage,
|
1330
|
+
paths: [
|
1331
|
+
{ path: "item.image.imageInfo" },
|
1332
|
+
{ path: "item.secondaryMedia.image.imageInfo" }
|
1333
|
+
]
|
1334
|
+
},
|
1335
|
+
{
|
1336
|
+
transformFn: import_video_v22.transformRESTVideoV2ToSDKVideoV2,
|
1337
|
+
paths: [{ path: "item.video.videoInfo" }]
|
1338
|
+
}
|
1339
|
+
])
|
1340
|
+
)?.item;
|
1341
|
+
} catch (err) {
|
1342
|
+
const transformedError = (0, import_transform_error.transformError)(
|
1343
|
+
err,
|
1344
|
+
{
|
1345
|
+
spreadPathsToArguments: {},
|
1346
|
+
explicitPathsToArguments: { galleryId: "$[0]", item: "$[1]" },
|
1347
|
+
singleArgumentUnchanged: false
|
1348
|
+
},
|
1349
|
+
["galleryId", "item"]
|
1350
|
+
);
|
1351
|
+
sideEffects?.onError?.(err);
|
1352
|
+
throw transformedError;
|
1353
|
+
}
|
1354
|
+
}
|
1355
|
+
async function updateGalleryItem2(identifiers, item) {
|
1356
|
+
const { httpClient, sideEffects } = arguments[2];
|
1357
|
+
const payload = (0, import_transform_paths2.transformPaths)(
|
1358
|
+
(0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
|
1359
|
+
galleryId: identifiers?.galleryId,
|
1360
|
+
item: { ...item, id: identifiers?.itemId }
|
1361
|
+
}),
|
1362
|
+
[
|
1363
|
+
{
|
1364
|
+
transformFn: import_image.transformSDKImageToRESTImage,
|
1365
|
+
paths: [
|
1366
|
+
{ path: "item.image.imageInfo" },
|
1367
|
+
{ path: "item.secondaryMedia.image.imageInfo" }
|
1368
|
+
]
|
1369
|
+
},
|
1370
|
+
{
|
1371
|
+
transformFn: import_video_v2.transformSDKVideoV2ToRESTVideoV2,
|
1372
|
+
paths: [{ path: "item.video.videoInfo" }]
|
1373
|
+
}
|
1374
|
+
]
|
1375
|
+
);
|
1376
|
+
const reqOpts = updateGalleryItem(payload);
|
1377
|
+
sideEffects?.onSiteCall?.();
|
1378
|
+
try {
|
1379
|
+
const result = await httpClient.request(reqOpts);
|
1380
|
+
sideEffects?.onSuccess?.(result);
|
1381
|
+
return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(
|
1382
|
+
(0, import_transform_paths2.transformPaths)(result.data, [
|
1383
|
+
{
|
1384
|
+
transformFn: import_image2.transformRESTImageToSDKImage,
|
1385
|
+
paths: [
|
1386
|
+
{ path: "item.image.imageInfo" },
|
1387
|
+
{ path: "item.secondaryMedia.image.imageInfo" }
|
1388
|
+
]
|
1389
|
+
},
|
1390
|
+
{
|
1391
|
+
transformFn: import_video_v22.transformRESTVideoV2ToSDKVideoV2,
|
1392
|
+
paths: [{ path: "item.video.videoInfo" }]
|
1393
|
+
}
|
1394
|
+
])
|
1395
|
+
)?.item;
|
1396
|
+
} catch (err) {
|
1397
|
+
const transformedError = (0, import_transform_error.transformError)(
|
1398
|
+
err,
|
1399
|
+
{
|
1400
|
+
spreadPathsToArguments: { item: "$[1]" },
|
1401
|
+
explicitPathsToArguments: {
|
1402
|
+
galleryId: "$[0].galleryId",
|
1403
|
+
"item.id": "$[0].itemId"
|
1404
|
+
},
|
1405
|
+
singleArgumentUnchanged: false
|
1406
|
+
},
|
1407
|
+
["identifiers", "item"]
|
1408
|
+
);
|
1409
|
+
sideEffects?.onError?.(err);
|
1410
|
+
throw transformedError;
|
1411
|
+
}
|
1412
|
+
}
|
1413
|
+
async function deleteGalleryItem2(identifiers) {
|
1414
|
+
const { httpClient, sideEffects } = arguments[1];
|
1415
|
+
const payload = (0, import_rename_all_nested_keys.renameKeysFromSDKRequestToRESTRequest)({
|
1416
|
+
galleryId: identifiers?.galleryId,
|
1417
|
+
itemId: identifiers?.itemId
|
1418
|
+
});
|
1419
|
+
const reqOpts = deleteGalleryItem(payload);
|
1420
|
+
sideEffects?.onSiteCall?.();
|
1421
|
+
try {
|
1422
|
+
const result = await httpClient.request(reqOpts);
|
1423
|
+
sideEffects?.onSuccess?.(result);
|
1424
|
+
return (0, import_rename_all_nested_keys.renameKeysFromRESTResponseToSDKResponse)(result.data);
|
1425
|
+
} catch (err) {
|
1426
|
+
const transformedError = (0, import_transform_error.transformError)(
|
1427
|
+
err,
|
1428
|
+
{
|
1429
|
+
spreadPathsToArguments: {},
|
1430
|
+
explicitPathsToArguments: {
|
1431
|
+
galleryId: "$[0].galleryId",
|
1432
|
+
itemId: "$[0].itemId"
|
1433
|
+
},
|
1434
|
+
singleArgumentUnchanged: false
|
1435
|
+
},
|
1436
|
+
["identifiers"]
|
1437
|
+
);
|
1438
|
+
sideEffects?.onError?.(err);
|
1439
|
+
throw transformedError;
|
1440
|
+
}
|
1441
|
+
}
|
1442
|
+
// Annotate the CommonJS export names for ESM import in node:
|
1443
|
+
0 && (module.exports = {
|
1444
|
+
Enum,
|
1445
|
+
ImageType,
|
1446
|
+
LinkRel,
|
1447
|
+
LinkType,
|
1448
|
+
RCLabel,
|
1449
|
+
SearchIndexingNotificationState,
|
1450
|
+
State,
|
1451
|
+
Type,
|
1452
|
+
VideoType,
|
1453
|
+
WebhookIdentityType,
|
1454
|
+
bulkDeleteGalleryItems,
|
1455
|
+
createGallery,
|
1456
|
+
createGalleryItem,
|
1457
|
+
deleteGallery,
|
1458
|
+
deleteGalleryItem,
|
1459
|
+
deleteGalleryItems,
|
1460
|
+
getGallery,
|
1461
|
+
getGalleryItem,
|
1462
|
+
listGalleries,
|
1463
|
+
listGalleryItems,
|
1464
|
+
updateGallery,
|
1465
|
+
updateGalleryItem
|
1466
|
+
});
|
1467
|
+
//# sourceMappingURL=index.typings.js.map
|