@wix/media 1.0.51 → 1.0.53
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/cjs/index.js +5 -1
- package/build/cjs/index.js.map +1 -1
- package/build/cjs/index.typings.js +5 -1
- package/build/cjs/index.typings.js.map +1 -1
- package/build/cjs/meta.js +5 -1
- package/build/cjs/meta.js.map +1 -1
- package/build/cjs/src/media-site-media-v1-file-descriptor.http.js +350 -316
- package/build/cjs/src/media-site-media-v1-file-descriptor.http.js.map +1 -1
- package/build/cjs/src/media-site-media-v1-file-descriptor.meta.d.ts +1 -1
- package/build/cjs/src/media-site-media-v1-file-descriptor.meta.js +5 -1
- package/build/cjs/src/media-site-media-v1-file-descriptor.meta.js.map +1 -1
- package/build/cjs/src/media-site-media-v1-file-descriptor.public.d.ts +11 -11
- package/build/cjs/src/media-site-media-v1-file-descriptor.types.d.ts +72 -6
- package/build/cjs/src/media-site-media-v1-file-descriptor.types.js +10 -10
- package/build/cjs/src/media-site-media-v1-file-descriptor.types.js.map +1 -1
- package/build/cjs/src/media-site-media-v1-file-descriptor.universal.d.ts +72 -6
- package/build/cjs/src/media-site-media-v1-file-descriptor.universal.js +155 -67
- package/build/cjs/src/media-site-media-v1-file-descriptor.universal.js.map +1 -1
- package/build/cjs/src/media-site-media-v1-folder.http.js +84 -89
- package/build/cjs/src/media-site-media-v1-folder.http.js.map +1 -1
- package/build/cjs/src/media-site-media-v1-folder.meta.d.ts +1 -1
- package/build/cjs/src/media-site-media-v1-folder.meta.js +5 -1
- package/build/cjs/src/media-site-media-v1-folder.meta.js.map +1 -1
- package/build/cjs/src/media-site-media-v1-folder.public.d.ts +6 -6
- package/build/cjs/src/media-site-media-v1-folder.types.d.ts +71 -5
- package/build/cjs/src/media-site-media-v1-folder.types.js +4 -4
- package/build/cjs/src/media-site-media-v1-folder.types.js.map +1 -1
- package/build/cjs/src/media-site-media-v1-folder.universal.d.ts +71 -5
- package/build/cjs/src/media-site-media-v1-folder.universal.js +74 -35
- package/build/cjs/src/media-site-media-v1-folder.universal.js.map +1 -1
- package/build/es/src/media-site-media-v1-file-descriptor.http.js +350 -316
- package/build/es/src/media-site-media-v1-file-descriptor.http.js.map +1 -1
- package/build/es/src/media-site-media-v1-file-descriptor.meta.d.ts +1 -1
- package/build/es/src/media-site-media-v1-file-descriptor.public.d.ts +11 -11
- package/build/es/src/media-site-media-v1-file-descriptor.types.d.ts +72 -6
- package/build/es/src/media-site-media-v1-file-descriptor.types.js.map +1 -1
- package/build/es/src/media-site-media-v1-file-descriptor.universal.d.ts +72 -6
- package/build/es/src/media-site-media-v1-file-descriptor.universal.js +141 -57
- package/build/es/src/media-site-media-v1-file-descriptor.universal.js.map +1 -1
- package/build/es/src/media-site-media-v1-folder.http.js +84 -89
- package/build/es/src/media-site-media-v1-folder.http.js.map +1 -1
- package/build/es/src/media-site-media-v1-folder.meta.d.ts +1 -1
- package/build/es/src/media-site-media-v1-folder.public.d.ts +6 -6
- package/build/es/src/media-site-media-v1-folder.types.d.ts +71 -5
- package/build/es/src/media-site-media-v1-folder.types.js.map +1 -1
- package/build/es/src/media-site-media-v1-folder.universal.d.ts +71 -5
- package/build/es/src/media-site-media-v1-folder.universal.js +66 -31
- package/build/es/src/media-site-media-v1-folder.universal.js.map +1 -1
- package/package.json +7 -3
|
@@ -1,31 +1,9 @@
|
|
|
1
1
|
import { toURLSearchParams } from '@wix/metro-runtime';
|
|
2
|
-
import {
|
|
2
|
+
import { transformSDKTimestampToRESTTimestamp } from '@wix/sdk-runtime/transformations/timestamp';
|
|
3
|
+
import { transformRESTTimestampToSDKTimestamp } from '@wix/sdk-runtime/transformations/timestamp';
|
|
4
|
+
import { transformSDKFieldMaskToRESTFieldMask } from '@wix/sdk-runtime/transformations/field-mask';
|
|
5
|
+
import { transformPaths } from '@wix/sdk-runtime/transformations/transform-paths';
|
|
3
6
|
import { resolveUrl } from '@wix/metro-runtime';
|
|
4
|
-
const _bulkDeleteFoldersRequest = {};
|
|
5
|
-
const _bulkDeleteFoldersResponse = {};
|
|
6
|
-
const _bulkRestoreFoldersFromTrashBinRequest = {};
|
|
7
|
-
const _bulkRestoreFoldersFromTrashBinResponse = {};
|
|
8
|
-
const _createFolderRequest = {};
|
|
9
|
-
const _createFolderResponse = { folder: '_folder' };
|
|
10
|
-
const _folder = {
|
|
11
|
-
createdDate: 'google.protobuf.Timestamp',
|
|
12
|
-
updatedDate: 'google.protobuf.Timestamp',
|
|
13
|
-
};
|
|
14
|
-
const _generateFolderDownloadUrlRequest = {};
|
|
15
|
-
const _generateFolderDownloadUrlResponse = {};
|
|
16
|
-
const _getFolderRequest = {};
|
|
17
|
-
const _getFolderResponse = { folder: '_folder' };
|
|
18
|
-
const _listDeletedFoldersRequest = {};
|
|
19
|
-
const _listDeletedFoldersResponse = { folders: '_folder' };
|
|
20
|
-
const _listFoldersRequest = {};
|
|
21
|
-
const _listFoldersResponse = { folders: '_folder' };
|
|
22
|
-
const _searchFoldersRequest = {};
|
|
23
|
-
const _searchFoldersResponse = { folders: '_folder' };
|
|
24
|
-
const _updateFolderRequest = {
|
|
25
|
-
fieldMask: 'google.protobuf.FieldMask',
|
|
26
|
-
folder: '_folder',
|
|
27
|
-
};
|
|
28
|
-
const _updateFolderResponse = { folder: '_folder' };
|
|
29
7
|
function resolveComWixMediaSiteMediaV1FoldersServiceUrl(opts) {
|
|
30
8
|
const domainToMappings = {
|
|
31
9
|
'apps._base_domain_': [
|
|
@@ -62,25 +40,29 @@ function resolveComWixMediaSiteMediaV1FoldersServiceUrl(opts) {
|
|
|
62
40
|
* If no folder is specified, the new folder is created in the `media-root` folder.
|
|
63
41
|
*/
|
|
64
42
|
export function createFolder(payload) {
|
|
65
|
-
const { toJSON: toReq, fromJSON: fromReq } = serializer(_createFolderRequest, {});
|
|
66
|
-
const { fromJSON: fromRes } = serializer(_createFolderResponse, { _folder });
|
|
67
43
|
function __createFolder({ host }) {
|
|
68
|
-
const serializedData = toReq(payload);
|
|
69
44
|
const metadata = {
|
|
70
45
|
entityFqdn: 'wix.media.site_media.v1.folder',
|
|
71
46
|
method: 'POST',
|
|
72
47
|
methodFqn: 'com.wix.media.site_media.v1.FoldersService.CreateFolder',
|
|
73
48
|
url: resolveComWixMediaSiteMediaV1FoldersServiceUrl({
|
|
74
49
|
protoPath: '/v1/folders',
|
|
75
|
-
data:
|
|
50
|
+
data: payload,
|
|
76
51
|
host,
|
|
77
52
|
}),
|
|
78
|
-
data:
|
|
79
|
-
transformResponse:
|
|
53
|
+
data: payload,
|
|
54
|
+
transformResponse: (payload) => transformPaths(payload, [
|
|
55
|
+
{
|
|
56
|
+
transformFn: transformRESTTimestampToSDKTimestamp,
|
|
57
|
+
paths: [
|
|
58
|
+
{ path: 'folder.createdDate' },
|
|
59
|
+
{ path: 'folder.updatedDate' },
|
|
60
|
+
],
|
|
61
|
+
},
|
|
62
|
+
]),
|
|
80
63
|
};
|
|
81
64
|
return metadata;
|
|
82
65
|
}
|
|
83
|
-
__createFolder.fromReq = fromReq;
|
|
84
66
|
return __createFolder;
|
|
85
67
|
}
|
|
86
68
|
/**
|
|
@@ -89,25 +71,29 @@ export function createFolder(payload) {
|
|
|
89
71
|
* The `getFolder()` function returns a Promise that resolves to information about the specified folder.
|
|
90
72
|
*/
|
|
91
73
|
export function getFolder(payload) {
|
|
92
|
-
const { toJSON: toReq, fromJSON: fromReq } = serializer(_getFolderRequest, {});
|
|
93
|
-
const { fromJSON: fromRes } = serializer(_getFolderResponse, { _folder });
|
|
94
74
|
function __getFolder({ host }) {
|
|
95
|
-
const serializedData = toReq(payload);
|
|
96
75
|
const metadata = {
|
|
97
76
|
entityFqdn: 'wix.media.site_media.v1.folder',
|
|
98
77
|
method: 'GET',
|
|
99
78
|
methodFqn: 'com.wix.media.site_media.v1.FoldersService.GetFolder',
|
|
100
79
|
url: resolveComWixMediaSiteMediaV1FoldersServiceUrl({
|
|
101
80
|
protoPath: '/v1/folders/{folderId}',
|
|
102
|
-
data:
|
|
81
|
+
data: payload,
|
|
103
82
|
host,
|
|
104
83
|
}),
|
|
105
|
-
params: toURLSearchParams(
|
|
106
|
-
transformResponse:
|
|
84
|
+
params: toURLSearchParams(payload),
|
|
85
|
+
transformResponse: (payload) => transformPaths(payload, [
|
|
86
|
+
{
|
|
87
|
+
transformFn: transformRESTTimestampToSDKTimestamp,
|
|
88
|
+
paths: [
|
|
89
|
+
{ path: 'folder.createdDate' },
|
|
90
|
+
{ path: 'folder.updatedDate' },
|
|
91
|
+
],
|
|
92
|
+
},
|
|
93
|
+
]),
|
|
107
94
|
};
|
|
108
95
|
return metadata;
|
|
109
96
|
}
|
|
110
|
-
__getFolder.fromReq = fromReq;
|
|
111
97
|
return __getFolder;
|
|
112
98
|
}
|
|
113
99
|
/**
|
|
@@ -120,25 +106,29 @@ export function getFolder(payload) {
|
|
|
120
106
|
* To retrieve a list of (non-permanently) deleted folders, use the `listDeletedFolders()` function.
|
|
121
107
|
*/
|
|
122
108
|
export function listFolders(payload) {
|
|
123
|
-
const { toJSON: toReq, fromJSON: fromReq } = serializer(_listFoldersRequest, {});
|
|
124
|
-
const { fromJSON: fromRes } = serializer(_listFoldersResponse, { _folder });
|
|
125
109
|
function __listFolders({ host }) {
|
|
126
|
-
const serializedData = toReq(payload);
|
|
127
110
|
const metadata = {
|
|
128
111
|
entityFqdn: 'wix.media.site_media.v1.folder',
|
|
129
112
|
method: 'GET',
|
|
130
113
|
methodFqn: 'com.wix.media.site_media.v1.FoldersService.ListFolders',
|
|
131
114
|
url: resolveComWixMediaSiteMediaV1FoldersServiceUrl({
|
|
132
115
|
protoPath: '/v1/folders',
|
|
133
|
-
data:
|
|
116
|
+
data: payload,
|
|
134
117
|
host,
|
|
135
118
|
}),
|
|
136
|
-
params: toURLSearchParams(
|
|
137
|
-
transformResponse:
|
|
119
|
+
params: toURLSearchParams(payload),
|
|
120
|
+
transformResponse: (payload) => transformPaths(payload, [
|
|
121
|
+
{
|
|
122
|
+
transformFn: transformRESTTimestampToSDKTimestamp,
|
|
123
|
+
paths: [
|
|
124
|
+
{ path: 'folders.createdDate' },
|
|
125
|
+
{ path: 'folders.updatedDate' },
|
|
126
|
+
],
|
|
127
|
+
},
|
|
128
|
+
]),
|
|
138
129
|
};
|
|
139
130
|
return metadata;
|
|
140
131
|
}
|
|
141
|
-
__listFolders.fromReq = fromReq;
|
|
142
132
|
return __listFolders;
|
|
143
133
|
}
|
|
144
134
|
/**
|
|
@@ -149,25 +139,29 @@ export function listFolders(payload) {
|
|
|
149
139
|
* If no parameters are specified, the function returns all folders in the `MEDIA_ROOT` folder.
|
|
150
140
|
*/
|
|
151
141
|
export function searchFolders(payload) {
|
|
152
|
-
const { toJSON: toReq, fromJSON: fromReq } = serializer(_searchFoldersRequest, {});
|
|
153
|
-
const { fromJSON: fromRes } = serializer(_searchFoldersResponse, { _folder });
|
|
154
142
|
function __searchFolders({ host }) {
|
|
155
|
-
const serializedData = toReq(payload);
|
|
156
143
|
const metadata = {
|
|
157
144
|
entityFqdn: 'wix.media.site_media.v1.folder',
|
|
158
145
|
method: 'POST',
|
|
159
146
|
methodFqn: 'com.wix.media.site_media.v1.FoldersService.SearchFolders',
|
|
160
147
|
url: resolveComWixMediaSiteMediaV1FoldersServiceUrl({
|
|
161
148
|
protoPath: '/v1/folders/search',
|
|
162
|
-
data:
|
|
149
|
+
data: payload,
|
|
163
150
|
host,
|
|
164
151
|
}),
|
|
165
|
-
data:
|
|
166
|
-
transformResponse:
|
|
152
|
+
data: payload,
|
|
153
|
+
transformResponse: (payload) => transformPaths(payload, [
|
|
154
|
+
{
|
|
155
|
+
transformFn: transformRESTTimestampToSDKTimestamp,
|
|
156
|
+
paths: [
|
|
157
|
+
{ path: 'folders.createdDate' },
|
|
158
|
+
{ path: 'folders.updatedDate' },
|
|
159
|
+
],
|
|
160
|
+
},
|
|
161
|
+
]),
|
|
167
162
|
};
|
|
168
163
|
return metadata;
|
|
169
164
|
}
|
|
170
|
-
__searchFolders.fromReq = fromReq;
|
|
171
165
|
return __searchFolders;
|
|
172
166
|
}
|
|
173
167
|
/**
|
|
@@ -178,10 +172,17 @@ export function searchFolders(payload) {
|
|
|
178
172
|
* You can use the `parentFolderId` parameter to move a folder from its current parent folder to a different parent folder.
|
|
179
173
|
*/
|
|
180
174
|
export function updateFolder(payload) {
|
|
181
|
-
const { toJSON: toReq, fromJSON: fromReq } = serializer(_updateFolderRequest, { _folder });
|
|
182
|
-
const { fromJSON: fromRes } = serializer(_updateFolderResponse, { _folder });
|
|
183
175
|
function __updateFolder({ host }) {
|
|
184
|
-
const serializedData =
|
|
176
|
+
const serializedData = transformPaths(payload, [
|
|
177
|
+
{
|
|
178
|
+
transformFn: transformSDKFieldMaskToRESTFieldMask,
|
|
179
|
+
paths: [{ path: 'fieldMask' }],
|
|
180
|
+
},
|
|
181
|
+
{
|
|
182
|
+
transformFn: transformSDKTimestampToRESTTimestamp,
|
|
183
|
+
paths: [{ path: 'folder.createdDate' }, { path: 'folder.updatedDate' }],
|
|
184
|
+
},
|
|
185
|
+
]);
|
|
185
186
|
const metadata = {
|
|
186
187
|
entityFqdn: 'wix.media.site_media.v1.folder',
|
|
187
188
|
method: 'PATCH',
|
|
@@ -192,11 +193,18 @@ export function updateFolder(payload) {
|
|
|
192
193
|
host,
|
|
193
194
|
}),
|
|
194
195
|
data: serializedData,
|
|
195
|
-
transformResponse:
|
|
196
|
+
transformResponse: (payload) => transformPaths(payload, [
|
|
197
|
+
{
|
|
198
|
+
transformFn: transformRESTTimestampToSDKTimestamp,
|
|
199
|
+
paths: [
|
|
200
|
+
{ path: 'folder.createdDate' },
|
|
201
|
+
{ path: 'folder.updatedDate' },
|
|
202
|
+
],
|
|
203
|
+
},
|
|
204
|
+
]),
|
|
196
205
|
};
|
|
197
206
|
return metadata;
|
|
198
207
|
}
|
|
199
|
-
__updateFolder.fromReq = fromReq;
|
|
200
208
|
return __updateFolder;
|
|
201
209
|
}
|
|
202
210
|
/**
|
|
@@ -207,25 +215,20 @@ export function updateFolder(payload) {
|
|
|
207
215
|
* The compressed file can contain sub-folders, and up to 1000 files.
|
|
208
216
|
*/
|
|
209
217
|
export function generateFolderDownloadUrl(payload) {
|
|
210
|
-
const { toJSON: toReq, fromJSON: fromReq } = serializer(_generateFolderDownloadUrlRequest, {});
|
|
211
|
-
const { fromJSON: fromRes } = serializer(_generateFolderDownloadUrlResponse, {});
|
|
212
218
|
function __generateFolderDownloadUrl({ host }) {
|
|
213
|
-
const serializedData = toReq(payload);
|
|
214
219
|
const metadata = {
|
|
215
220
|
entityFqdn: 'wix.media.site_media.v1.folder',
|
|
216
221
|
method: 'POST',
|
|
217
222
|
methodFqn: 'com.wix.media.site_media.v1.FoldersService.GenerateFolderDownloadUrl',
|
|
218
223
|
url: resolveComWixMediaSiteMediaV1FoldersServiceUrl({
|
|
219
224
|
protoPath: '/v1/folders/{folderId}/generate-download-url',
|
|
220
|
-
data:
|
|
225
|
+
data: payload,
|
|
221
226
|
host,
|
|
222
227
|
}),
|
|
223
|
-
data:
|
|
224
|
-
transformResponse: fromRes,
|
|
228
|
+
data: payload,
|
|
225
229
|
};
|
|
226
230
|
return metadata;
|
|
227
231
|
}
|
|
228
|
-
__generateFolderDownloadUrl.fromReq = fromReq;
|
|
229
232
|
return __generateFolderDownloadUrl;
|
|
230
233
|
}
|
|
231
234
|
/**
|
|
@@ -244,25 +247,20 @@ export function generateFolderDownloadUrl(payload) {
|
|
|
244
247
|
* > - You can use the `bulkRestoreFoldersFromTrashBin()` endpoint to restore folders from the Media Manager's trash bin.
|
|
245
248
|
*/
|
|
246
249
|
export function bulkDeleteFolders(payload) {
|
|
247
|
-
const { toJSON: toReq, fromJSON: fromReq } = serializer(_bulkDeleteFoldersRequest, {});
|
|
248
|
-
const { fromJSON: fromRes } = serializer(_bulkDeleteFoldersResponse, {});
|
|
249
250
|
function __bulkDeleteFolders({ host }) {
|
|
250
|
-
const serializedData = toReq(payload);
|
|
251
251
|
const metadata = {
|
|
252
252
|
entityFqdn: 'wix.media.site_media.v1.folder',
|
|
253
253
|
method: 'POST',
|
|
254
254
|
methodFqn: 'com.wix.media.site_media.v1.FoldersService.BulkDeleteFolders',
|
|
255
255
|
url: resolveComWixMediaSiteMediaV1FoldersServiceUrl({
|
|
256
256
|
protoPath: '/v1/bulk/folders/delete',
|
|
257
|
-
data:
|
|
257
|
+
data: payload,
|
|
258
258
|
host,
|
|
259
259
|
}),
|
|
260
|
-
data:
|
|
261
|
-
transformResponse: fromRes,
|
|
260
|
+
data: payload,
|
|
262
261
|
};
|
|
263
262
|
return metadata;
|
|
264
263
|
}
|
|
265
|
-
__bulkDeleteFolders.fromReq = fromReq;
|
|
266
264
|
return __bulkDeleteFolders;
|
|
267
265
|
}
|
|
268
266
|
/**
|
|
@@ -272,25 +270,20 @@ export function bulkDeleteFolders(payload) {
|
|
|
272
270
|
* The `bulkRestoreFoldersFromTrashBin()` function returns a Promise that resolves when the folders have been restored.
|
|
273
271
|
*/
|
|
274
272
|
export function bulkRestoreFoldersFromTrashBin(payload) {
|
|
275
|
-
const { toJSON: toReq, fromJSON: fromReq } = serializer(_bulkRestoreFoldersFromTrashBinRequest, {});
|
|
276
|
-
const { fromJSON: fromRes } = serializer(_bulkRestoreFoldersFromTrashBinResponse, {});
|
|
277
273
|
function __bulkRestoreFoldersFromTrashBin({ host }) {
|
|
278
|
-
const serializedData = toReq(payload);
|
|
279
274
|
const metadata = {
|
|
280
275
|
entityFqdn: 'wix.media.site_media.v1.folder',
|
|
281
276
|
method: 'POST',
|
|
282
277
|
methodFqn: 'com.wix.media.site_media.v1.FoldersService.BulkRestoreFoldersFromTrashBin',
|
|
283
278
|
url: resolveComWixMediaSiteMediaV1FoldersServiceUrl({
|
|
284
279
|
protoPath: '/v1/bulk/trash-bin/folders/restore',
|
|
285
|
-
data:
|
|
280
|
+
data: payload,
|
|
286
281
|
host,
|
|
287
282
|
}),
|
|
288
|
-
data:
|
|
289
|
-
transformResponse: fromRes,
|
|
283
|
+
data: payload,
|
|
290
284
|
};
|
|
291
285
|
return metadata;
|
|
292
286
|
}
|
|
293
|
-
__bulkRestoreFoldersFromTrashBin.fromReq = fromReq;
|
|
294
287
|
return __bulkRestoreFoldersFromTrashBin;
|
|
295
288
|
}
|
|
296
289
|
/**
|
|
@@ -301,27 +294,29 @@ export function bulkRestoreFoldersFromTrashBin(payload) {
|
|
|
301
294
|
* To retrieve a list of non-deleted folders, use the `listFolders()` function.
|
|
302
295
|
*/
|
|
303
296
|
export function listDeletedFolders(payload) {
|
|
304
|
-
const { toJSON: toReq, fromJSON: fromReq } = serializer(_listDeletedFoldersRequest, {});
|
|
305
|
-
const { fromJSON: fromRes } = serializer(_listDeletedFoldersResponse, {
|
|
306
|
-
_folder,
|
|
307
|
-
});
|
|
308
297
|
function __listDeletedFolders({ host }) {
|
|
309
|
-
const serializedData = toReq(payload);
|
|
310
298
|
const metadata = {
|
|
311
299
|
entityFqdn: 'wix.media.site_media.v1.folder',
|
|
312
300
|
method: 'GET',
|
|
313
301
|
methodFqn: 'com.wix.media.site_media.v1.FoldersService.ListDeletedFolders',
|
|
314
302
|
url: resolveComWixMediaSiteMediaV1FoldersServiceUrl({
|
|
315
303
|
protoPath: '/v1/trash-bin/folders',
|
|
316
|
-
data:
|
|
304
|
+
data: payload,
|
|
317
305
|
host,
|
|
318
306
|
}),
|
|
319
|
-
params: toURLSearchParams(
|
|
320
|
-
transformResponse:
|
|
307
|
+
params: toURLSearchParams(payload),
|
|
308
|
+
transformResponse: (payload) => transformPaths(payload, [
|
|
309
|
+
{
|
|
310
|
+
transformFn: transformRESTTimestampToSDKTimestamp,
|
|
311
|
+
paths: [
|
|
312
|
+
{ path: 'folders.createdDate' },
|
|
313
|
+
{ path: 'folders.updatedDate' },
|
|
314
|
+
],
|
|
315
|
+
},
|
|
316
|
+
]),
|
|
321
317
|
};
|
|
322
318
|
return metadata;
|
|
323
319
|
}
|
|
324
|
-
__listDeletedFolders.fromReq = fromReq;
|
|
325
320
|
return __listDeletedFolders;
|
|
326
321
|
}
|
|
327
322
|
//# sourceMappingURL=media-site-media-v1-folder.http.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"media-site-media-v1-folder.http.js","sourceRoot":"","sources":["../../../src/media-site-media-v1-folder.http.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,iBAAiB,EAAE,MAAM,oBAAoB,CAAC;AACvD,OAAO,EAAE,
|
|
1
|
+
{"version":3,"file":"media-site-media-v1-folder.http.js","sourceRoot":"","sources":["../../../src/media-site-media-v1-folder.http.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,iBAAiB,EAAE,MAAM,oBAAoB,CAAC;AACvD,OAAO,EAAE,oCAAoC,EAAE,MAAM,4CAA4C,CAAC;AAClG,OAAO,EAAE,oCAAoC,EAAE,MAAM,4CAA4C,CAAC;AAClG,OAAO,EAAE,oCAAoC,EAAE,MAAM,6CAA6C,CAAC;AACnG,OAAO,EAAE,cAAc,EAAE,MAAM,kDAAkD,CAAC;AAClF,OAAO,EAAE,UAAU,EAAE,MAAM,oBAAoB,CAAC;AA+BhD,SAAS,8CAA8C,CACrD,IAA8C;IAE9C,MAAM,gBAAgB,GAAG;QACvB,oBAAoB,EAAE;YACpB;gBACE,OAAO,EAAE,qCAAqC;gBAC9C,QAAQ,EAAE,MAAM;aACjB;YACD;gBACE,OAAO,EAAE,wCAAwC;gBACjD,QAAQ,EAAE,KAAK;aAChB;SACF;QACD,sBAAsB,EAAE;YACtB;gBACE,OAAO,EAAE,qCAAqC;gBAC9C,QAAQ,EAAE,EAAE;aACb;SACF;QACD,iBAAiB,EAAE;YACjB;gBACE,OAAO,EAAE,gBAAgB;gBACzB,QAAQ,EAAE,KAAK;aAChB;SACF;KACF,CAAC;IAEF,OAAO,UAAU,CAAC,MAAM,CAAC,MAAM,CAAC,IAAI,EAAE,EAAE,gBAAgB,EAAE,CAAC,CAAC,CAAC;AAC/D,CAAC;AAED;;;;;;;GAOG;AACH,MAAM,UAAU,YAAY,CAC1B,OAA4B;IAI5B,SAAS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C5C,MAAM,EAAE,KAAY;YACpB,SAAS,EACP,+DAA+D;YACjE,GAAG,EAAE,8CAA8C,CAAC;gBAClD,SAAS,EAAE,uBAAuB;gBAClC,IAAI,EAAE,OAAO;gBACb,IAAI;aACL,CAAC;YACF,MAAM,EAAE,iBAAiB,CAAC,OAAO,CAAC;YAClC,iBAAiB,EAAE,CAAC,OAAY,EAAE,EAAE,CAClC,cAAc,CAAC,OAAO,EAAE;gBACtB;oBACE,WAAW,EAAE,oCAAoC;oBACjD,KAAK,EAAE;wBACL,EAAE,IAAI,EAAE,qBAAqB,EAAE;wBAC/B,EAAE,IAAI,EAAE,qBAAqB,EAAE;qBAChC;iBACF;aACF,CAAC;SACL,CAAC;QAEF,OAAO,QAAQ,CAAC;IAClB,CAAC;IAED,OAAO,oBAAoB,CAAC;AAC9B,CAAC"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as ambassadorWixMediaSiteMediaV1FolderTypes from './media-site-media-v1-folder.types';
|
|
2
2
|
import * as ambassadorWixMediaSiteMediaV1FolderUniversalTypes from './media-site-media-v1-folder.universal';
|
|
3
|
-
export
|
|
3
|
+
export type __PublicMethodMetaInfo<K = string, M = unknown, T = unknown, S = unknown, Q = unknown, R = unknown> = {
|
|
4
4
|
getUrl: (context: any) => string;
|
|
5
5
|
httpMethod: K;
|
|
6
6
|
path: string;
|
|
@@ -3,15 +3,15 @@ import { UpdateFolder, BulkDeleteFoldersOptions, CreateFolderOptions, ListDelete
|
|
|
3
3
|
export declare const __metadata: {
|
|
4
4
|
PACKAGE_NAME: string;
|
|
5
5
|
};
|
|
6
|
-
export declare function createFolder(httpClient: HttpClient): (displayName: string, options?: CreateFolderOptions
|
|
6
|
+
export declare function createFolder(httpClient: HttpClient): (displayName: string, options?: CreateFolderOptions) => Promise<import("./media-site-media-v1-folder.universal").CreateFolderResponse & import("./media-site-media-v1-folder.universal").CreateFolderResponseNonNullableFields>;
|
|
7
7
|
export declare function getFolder(httpClient: HttpClient): (folderId: string) => Promise<import("./media-site-media-v1-folder.universal").Folder & {
|
|
8
8
|
_id: string;
|
|
9
9
|
displayName: string;
|
|
10
10
|
parentFolderId: string;
|
|
11
11
|
state: import("./media-site-media-v1-folder.universal").State;
|
|
12
12
|
}>;
|
|
13
|
-
export declare function listFolders(httpClient: HttpClient): (options?: ListFoldersOptions
|
|
14
|
-
export declare function searchFolders(httpClient: HttpClient): (options?: SearchFoldersOptions
|
|
13
|
+
export declare function listFolders(httpClient: HttpClient): (options?: ListFoldersOptions) => Promise<import("./media-site-media-v1-folder.universal").ListFoldersResponse & import("./media-site-media-v1-folder.universal").ListFoldersResponseNonNullableFields>;
|
|
14
|
+
export declare function searchFolders(httpClient: HttpClient): (options?: SearchFoldersOptions) => Promise<import("./media-site-media-v1-folder.universal").SearchFoldersResponse & import("./media-site-media-v1-folder.universal").SearchFoldersResponseNonNullableFields>;
|
|
15
15
|
export declare function updateFolder(httpClient: HttpClient): (_id: string, folder: UpdateFolder) => Promise<import("./media-site-media-v1-folder.universal").Folder & {
|
|
16
16
|
_id: string;
|
|
17
17
|
displayName: string;
|
|
@@ -19,8 +19,8 @@ export declare function updateFolder(httpClient: HttpClient): (_id: string, fold
|
|
|
19
19
|
state: import("./media-site-media-v1-folder.universal").State;
|
|
20
20
|
}>;
|
|
21
21
|
export declare function generateFolderDownloadUrl(httpClient: HttpClient): (folderId: string) => Promise<import("./media-site-media-v1-folder.universal").GenerateFolderDownloadUrlResponse & import("./media-site-media-v1-folder.universal").GenerateFolderDownloadUrlResponseNonNullableFields>;
|
|
22
|
-
export declare function bulkDeleteFolders(httpClient: HttpClient): (folderIds: string[], options?: BulkDeleteFoldersOptions
|
|
22
|
+
export declare function bulkDeleteFolders(httpClient: HttpClient): (folderIds: string[], options?: BulkDeleteFoldersOptions) => Promise<void>;
|
|
23
23
|
export declare function bulkRestoreFoldersFromTrashBin(httpClient: HttpClient): (folderIds: string[]) => Promise<void>;
|
|
24
|
-
export declare function listDeletedFolders(httpClient: HttpClient): (options?: ListDeletedFoldersOptions
|
|
24
|
+
export declare function listDeletedFolders(httpClient: HttpClient): (options?: ListDeletedFoldersOptions) => Promise<import("./media-site-media-v1-folder.universal").ListDeletedFoldersResponse & import("./media-site-media-v1-folder.universal").ListDeletedFoldersResponseNonNullableFields>;
|
|
25
25
|
export { State, Namespace, SortOrder, RootFolder, } from './media-site-media-v1-folder.universal';
|
|
26
|
-
export { Folder, CreateFolderRequest, CreateFolderResponse, GetFolderRequest, GetFolderResponse, ListFoldersRequest, Sorting, CursorPaging, ListFoldersResponse, PagingMetadataV2, Cursors, SearchFoldersRequest, SearchFoldersResponse, UpdateFolderRequest, UpdateFolderResponse, GenerateFolderDownloadUrlRequest, GenerateFolderDownloadUrlResponse, BulkDeleteFoldersRequest, BulkDeleteFoldersResponse, BulkRestoreFoldersFromTrashBinRequest, BulkRestoreFoldersFromTrashBinResponse, ListDeletedFoldersRequest, ListDeletedFoldersResponse, CreateFolderResponseNonNullableFields, GetFolderResponseNonNullableFields, ListFoldersResponseNonNullableFields, SearchFoldersResponseNonNullableFields, UpdateFolderResponseNonNullableFields, GenerateFolderDownloadUrlResponseNonNullableFields, ListDeletedFoldersResponseNonNullableFields, CreateFolderOptions, ListFoldersOptions, SearchFoldersOptions, UpdateFolder, BulkDeleteFoldersOptions, ListDeletedFoldersOptions, } from './media-site-media-v1-folder.universal';
|
|
26
|
+
export { Folder, CreateFolderRequest, CreateFolderResponse, GetFolderRequest, GetFolderResponse, ListFoldersRequest, Sorting, CursorPaging, ListFoldersResponse, PagingMetadataV2, Cursors, SearchFoldersRequest, SearchFoldersResponse, UpdateFolderRequest, UpdateFolderResponse, GenerateFolderDownloadUrlRequest, GenerateFolderDownloadUrlResponse, BulkDeleteFoldersRequest, BulkDeleteFoldersResponse, BulkRestoreFoldersFromTrashBinRequest, BulkRestoreFoldersFromTrashBinResponse, ListDeletedFoldersRequest, ListDeletedFoldersResponse, DomainEvent, DomainEventBodyOneOf, EntityCreatedEvent, EntityUpdatedEvent, EntityDeletedEvent, ActionEvent, CreateFolderResponseNonNullableFields, GetFolderResponseNonNullableFields, ListFoldersResponseNonNullableFields, SearchFoldersResponseNonNullableFields, UpdateFolderResponseNonNullableFields, GenerateFolderDownloadUrlResponseNonNullableFields, ListDeletedFoldersResponseNonNullableFields, CreateFolderOptions, ListFoldersOptions, SearchFoldersOptions, UpdateFolder, BulkDeleteFoldersOptions, ListDeletedFoldersOptions, } from './media-site-media-v1-folder.universal';
|
|
@@ -96,13 +96,12 @@ export declare enum SortOrder {
|
|
|
96
96
|
DESC = "DESC"
|
|
97
97
|
}
|
|
98
98
|
export interface CursorPaging {
|
|
99
|
-
/**
|
|
99
|
+
/** Maximum number of items to return in the results. */
|
|
100
100
|
limit?: number | null;
|
|
101
101
|
/**
|
|
102
102
|
* Pointer to the next or previous page in the list of results.
|
|
103
103
|
*
|
|
104
|
-
*
|
|
105
|
-
* from the `pagingMetadata` object in the previous call's response.
|
|
104
|
+
* Pass the relevant cursor token from the `pagingMetadata` object in the previous call's response.
|
|
106
105
|
* Not relevant for the first request.
|
|
107
106
|
*/
|
|
108
107
|
cursor?: string | null;
|
|
@@ -114,13 +113,13 @@ export interface ListFoldersResponse {
|
|
|
114
113
|
nextCursor?: PagingMetadataV2;
|
|
115
114
|
}
|
|
116
115
|
export interface PagingMetadataV2 {
|
|
117
|
-
/** Total number of items that match the query. */
|
|
116
|
+
/** Total number of items that match the query. Returned if offset paging is used and the `tooManyToCount` flag is not set. */
|
|
118
117
|
total?: number | null;
|
|
119
118
|
/** Cursors to navigate through the result pages using `next` and `prev`. Returned if cursor paging is used. */
|
|
120
119
|
cursors?: Cursors;
|
|
121
120
|
}
|
|
122
121
|
export interface Cursors {
|
|
123
|
-
/** Cursor pointing to next page in the list of results. */
|
|
122
|
+
/** Cursor string pointing to the next page in the list of results. */
|
|
124
123
|
next?: string | null;
|
|
125
124
|
}
|
|
126
125
|
export interface SearchFoldersRequest {
|
|
@@ -210,6 +209,73 @@ export interface ListDeletedFoldersResponse {
|
|
|
210
209
|
/** The next cursor if it exists. */
|
|
211
210
|
nextCursor?: PagingMetadataV2;
|
|
212
211
|
}
|
|
212
|
+
export interface DomainEvent extends DomainEventBodyOneOf {
|
|
213
|
+
createdEvent?: EntityCreatedEvent;
|
|
214
|
+
updatedEvent?: EntityUpdatedEvent;
|
|
215
|
+
deletedEvent?: EntityDeletedEvent;
|
|
216
|
+
actionEvent?: ActionEvent;
|
|
217
|
+
/**
|
|
218
|
+
* Unique event ID.
|
|
219
|
+
* Allows clients to ignore duplicate webhooks.
|
|
220
|
+
*/
|
|
221
|
+
id?: string;
|
|
222
|
+
/**
|
|
223
|
+
* Assumes actions are also always typed to an entity_type
|
|
224
|
+
* Example: wix.stores.catalog.product, wix.bookings.session, wix.payments.transaction
|
|
225
|
+
*/
|
|
226
|
+
entityFqdn?: string;
|
|
227
|
+
/**
|
|
228
|
+
* This is top level to ease client code dispatching of messages (switch on entity_fqdn+slug)
|
|
229
|
+
* This is although the created/updated/deleted notion is duplication of the oneof types
|
|
230
|
+
* Example: created/updated/deleted/started/completed/email_opened
|
|
231
|
+
*/
|
|
232
|
+
slug?: string;
|
|
233
|
+
/** ID of the entity associated with the event. */
|
|
234
|
+
entityId?: string;
|
|
235
|
+
/** Event timestamp. */
|
|
236
|
+
eventTime?: Date;
|
|
237
|
+
/**
|
|
238
|
+
* Whether the event was triggered as a result of a privacy regulation application
|
|
239
|
+
* (for example, GDPR).
|
|
240
|
+
*/
|
|
241
|
+
triggeredByAnonymizeRequest?: boolean | null;
|
|
242
|
+
/** If present, indicates the action that triggered the event. */
|
|
243
|
+
originatedFrom?: string | null;
|
|
244
|
+
/**
|
|
245
|
+
* A sequence number defining the order of updates to the underlying entity.
|
|
246
|
+
* For example, given that some entity was updated at 16:00 and than again at 16:01,
|
|
247
|
+
* it is guaranteed that the sequence number of the second update is strictly higher than the first.
|
|
248
|
+
* As the consumer, you can use this value to ensure that you handle messages in the correct order.
|
|
249
|
+
* To do so, you will need to persist this number on your end, and compare the sequence number from the
|
|
250
|
+
* message against the one you have stored. Given that the stored number is higher, you should ignore the message.
|
|
251
|
+
*/
|
|
252
|
+
entityEventSequence?: string | null;
|
|
253
|
+
}
|
|
254
|
+
/** @oneof */
|
|
255
|
+
export interface DomainEventBodyOneOf {
|
|
256
|
+
createdEvent?: EntityCreatedEvent;
|
|
257
|
+
updatedEvent?: EntityUpdatedEvent;
|
|
258
|
+
deletedEvent?: EntityDeletedEvent;
|
|
259
|
+
actionEvent?: ActionEvent;
|
|
260
|
+
}
|
|
261
|
+
export interface EntityCreatedEvent {
|
|
262
|
+
entityAsJson?: string;
|
|
263
|
+
}
|
|
264
|
+
export interface EntityUpdatedEvent {
|
|
265
|
+
/**
|
|
266
|
+
* Since platformized APIs only expose PATCH and not PUT we can't assume that the fields sent from the client are the actual diff.
|
|
267
|
+
* This means that to generate a list of changed fields (as opposed to sent fields) one needs to traverse both objects.
|
|
268
|
+
* We don't want to impose this on all developers and so we leave this traversal to the notification recipients which need it.
|
|
269
|
+
*/
|
|
270
|
+
currentEntityAsJson?: string;
|
|
271
|
+
}
|
|
272
|
+
export interface EntityDeletedEvent {
|
|
273
|
+
/** Entity that was deleted */
|
|
274
|
+
deletedEntityAsJson?: string | null;
|
|
275
|
+
}
|
|
276
|
+
export interface ActionEvent {
|
|
277
|
+
bodyAsJson?: string;
|
|
278
|
+
}
|
|
213
279
|
export interface CreateFolderResponseNonNullableFields {
|
|
214
280
|
folder?: {
|
|
215
281
|
id: string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"media-site-media-v1-folder.types.js","sourceRoot":"","sources":["../../../src/media-site-media-v1-folder.types.ts"],"names":[],"mappings":"AAwBA,MAAM,CAAN,IAAY,KAGX;AAHD,WAAY,KAAK;IACf,kBAAS,CAAA;IACT,4BAAmB,CAAA;AACrB,CAAC,EAHW,KAAK,KAAL,KAAK,QAGhB;AAED,MAAM,CAAN,IAAY,SAyBX;AAzBD,WAAY,SAAS;IACnB,0CAA6B,CAAA;IAC7B,8BAAiB,CAAA;IACjB,eAAe;IACf,oCAAuB,CAAA;IACvB,kBAAkB;IAClB,oCAAuB,CAAA;IACvB,kBAAkB;IAClB,0DAA6C,CAAA;IAC7C,wBAAwB;IACxB,kCAAqB,CAAA;IACrB,uBAAuB;IACvB,gDAAmC,CAAA;IACnC,qBAAqB;IACrB,wCAA2B,CAAA;IAC3B,aAAa;IACb,0BAAa,CAAA;IACb,kBAAkB;IAClB,0CAA6B,CAAA;IAC7B,kBAAkB;IAClB,sCAAyB,CAAA;IACzB,0BAA0B;IAC1B,wCAA2B,CAAA;IAC3B,kBAAkB;IAClB,oCAAuB,CAAA;AACzB,CAAC,EAzBW,SAAS,KAAT,SAAS,QAyBpB;AAgDD,MAAM,CAAN,IAAY,SAGX;AAHD,WAAY,SAAS;IACnB,wBAAW,CAAA;IACX,0BAAa,CAAA;AACf,CAAC,EAHW,SAAS,KAAT,SAAS,QAGpB;
|
|
1
|
+
{"version":3,"file":"media-site-media-v1-folder.types.js","sourceRoot":"","sources":["../../../src/media-site-media-v1-folder.types.ts"],"names":[],"mappings":"AAwBA,MAAM,CAAN,IAAY,KAGX;AAHD,WAAY,KAAK;IACf,kBAAS,CAAA;IACT,4BAAmB,CAAA;AACrB,CAAC,EAHW,KAAK,KAAL,KAAK,QAGhB;AAED,MAAM,CAAN,IAAY,SAyBX;AAzBD,WAAY,SAAS;IACnB,0CAA6B,CAAA;IAC7B,8BAAiB,CAAA;IACjB,eAAe;IACf,oCAAuB,CAAA;IACvB,kBAAkB;IAClB,oCAAuB,CAAA;IACvB,kBAAkB;IAClB,0DAA6C,CAAA;IAC7C,wBAAwB;IACxB,kCAAqB,CAAA;IACrB,uBAAuB;IACvB,gDAAmC,CAAA;IACnC,qBAAqB;IACrB,wCAA2B,CAAA;IAC3B,aAAa;IACb,0BAAa,CAAA;IACb,kBAAkB;IAClB,0CAA6B,CAAA;IAC7B,kBAAkB;IAClB,sCAAyB,CAAA;IACzB,0BAA0B;IAC1B,wCAA2B,CAAA;IAC3B,kBAAkB;IAClB,oCAAuB,CAAA;AACzB,CAAC,EAzBW,SAAS,KAAT,SAAS,QAyBpB;AAgDD,MAAM,CAAN,IAAY,SAGX;AAHD,WAAY,SAAS;IACnB,wBAAW,CAAA;IACX,0BAAa,CAAA;AACf,CAAC,EAHW,SAAS,KAAT,SAAS,QAGpB;AAuDD,MAAM,CAAN,IAAY,UAOX;AAPD,WAAY,UAAU;IACpB,6BAA6B;IAC7B,uCAAyB,CAAA;IACzB,sCAAsC;IACtC,uCAAyB,CAAA;IACzB,kCAAkC;IAClC,2DAA6C,CAAA;AAC/C,CAAC,EAPW,UAAU,KAAV,UAAU,QAOrB"}
|
|
@@ -108,13 +108,12 @@ export declare enum SortOrder {
|
|
|
108
108
|
DESC = "DESC"
|
|
109
109
|
}
|
|
110
110
|
export interface CursorPaging {
|
|
111
|
-
/**
|
|
111
|
+
/** Maximum number of items to return in the results. */
|
|
112
112
|
limit?: number | null;
|
|
113
113
|
/**
|
|
114
114
|
* Pointer to the next or previous page in the list of results.
|
|
115
115
|
*
|
|
116
|
-
*
|
|
117
|
-
* from the `pagingMetadata` object in the previous call's response.
|
|
116
|
+
* Pass the relevant cursor token from the `pagingMetadata` object in the previous call's response.
|
|
118
117
|
* Not relevant for the first request.
|
|
119
118
|
*/
|
|
120
119
|
cursor?: string | null;
|
|
@@ -126,13 +125,13 @@ export interface ListFoldersResponse {
|
|
|
126
125
|
nextCursor?: PagingMetadataV2;
|
|
127
126
|
}
|
|
128
127
|
export interface PagingMetadataV2 {
|
|
129
|
-
/** Total number of items that match the query. */
|
|
128
|
+
/** Total number of items that match the query. Returned if offset paging is used and the `tooManyToCount` flag is not set. */
|
|
130
129
|
total?: number | null;
|
|
131
130
|
/** Cursors to navigate through the result pages using `next` and `prev`. Returned if cursor paging is used. */
|
|
132
131
|
cursors?: Cursors;
|
|
133
132
|
}
|
|
134
133
|
export interface Cursors {
|
|
135
|
-
/** Cursor pointing to next page in the list of results. */
|
|
134
|
+
/** Cursor string pointing to the next page in the list of results. */
|
|
136
135
|
next?: string | null;
|
|
137
136
|
}
|
|
138
137
|
export interface SearchFoldersRequest {
|
|
@@ -224,6 +223,73 @@ export interface ListDeletedFoldersResponse {
|
|
|
224
223
|
/** The next cursor if it exists. */
|
|
225
224
|
nextCursor?: PagingMetadataV2;
|
|
226
225
|
}
|
|
226
|
+
export interface DomainEvent extends DomainEventBodyOneOf {
|
|
227
|
+
createdEvent?: EntityCreatedEvent;
|
|
228
|
+
updatedEvent?: EntityUpdatedEvent;
|
|
229
|
+
deletedEvent?: EntityDeletedEvent;
|
|
230
|
+
actionEvent?: ActionEvent;
|
|
231
|
+
/**
|
|
232
|
+
* Unique event ID.
|
|
233
|
+
* Allows clients to ignore duplicate webhooks.
|
|
234
|
+
*/
|
|
235
|
+
_id?: string;
|
|
236
|
+
/**
|
|
237
|
+
* Assumes actions are also always typed to an entity_type
|
|
238
|
+
* Example: wix.stores.catalog.product, wix.bookings.session, wix.payments.transaction
|
|
239
|
+
*/
|
|
240
|
+
entityFqdn?: string;
|
|
241
|
+
/**
|
|
242
|
+
* This is top level to ease client code dispatching of messages (switch on entity_fqdn+slug)
|
|
243
|
+
* This is although the created/updated/deleted notion is duplication of the oneof types
|
|
244
|
+
* Example: created/updated/deleted/started/completed/email_opened
|
|
245
|
+
*/
|
|
246
|
+
slug?: string;
|
|
247
|
+
/** ID of the entity associated with the event. */
|
|
248
|
+
entityId?: string;
|
|
249
|
+
/** Event timestamp. */
|
|
250
|
+
eventTime?: Date;
|
|
251
|
+
/**
|
|
252
|
+
* Whether the event was triggered as a result of a privacy regulation application
|
|
253
|
+
* (for example, GDPR).
|
|
254
|
+
*/
|
|
255
|
+
triggeredByAnonymizeRequest?: boolean | null;
|
|
256
|
+
/** If present, indicates the action that triggered the event. */
|
|
257
|
+
originatedFrom?: string | null;
|
|
258
|
+
/**
|
|
259
|
+
* A sequence number defining the order of updates to the underlying entity.
|
|
260
|
+
* For example, given that some entity was updated at 16:00 and than again at 16:01,
|
|
261
|
+
* it is guaranteed that the sequence number of the second update is strictly higher than the first.
|
|
262
|
+
* As the consumer, you can use this value to ensure that you handle messages in the correct order.
|
|
263
|
+
* To do so, you will need to persist this number on your end, and compare the sequence number from the
|
|
264
|
+
* message against the one you have stored. Given that the stored number is higher, you should ignore the message.
|
|
265
|
+
*/
|
|
266
|
+
entityEventSequence?: string | null;
|
|
267
|
+
}
|
|
268
|
+
/** @oneof */
|
|
269
|
+
export interface DomainEventBodyOneOf {
|
|
270
|
+
createdEvent?: EntityCreatedEvent;
|
|
271
|
+
updatedEvent?: EntityUpdatedEvent;
|
|
272
|
+
deletedEvent?: EntityDeletedEvent;
|
|
273
|
+
actionEvent?: ActionEvent;
|
|
274
|
+
}
|
|
275
|
+
export interface EntityCreatedEvent {
|
|
276
|
+
entityAsJson?: string;
|
|
277
|
+
}
|
|
278
|
+
export interface EntityUpdatedEvent {
|
|
279
|
+
/**
|
|
280
|
+
* Since platformized APIs only expose PATCH and not PUT we can't assume that the fields sent from the client are the actual diff.
|
|
281
|
+
* This means that to generate a list of changed fields (as opposed to sent fields) one needs to traverse both objects.
|
|
282
|
+
* We don't want to impose this on all developers and so we leave this traversal to the notification recipients which need it.
|
|
283
|
+
*/
|
|
284
|
+
currentEntityAsJson?: string;
|
|
285
|
+
}
|
|
286
|
+
export interface EntityDeletedEvent {
|
|
287
|
+
/** Entity that was deleted */
|
|
288
|
+
deletedEntityAsJson?: string | null;
|
|
289
|
+
}
|
|
290
|
+
export interface ActionEvent {
|
|
291
|
+
bodyAsJson?: string;
|
|
292
|
+
}
|
|
227
293
|
export interface CreateFolderResponseNonNullableFields {
|
|
228
294
|
folder?: {
|
|
229
295
|
_id: string;
|