@wix/auto_sdk_online-programs_programs 1.0.30 → 1.0.31
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/package.json +4 -11
- package/build/cjs/schemas.d.ts +0 -1895
- package/build/cjs/schemas.js +0 -3177
- package/build/cjs/schemas.js.map +0 -1
- package/build/es/schemas.d.mts +0 -1895
- package/build/es/schemas.mjs +0 -3115
- package/build/es/schemas.mjs.map +0 -1
- package/build/internal/cjs/index.js +0 -1935
- package/build/internal/cjs/index.js.map +0 -1
- package/build/internal/cjs/index.typings.js +0 -1809
- package/build/internal/cjs/index.typings.js.map +0 -1
- package/build/internal/cjs/meta.js +0 -1436
- package/build/internal/cjs/meta.js.map +0 -1
- package/build/internal/cjs/schemas.d.ts +0 -1895
- package/build/internal/cjs/schemas.js +0 -3177
- package/build/internal/cjs/schemas.js.map +0 -1
- package/build/internal/es/index.mjs +0 -1875
- package/build/internal/es/index.mjs.map +0 -1
- package/build/internal/es/index.typings.mjs +0 -1748
- package/build/internal/es/index.typings.mjs.map +0 -1
- package/build/internal/es/meta.mjs +0 -1374
- package/build/internal/es/meta.mjs.map +0 -1
- package/build/internal/es/schemas.d.mts +0 -1895
- package/build/internal/es/schemas.mjs +0 -3115
- package/build/internal/es/schemas.mjs.map +0 -1
- package/schemas/package.json +0 -3
|
@@ -1,1875 +0,0 @@
|
|
|
1
|
-
// src/online-programs-v3-program-programs.universal.ts
|
|
2
|
-
import { transformError as sdkTransformError } from "@wix/sdk-runtime/transform-error";
|
|
3
|
-
import { queryBuilder } from "@wix/sdk-runtime/query-builder";
|
|
4
|
-
import {
|
|
5
|
-
renameKeysFromSDKRequestToRESTRequest,
|
|
6
|
-
renameKeysFromRESTResponseToSDKResponse
|
|
7
|
-
} from "@wix/sdk-runtime/rename-all-nested-keys";
|
|
8
|
-
|
|
9
|
-
// src/online-programs-v3-program-programs.http.ts
|
|
10
|
-
import { toURLSearchParams } from "@wix/sdk-runtime/rest-modules";
|
|
11
|
-
import { transformSDKFloatToRESTFloat } from "@wix/sdk-runtime/transformations/float";
|
|
12
|
-
import { transformRESTFloatToSDKFloat } from "@wix/sdk-runtime/transformations/float";
|
|
13
|
-
import { transformSDKTimestampToRESTTimestamp } from "@wix/sdk-runtime/transformations/timestamp";
|
|
14
|
-
import { transformRESTTimestampToSDKTimestamp } from "@wix/sdk-runtime/transformations/timestamp";
|
|
15
|
-
import { transformSDKFieldMaskToRESTFieldMask } from "@wix/sdk-runtime/transformations/field-mask";
|
|
16
|
-
import { transformPaths } from "@wix/sdk-runtime/transformations/transform-paths";
|
|
17
|
-
import { resolveUrl } from "@wix/sdk-runtime/rest-modules";
|
|
18
|
-
function resolveWixOnlineprogramsProgramsV3ProgramsServiceUrl(opts) {
|
|
19
|
-
const domainToMappings = {
|
|
20
|
-
"manage._base_domain_": [
|
|
21
|
-
{
|
|
22
|
-
srcPath: "/_api/programs-service",
|
|
23
|
-
destPath: ""
|
|
24
|
-
}
|
|
25
|
-
],
|
|
26
|
-
_: [
|
|
27
|
-
{
|
|
28
|
-
srcPath: "/_api/programs-service",
|
|
29
|
-
destPath: ""
|
|
30
|
-
}
|
|
31
|
-
],
|
|
32
|
-
"editor.wixapps.net": [
|
|
33
|
-
{
|
|
34
|
-
srcPath: "/_api/programs-service",
|
|
35
|
-
destPath: ""
|
|
36
|
-
}
|
|
37
|
-
],
|
|
38
|
-
"www.wixapis.com": [
|
|
39
|
-
{
|
|
40
|
-
srcPath: "/_api/programs-service",
|
|
41
|
-
destPath: ""
|
|
42
|
-
},
|
|
43
|
-
{
|
|
44
|
-
srcPath: "/online-programs/v3/programs",
|
|
45
|
-
destPath: "/v3/programs"
|
|
46
|
-
},
|
|
47
|
-
{
|
|
48
|
-
srcPath: "/online-programs/v3/bulk/programs",
|
|
49
|
-
destPath: "/v3/bulk/programs"
|
|
50
|
-
}
|
|
51
|
-
],
|
|
52
|
-
"*.dev.wix-code.com": [
|
|
53
|
-
{
|
|
54
|
-
srcPath: "/online-programs/v3/programs",
|
|
55
|
-
destPath: "/v3/programs"
|
|
56
|
-
},
|
|
57
|
-
{
|
|
58
|
-
srcPath: "/online-programs/v3/bulk/programs",
|
|
59
|
-
destPath: "/v3/bulk/programs"
|
|
60
|
-
}
|
|
61
|
-
]
|
|
62
|
-
};
|
|
63
|
-
return resolveUrl(Object.assign(opts, { domainToMappings }));
|
|
64
|
-
}
|
|
65
|
-
var PACKAGE_NAME = "@wix/auto_sdk_online-programs_programs";
|
|
66
|
-
function createProgram(payload) {
|
|
67
|
-
function __createProgram({ host }) {
|
|
68
|
-
const serializedData = transformPaths(payload, [
|
|
69
|
-
{
|
|
70
|
-
transformFn: transformSDKTimestampToRESTTimestamp,
|
|
71
|
-
paths: [
|
|
72
|
-
{ path: "program.createdDate" },
|
|
73
|
-
{ path: "program.updatedDate" },
|
|
74
|
-
{ path: "program.statusUpdatedDate" },
|
|
75
|
-
{ path: "program.description.image.urlExpirationDate" },
|
|
76
|
-
{ path: "program.description.video.urlExpirationDate" },
|
|
77
|
-
{ path: "program.description.video.resolutions.urlExpirationDate" },
|
|
78
|
-
{
|
|
79
|
-
path: "program.description.video.resolutions.poster.urlExpirationDate"
|
|
80
|
-
},
|
|
81
|
-
{ path: "program.description.video.posters.urlExpirationDate" },
|
|
82
|
-
{ path: "program.rewards.certificate.connectedDate" }
|
|
83
|
-
]
|
|
84
|
-
},
|
|
85
|
-
{
|
|
86
|
-
transformFn: transformSDKFloatToRESTFloat,
|
|
87
|
-
paths: [
|
|
88
|
-
{ path: "program.description.image.focalPoint.x" },
|
|
89
|
-
{ path: "program.description.image.focalPoint.y" },
|
|
90
|
-
{ path: "program.description.video.resolutions.poster.focalPoint.x" },
|
|
91
|
-
{ path: "program.description.video.resolutions.poster.focalPoint.y" },
|
|
92
|
-
{ path: "program.description.video.posters.focalPoint.x" },
|
|
93
|
-
{ path: "program.description.video.posters.focalPoint.y" },
|
|
94
|
-
{ path: "program.videoStepsSettings.requiredCompletionPercentage" }
|
|
95
|
-
]
|
|
96
|
-
}
|
|
97
|
-
]);
|
|
98
|
-
const metadata = {
|
|
99
|
-
entityFqdn: "wix.online_programs.v3.program",
|
|
100
|
-
method: "POST",
|
|
101
|
-
methodFqn: "wix.onlineprograms.programs.v3.ProgramsService.CreateProgram",
|
|
102
|
-
packageName: PACKAGE_NAME,
|
|
103
|
-
migrationOptions: {
|
|
104
|
-
optInTransformResponse: true
|
|
105
|
-
},
|
|
106
|
-
url: resolveWixOnlineprogramsProgramsV3ProgramsServiceUrl({
|
|
107
|
-
protoPath: "/v3/programs",
|
|
108
|
-
data: serializedData,
|
|
109
|
-
host
|
|
110
|
-
}),
|
|
111
|
-
data: serializedData,
|
|
112
|
-
transformResponse: (payload2) => transformPaths(payload2, [
|
|
113
|
-
{
|
|
114
|
-
transformFn: transformRESTTimestampToSDKTimestamp,
|
|
115
|
-
paths: [
|
|
116
|
-
{ path: "program.createdDate" },
|
|
117
|
-
{ path: "program.updatedDate" },
|
|
118
|
-
{ path: "program.statusUpdatedDate" },
|
|
119
|
-
{ path: "program.description.image.urlExpirationDate" },
|
|
120
|
-
{ path: "program.description.video.urlExpirationDate" },
|
|
121
|
-
{
|
|
122
|
-
path: "program.description.video.resolutions.urlExpirationDate"
|
|
123
|
-
},
|
|
124
|
-
{
|
|
125
|
-
path: "program.description.video.resolutions.poster.urlExpirationDate"
|
|
126
|
-
},
|
|
127
|
-
{ path: "program.description.video.posters.urlExpirationDate" },
|
|
128
|
-
{ path: "program.rewards.certificate.connectedDate" }
|
|
129
|
-
]
|
|
130
|
-
},
|
|
131
|
-
{
|
|
132
|
-
transformFn: transformRESTFloatToSDKFloat,
|
|
133
|
-
paths: [
|
|
134
|
-
{ path: "program.description.image.focalPoint.x" },
|
|
135
|
-
{ path: "program.description.image.focalPoint.y" },
|
|
136
|
-
{
|
|
137
|
-
path: "program.description.video.resolutions.poster.focalPoint.x"
|
|
138
|
-
},
|
|
139
|
-
{
|
|
140
|
-
path: "program.description.video.resolutions.poster.focalPoint.y"
|
|
141
|
-
},
|
|
142
|
-
{ path: "program.description.video.posters.focalPoint.x" },
|
|
143
|
-
{ path: "program.description.video.posters.focalPoint.y" },
|
|
144
|
-
{
|
|
145
|
-
path: "program.videoStepsSettings.requiredCompletionPercentage"
|
|
146
|
-
}
|
|
147
|
-
]
|
|
148
|
-
}
|
|
149
|
-
])
|
|
150
|
-
};
|
|
151
|
-
return metadata;
|
|
152
|
-
}
|
|
153
|
-
return __createProgram;
|
|
154
|
-
}
|
|
155
|
-
function duplicateProgram(payload) {
|
|
156
|
-
function __duplicateProgram({ host }) {
|
|
157
|
-
const metadata = {
|
|
158
|
-
entityFqdn: "wix.online_programs.v3.program",
|
|
159
|
-
method: "POST",
|
|
160
|
-
methodFqn: "wix.onlineprograms.programs.v3.ProgramsService.DuplicateProgram",
|
|
161
|
-
packageName: PACKAGE_NAME,
|
|
162
|
-
migrationOptions: {
|
|
163
|
-
optInTransformResponse: true
|
|
164
|
-
},
|
|
165
|
-
url: resolveWixOnlineprogramsProgramsV3ProgramsServiceUrl({
|
|
166
|
-
protoPath: "/v3/programs/{programId}/duplicate",
|
|
167
|
-
data: payload,
|
|
168
|
-
host
|
|
169
|
-
}),
|
|
170
|
-
data: payload,
|
|
171
|
-
transformResponse: (payload2) => transformPaths(payload2, [
|
|
172
|
-
{
|
|
173
|
-
transformFn: transformRESTTimestampToSDKTimestamp,
|
|
174
|
-
paths: [
|
|
175
|
-
{ path: "program.createdDate" },
|
|
176
|
-
{ path: "program.updatedDate" },
|
|
177
|
-
{ path: "program.statusUpdatedDate" },
|
|
178
|
-
{ path: "program.description.image.urlExpirationDate" },
|
|
179
|
-
{ path: "program.description.video.urlExpirationDate" },
|
|
180
|
-
{
|
|
181
|
-
path: "program.description.video.resolutions.urlExpirationDate"
|
|
182
|
-
},
|
|
183
|
-
{
|
|
184
|
-
path: "program.description.video.resolutions.poster.urlExpirationDate"
|
|
185
|
-
},
|
|
186
|
-
{ path: "program.description.video.posters.urlExpirationDate" },
|
|
187
|
-
{ path: "program.rewards.certificate.connectedDate" }
|
|
188
|
-
]
|
|
189
|
-
},
|
|
190
|
-
{
|
|
191
|
-
transformFn: transformRESTFloatToSDKFloat,
|
|
192
|
-
paths: [
|
|
193
|
-
{ path: "program.description.image.focalPoint.x" },
|
|
194
|
-
{ path: "program.description.image.focalPoint.y" },
|
|
195
|
-
{
|
|
196
|
-
path: "program.description.video.resolutions.poster.focalPoint.x"
|
|
197
|
-
},
|
|
198
|
-
{
|
|
199
|
-
path: "program.description.video.resolutions.poster.focalPoint.y"
|
|
200
|
-
},
|
|
201
|
-
{ path: "program.description.video.posters.focalPoint.x" },
|
|
202
|
-
{ path: "program.description.video.posters.focalPoint.y" },
|
|
203
|
-
{
|
|
204
|
-
path: "program.videoStepsSettings.requiredCompletionPercentage"
|
|
205
|
-
}
|
|
206
|
-
]
|
|
207
|
-
}
|
|
208
|
-
])
|
|
209
|
-
};
|
|
210
|
-
return metadata;
|
|
211
|
-
}
|
|
212
|
-
return __duplicateProgram;
|
|
213
|
-
}
|
|
214
|
-
function getProgram(payload) {
|
|
215
|
-
function __getProgram({ host }) {
|
|
216
|
-
const metadata = {
|
|
217
|
-
entityFqdn: "wix.online_programs.v3.program",
|
|
218
|
-
method: "GET",
|
|
219
|
-
methodFqn: "wix.onlineprograms.programs.v3.ProgramsService.GetProgram",
|
|
220
|
-
packageName: PACKAGE_NAME,
|
|
221
|
-
migrationOptions: {
|
|
222
|
-
optInTransformResponse: true
|
|
223
|
-
},
|
|
224
|
-
url: resolveWixOnlineprogramsProgramsV3ProgramsServiceUrl({
|
|
225
|
-
protoPath: "/v3/programs/{programId}",
|
|
226
|
-
data: payload,
|
|
227
|
-
host
|
|
228
|
-
}),
|
|
229
|
-
params: toURLSearchParams(payload),
|
|
230
|
-
transformResponse: (payload2) => transformPaths(payload2, [
|
|
231
|
-
{
|
|
232
|
-
transformFn: transformRESTTimestampToSDKTimestamp,
|
|
233
|
-
paths: [
|
|
234
|
-
{ path: "program.createdDate" },
|
|
235
|
-
{ path: "program.updatedDate" },
|
|
236
|
-
{ path: "program.statusUpdatedDate" },
|
|
237
|
-
{ path: "program.description.image.urlExpirationDate" },
|
|
238
|
-
{ path: "program.description.video.urlExpirationDate" },
|
|
239
|
-
{
|
|
240
|
-
path: "program.description.video.resolutions.urlExpirationDate"
|
|
241
|
-
},
|
|
242
|
-
{
|
|
243
|
-
path: "program.description.video.resolutions.poster.urlExpirationDate"
|
|
244
|
-
},
|
|
245
|
-
{ path: "program.description.video.posters.urlExpirationDate" },
|
|
246
|
-
{ path: "program.rewards.certificate.connectedDate" }
|
|
247
|
-
]
|
|
248
|
-
},
|
|
249
|
-
{
|
|
250
|
-
transformFn: transformRESTFloatToSDKFloat,
|
|
251
|
-
paths: [
|
|
252
|
-
{ path: "program.description.image.focalPoint.x" },
|
|
253
|
-
{ path: "program.description.image.focalPoint.y" },
|
|
254
|
-
{
|
|
255
|
-
path: "program.description.video.resolutions.poster.focalPoint.x"
|
|
256
|
-
},
|
|
257
|
-
{
|
|
258
|
-
path: "program.description.video.resolutions.poster.focalPoint.y"
|
|
259
|
-
},
|
|
260
|
-
{ path: "program.description.video.posters.focalPoint.x" },
|
|
261
|
-
{ path: "program.description.video.posters.focalPoint.y" },
|
|
262
|
-
{
|
|
263
|
-
path: "program.videoStepsSettings.requiredCompletionPercentage"
|
|
264
|
-
}
|
|
265
|
-
]
|
|
266
|
-
}
|
|
267
|
-
])
|
|
268
|
-
};
|
|
269
|
-
return metadata;
|
|
270
|
-
}
|
|
271
|
-
return __getProgram;
|
|
272
|
-
}
|
|
273
|
-
function updateProgram(payload) {
|
|
274
|
-
function __updateProgram({ host }) {
|
|
275
|
-
const serializedData = transformPaths(payload, [
|
|
276
|
-
{
|
|
277
|
-
transformFn: transformSDKFieldMaskToRESTFieldMask,
|
|
278
|
-
paths: [{ path: "fieldMask" }]
|
|
279
|
-
},
|
|
280
|
-
{
|
|
281
|
-
transformFn: transformSDKTimestampToRESTTimestamp,
|
|
282
|
-
paths: [
|
|
283
|
-
{ path: "program.createdDate" },
|
|
284
|
-
{ path: "program.updatedDate" },
|
|
285
|
-
{ path: "program.statusUpdatedDate" },
|
|
286
|
-
{ path: "program.description.image.urlExpirationDate" },
|
|
287
|
-
{ path: "program.description.video.urlExpirationDate" },
|
|
288
|
-
{ path: "program.description.video.resolutions.urlExpirationDate" },
|
|
289
|
-
{
|
|
290
|
-
path: "program.description.video.resolutions.poster.urlExpirationDate"
|
|
291
|
-
},
|
|
292
|
-
{ path: "program.description.video.posters.urlExpirationDate" },
|
|
293
|
-
{ path: "program.rewards.certificate.connectedDate" }
|
|
294
|
-
]
|
|
295
|
-
},
|
|
296
|
-
{
|
|
297
|
-
transformFn: transformSDKFloatToRESTFloat,
|
|
298
|
-
paths: [
|
|
299
|
-
{ path: "program.description.image.focalPoint.x" },
|
|
300
|
-
{ path: "program.description.image.focalPoint.y" },
|
|
301
|
-
{ path: "program.description.video.resolutions.poster.focalPoint.x" },
|
|
302
|
-
{ path: "program.description.video.resolutions.poster.focalPoint.y" },
|
|
303
|
-
{ path: "program.description.video.posters.focalPoint.x" },
|
|
304
|
-
{ path: "program.description.video.posters.focalPoint.y" },
|
|
305
|
-
{ path: "program.videoStepsSettings.requiredCompletionPercentage" }
|
|
306
|
-
]
|
|
307
|
-
}
|
|
308
|
-
]);
|
|
309
|
-
const metadata = {
|
|
310
|
-
entityFqdn: "wix.online_programs.v3.program",
|
|
311
|
-
method: "PATCH",
|
|
312
|
-
methodFqn: "wix.onlineprograms.programs.v3.ProgramsService.UpdateProgram",
|
|
313
|
-
packageName: PACKAGE_NAME,
|
|
314
|
-
migrationOptions: {
|
|
315
|
-
optInTransformResponse: true
|
|
316
|
-
},
|
|
317
|
-
url: resolveWixOnlineprogramsProgramsV3ProgramsServiceUrl({
|
|
318
|
-
protoPath: "/v3/programs/{program.id}",
|
|
319
|
-
data: serializedData,
|
|
320
|
-
host
|
|
321
|
-
}),
|
|
322
|
-
data: serializedData,
|
|
323
|
-
transformResponse: (payload2) => transformPaths(payload2, [
|
|
324
|
-
{
|
|
325
|
-
transformFn: transformRESTTimestampToSDKTimestamp,
|
|
326
|
-
paths: [
|
|
327
|
-
{ path: "program.createdDate" },
|
|
328
|
-
{ path: "program.updatedDate" },
|
|
329
|
-
{ path: "program.statusUpdatedDate" },
|
|
330
|
-
{ path: "program.description.image.urlExpirationDate" },
|
|
331
|
-
{ path: "program.description.video.urlExpirationDate" },
|
|
332
|
-
{
|
|
333
|
-
path: "program.description.video.resolutions.urlExpirationDate"
|
|
334
|
-
},
|
|
335
|
-
{
|
|
336
|
-
path: "program.description.video.resolutions.poster.urlExpirationDate"
|
|
337
|
-
},
|
|
338
|
-
{ path: "program.description.video.posters.urlExpirationDate" },
|
|
339
|
-
{ path: "program.rewards.certificate.connectedDate" }
|
|
340
|
-
]
|
|
341
|
-
},
|
|
342
|
-
{
|
|
343
|
-
transformFn: transformRESTFloatToSDKFloat,
|
|
344
|
-
paths: [
|
|
345
|
-
{ path: "program.description.image.focalPoint.x" },
|
|
346
|
-
{ path: "program.description.image.focalPoint.y" },
|
|
347
|
-
{
|
|
348
|
-
path: "program.description.video.resolutions.poster.focalPoint.x"
|
|
349
|
-
},
|
|
350
|
-
{
|
|
351
|
-
path: "program.description.video.resolutions.poster.focalPoint.y"
|
|
352
|
-
},
|
|
353
|
-
{ path: "program.description.video.posters.focalPoint.x" },
|
|
354
|
-
{ path: "program.description.video.posters.focalPoint.y" },
|
|
355
|
-
{
|
|
356
|
-
path: "program.videoStepsSettings.requiredCompletionPercentage"
|
|
357
|
-
}
|
|
358
|
-
]
|
|
359
|
-
}
|
|
360
|
-
])
|
|
361
|
-
};
|
|
362
|
-
return metadata;
|
|
363
|
-
}
|
|
364
|
-
return __updateProgram;
|
|
365
|
-
}
|
|
366
|
-
function deleteProgram(payload) {
|
|
367
|
-
function __deleteProgram({ host }) {
|
|
368
|
-
const metadata = {
|
|
369
|
-
entityFqdn: "wix.online_programs.v3.program",
|
|
370
|
-
method: "DELETE",
|
|
371
|
-
methodFqn: "wix.onlineprograms.programs.v3.ProgramsService.DeleteProgram",
|
|
372
|
-
packageName: PACKAGE_NAME,
|
|
373
|
-
migrationOptions: {
|
|
374
|
-
optInTransformResponse: true
|
|
375
|
-
},
|
|
376
|
-
url: resolveWixOnlineprogramsProgramsV3ProgramsServiceUrl({
|
|
377
|
-
protoPath: "/v3/programs/{programId}",
|
|
378
|
-
data: payload,
|
|
379
|
-
host
|
|
380
|
-
}),
|
|
381
|
-
params: toURLSearchParams(payload)
|
|
382
|
-
};
|
|
383
|
-
return metadata;
|
|
384
|
-
}
|
|
385
|
-
return __deleteProgram;
|
|
386
|
-
}
|
|
387
|
-
function queryPrograms(payload) {
|
|
388
|
-
function __queryPrograms({ host }) {
|
|
389
|
-
const metadata = {
|
|
390
|
-
entityFqdn: "wix.online_programs.v3.program",
|
|
391
|
-
method: "POST",
|
|
392
|
-
methodFqn: "wix.onlineprograms.programs.v3.ProgramsService.QueryPrograms",
|
|
393
|
-
packageName: PACKAGE_NAME,
|
|
394
|
-
migrationOptions: {
|
|
395
|
-
optInTransformResponse: true
|
|
396
|
-
},
|
|
397
|
-
url: resolveWixOnlineprogramsProgramsV3ProgramsServiceUrl({
|
|
398
|
-
protoPath: "/v3/programs/query",
|
|
399
|
-
data: payload,
|
|
400
|
-
host
|
|
401
|
-
}),
|
|
402
|
-
data: payload,
|
|
403
|
-
transformResponse: (payload2) => transformPaths(payload2, [
|
|
404
|
-
{
|
|
405
|
-
transformFn: transformRESTTimestampToSDKTimestamp,
|
|
406
|
-
paths: [
|
|
407
|
-
{ path: "programs.createdDate" },
|
|
408
|
-
{ path: "programs.updatedDate" },
|
|
409
|
-
{ path: "programs.statusUpdatedDate" },
|
|
410
|
-
{ path: "programs.description.image.urlExpirationDate" },
|
|
411
|
-
{ path: "programs.description.video.urlExpirationDate" },
|
|
412
|
-
{
|
|
413
|
-
path: "programs.description.video.resolutions.urlExpirationDate"
|
|
414
|
-
},
|
|
415
|
-
{
|
|
416
|
-
path: "programs.description.video.resolutions.poster.urlExpirationDate"
|
|
417
|
-
},
|
|
418
|
-
{ path: "programs.description.video.posters.urlExpirationDate" },
|
|
419
|
-
{ path: "programs.rewards.certificate.connectedDate" }
|
|
420
|
-
]
|
|
421
|
-
},
|
|
422
|
-
{
|
|
423
|
-
transformFn: transformRESTFloatToSDKFloat,
|
|
424
|
-
paths: [
|
|
425
|
-
{ path: "programs.description.image.focalPoint.x" },
|
|
426
|
-
{ path: "programs.description.image.focalPoint.y" },
|
|
427
|
-
{
|
|
428
|
-
path: "programs.description.video.resolutions.poster.focalPoint.x"
|
|
429
|
-
},
|
|
430
|
-
{
|
|
431
|
-
path: "programs.description.video.resolutions.poster.focalPoint.y"
|
|
432
|
-
},
|
|
433
|
-
{ path: "programs.description.video.posters.focalPoint.x" },
|
|
434
|
-
{ path: "programs.description.video.posters.focalPoint.y" },
|
|
435
|
-
{
|
|
436
|
-
path: "programs.videoStepsSettings.requiredCompletionPercentage"
|
|
437
|
-
}
|
|
438
|
-
]
|
|
439
|
-
}
|
|
440
|
-
])
|
|
441
|
-
};
|
|
442
|
-
return metadata;
|
|
443
|
-
}
|
|
444
|
-
return __queryPrograms;
|
|
445
|
-
}
|
|
446
|
-
function searchPrograms(payload) {
|
|
447
|
-
function __searchPrograms({ host }) {
|
|
448
|
-
const serializedData = transformPaths(payload, [
|
|
449
|
-
{
|
|
450
|
-
transformFn: transformSDKFloatToRESTFloat,
|
|
451
|
-
paths: [
|
|
452
|
-
{ path: "search.aggregations.range.buckets.from" },
|
|
453
|
-
{ path: "search.aggregations.range.buckets.to" },
|
|
454
|
-
{
|
|
455
|
-
path: "search.aggregations.nested.nestedAggregations.range.buckets.from"
|
|
456
|
-
},
|
|
457
|
-
{
|
|
458
|
-
path: "search.aggregations.nested.nestedAggregations.range.buckets.to"
|
|
459
|
-
}
|
|
460
|
-
]
|
|
461
|
-
}
|
|
462
|
-
]);
|
|
463
|
-
const metadata = {
|
|
464
|
-
entityFqdn: "wix.online_programs.v3.program",
|
|
465
|
-
method: "POST",
|
|
466
|
-
methodFqn: "wix.onlineprograms.programs.v3.ProgramsService.SearchPrograms",
|
|
467
|
-
packageName: PACKAGE_NAME,
|
|
468
|
-
migrationOptions: {
|
|
469
|
-
optInTransformResponse: true
|
|
470
|
-
},
|
|
471
|
-
url: resolveWixOnlineprogramsProgramsV3ProgramsServiceUrl({
|
|
472
|
-
protoPath: "/v3/programs/search",
|
|
473
|
-
data: serializedData,
|
|
474
|
-
host
|
|
475
|
-
}),
|
|
476
|
-
data: serializedData,
|
|
477
|
-
transformResponse: (payload2) => transformPaths(payload2, [
|
|
478
|
-
{
|
|
479
|
-
transformFn: transformRESTTimestampToSDKTimestamp,
|
|
480
|
-
paths: [
|
|
481
|
-
{ path: "programs.createdDate" },
|
|
482
|
-
{ path: "programs.updatedDate" },
|
|
483
|
-
{ path: "programs.statusUpdatedDate" },
|
|
484
|
-
{ path: "programs.description.image.urlExpirationDate" },
|
|
485
|
-
{ path: "programs.description.video.urlExpirationDate" },
|
|
486
|
-
{
|
|
487
|
-
path: "programs.description.video.resolutions.urlExpirationDate"
|
|
488
|
-
},
|
|
489
|
-
{
|
|
490
|
-
path: "programs.description.video.resolutions.poster.urlExpirationDate"
|
|
491
|
-
},
|
|
492
|
-
{ path: "programs.description.video.posters.urlExpirationDate" },
|
|
493
|
-
{ path: "programs.rewards.certificate.connectedDate" }
|
|
494
|
-
]
|
|
495
|
-
},
|
|
496
|
-
{
|
|
497
|
-
transformFn: transformRESTFloatToSDKFloat,
|
|
498
|
-
paths: [
|
|
499
|
-
{ path: "programs.description.image.focalPoint.x" },
|
|
500
|
-
{ path: "programs.description.image.focalPoint.y" },
|
|
501
|
-
{
|
|
502
|
-
path: "programs.description.video.resolutions.poster.focalPoint.x"
|
|
503
|
-
},
|
|
504
|
-
{
|
|
505
|
-
path: "programs.description.video.resolutions.poster.focalPoint.y"
|
|
506
|
-
},
|
|
507
|
-
{ path: "programs.description.video.posters.focalPoint.x" },
|
|
508
|
-
{ path: "programs.description.video.posters.focalPoint.y" },
|
|
509
|
-
{
|
|
510
|
-
path: "programs.videoStepsSettings.requiredCompletionPercentage"
|
|
511
|
-
},
|
|
512
|
-
{ path: "aggregationData.results.scalar.value" },
|
|
513
|
-
{
|
|
514
|
-
path: "aggregationData.results.groupedByValue.results.nestedResults.scalar.value"
|
|
515
|
-
},
|
|
516
|
-
{
|
|
517
|
-
path: "aggregationData.results.nested.results.results.*.scalar.value"
|
|
518
|
-
},
|
|
519
|
-
{ path: "aggregationData.results.ranges.results.from" },
|
|
520
|
-
{ path: "aggregationData.results.ranges.results.to" },
|
|
521
|
-
{
|
|
522
|
-
path: "aggregationData.results.groupedByValue.results.nestedResults.ranges.results.from"
|
|
523
|
-
},
|
|
524
|
-
{
|
|
525
|
-
path: "aggregationData.results.groupedByValue.results.nestedResults.ranges.results.to"
|
|
526
|
-
},
|
|
527
|
-
{
|
|
528
|
-
path: "aggregationData.results.nested.results.results.*.range.from"
|
|
529
|
-
},
|
|
530
|
-
{
|
|
531
|
-
path: "aggregationData.results.nested.results.results.*.range.to"
|
|
532
|
-
}
|
|
533
|
-
]
|
|
534
|
-
}
|
|
535
|
-
])
|
|
536
|
-
};
|
|
537
|
-
return metadata;
|
|
538
|
-
}
|
|
539
|
-
return __searchPrograms;
|
|
540
|
-
}
|
|
541
|
-
function publishProgram(payload) {
|
|
542
|
-
function __publishProgram({ host }) {
|
|
543
|
-
const metadata = {
|
|
544
|
-
entityFqdn: "wix.online_programs.v3.program",
|
|
545
|
-
method: "POST",
|
|
546
|
-
methodFqn: "wix.onlineprograms.programs.v3.ProgramsService.PublishProgram",
|
|
547
|
-
packageName: PACKAGE_NAME,
|
|
548
|
-
migrationOptions: {
|
|
549
|
-
optInTransformResponse: true
|
|
550
|
-
},
|
|
551
|
-
url: resolveWixOnlineprogramsProgramsV3ProgramsServiceUrl({
|
|
552
|
-
protoPath: "/v3/programs/{programId}/publish",
|
|
553
|
-
data: payload,
|
|
554
|
-
host
|
|
555
|
-
}),
|
|
556
|
-
data: payload,
|
|
557
|
-
transformResponse: (payload2) => transformPaths(payload2, [
|
|
558
|
-
{
|
|
559
|
-
transformFn: transformRESTTimestampToSDKTimestamp,
|
|
560
|
-
paths: [
|
|
561
|
-
{ path: "program.createdDate" },
|
|
562
|
-
{ path: "program.updatedDate" },
|
|
563
|
-
{ path: "program.statusUpdatedDate" },
|
|
564
|
-
{ path: "program.description.image.urlExpirationDate" },
|
|
565
|
-
{ path: "program.description.video.urlExpirationDate" },
|
|
566
|
-
{
|
|
567
|
-
path: "program.description.video.resolutions.urlExpirationDate"
|
|
568
|
-
},
|
|
569
|
-
{
|
|
570
|
-
path: "program.description.video.resolutions.poster.urlExpirationDate"
|
|
571
|
-
},
|
|
572
|
-
{ path: "program.description.video.posters.urlExpirationDate" },
|
|
573
|
-
{ path: "program.rewards.certificate.connectedDate" }
|
|
574
|
-
]
|
|
575
|
-
},
|
|
576
|
-
{
|
|
577
|
-
transformFn: transformRESTFloatToSDKFloat,
|
|
578
|
-
paths: [
|
|
579
|
-
{ path: "program.description.image.focalPoint.x" },
|
|
580
|
-
{ path: "program.description.image.focalPoint.y" },
|
|
581
|
-
{
|
|
582
|
-
path: "program.description.video.resolutions.poster.focalPoint.x"
|
|
583
|
-
},
|
|
584
|
-
{
|
|
585
|
-
path: "program.description.video.resolutions.poster.focalPoint.y"
|
|
586
|
-
},
|
|
587
|
-
{ path: "program.description.video.posters.focalPoint.x" },
|
|
588
|
-
{ path: "program.description.video.posters.focalPoint.y" },
|
|
589
|
-
{
|
|
590
|
-
path: "program.videoStepsSettings.requiredCompletionPercentage"
|
|
591
|
-
}
|
|
592
|
-
]
|
|
593
|
-
}
|
|
594
|
-
])
|
|
595
|
-
};
|
|
596
|
-
return metadata;
|
|
597
|
-
}
|
|
598
|
-
return __publishProgram;
|
|
599
|
-
}
|
|
600
|
-
function endProgram(payload) {
|
|
601
|
-
function __endProgram({ host }) {
|
|
602
|
-
const metadata = {
|
|
603
|
-
entityFqdn: "wix.online_programs.v3.program",
|
|
604
|
-
method: "POST",
|
|
605
|
-
methodFqn: "wix.onlineprograms.programs.v3.ProgramsService.EndProgram",
|
|
606
|
-
packageName: PACKAGE_NAME,
|
|
607
|
-
migrationOptions: {
|
|
608
|
-
optInTransformResponse: true
|
|
609
|
-
},
|
|
610
|
-
url: resolveWixOnlineprogramsProgramsV3ProgramsServiceUrl({
|
|
611
|
-
protoPath: "/v3/programs/{programId}/end",
|
|
612
|
-
data: payload,
|
|
613
|
-
host
|
|
614
|
-
}),
|
|
615
|
-
data: payload,
|
|
616
|
-
transformResponse: (payload2) => transformPaths(payload2, [
|
|
617
|
-
{
|
|
618
|
-
transformFn: transformRESTTimestampToSDKTimestamp,
|
|
619
|
-
paths: [
|
|
620
|
-
{ path: "program.createdDate" },
|
|
621
|
-
{ path: "program.updatedDate" },
|
|
622
|
-
{ path: "program.statusUpdatedDate" },
|
|
623
|
-
{ path: "program.description.image.urlExpirationDate" },
|
|
624
|
-
{ path: "program.description.video.urlExpirationDate" },
|
|
625
|
-
{
|
|
626
|
-
path: "program.description.video.resolutions.urlExpirationDate"
|
|
627
|
-
},
|
|
628
|
-
{
|
|
629
|
-
path: "program.description.video.resolutions.poster.urlExpirationDate"
|
|
630
|
-
},
|
|
631
|
-
{ path: "program.description.video.posters.urlExpirationDate" },
|
|
632
|
-
{ path: "program.rewards.certificate.connectedDate" }
|
|
633
|
-
]
|
|
634
|
-
},
|
|
635
|
-
{
|
|
636
|
-
transformFn: transformRESTFloatToSDKFloat,
|
|
637
|
-
paths: [
|
|
638
|
-
{ path: "program.description.image.focalPoint.x" },
|
|
639
|
-
{ path: "program.description.image.focalPoint.y" },
|
|
640
|
-
{
|
|
641
|
-
path: "program.description.video.resolutions.poster.focalPoint.x"
|
|
642
|
-
},
|
|
643
|
-
{
|
|
644
|
-
path: "program.description.video.resolutions.poster.focalPoint.y"
|
|
645
|
-
},
|
|
646
|
-
{ path: "program.description.video.posters.focalPoint.x" },
|
|
647
|
-
{ path: "program.description.video.posters.focalPoint.y" },
|
|
648
|
-
{
|
|
649
|
-
path: "program.videoStepsSettings.requiredCompletionPercentage"
|
|
650
|
-
}
|
|
651
|
-
]
|
|
652
|
-
}
|
|
653
|
-
])
|
|
654
|
-
};
|
|
655
|
-
return metadata;
|
|
656
|
-
}
|
|
657
|
-
return __endProgram;
|
|
658
|
-
}
|
|
659
|
-
function archiveProgram(payload) {
|
|
660
|
-
function __archiveProgram({ host }) {
|
|
661
|
-
const metadata = {
|
|
662
|
-
entityFqdn: "wix.online_programs.v3.program",
|
|
663
|
-
method: "POST",
|
|
664
|
-
methodFqn: "wix.onlineprograms.programs.v3.ProgramsService.ArchiveProgram",
|
|
665
|
-
packageName: PACKAGE_NAME,
|
|
666
|
-
migrationOptions: {
|
|
667
|
-
optInTransformResponse: true
|
|
668
|
-
},
|
|
669
|
-
url: resolveWixOnlineprogramsProgramsV3ProgramsServiceUrl({
|
|
670
|
-
protoPath: "/v3/programs/{programId}/archive",
|
|
671
|
-
data: payload,
|
|
672
|
-
host
|
|
673
|
-
}),
|
|
674
|
-
data: payload,
|
|
675
|
-
transformResponse: (payload2) => transformPaths(payload2, [
|
|
676
|
-
{
|
|
677
|
-
transformFn: transformRESTTimestampToSDKTimestamp,
|
|
678
|
-
paths: [
|
|
679
|
-
{ path: "program.createdDate" },
|
|
680
|
-
{ path: "program.updatedDate" },
|
|
681
|
-
{ path: "program.statusUpdatedDate" },
|
|
682
|
-
{ path: "program.description.image.urlExpirationDate" },
|
|
683
|
-
{ path: "program.description.video.urlExpirationDate" },
|
|
684
|
-
{
|
|
685
|
-
path: "program.description.video.resolutions.urlExpirationDate"
|
|
686
|
-
},
|
|
687
|
-
{
|
|
688
|
-
path: "program.description.video.resolutions.poster.urlExpirationDate"
|
|
689
|
-
},
|
|
690
|
-
{ path: "program.description.video.posters.urlExpirationDate" },
|
|
691
|
-
{ path: "program.rewards.certificate.connectedDate" }
|
|
692
|
-
]
|
|
693
|
-
},
|
|
694
|
-
{
|
|
695
|
-
transformFn: transformRESTFloatToSDKFloat,
|
|
696
|
-
paths: [
|
|
697
|
-
{ path: "program.description.image.focalPoint.x" },
|
|
698
|
-
{ path: "program.description.image.focalPoint.y" },
|
|
699
|
-
{
|
|
700
|
-
path: "program.description.video.resolutions.poster.focalPoint.x"
|
|
701
|
-
},
|
|
702
|
-
{
|
|
703
|
-
path: "program.description.video.resolutions.poster.focalPoint.y"
|
|
704
|
-
},
|
|
705
|
-
{ path: "program.description.video.posters.focalPoint.x" },
|
|
706
|
-
{ path: "program.description.video.posters.focalPoint.y" },
|
|
707
|
-
{
|
|
708
|
-
path: "program.videoStepsSettings.requiredCompletionPercentage"
|
|
709
|
-
}
|
|
710
|
-
]
|
|
711
|
-
}
|
|
712
|
-
])
|
|
713
|
-
};
|
|
714
|
-
return metadata;
|
|
715
|
-
}
|
|
716
|
-
return __archiveProgram;
|
|
717
|
-
}
|
|
718
|
-
function bulkUpdatePrograms(payload) {
|
|
719
|
-
function __bulkUpdatePrograms({ host }) {
|
|
720
|
-
const serializedData = transformPaths(payload, [
|
|
721
|
-
{
|
|
722
|
-
transformFn: transformSDKFieldMaskToRESTFieldMask,
|
|
723
|
-
paths: [{ path: "programs.fieldMask" }]
|
|
724
|
-
},
|
|
725
|
-
{
|
|
726
|
-
transformFn: transformSDKTimestampToRESTTimestamp,
|
|
727
|
-
paths: [
|
|
728
|
-
{ path: "programs.program.createdDate" },
|
|
729
|
-
{ path: "programs.program.updatedDate" },
|
|
730
|
-
{ path: "programs.program.statusUpdatedDate" },
|
|
731
|
-
{ path: "programs.program.description.image.urlExpirationDate" },
|
|
732
|
-
{ path: "programs.program.description.video.urlExpirationDate" },
|
|
733
|
-
{
|
|
734
|
-
path: "programs.program.description.video.resolutions.urlExpirationDate"
|
|
735
|
-
},
|
|
736
|
-
{
|
|
737
|
-
path: "programs.program.description.video.resolutions.poster.urlExpirationDate"
|
|
738
|
-
},
|
|
739
|
-
{
|
|
740
|
-
path: "programs.program.description.video.posters.urlExpirationDate"
|
|
741
|
-
},
|
|
742
|
-
{ path: "programs.program.rewards.certificate.connectedDate" }
|
|
743
|
-
]
|
|
744
|
-
},
|
|
745
|
-
{
|
|
746
|
-
transformFn: transformSDKFloatToRESTFloat,
|
|
747
|
-
paths: [
|
|
748
|
-
{ path: "programs.program.description.image.focalPoint.x" },
|
|
749
|
-
{ path: "programs.program.description.image.focalPoint.y" },
|
|
750
|
-
{
|
|
751
|
-
path: "programs.program.description.video.resolutions.poster.focalPoint.x"
|
|
752
|
-
},
|
|
753
|
-
{
|
|
754
|
-
path: "programs.program.description.video.resolutions.poster.focalPoint.y"
|
|
755
|
-
},
|
|
756
|
-
{ path: "programs.program.description.video.posters.focalPoint.x" },
|
|
757
|
-
{ path: "programs.program.description.video.posters.focalPoint.y" },
|
|
758
|
-
{
|
|
759
|
-
path: "programs.program.videoStepsSettings.requiredCompletionPercentage"
|
|
760
|
-
}
|
|
761
|
-
]
|
|
762
|
-
}
|
|
763
|
-
]);
|
|
764
|
-
const metadata = {
|
|
765
|
-
entityFqdn: "wix.online_programs.v3.program",
|
|
766
|
-
method: "POST",
|
|
767
|
-
methodFqn: "wix.onlineprograms.programs.v3.ProgramsService.BulkUpdatePrograms",
|
|
768
|
-
packageName: PACKAGE_NAME,
|
|
769
|
-
migrationOptions: {
|
|
770
|
-
optInTransformResponse: true
|
|
771
|
-
},
|
|
772
|
-
url: resolveWixOnlineprogramsProgramsV3ProgramsServiceUrl({
|
|
773
|
-
protoPath: "/v3/bulk/programs/update",
|
|
774
|
-
data: serializedData,
|
|
775
|
-
host
|
|
776
|
-
}),
|
|
777
|
-
data: serializedData,
|
|
778
|
-
transformResponse: (payload2) => transformPaths(payload2, [
|
|
779
|
-
{
|
|
780
|
-
transformFn: transformRESTTimestampToSDKTimestamp,
|
|
781
|
-
paths: [
|
|
782
|
-
{ path: "results.item.createdDate" },
|
|
783
|
-
{ path: "results.item.updatedDate" },
|
|
784
|
-
{ path: "results.item.statusUpdatedDate" },
|
|
785
|
-
{ path: "results.item.description.image.urlExpirationDate" },
|
|
786
|
-
{ path: "results.item.description.video.urlExpirationDate" },
|
|
787
|
-
{
|
|
788
|
-
path: "results.item.description.video.resolutions.urlExpirationDate"
|
|
789
|
-
},
|
|
790
|
-
{
|
|
791
|
-
path: "results.item.description.video.resolutions.poster.urlExpirationDate"
|
|
792
|
-
},
|
|
793
|
-
{
|
|
794
|
-
path: "results.item.description.video.posters.urlExpirationDate"
|
|
795
|
-
},
|
|
796
|
-
{ path: "results.item.rewards.certificate.connectedDate" }
|
|
797
|
-
]
|
|
798
|
-
},
|
|
799
|
-
{
|
|
800
|
-
transformFn: transformRESTFloatToSDKFloat,
|
|
801
|
-
paths: [
|
|
802
|
-
{ path: "results.item.description.image.focalPoint.x" },
|
|
803
|
-
{ path: "results.item.description.image.focalPoint.y" },
|
|
804
|
-
{
|
|
805
|
-
path: "results.item.description.video.resolutions.poster.focalPoint.x"
|
|
806
|
-
},
|
|
807
|
-
{
|
|
808
|
-
path: "results.item.description.video.resolutions.poster.focalPoint.y"
|
|
809
|
-
},
|
|
810
|
-
{ path: "results.item.description.video.posters.focalPoint.x" },
|
|
811
|
-
{ path: "results.item.description.video.posters.focalPoint.y" },
|
|
812
|
-
{
|
|
813
|
-
path: "results.item.videoStepsSettings.requiredCompletionPercentage"
|
|
814
|
-
}
|
|
815
|
-
]
|
|
816
|
-
}
|
|
817
|
-
])
|
|
818
|
-
};
|
|
819
|
-
return metadata;
|
|
820
|
-
}
|
|
821
|
-
return __bulkUpdatePrograms;
|
|
822
|
-
}
|
|
823
|
-
function countPrograms(payload) {
|
|
824
|
-
function __countPrograms({ host }) {
|
|
825
|
-
const metadata = {
|
|
826
|
-
entityFqdn: "wix.online_programs.v3.program",
|
|
827
|
-
method: "POST",
|
|
828
|
-
methodFqn: "wix.onlineprograms.programs.v3.ProgramsService.CountPrograms",
|
|
829
|
-
packageName: PACKAGE_NAME,
|
|
830
|
-
migrationOptions: {
|
|
831
|
-
optInTransformResponse: true
|
|
832
|
-
},
|
|
833
|
-
url: resolveWixOnlineprogramsProgramsV3ProgramsServiceUrl({
|
|
834
|
-
protoPath: "/v3/programs/count",
|
|
835
|
-
data: payload,
|
|
836
|
-
host
|
|
837
|
-
}),
|
|
838
|
-
data: payload
|
|
839
|
-
};
|
|
840
|
-
return metadata;
|
|
841
|
-
}
|
|
842
|
-
return __countPrograms;
|
|
843
|
-
}
|
|
844
|
-
function listSamplePrograms(payload) {
|
|
845
|
-
function __listSamplePrograms({ host }) {
|
|
846
|
-
const metadata = {
|
|
847
|
-
entityFqdn: "wix.online_programs.v3.program",
|
|
848
|
-
method: "GET",
|
|
849
|
-
methodFqn: "wix.onlineprograms.programs.v3.ProgramsService.ListSamplePrograms",
|
|
850
|
-
packageName: PACKAGE_NAME,
|
|
851
|
-
migrationOptions: {
|
|
852
|
-
optInTransformResponse: true
|
|
853
|
-
},
|
|
854
|
-
url: resolveWixOnlineprogramsProgramsV3ProgramsServiceUrl({
|
|
855
|
-
protoPath: "/v3/programs/samples",
|
|
856
|
-
data: payload,
|
|
857
|
-
host
|
|
858
|
-
}),
|
|
859
|
-
params: toURLSearchParams(payload),
|
|
860
|
-
transformResponse: (payload2) => transformPaths(payload2, [
|
|
861
|
-
{
|
|
862
|
-
transformFn: transformRESTTimestampToSDKTimestamp,
|
|
863
|
-
paths: [
|
|
864
|
-
{ path: "programs.program.createdDate" },
|
|
865
|
-
{ path: "programs.program.updatedDate" },
|
|
866
|
-
{ path: "programs.program.statusUpdatedDate" },
|
|
867
|
-
{ path: "programs.program.description.image.urlExpirationDate" },
|
|
868
|
-
{ path: "programs.program.description.video.urlExpirationDate" },
|
|
869
|
-
{
|
|
870
|
-
path: "programs.program.description.video.resolutions.urlExpirationDate"
|
|
871
|
-
},
|
|
872
|
-
{
|
|
873
|
-
path: "programs.program.description.video.resolutions.poster.urlExpirationDate"
|
|
874
|
-
},
|
|
875
|
-
{
|
|
876
|
-
path: "programs.program.description.video.posters.urlExpirationDate"
|
|
877
|
-
},
|
|
878
|
-
{ path: "programs.program.rewards.certificate.connectedDate" }
|
|
879
|
-
]
|
|
880
|
-
},
|
|
881
|
-
{
|
|
882
|
-
transformFn: transformRESTFloatToSDKFloat,
|
|
883
|
-
paths: [
|
|
884
|
-
{ path: "programs.program.description.image.focalPoint.x" },
|
|
885
|
-
{ path: "programs.program.description.image.focalPoint.y" },
|
|
886
|
-
{
|
|
887
|
-
path: "programs.program.description.video.resolutions.poster.focalPoint.x"
|
|
888
|
-
},
|
|
889
|
-
{
|
|
890
|
-
path: "programs.program.description.video.resolutions.poster.focalPoint.y"
|
|
891
|
-
},
|
|
892
|
-
{
|
|
893
|
-
path: "programs.program.description.video.posters.focalPoint.x"
|
|
894
|
-
},
|
|
895
|
-
{
|
|
896
|
-
path: "programs.program.description.video.posters.focalPoint.y"
|
|
897
|
-
},
|
|
898
|
-
{
|
|
899
|
-
path: "programs.program.videoStepsSettings.requiredCompletionPercentage"
|
|
900
|
-
}
|
|
901
|
-
]
|
|
902
|
-
}
|
|
903
|
-
])
|
|
904
|
-
};
|
|
905
|
-
return metadata;
|
|
906
|
-
}
|
|
907
|
-
return __listSamplePrograms;
|
|
908
|
-
}
|
|
909
|
-
|
|
910
|
-
// src/online-programs-v3-program-programs.universal.ts
|
|
911
|
-
import { transformSDKImageToRESTImage } from "@wix/sdk-runtime/transformations/image";
|
|
912
|
-
import { transformRESTImageToSDKImage } from "@wix/sdk-runtime/transformations/image";
|
|
913
|
-
import { transformSDKVideoV2ToRESTVideoV2 } from "@wix/sdk-runtime/transformations/video-v2";
|
|
914
|
-
import { transformRESTVideoV2ToSDKVideoV2 } from "@wix/sdk-runtime/transformations/video-v2";
|
|
915
|
-
import { transformSDKPageURLToRESTPageURL } from "@wix/sdk-runtime/transformations/page-url";
|
|
916
|
-
import { transformRESTPageURLToSDKPageURL } from "@wix/sdk-runtime/transformations/page-url";
|
|
917
|
-
import { transformPaths as transformPaths2 } from "@wix/sdk-runtime/transformations/transform-paths";
|
|
918
|
-
import { createQueryUtils } from "@wix/sdk-runtime/query-builder-utils";
|
|
919
|
-
import { createSearchUtils } from "@wix/sdk-runtime/search-builder-utils";
|
|
920
|
-
var Status = /* @__PURE__ */ ((Status2) => {
|
|
921
|
-
Status2["DRAFT"] = "DRAFT";
|
|
922
|
-
Status2["PUBLISHED"] = "PUBLISHED";
|
|
923
|
-
Status2["ENDED"] = "ENDED";
|
|
924
|
-
Status2["ARCHIVED"] = "ARCHIVED";
|
|
925
|
-
return Status2;
|
|
926
|
-
})(Status || {});
|
|
927
|
-
var AccessType = /* @__PURE__ */ ((AccessType2) => {
|
|
928
|
-
AccessType2["PUBLIC"] = "PUBLIC";
|
|
929
|
-
AccessType2["PRIVATE"] = "PRIVATE";
|
|
930
|
-
AccessType2["SECRET"] = "SECRET";
|
|
931
|
-
return AccessType2;
|
|
932
|
-
})(AccessType || {});
|
|
933
|
-
var Trigger = /* @__PURE__ */ ((Trigger2) => {
|
|
934
|
-
Trigger2["JOINED_TO_PROGRAM"] = "JOINED_TO_PROGRAM";
|
|
935
|
-
Trigger2["STEP_COMPLETED"] = "STEP_COMPLETED";
|
|
936
|
-
Trigger2["ALL_STEPS_COMPLETED"] = "ALL_STEPS_COMPLETED";
|
|
937
|
-
return Trigger2;
|
|
938
|
-
})(Trigger || {});
|
|
939
|
-
var Enum = /* @__PURE__ */ ((Enum2) => {
|
|
940
|
-
Enum2["UNKNOWN"] = "UNKNOWN";
|
|
941
|
-
Enum2["PROTECTED"] = "PROTECTED";
|
|
942
|
-
Enum2["PRIVATE"] = "PRIVATE";
|
|
943
|
-
Enum2["PUBLIC"] = "PUBLIC";
|
|
944
|
-
Enum2["UNCHANGED"] = "UNCHANGED";
|
|
945
|
-
Enum2["GROUP_PROTECTED"] = "GROUP_PROTECTED";
|
|
946
|
-
return Enum2;
|
|
947
|
-
})(Enum || {});
|
|
948
|
-
var BulkActionType = /* @__PURE__ */ ((BulkActionType2) => {
|
|
949
|
-
BulkActionType2["UNKNOWN_ACTION_TYPE"] = "UNKNOWN_ACTION_TYPE";
|
|
950
|
-
BulkActionType2["INSERT"] = "INSERT";
|
|
951
|
-
BulkActionType2["UPDATE"] = "UPDATE";
|
|
952
|
-
BulkActionType2["DELETE"] = "DELETE";
|
|
953
|
-
return BulkActionType2;
|
|
954
|
-
})(BulkActionType || {});
|
|
955
|
-
var SortOrder = /* @__PURE__ */ ((SortOrder2) => {
|
|
956
|
-
SortOrder2["ASC"] = "ASC";
|
|
957
|
-
SortOrder2["DESC"] = "DESC";
|
|
958
|
-
return SortOrder2;
|
|
959
|
-
})(SortOrder || {});
|
|
960
|
-
var SortType = /* @__PURE__ */ ((SortType2) => {
|
|
961
|
-
SortType2["COUNT"] = "COUNT";
|
|
962
|
-
SortType2["VALUE"] = "VALUE";
|
|
963
|
-
return SortType2;
|
|
964
|
-
})(SortType || {});
|
|
965
|
-
var SortDirection = /* @__PURE__ */ ((SortDirection2) => {
|
|
966
|
-
SortDirection2["DESC"] = "DESC";
|
|
967
|
-
SortDirection2["ASC"] = "ASC";
|
|
968
|
-
return SortDirection2;
|
|
969
|
-
})(SortDirection || {});
|
|
970
|
-
var MissingValues = /* @__PURE__ */ ((MissingValues2) => {
|
|
971
|
-
MissingValues2["EXCLUDE"] = "EXCLUDE";
|
|
972
|
-
MissingValues2["INCLUDE"] = "INCLUDE";
|
|
973
|
-
return MissingValues2;
|
|
974
|
-
})(MissingValues || {});
|
|
975
|
-
var ScalarType = /* @__PURE__ */ ((ScalarType2) => {
|
|
976
|
-
ScalarType2["COUNT_DISTINCT"] = "COUNT_DISTINCT";
|
|
977
|
-
ScalarType2["MIN"] = "MIN";
|
|
978
|
-
ScalarType2["MAX"] = "MAX";
|
|
979
|
-
ScalarType2["SUM"] = "SUM";
|
|
980
|
-
ScalarType2["AVG"] = "AVG";
|
|
981
|
-
return ScalarType2;
|
|
982
|
-
})(ScalarType || {});
|
|
983
|
-
var NestedAggregationType = /* @__PURE__ */ ((NestedAggregationType2) => {
|
|
984
|
-
NestedAggregationType2["VALUE"] = "VALUE";
|
|
985
|
-
NestedAggregationType2["RANGE"] = "RANGE";
|
|
986
|
-
NestedAggregationType2["SCALAR"] = "SCALAR";
|
|
987
|
-
NestedAggregationType2["DATE_HISTOGRAM"] = "DATE_HISTOGRAM";
|
|
988
|
-
return NestedAggregationType2;
|
|
989
|
-
})(NestedAggregationType || {});
|
|
990
|
-
var Interval = /* @__PURE__ */ ((Interval2) => {
|
|
991
|
-
Interval2["YEAR"] = "YEAR";
|
|
992
|
-
Interval2["MONTH"] = "MONTH";
|
|
993
|
-
Interval2["WEEK"] = "WEEK";
|
|
994
|
-
Interval2["DAY"] = "DAY";
|
|
995
|
-
Interval2["HOUR"] = "HOUR";
|
|
996
|
-
Interval2["MINUTE"] = "MINUTE";
|
|
997
|
-
Interval2["SECOND"] = "SECOND";
|
|
998
|
-
return Interval2;
|
|
999
|
-
})(Interval || {});
|
|
1000
|
-
var AggregationType = /* @__PURE__ */ ((AggregationType2) => {
|
|
1001
|
-
AggregationType2["VALUE"] = "VALUE";
|
|
1002
|
-
AggregationType2["RANGE"] = "RANGE";
|
|
1003
|
-
AggregationType2["SCALAR"] = "SCALAR";
|
|
1004
|
-
AggregationType2["DATE_HISTOGRAM"] = "DATE_HISTOGRAM";
|
|
1005
|
-
AggregationType2["NESTED"] = "NESTED";
|
|
1006
|
-
return AggregationType2;
|
|
1007
|
-
})(AggregationType || {});
|
|
1008
|
-
var Mode = /* @__PURE__ */ ((Mode2) => {
|
|
1009
|
-
Mode2["OR"] = "OR";
|
|
1010
|
-
Mode2["AND"] = "AND";
|
|
1011
|
-
return Mode2;
|
|
1012
|
-
})(Mode || {});
|
|
1013
|
-
var State = /* @__PURE__ */ ((State2) => {
|
|
1014
|
-
State2["UNKNOWN"] = "UNKNOWN";
|
|
1015
|
-
State2["ENABLED"] = "ENABLED";
|
|
1016
|
-
State2["DISABLED"] = "DISABLED";
|
|
1017
|
-
State2["PENDING"] = "PENDING";
|
|
1018
|
-
State2["DEMO"] = "DEMO";
|
|
1019
|
-
return State2;
|
|
1020
|
-
})(State || {});
|
|
1021
|
-
var SiteCreatedContext = /* @__PURE__ */ ((SiteCreatedContext2) => {
|
|
1022
|
-
SiteCreatedContext2["OTHER"] = "OTHER";
|
|
1023
|
-
SiteCreatedContext2["FROM_TEMPLATE"] = "FROM_TEMPLATE";
|
|
1024
|
-
SiteCreatedContext2["DUPLICATE_BY_SITE_TRANSFER"] = "DUPLICATE_BY_SITE_TRANSFER";
|
|
1025
|
-
SiteCreatedContext2["DUPLICATE"] = "DUPLICATE";
|
|
1026
|
-
SiteCreatedContext2["OLD_SITE_TRANSFER"] = "OLD_SITE_TRANSFER";
|
|
1027
|
-
SiteCreatedContext2["FLASH"] = "FLASH";
|
|
1028
|
-
return SiteCreatedContext2;
|
|
1029
|
-
})(SiteCreatedContext || {});
|
|
1030
|
-
var Namespace = /* @__PURE__ */ ((Namespace2) => {
|
|
1031
|
-
Namespace2["UNKNOWN_NAMESPACE"] = "UNKNOWN_NAMESPACE";
|
|
1032
|
-
Namespace2["WIX"] = "WIX";
|
|
1033
|
-
Namespace2["SHOUT_OUT"] = "SHOUT_OUT";
|
|
1034
|
-
Namespace2["ALBUMS"] = "ALBUMS";
|
|
1035
|
-
Namespace2["WIX_STORES_TEST_DRIVE"] = "WIX_STORES_TEST_DRIVE";
|
|
1036
|
-
Namespace2["HOTELS"] = "HOTELS";
|
|
1037
|
-
Namespace2["CLUBS"] = "CLUBS";
|
|
1038
|
-
Namespace2["ONBOARDING_DRAFT"] = "ONBOARDING_DRAFT";
|
|
1039
|
-
Namespace2["DEV_SITE"] = "DEV_SITE";
|
|
1040
|
-
Namespace2["LOGOS"] = "LOGOS";
|
|
1041
|
-
Namespace2["VIDEO_MAKER"] = "VIDEO_MAKER";
|
|
1042
|
-
Namespace2["PARTNER_DASHBOARD"] = "PARTNER_DASHBOARD";
|
|
1043
|
-
Namespace2["DEV_CENTER_COMPANY"] = "DEV_CENTER_COMPANY";
|
|
1044
|
-
Namespace2["HTML_DRAFT"] = "HTML_DRAFT";
|
|
1045
|
-
Namespace2["SITELESS_BUSINESS"] = "SITELESS_BUSINESS";
|
|
1046
|
-
Namespace2["CREATOR_ECONOMY"] = "CREATOR_ECONOMY";
|
|
1047
|
-
Namespace2["DASHBOARD_FIRST"] = "DASHBOARD_FIRST";
|
|
1048
|
-
Namespace2["ANYWHERE"] = "ANYWHERE";
|
|
1049
|
-
Namespace2["HEADLESS"] = "HEADLESS";
|
|
1050
|
-
Namespace2["ACCOUNT_MASTER_CMS"] = "ACCOUNT_MASTER_CMS";
|
|
1051
|
-
Namespace2["RISE"] = "RISE";
|
|
1052
|
-
Namespace2["BRANDED_FIRST"] = "BRANDED_FIRST";
|
|
1053
|
-
Namespace2["NOWNIA"] = "NOWNIA";
|
|
1054
|
-
Namespace2["UGC_TEMPLATE"] = "UGC_TEMPLATE";
|
|
1055
|
-
Namespace2["CODUX"] = "CODUX";
|
|
1056
|
-
Namespace2["MEDIA_DESIGN_CREATOR"] = "MEDIA_DESIGN_CREATOR";
|
|
1057
|
-
Namespace2["SHARED_BLOG_ENTERPRISE"] = "SHARED_BLOG_ENTERPRISE";
|
|
1058
|
-
Namespace2["STANDALONE_FORMS"] = "STANDALONE_FORMS";
|
|
1059
|
-
Namespace2["STANDALONE_EVENTS"] = "STANDALONE_EVENTS";
|
|
1060
|
-
Namespace2["MIMIR"] = "MIMIR";
|
|
1061
|
-
Namespace2["TWINS"] = "TWINS";
|
|
1062
|
-
Namespace2["NANO"] = "NANO";
|
|
1063
|
-
Namespace2["BASE44"] = "BASE44";
|
|
1064
|
-
Namespace2["CHANNELS"] = "CHANNELS";
|
|
1065
|
-
Namespace2["NAUTILUS"] = "NAUTILUS";
|
|
1066
|
-
Namespace2["SYMPHONY"] = "SYMPHONY";
|
|
1067
|
-
Namespace2["NAUTILUS_APPS"] = "NAUTILUS_APPS";
|
|
1068
|
-
Namespace2["VIBU"] = "VIBU";
|
|
1069
|
-
Namespace2["ENTERPRISE_BRAND_KIT"] = "ENTERPRISE_BRAND_KIT";
|
|
1070
|
-
Namespace2["DEV_CENTER_DEV_SITE"] = "DEV_CENTER_DEV_SITE";
|
|
1071
|
-
return Namespace2;
|
|
1072
|
-
})(Namespace || {});
|
|
1073
|
-
var DeleteStatus = /* @__PURE__ */ ((DeleteStatus2) => {
|
|
1074
|
-
DeleteStatus2["UNKNOWN"] = "UNKNOWN";
|
|
1075
|
-
DeleteStatus2["TRASH"] = "TRASH";
|
|
1076
|
-
DeleteStatus2["DELETED"] = "DELETED";
|
|
1077
|
-
DeleteStatus2["PENDING_PURGE"] = "PENDING_PURGE";
|
|
1078
|
-
DeleteStatus2["PURGED_EXTERNALLY"] = "PURGED_EXTERNALLY";
|
|
1079
|
-
return DeleteStatus2;
|
|
1080
|
-
})(DeleteStatus || {});
|
|
1081
|
-
var SearchIndexingNotificationState = /* @__PURE__ */ ((SearchIndexingNotificationState2) => {
|
|
1082
|
-
SearchIndexingNotificationState2["Unknown"] = "Unknown";
|
|
1083
|
-
SearchIndexingNotificationState2["Off"] = "Off";
|
|
1084
|
-
SearchIndexingNotificationState2["On"] = "On";
|
|
1085
|
-
return SearchIndexingNotificationState2;
|
|
1086
|
-
})(SearchIndexingNotificationState || {});
|
|
1087
|
-
var PlacementType = /* @__PURE__ */ ((PlacementType2) => {
|
|
1088
|
-
PlacementType2["BEFORE"] = "BEFORE";
|
|
1089
|
-
PlacementType2["AFTER"] = "AFTER";
|
|
1090
|
-
PlacementType2["REPLACE"] = "REPLACE";
|
|
1091
|
-
return PlacementType2;
|
|
1092
|
-
})(PlacementType || {});
|
|
1093
|
-
var DayOfWeek = /* @__PURE__ */ ((DayOfWeek2) => {
|
|
1094
|
-
DayOfWeek2["MONDAY"] = "MONDAY";
|
|
1095
|
-
DayOfWeek2["TUESDAY"] = "TUESDAY";
|
|
1096
|
-
DayOfWeek2["WEDNESDAY"] = "WEDNESDAY";
|
|
1097
|
-
DayOfWeek2["THURSDAY"] = "THURSDAY";
|
|
1098
|
-
DayOfWeek2["FRIDAY"] = "FRIDAY";
|
|
1099
|
-
DayOfWeek2["SATURDAY"] = "SATURDAY";
|
|
1100
|
-
DayOfWeek2["SUNDAY"] = "SUNDAY";
|
|
1101
|
-
return DayOfWeek2;
|
|
1102
|
-
})(DayOfWeek || {});
|
|
1103
|
-
var ResolutionMethod = /* @__PURE__ */ ((ResolutionMethod2) => {
|
|
1104
|
-
ResolutionMethod2["QUERY_PARAM"] = "QUERY_PARAM";
|
|
1105
|
-
ResolutionMethod2["SUBDOMAIN"] = "SUBDOMAIN";
|
|
1106
|
-
ResolutionMethod2["SUBDIRECTORY"] = "SUBDIRECTORY";
|
|
1107
|
-
return ResolutionMethod2;
|
|
1108
|
-
})(ResolutionMethod || {});
|
|
1109
|
-
var WebhookIdentityType = /* @__PURE__ */ ((WebhookIdentityType2) => {
|
|
1110
|
-
WebhookIdentityType2["UNKNOWN"] = "UNKNOWN";
|
|
1111
|
-
WebhookIdentityType2["ANONYMOUS_VISITOR"] = "ANONYMOUS_VISITOR";
|
|
1112
|
-
WebhookIdentityType2["MEMBER"] = "MEMBER";
|
|
1113
|
-
WebhookIdentityType2["WIX_USER"] = "WIX_USER";
|
|
1114
|
-
WebhookIdentityType2["APP"] = "APP";
|
|
1115
|
-
return WebhookIdentityType2;
|
|
1116
|
-
})(WebhookIdentityType || {});
|
|
1117
|
-
async function createProgram2(program) {
|
|
1118
|
-
const { httpClient, sideEffects } = arguments[1];
|
|
1119
|
-
const payload = transformPaths2(
|
|
1120
|
-
renameKeysFromSDKRequestToRESTRequest({ program }),
|
|
1121
|
-
[
|
|
1122
|
-
{
|
|
1123
|
-
transformFn: transformSDKImageToRESTImage,
|
|
1124
|
-
paths: [{ path: "program.description.image" }]
|
|
1125
|
-
},
|
|
1126
|
-
{
|
|
1127
|
-
transformFn: transformSDKVideoV2ToRESTVideoV2,
|
|
1128
|
-
paths: [{ path: "program.description.video" }]
|
|
1129
|
-
},
|
|
1130
|
-
{
|
|
1131
|
-
transformFn: transformSDKPageURLToRESTPageURL,
|
|
1132
|
-
paths: [{ path: "program.seo.url" }]
|
|
1133
|
-
}
|
|
1134
|
-
]
|
|
1135
|
-
);
|
|
1136
|
-
const reqOpts = createProgram(payload);
|
|
1137
|
-
sideEffects?.onSiteCall?.();
|
|
1138
|
-
try {
|
|
1139
|
-
const result = await httpClient.request(reqOpts);
|
|
1140
|
-
sideEffects?.onSuccess?.(result);
|
|
1141
|
-
return renameKeysFromRESTResponseToSDKResponse(
|
|
1142
|
-
transformPaths2(result.data, [
|
|
1143
|
-
{
|
|
1144
|
-
transformFn: transformRESTImageToSDKImage,
|
|
1145
|
-
paths: [{ path: "program.description.image" }]
|
|
1146
|
-
},
|
|
1147
|
-
{
|
|
1148
|
-
transformFn: transformRESTVideoV2ToSDKVideoV2,
|
|
1149
|
-
paths: [{ path: "program.description.video" }]
|
|
1150
|
-
},
|
|
1151
|
-
{
|
|
1152
|
-
transformFn: transformRESTPageURLToSDKPageURL,
|
|
1153
|
-
paths: [{ path: "program.seo.url" }]
|
|
1154
|
-
}
|
|
1155
|
-
])
|
|
1156
|
-
)?.program;
|
|
1157
|
-
} catch (err) {
|
|
1158
|
-
const transformedError = sdkTransformError(
|
|
1159
|
-
err,
|
|
1160
|
-
{
|
|
1161
|
-
spreadPathsToArguments: {},
|
|
1162
|
-
explicitPathsToArguments: { program: "$[0]" },
|
|
1163
|
-
singleArgumentUnchanged: false
|
|
1164
|
-
},
|
|
1165
|
-
["program"]
|
|
1166
|
-
);
|
|
1167
|
-
sideEffects?.onError?.(err);
|
|
1168
|
-
throw transformedError;
|
|
1169
|
-
}
|
|
1170
|
-
}
|
|
1171
|
-
async function duplicateProgram2(programId) {
|
|
1172
|
-
const { httpClient, sideEffects } = arguments[1];
|
|
1173
|
-
const payload = renameKeysFromSDKRequestToRESTRequest({
|
|
1174
|
-
programId
|
|
1175
|
-
});
|
|
1176
|
-
const reqOpts = duplicateProgram(payload);
|
|
1177
|
-
sideEffects?.onSiteCall?.();
|
|
1178
|
-
try {
|
|
1179
|
-
const result = await httpClient.request(reqOpts);
|
|
1180
|
-
sideEffects?.onSuccess?.(result);
|
|
1181
|
-
return renameKeysFromRESTResponseToSDKResponse(
|
|
1182
|
-
transformPaths2(result.data, [
|
|
1183
|
-
{
|
|
1184
|
-
transformFn: transformRESTImageToSDKImage,
|
|
1185
|
-
paths: [{ path: "program.description.image" }]
|
|
1186
|
-
},
|
|
1187
|
-
{
|
|
1188
|
-
transformFn: transformRESTVideoV2ToSDKVideoV2,
|
|
1189
|
-
paths: [{ path: "program.description.video" }]
|
|
1190
|
-
},
|
|
1191
|
-
{
|
|
1192
|
-
transformFn: transformRESTPageURLToSDKPageURL,
|
|
1193
|
-
paths: [{ path: "program.seo.url" }]
|
|
1194
|
-
}
|
|
1195
|
-
])
|
|
1196
|
-
);
|
|
1197
|
-
} catch (err) {
|
|
1198
|
-
const transformedError = sdkTransformError(
|
|
1199
|
-
err,
|
|
1200
|
-
{
|
|
1201
|
-
spreadPathsToArguments: {},
|
|
1202
|
-
explicitPathsToArguments: { programId: "$[0]" },
|
|
1203
|
-
singleArgumentUnchanged: false
|
|
1204
|
-
},
|
|
1205
|
-
["programId"]
|
|
1206
|
-
);
|
|
1207
|
-
sideEffects?.onError?.(err);
|
|
1208
|
-
throw transformedError;
|
|
1209
|
-
}
|
|
1210
|
-
}
|
|
1211
|
-
async function getProgram2(programId) {
|
|
1212
|
-
const { httpClient, sideEffects } = arguments[1];
|
|
1213
|
-
const payload = renameKeysFromSDKRequestToRESTRequest({
|
|
1214
|
-
programId
|
|
1215
|
-
});
|
|
1216
|
-
const reqOpts = getProgram(payload);
|
|
1217
|
-
sideEffects?.onSiteCall?.();
|
|
1218
|
-
try {
|
|
1219
|
-
const result = await httpClient.request(reqOpts);
|
|
1220
|
-
sideEffects?.onSuccess?.(result);
|
|
1221
|
-
return renameKeysFromRESTResponseToSDKResponse(
|
|
1222
|
-
transformPaths2(result.data, [
|
|
1223
|
-
{
|
|
1224
|
-
transformFn: transformRESTImageToSDKImage,
|
|
1225
|
-
paths: [{ path: "program.description.image" }]
|
|
1226
|
-
},
|
|
1227
|
-
{
|
|
1228
|
-
transformFn: transformRESTVideoV2ToSDKVideoV2,
|
|
1229
|
-
paths: [{ path: "program.description.video" }]
|
|
1230
|
-
},
|
|
1231
|
-
{
|
|
1232
|
-
transformFn: transformRESTPageURLToSDKPageURL,
|
|
1233
|
-
paths: [{ path: "program.seo.url" }]
|
|
1234
|
-
}
|
|
1235
|
-
])
|
|
1236
|
-
)?.program;
|
|
1237
|
-
} catch (err) {
|
|
1238
|
-
const transformedError = sdkTransformError(
|
|
1239
|
-
err,
|
|
1240
|
-
{
|
|
1241
|
-
spreadPathsToArguments: {},
|
|
1242
|
-
explicitPathsToArguments: { programId: "$[0]" },
|
|
1243
|
-
singleArgumentUnchanged: false
|
|
1244
|
-
},
|
|
1245
|
-
["programId"]
|
|
1246
|
-
);
|
|
1247
|
-
sideEffects?.onError?.(err);
|
|
1248
|
-
throw transformedError;
|
|
1249
|
-
}
|
|
1250
|
-
}
|
|
1251
|
-
async function updateProgram2(_id, program) {
|
|
1252
|
-
const { httpClient, sideEffects } = arguments[2];
|
|
1253
|
-
const payload = transformPaths2(
|
|
1254
|
-
renameKeysFromSDKRequestToRESTRequest({ program: { ...program, id: _id } }),
|
|
1255
|
-
[
|
|
1256
|
-
{
|
|
1257
|
-
transformFn: transformSDKImageToRESTImage,
|
|
1258
|
-
paths: [{ path: "program.description.image" }]
|
|
1259
|
-
},
|
|
1260
|
-
{
|
|
1261
|
-
transformFn: transformSDKVideoV2ToRESTVideoV2,
|
|
1262
|
-
paths: [{ path: "program.description.video" }]
|
|
1263
|
-
},
|
|
1264
|
-
{
|
|
1265
|
-
transformFn: transformSDKPageURLToRESTPageURL,
|
|
1266
|
-
paths: [{ path: "program.seo.url" }]
|
|
1267
|
-
}
|
|
1268
|
-
]
|
|
1269
|
-
);
|
|
1270
|
-
const reqOpts = updateProgram(payload);
|
|
1271
|
-
sideEffects?.onSiteCall?.();
|
|
1272
|
-
try {
|
|
1273
|
-
const result = await httpClient.request(reqOpts);
|
|
1274
|
-
sideEffects?.onSuccess?.(result);
|
|
1275
|
-
return renameKeysFromRESTResponseToSDKResponse(
|
|
1276
|
-
transformPaths2(result.data, [
|
|
1277
|
-
{
|
|
1278
|
-
transformFn: transformRESTImageToSDKImage,
|
|
1279
|
-
paths: [{ path: "program.description.image" }]
|
|
1280
|
-
},
|
|
1281
|
-
{
|
|
1282
|
-
transformFn: transformRESTVideoV2ToSDKVideoV2,
|
|
1283
|
-
paths: [{ path: "program.description.video" }]
|
|
1284
|
-
},
|
|
1285
|
-
{
|
|
1286
|
-
transformFn: transformRESTPageURLToSDKPageURL,
|
|
1287
|
-
paths: [{ path: "program.seo.url" }]
|
|
1288
|
-
}
|
|
1289
|
-
])
|
|
1290
|
-
)?.program;
|
|
1291
|
-
} catch (err) {
|
|
1292
|
-
const transformedError = sdkTransformError(
|
|
1293
|
-
err,
|
|
1294
|
-
{
|
|
1295
|
-
spreadPathsToArguments: { program: "$[1]" },
|
|
1296
|
-
explicitPathsToArguments: { "program.id": "$[0]" },
|
|
1297
|
-
singleArgumentUnchanged: false
|
|
1298
|
-
},
|
|
1299
|
-
["_id", "program"]
|
|
1300
|
-
);
|
|
1301
|
-
sideEffects?.onError?.(err);
|
|
1302
|
-
throw transformedError;
|
|
1303
|
-
}
|
|
1304
|
-
}
|
|
1305
|
-
async function deleteProgram2(programId) {
|
|
1306
|
-
const { httpClient, sideEffects } = arguments[1];
|
|
1307
|
-
const payload = renameKeysFromSDKRequestToRESTRequest({
|
|
1308
|
-
programId
|
|
1309
|
-
});
|
|
1310
|
-
const reqOpts = deleteProgram(payload);
|
|
1311
|
-
sideEffects?.onSiteCall?.();
|
|
1312
|
-
try {
|
|
1313
|
-
const result = await httpClient.request(reqOpts);
|
|
1314
|
-
sideEffects?.onSuccess?.(result);
|
|
1315
|
-
} catch (err) {
|
|
1316
|
-
const transformedError = sdkTransformError(
|
|
1317
|
-
err,
|
|
1318
|
-
{
|
|
1319
|
-
spreadPathsToArguments: {},
|
|
1320
|
-
explicitPathsToArguments: { programId: "$[0]" },
|
|
1321
|
-
singleArgumentUnchanged: false
|
|
1322
|
-
},
|
|
1323
|
-
["programId"]
|
|
1324
|
-
);
|
|
1325
|
-
sideEffects?.onError?.(err);
|
|
1326
|
-
throw transformedError;
|
|
1327
|
-
}
|
|
1328
|
-
}
|
|
1329
|
-
function queryPrograms2() {
|
|
1330
|
-
const { httpClient, sideEffects } = arguments[0];
|
|
1331
|
-
return queryBuilder({
|
|
1332
|
-
func: async (payload) => {
|
|
1333
|
-
const reqOpts = queryPrograms(payload);
|
|
1334
|
-
sideEffects?.onSiteCall?.();
|
|
1335
|
-
try {
|
|
1336
|
-
const result = await httpClient.request(reqOpts);
|
|
1337
|
-
sideEffects?.onSuccess?.(result);
|
|
1338
|
-
return result;
|
|
1339
|
-
} catch (err) {
|
|
1340
|
-
sideEffects?.onError?.(err);
|
|
1341
|
-
throw err;
|
|
1342
|
-
}
|
|
1343
|
-
},
|
|
1344
|
-
requestTransformer: (query) => {
|
|
1345
|
-
const args = [query, {}];
|
|
1346
|
-
return renameKeysFromSDKRequestToRESTRequest({
|
|
1347
|
-
...args?.[1],
|
|
1348
|
-
query: args?.[0]
|
|
1349
|
-
});
|
|
1350
|
-
},
|
|
1351
|
-
responseTransformer: ({ data }) => {
|
|
1352
|
-
const transformedData = renameKeysFromRESTResponseToSDKResponse(
|
|
1353
|
-
transformPaths2(data, [
|
|
1354
|
-
{
|
|
1355
|
-
transformFn: transformRESTImageToSDKImage,
|
|
1356
|
-
paths: [{ path: "programs.description.image" }]
|
|
1357
|
-
},
|
|
1358
|
-
{
|
|
1359
|
-
transformFn: transformRESTVideoV2ToSDKVideoV2,
|
|
1360
|
-
paths: [{ path: "programs.description.video" }]
|
|
1361
|
-
},
|
|
1362
|
-
{
|
|
1363
|
-
transformFn: transformRESTPageURLToSDKPageURL,
|
|
1364
|
-
paths: [{ path: "programs.seo.url" }]
|
|
1365
|
-
}
|
|
1366
|
-
])
|
|
1367
|
-
);
|
|
1368
|
-
return {
|
|
1369
|
-
items: transformedData?.programs,
|
|
1370
|
-
pagingMetadata: transformedData?.pagingMetadata
|
|
1371
|
-
};
|
|
1372
|
-
},
|
|
1373
|
-
errorTransformer: (err) => {
|
|
1374
|
-
const transformedError = sdkTransformError(err, {
|
|
1375
|
-
spreadPathsToArguments: {},
|
|
1376
|
-
explicitPathsToArguments: { query: "$[0]" },
|
|
1377
|
-
singleArgumentUnchanged: false
|
|
1378
|
-
});
|
|
1379
|
-
throw transformedError;
|
|
1380
|
-
},
|
|
1381
|
-
pagingMethod: "CURSOR",
|
|
1382
|
-
transformationPaths: {}
|
|
1383
|
-
});
|
|
1384
|
-
}
|
|
1385
|
-
async function typedQueryPrograms(query) {
|
|
1386
|
-
const { httpClient, sideEffects } = arguments[1];
|
|
1387
|
-
const payload = renameKeysFromSDKRequestToRESTRequest({ query });
|
|
1388
|
-
const reqOpts = queryPrograms(payload);
|
|
1389
|
-
sideEffects?.onSiteCall?.();
|
|
1390
|
-
try {
|
|
1391
|
-
const result = await httpClient.request(reqOpts);
|
|
1392
|
-
sideEffects?.onSuccess?.(result);
|
|
1393
|
-
return renameKeysFromRESTResponseToSDKResponse(
|
|
1394
|
-
transformPaths2(result.data, [
|
|
1395
|
-
{
|
|
1396
|
-
transformFn: transformRESTImageToSDKImage,
|
|
1397
|
-
paths: [{ path: "programs.description.image" }]
|
|
1398
|
-
},
|
|
1399
|
-
{
|
|
1400
|
-
transformFn: transformRESTVideoV2ToSDKVideoV2,
|
|
1401
|
-
paths: [{ path: "programs.description.video" }]
|
|
1402
|
-
},
|
|
1403
|
-
{
|
|
1404
|
-
transformFn: transformRESTPageURLToSDKPageURL,
|
|
1405
|
-
paths: [{ path: "programs.seo.url" }]
|
|
1406
|
-
}
|
|
1407
|
-
])
|
|
1408
|
-
);
|
|
1409
|
-
} catch (err) {
|
|
1410
|
-
const transformedError = sdkTransformError(
|
|
1411
|
-
err,
|
|
1412
|
-
{
|
|
1413
|
-
spreadPathsToArguments: {},
|
|
1414
|
-
explicitPathsToArguments: { query: "$[0]" },
|
|
1415
|
-
singleArgumentUnchanged: false
|
|
1416
|
-
},
|
|
1417
|
-
["query"]
|
|
1418
|
-
);
|
|
1419
|
-
sideEffects?.onError?.(err);
|
|
1420
|
-
throw transformedError;
|
|
1421
|
-
}
|
|
1422
|
-
}
|
|
1423
|
-
var utils = {
|
|
1424
|
-
query: /* @__PURE__ */ createQueryUtils(),
|
|
1425
|
-
search: /* @__PURE__ */ createSearchUtils()
|
|
1426
|
-
};
|
|
1427
|
-
async function searchPrograms2(search) {
|
|
1428
|
-
const { httpClient, sideEffects } = arguments[1];
|
|
1429
|
-
const payload = renameKeysFromSDKRequestToRESTRequest({ search });
|
|
1430
|
-
const reqOpts = searchPrograms(payload);
|
|
1431
|
-
sideEffects?.onSiteCall?.();
|
|
1432
|
-
try {
|
|
1433
|
-
const result = await httpClient.request(reqOpts);
|
|
1434
|
-
sideEffects?.onSuccess?.(result);
|
|
1435
|
-
return renameKeysFromRESTResponseToSDKResponse(
|
|
1436
|
-
transformPaths2(result.data, [
|
|
1437
|
-
{
|
|
1438
|
-
transformFn: transformRESTImageToSDKImage,
|
|
1439
|
-
paths: [{ path: "programs.description.image" }]
|
|
1440
|
-
},
|
|
1441
|
-
{
|
|
1442
|
-
transformFn: transformRESTVideoV2ToSDKVideoV2,
|
|
1443
|
-
paths: [{ path: "programs.description.video" }]
|
|
1444
|
-
},
|
|
1445
|
-
{
|
|
1446
|
-
transformFn: transformRESTPageURLToSDKPageURL,
|
|
1447
|
-
paths: [{ path: "programs.seo.url" }]
|
|
1448
|
-
}
|
|
1449
|
-
])
|
|
1450
|
-
);
|
|
1451
|
-
} catch (err) {
|
|
1452
|
-
const transformedError = sdkTransformError(
|
|
1453
|
-
err,
|
|
1454
|
-
{
|
|
1455
|
-
spreadPathsToArguments: {},
|
|
1456
|
-
explicitPathsToArguments: { search: "$[0]" },
|
|
1457
|
-
singleArgumentUnchanged: false
|
|
1458
|
-
},
|
|
1459
|
-
["search"]
|
|
1460
|
-
);
|
|
1461
|
-
sideEffects?.onError?.(err);
|
|
1462
|
-
throw transformedError;
|
|
1463
|
-
}
|
|
1464
|
-
}
|
|
1465
|
-
async function publishProgram2(programId) {
|
|
1466
|
-
const { httpClient, sideEffects } = arguments[1];
|
|
1467
|
-
const payload = renameKeysFromSDKRequestToRESTRequest({
|
|
1468
|
-
programId
|
|
1469
|
-
});
|
|
1470
|
-
const reqOpts = publishProgram(payload);
|
|
1471
|
-
sideEffects?.onSiteCall?.();
|
|
1472
|
-
try {
|
|
1473
|
-
const result = await httpClient.request(reqOpts);
|
|
1474
|
-
sideEffects?.onSuccess?.(result);
|
|
1475
|
-
return renameKeysFromRESTResponseToSDKResponse(
|
|
1476
|
-
transformPaths2(result.data, [
|
|
1477
|
-
{
|
|
1478
|
-
transformFn: transformRESTImageToSDKImage,
|
|
1479
|
-
paths: [{ path: "program.description.image" }]
|
|
1480
|
-
},
|
|
1481
|
-
{
|
|
1482
|
-
transformFn: transformRESTVideoV2ToSDKVideoV2,
|
|
1483
|
-
paths: [{ path: "program.description.video" }]
|
|
1484
|
-
},
|
|
1485
|
-
{
|
|
1486
|
-
transformFn: transformRESTPageURLToSDKPageURL,
|
|
1487
|
-
paths: [{ path: "program.seo.url" }]
|
|
1488
|
-
}
|
|
1489
|
-
])
|
|
1490
|
-
);
|
|
1491
|
-
} catch (err) {
|
|
1492
|
-
const transformedError = sdkTransformError(
|
|
1493
|
-
err,
|
|
1494
|
-
{
|
|
1495
|
-
spreadPathsToArguments: {},
|
|
1496
|
-
explicitPathsToArguments: { programId: "$[0]" },
|
|
1497
|
-
singleArgumentUnchanged: false
|
|
1498
|
-
},
|
|
1499
|
-
["programId"]
|
|
1500
|
-
);
|
|
1501
|
-
sideEffects?.onError?.(err);
|
|
1502
|
-
throw transformedError;
|
|
1503
|
-
}
|
|
1504
|
-
}
|
|
1505
|
-
async function endProgram2(programId) {
|
|
1506
|
-
const { httpClient, sideEffects } = arguments[1];
|
|
1507
|
-
const payload = renameKeysFromSDKRequestToRESTRequest({
|
|
1508
|
-
programId
|
|
1509
|
-
});
|
|
1510
|
-
const reqOpts = endProgram(payload);
|
|
1511
|
-
sideEffects?.onSiteCall?.();
|
|
1512
|
-
try {
|
|
1513
|
-
const result = await httpClient.request(reqOpts);
|
|
1514
|
-
sideEffects?.onSuccess?.(result);
|
|
1515
|
-
return renameKeysFromRESTResponseToSDKResponse(
|
|
1516
|
-
transformPaths2(result.data, [
|
|
1517
|
-
{
|
|
1518
|
-
transformFn: transformRESTImageToSDKImage,
|
|
1519
|
-
paths: [{ path: "program.description.image" }]
|
|
1520
|
-
},
|
|
1521
|
-
{
|
|
1522
|
-
transformFn: transformRESTVideoV2ToSDKVideoV2,
|
|
1523
|
-
paths: [{ path: "program.description.video" }]
|
|
1524
|
-
},
|
|
1525
|
-
{
|
|
1526
|
-
transformFn: transformRESTPageURLToSDKPageURL,
|
|
1527
|
-
paths: [{ path: "program.seo.url" }]
|
|
1528
|
-
}
|
|
1529
|
-
])
|
|
1530
|
-
);
|
|
1531
|
-
} catch (err) {
|
|
1532
|
-
const transformedError = sdkTransformError(
|
|
1533
|
-
err,
|
|
1534
|
-
{
|
|
1535
|
-
spreadPathsToArguments: {},
|
|
1536
|
-
explicitPathsToArguments: { programId: "$[0]" },
|
|
1537
|
-
singleArgumentUnchanged: false
|
|
1538
|
-
},
|
|
1539
|
-
["programId"]
|
|
1540
|
-
);
|
|
1541
|
-
sideEffects?.onError?.(err);
|
|
1542
|
-
throw transformedError;
|
|
1543
|
-
}
|
|
1544
|
-
}
|
|
1545
|
-
async function archiveProgram2(programId) {
|
|
1546
|
-
const { httpClient, sideEffects } = arguments[1];
|
|
1547
|
-
const payload = renameKeysFromSDKRequestToRESTRequest({
|
|
1548
|
-
programId
|
|
1549
|
-
});
|
|
1550
|
-
const reqOpts = archiveProgram(payload);
|
|
1551
|
-
sideEffects?.onSiteCall?.();
|
|
1552
|
-
try {
|
|
1553
|
-
const result = await httpClient.request(reqOpts);
|
|
1554
|
-
sideEffects?.onSuccess?.(result);
|
|
1555
|
-
return renameKeysFromRESTResponseToSDKResponse(
|
|
1556
|
-
transformPaths2(result.data, [
|
|
1557
|
-
{
|
|
1558
|
-
transformFn: transformRESTImageToSDKImage,
|
|
1559
|
-
paths: [{ path: "program.description.image" }]
|
|
1560
|
-
},
|
|
1561
|
-
{
|
|
1562
|
-
transformFn: transformRESTVideoV2ToSDKVideoV2,
|
|
1563
|
-
paths: [{ path: "program.description.video" }]
|
|
1564
|
-
},
|
|
1565
|
-
{
|
|
1566
|
-
transformFn: transformRESTPageURLToSDKPageURL,
|
|
1567
|
-
paths: [{ path: "program.seo.url" }]
|
|
1568
|
-
}
|
|
1569
|
-
])
|
|
1570
|
-
);
|
|
1571
|
-
} catch (err) {
|
|
1572
|
-
const transformedError = sdkTransformError(
|
|
1573
|
-
err,
|
|
1574
|
-
{
|
|
1575
|
-
spreadPathsToArguments: {},
|
|
1576
|
-
explicitPathsToArguments: { programId: "$[0]" },
|
|
1577
|
-
singleArgumentUnchanged: false
|
|
1578
|
-
},
|
|
1579
|
-
["programId"]
|
|
1580
|
-
);
|
|
1581
|
-
sideEffects?.onError?.(err);
|
|
1582
|
-
throw transformedError;
|
|
1583
|
-
}
|
|
1584
|
-
}
|
|
1585
|
-
async function bulkUpdatePrograms2(programs, options) {
|
|
1586
|
-
const { httpClient, sideEffects } = arguments[2];
|
|
1587
|
-
const payload = transformPaths2(
|
|
1588
|
-
renameKeysFromSDKRequestToRESTRequest({
|
|
1589
|
-
programs,
|
|
1590
|
-
returnEntity: options?.returnEntity
|
|
1591
|
-
}),
|
|
1592
|
-
[
|
|
1593
|
-
{
|
|
1594
|
-
transformFn: transformSDKImageToRESTImage,
|
|
1595
|
-
paths: [{ path: "programs.program.description.image" }]
|
|
1596
|
-
},
|
|
1597
|
-
{
|
|
1598
|
-
transformFn: transformSDKVideoV2ToRESTVideoV2,
|
|
1599
|
-
paths: [{ path: "programs.program.description.video" }]
|
|
1600
|
-
},
|
|
1601
|
-
{
|
|
1602
|
-
transformFn: transformSDKPageURLToRESTPageURL,
|
|
1603
|
-
paths: [{ path: "programs.program.seo.url" }]
|
|
1604
|
-
}
|
|
1605
|
-
]
|
|
1606
|
-
);
|
|
1607
|
-
const reqOpts = bulkUpdatePrograms(payload);
|
|
1608
|
-
sideEffects?.onSiteCall?.();
|
|
1609
|
-
try {
|
|
1610
|
-
const result = await httpClient.request(reqOpts);
|
|
1611
|
-
sideEffects?.onSuccess?.(result);
|
|
1612
|
-
return renameKeysFromRESTResponseToSDKResponse(
|
|
1613
|
-
transformPaths2(result.data, [
|
|
1614
|
-
{
|
|
1615
|
-
transformFn: transformRESTImageToSDKImage,
|
|
1616
|
-
paths: [{ path: "results.item.description.image" }]
|
|
1617
|
-
},
|
|
1618
|
-
{
|
|
1619
|
-
transformFn: transformRESTVideoV2ToSDKVideoV2,
|
|
1620
|
-
paths: [{ path: "results.item.description.video" }]
|
|
1621
|
-
},
|
|
1622
|
-
{
|
|
1623
|
-
transformFn: transformRESTPageURLToSDKPageURL,
|
|
1624
|
-
paths: [{ path: "results.item.seo.url" }]
|
|
1625
|
-
}
|
|
1626
|
-
])
|
|
1627
|
-
);
|
|
1628
|
-
} catch (err) {
|
|
1629
|
-
const transformedError = sdkTransformError(
|
|
1630
|
-
err,
|
|
1631
|
-
{
|
|
1632
|
-
spreadPathsToArguments: {},
|
|
1633
|
-
explicitPathsToArguments: {
|
|
1634
|
-
programs: "$[0]",
|
|
1635
|
-
returnEntity: "$[1].returnEntity"
|
|
1636
|
-
},
|
|
1637
|
-
singleArgumentUnchanged: false
|
|
1638
|
-
},
|
|
1639
|
-
["programs", "options"]
|
|
1640
|
-
);
|
|
1641
|
-
sideEffects?.onError?.(err);
|
|
1642
|
-
throw transformedError;
|
|
1643
|
-
}
|
|
1644
|
-
}
|
|
1645
|
-
async function countPrograms2(options) {
|
|
1646
|
-
const { httpClient, sideEffects } = arguments[1];
|
|
1647
|
-
const payload = renameKeysFromSDKRequestToRESTRequest({
|
|
1648
|
-
filter: options?.filter
|
|
1649
|
-
});
|
|
1650
|
-
const reqOpts = countPrograms(payload);
|
|
1651
|
-
sideEffects?.onSiteCall?.();
|
|
1652
|
-
try {
|
|
1653
|
-
const result = await httpClient.request(reqOpts);
|
|
1654
|
-
sideEffects?.onSuccess?.(result);
|
|
1655
|
-
return renameKeysFromRESTResponseToSDKResponse(result.data);
|
|
1656
|
-
} catch (err) {
|
|
1657
|
-
const transformedError = sdkTransformError(
|
|
1658
|
-
err,
|
|
1659
|
-
{
|
|
1660
|
-
spreadPathsToArguments: {},
|
|
1661
|
-
explicitPathsToArguments: { filter: "$[0].filter" },
|
|
1662
|
-
singleArgumentUnchanged: false
|
|
1663
|
-
},
|
|
1664
|
-
["options"]
|
|
1665
|
-
);
|
|
1666
|
-
sideEffects?.onError?.(err);
|
|
1667
|
-
throw transformedError;
|
|
1668
|
-
}
|
|
1669
|
-
}
|
|
1670
|
-
async function listSamplePrograms2() {
|
|
1671
|
-
const { httpClient, sideEffects } = arguments[0];
|
|
1672
|
-
const payload = renameKeysFromSDKRequestToRESTRequest({});
|
|
1673
|
-
const reqOpts = listSamplePrograms(payload);
|
|
1674
|
-
sideEffects?.onSiteCall?.();
|
|
1675
|
-
try {
|
|
1676
|
-
const result = await httpClient.request(reqOpts);
|
|
1677
|
-
sideEffects?.onSuccess?.(result);
|
|
1678
|
-
return renameKeysFromRESTResponseToSDKResponse(
|
|
1679
|
-
transformPaths2(result.data, [
|
|
1680
|
-
{
|
|
1681
|
-
transformFn: transformRESTImageToSDKImage,
|
|
1682
|
-
paths: [{ path: "programs.program.description.image" }]
|
|
1683
|
-
},
|
|
1684
|
-
{
|
|
1685
|
-
transformFn: transformRESTVideoV2ToSDKVideoV2,
|
|
1686
|
-
paths: [{ path: "programs.program.description.video" }]
|
|
1687
|
-
},
|
|
1688
|
-
{
|
|
1689
|
-
transformFn: transformRESTPageURLToSDKPageURL,
|
|
1690
|
-
paths: [{ path: "programs.program.seo.url" }]
|
|
1691
|
-
}
|
|
1692
|
-
])
|
|
1693
|
-
);
|
|
1694
|
-
} catch (err) {
|
|
1695
|
-
const transformedError = sdkTransformError(
|
|
1696
|
-
err,
|
|
1697
|
-
{
|
|
1698
|
-
spreadPathsToArguments: {},
|
|
1699
|
-
explicitPathsToArguments: {},
|
|
1700
|
-
singleArgumentUnchanged: false
|
|
1701
|
-
},
|
|
1702
|
-
[]
|
|
1703
|
-
);
|
|
1704
|
-
sideEffects?.onError?.(err);
|
|
1705
|
-
throw transformedError;
|
|
1706
|
-
}
|
|
1707
|
-
}
|
|
1708
|
-
|
|
1709
|
-
// src/online-programs-v3-program-programs.public.ts
|
|
1710
|
-
function createProgram3(httpClient) {
|
|
1711
|
-
return (program) => createProgram2(
|
|
1712
|
-
program,
|
|
1713
|
-
// @ts-ignore
|
|
1714
|
-
{ httpClient }
|
|
1715
|
-
);
|
|
1716
|
-
}
|
|
1717
|
-
function duplicateProgram3(httpClient) {
|
|
1718
|
-
return (programId) => duplicateProgram2(
|
|
1719
|
-
programId,
|
|
1720
|
-
// @ts-ignore
|
|
1721
|
-
{ httpClient }
|
|
1722
|
-
);
|
|
1723
|
-
}
|
|
1724
|
-
function getProgram3(httpClient) {
|
|
1725
|
-
return (programId) => getProgram2(
|
|
1726
|
-
programId,
|
|
1727
|
-
// @ts-ignore
|
|
1728
|
-
{ httpClient }
|
|
1729
|
-
);
|
|
1730
|
-
}
|
|
1731
|
-
function updateProgram3(httpClient) {
|
|
1732
|
-
return (_id, program) => updateProgram2(
|
|
1733
|
-
_id,
|
|
1734
|
-
program,
|
|
1735
|
-
// @ts-ignore
|
|
1736
|
-
{ httpClient }
|
|
1737
|
-
);
|
|
1738
|
-
}
|
|
1739
|
-
function deleteProgram3(httpClient) {
|
|
1740
|
-
return (programId) => deleteProgram2(
|
|
1741
|
-
programId,
|
|
1742
|
-
// @ts-ignore
|
|
1743
|
-
{ httpClient }
|
|
1744
|
-
);
|
|
1745
|
-
}
|
|
1746
|
-
function queryPrograms3(httpClient) {
|
|
1747
|
-
return () => queryPrograms2(
|
|
1748
|
-
// @ts-ignore
|
|
1749
|
-
{ httpClient }
|
|
1750
|
-
);
|
|
1751
|
-
}
|
|
1752
|
-
function typedQueryPrograms2(httpClient) {
|
|
1753
|
-
return (query) => typedQueryPrograms(
|
|
1754
|
-
query,
|
|
1755
|
-
// @ts-ignore
|
|
1756
|
-
{ httpClient }
|
|
1757
|
-
);
|
|
1758
|
-
}
|
|
1759
|
-
function searchPrograms3(httpClient) {
|
|
1760
|
-
return (search) => searchPrograms2(
|
|
1761
|
-
search,
|
|
1762
|
-
// @ts-ignore
|
|
1763
|
-
{ httpClient }
|
|
1764
|
-
);
|
|
1765
|
-
}
|
|
1766
|
-
function publishProgram3(httpClient) {
|
|
1767
|
-
return (programId) => publishProgram2(
|
|
1768
|
-
programId,
|
|
1769
|
-
// @ts-ignore
|
|
1770
|
-
{ httpClient }
|
|
1771
|
-
);
|
|
1772
|
-
}
|
|
1773
|
-
function endProgram3(httpClient) {
|
|
1774
|
-
return (programId) => endProgram2(
|
|
1775
|
-
programId,
|
|
1776
|
-
// @ts-ignore
|
|
1777
|
-
{ httpClient }
|
|
1778
|
-
);
|
|
1779
|
-
}
|
|
1780
|
-
function archiveProgram3(httpClient) {
|
|
1781
|
-
return (programId) => archiveProgram2(
|
|
1782
|
-
programId,
|
|
1783
|
-
// @ts-ignore
|
|
1784
|
-
{ httpClient }
|
|
1785
|
-
);
|
|
1786
|
-
}
|
|
1787
|
-
function bulkUpdatePrograms3(httpClient) {
|
|
1788
|
-
return (programs, options) => bulkUpdatePrograms2(
|
|
1789
|
-
programs,
|
|
1790
|
-
options,
|
|
1791
|
-
// @ts-ignore
|
|
1792
|
-
{ httpClient }
|
|
1793
|
-
);
|
|
1794
|
-
}
|
|
1795
|
-
function countPrograms3(httpClient) {
|
|
1796
|
-
return (options) => countPrograms2(
|
|
1797
|
-
options,
|
|
1798
|
-
// @ts-ignore
|
|
1799
|
-
{ httpClient }
|
|
1800
|
-
);
|
|
1801
|
-
}
|
|
1802
|
-
function listSamplePrograms3(httpClient) {
|
|
1803
|
-
return () => listSamplePrograms2(
|
|
1804
|
-
// @ts-ignore
|
|
1805
|
-
{ httpClient }
|
|
1806
|
-
);
|
|
1807
|
-
}
|
|
1808
|
-
|
|
1809
|
-
// src/online-programs-v3-program-programs.context.ts
|
|
1810
|
-
import { createRESTModule } from "@wix/sdk-runtime/rest-modules";
|
|
1811
|
-
import { createQueryOverloadRouter } from "@wix/sdk-runtime/query-method-router";
|
|
1812
|
-
function customQueryPrograms(httpClient) {
|
|
1813
|
-
const router = /* @__PURE__ */ createQueryOverloadRouter({
|
|
1814
|
-
builderQueryFunction: () => queryPrograms3(httpClient)(),
|
|
1815
|
-
typedQueryFunction: (query) => typedQueryPrograms2(httpClient)(query),
|
|
1816
|
-
hasOptionsParameter: false
|
|
1817
|
-
});
|
|
1818
|
-
function overloadedQuery(query) {
|
|
1819
|
-
return router(...arguments);
|
|
1820
|
-
}
|
|
1821
|
-
return overloadedQuery;
|
|
1822
|
-
}
|
|
1823
|
-
var createProgram4 = /* @__PURE__ */ createRESTModule(createProgram3);
|
|
1824
|
-
var duplicateProgram4 = /* @__PURE__ */ createRESTModule(duplicateProgram3);
|
|
1825
|
-
var getProgram4 = /* @__PURE__ */ createRESTModule(getProgram3);
|
|
1826
|
-
var updateProgram4 = /* @__PURE__ */ createRESTModule(updateProgram3);
|
|
1827
|
-
var deleteProgram4 = /* @__PURE__ */ createRESTModule(deleteProgram3);
|
|
1828
|
-
var searchPrograms4 = /* @__PURE__ */ createRESTModule(searchPrograms3);
|
|
1829
|
-
var publishProgram4 = /* @__PURE__ */ createRESTModule(publishProgram3);
|
|
1830
|
-
var endProgram4 = /* @__PURE__ */ createRESTModule(endProgram3);
|
|
1831
|
-
var archiveProgram4 = /* @__PURE__ */ createRESTModule(archiveProgram3);
|
|
1832
|
-
var bulkUpdatePrograms4 = /* @__PURE__ */ createRESTModule(bulkUpdatePrograms3);
|
|
1833
|
-
var countPrograms4 = /* @__PURE__ */ createRESTModule(countPrograms3);
|
|
1834
|
-
var listSamplePrograms4 = /* @__PURE__ */ createRESTModule(listSamplePrograms3);
|
|
1835
|
-
var queryPrograms4 = /* @__PURE__ */ createRESTModule(customQueryPrograms);
|
|
1836
|
-
export {
|
|
1837
|
-
AccessType,
|
|
1838
|
-
AggregationType,
|
|
1839
|
-
BulkActionType,
|
|
1840
|
-
DayOfWeek,
|
|
1841
|
-
DeleteStatus,
|
|
1842
|
-
Enum,
|
|
1843
|
-
Interval,
|
|
1844
|
-
MissingValues,
|
|
1845
|
-
Mode,
|
|
1846
|
-
Namespace,
|
|
1847
|
-
NestedAggregationType,
|
|
1848
|
-
PlacementType,
|
|
1849
|
-
ResolutionMethod,
|
|
1850
|
-
ScalarType,
|
|
1851
|
-
SearchIndexingNotificationState,
|
|
1852
|
-
SiteCreatedContext,
|
|
1853
|
-
SortDirection,
|
|
1854
|
-
SortOrder,
|
|
1855
|
-
SortType,
|
|
1856
|
-
State,
|
|
1857
|
-
Status,
|
|
1858
|
-
Trigger,
|
|
1859
|
-
WebhookIdentityType,
|
|
1860
|
-
archiveProgram4 as archiveProgram,
|
|
1861
|
-
bulkUpdatePrograms4 as bulkUpdatePrograms,
|
|
1862
|
-
countPrograms4 as countPrograms,
|
|
1863
|
-
createProgram4 as createProgram,
|
|
1864
|
-
deleteProgram4 as deleteProgram,
|
|
1865
|
-
duplicateProgram4 as duplicateProgram,
|
|
1866
|
-
endProgram4 as endProgram,
|
|
1867
|
-
getProgram4 as getProgram,
|
|
1868
|
-
listSamplePrograms4 as listSamplePrograms,
|
|
1869
|
-
publishProgram4 as publishProgram,
|
|
1870
|
-
queryPrograms4 as queryPrograms,
|
|
1871
|
-
searchPrograms4 as searchPrograms,
|
|
1872
|
-
updateProgram4 as updateProgram,
|
|
1873
|
-
utils
|
|
1874
|
-
};
|
|
1875
|
-
//# sourceMappingURL=index.mjs.map
|