@wix/media 1.0.109 → 1.0.111
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 +6 -6
- package/type-bundles/context.bundle.d.ts +613 -169
- package/type-bundles/index.bundle.d.ts +613 -169
|
@@ -1,3 +1,47 @@
|
|
|
1
|
+
type RESTFunctionDescriptor<T extends (...args: any[]) => any = (...args: any[]) => any> = (httpClient: HttpClient) => T;
|
|
2
|
+
interface HttpClient {
|
|
3
|
+
request<TResponse, TData = any>(req: RequestOptionsFactory<TResponse, TData>): Promise<HttpResponse<TResponse>>;
|
|
4
|
+
fetchWithAuth: typeof fetch;
|
|
5
|
+
wixAPIFetch: (relativeUrl: string, options: RequestInit) => Promise<Response>;
|
|
6
|
+
}
|
|
7
|
+
type RequestOptionsFactory<TResponse = any, TData = any> = (context: any) => RequestOptions<TResponse, TData>;
|
|
8
|
+
type HttpResponse<T = any> = {
|
|
9
|
+
data: T;
|
|
10
|
+
status: number;
|
|
11
|
+
statusText: string;
|
|
12
|
+
headers: any;
|
|
13
|
+
request?: any;
|
|
14
|
+
};
|
|
15
|
+
type RequestOptions<_TResponse = any, Data = any> = {
|
|
16
|
+
method: 'POST' | 'GET' | 'PUT' | 'DELETE' | 'PATCH' | 'HEAD' | 'OPTIONS';
|
|
17
|
+
url: string;
|
|
18
|
+
data?: Data;
|
|
19
|
+
params?: URLSearchParams;
|
|
20
|
+
} & APIMetadata;
|
|
21
|
+
type APIMetadata = {
|
|
22
|
+
methodFqn?: string;
|
|
23
|
+
entityFqdn?: string;
|
|
24
|
+
packageName?: string;
|
|
25
|
+
};
|
|
26
|
+
type BuildRESTFunction<T extends RESTFunctionDescriptor> = T extends RESTFunctionDescriptor<infer U> ? U : never;
|
|
27
|
+
type EventDefinition<Payload = unknown, Type extends string = string> = {
|
|
28
|
+
__type: 'event-definition';
|
|
29
|
+
type: Type;
|
|
30
|
+
isDomainEvent?: boolean;
|
|
31
|
+
transformations?: (envelope: unknown) => Payload;
|
|
32
|
+
__payload: Payload;
|
|
33
|
+
};
|
|
34
|
+
declare function EventDefinition<Type extends string>(type: Type, isDomainEvent?: boolean, transformations?: (envelope: any) => unknown): <Payload = unknown>() => EventDefinition<Payload, Type>;
|
|
35
|
+
type EventHandler<T extends EventDefinition> = (payload: T['__payload']) => void | Promise<void>;
|
|
36
|
+
type BuildEventDefinition<T extends EventDefinition<any, string>> = (handler: EventHandler<T>) => void;
|
|
37
|
+
|
|
38
|
+
declare global {
|
|
39
|
+
// eslint-disable-next-line @typescript-eslint/consistent-type-definitions -- It has to be an `interface` so that it can be merged.
|
|
40
|
+
interface SymbolConstructor {
|
|
41
|
+
readonly observable: symbol;
|
|
42
|
+
}
|
|
43
|
+
}
|
|
44
|
+
|
|
1
45
|
interface EnterpriseCategory {
|
|
2
46
|
/**
|
|
3
47
|
* Id of the category
|
|
@@ -336,56 +380,57 @@ interface EnterpriseOnboardingOptions {
|
|
|
336
380
|
accountName?: string;
|
|
337
381
|
}
|
|
338
382
|
|
|
339
|
-
|
|
340
|
-
interface
|
|
341
|
-
|
|
342
|
-
|
|
343
|
-
|
|
383
|
+
declare function createCategory$1(httpClient: HttpClient): CreateCategorySignature;
|
|
384
|
+
interface CreateCategorySignature {
|
|
385
|
+
/**
|
|
386
|
+
* Fetch a list of random media from different providers, using site information to customize results when available
|
|
387
|
+
* @param - The category object that will be created
|
|
388
|
+
* @returns A list of items matching the request
|
|
389
|
+
*/
|
|
390
|
+
(category: EnterpriseCategory): Promise<EnterpriseCategory & EnterpriseCategoryNonNullableFields>;
|
|
344
391
|
}
|
|
345
|
-
|
|
346
|
-
|
|
347
|
-
|
|
348
|
-
|
|
349
|
-
|
|
350
|
-
|
|
351
|
-
|
|
352
|
-
}
|
|
353
|
-
|
|
354
|
-
|
|
355
|
-
|
|
356
|
-
|
|
357
|
-
|
|
358
|
-
|
|
359
|
-
|
|
360
|
-
|
|
361
|
-
|
|
362
|
-
|
|
363
|
-
|
|
364
|
-
|
|
365
|
-
|
|
366
|
-
|
|
367
|
-
|
|
368
|
-
|
|
369
|
-
|
|
370
|
-
|
|
371
|
-
|
|
372
|
-
|
|
373
|
-
|
|
374
|
-
|
|
375
|
-
|
|
376
|
-
|
|
377
|
-
|
|
378
|
-
|
|
379
|
-
|
|
380
|
-
|
|
392
|
+
declare function deleteCategory$1(httpClient: HttpClient): DeleteCategorySignature;
|
|
393
|
+
interface DeleteCategorySignature {
|
|
394
|
+
/**
|
|
395
|
+
* Delete a category including all its subcategories - but not the items
|
|
396
|
+
* @param - Category id
|
|
397
|
+
*/
|
|
398
|
+
(categoryId: string): Promise<void>;
|
|
399
|
+
}
|
|
400
|
+
declare function updateCategory$1(httpClient: HttpClient): UpdateCategorySignature;
|
|
401
|
+
interface UpdateCategorySignature {
|
|
402
|
+
/**
|
|
403
|
+
* Update category details
|
|
404
|
+
* @param - Id of the category
|
|
405
|
+
* @returns The updated category
|
|
406
|
+
*/
|
|
407
|
+
(_id: string, category: UpdateCategory): Promise<EnterpriseCategory & EnterpriseCategoryNonNullableFields>;
|
|
408
|
+
}
|
|
409
|
+
declare function getCategory$1(httpClient: HttpClient): GetCategorySignature;
|
|
410
|
+
interface GetCategorySignature {
|
|
411
|
+
/**
|
|
412
|
+
* Get information about a specific category
|
|
413
|
+
* @param - Category id
|
|
414
|
+
* @returns The category details
|
|
415
|
+
*/
|
|
416
|
+
(categoryId: string, options?: GetCategoryOptions | undefined): Promise<EnterpriseCategoryTree & EnterpriseCategoryTreeNonNullableFields>;
|
|
417
|
+
}
|
|
418
|
+
declare function enterpriseOnboarding$1(httpClient: HttpClient): EnterpriseOnboardingSignature;
|
|
419
|
+
interface EnterpriseOnboardingSignature {
|
|
420
|
+
/**
|
|
421
|
+
* Create the enterprise category under "enterprise-media" main category
|
|
422
|
+
* the caller identity must be have the same accountId of the request
|
|
423
|
+
* @param - The account id of the organization - will be used as the organization category id
|
|
424
|
+
*/
|
|
425
|
+
(accountId: string, options?: EnterpriseOnboardingOptions | undefined): Promise<EnterpriseOnboardingResponse & EnterpriseOnboardingResponseNonNullableFields>;
|
|
426
|
+
}
|
|
427
|
+
declare function getMediaManagerCategories$1(httpClient: HttpClient): GetMediaManagerCategoriesSignature;
|
|
428
|
+
interface GetMediaManagerCategoriesSignature {
|
|
429
|
+
/**
|
|
430
|
+
* Get the account category tree details
|
|
431
|
+
*/
|
|
432
|
+
(): Promise<GetMediaManagerCategoriesResponse & GetMediaManagerCategoriesResponseNonNullableFields>;
|
|
381
433
|
}
|
|
382
|
-
|
|
383
|
-
declare function createCategory$1(httpClient: HttpClient): (category: EnterpriseCategory) => Promise<EnterpriseCategory & EnterpriseCategoryNonNullableFields>;
|
|
384
|
-
declare function deleteCategory$1(httpClient: HttpClient): (categoryId: string) => Promise<void>;
|
|
385
|
-
declare function updateCategory$1(httpClient: HttpClient): (_id: string, category: UpdateCategory) => Promise<EnterpriseCategory & EnterpriseCategoryNonNullableFields>;
|
|
386
|
-
declare function getCategory$1(httpClient: HttpClient): (categoryId: string, options?: GetCategoryOptions) => Promise<EnterpriseCategoryTree & EnterpriseCategoryTreeNonNullableFields>;
|
|
387
|
-
declare function enterpriseOnboarding$1(httpClient: HttpClient): (accountId: string, options?: EnterpriseOnboardingOptions) => Promise<EnterpriseOnboardingResponse & EnterpriseOnboardingResponseNonNullableFields>;
|
|
388
|
-
declare function getMediaManagerCategories$1(httpClient: HttpClient): () => Promise<GetMediaManagerCategoriesResponse & GetMediaManagerCategoriesResponseNonNullableFields>;
|
|
389
434
|
declare const onEnterpriseCategoryCreated$1: EventDefinition<EnterpriseCategoryCreatedEnvelope, "wix.media.enterprise_public_media.v1.enterprise_category_created">;
|
|
390
435
|
declare const onEnterpriseCategoryDeleted$1: EventDefinition<EnterpriseCategoryDeletedEnvelope, "wix.media.enterprise_public_media.v1.enterprise_category_deleted">;
|
|
391
436
|
declare const onEnterpriseCategoryUpdated$1: EventDefinition<EnterpriseCategoryUpdatedEnvelope, "wix.media.enterprise_public_media.v1.enterprise_category_updated">;
|
|
@@ -408,12 +453,15 @@ type _publicGetMediaManagerCategoriesType = typeof getMediaManagerCategories$1;
|
|
|
408
453
|
declare const getMediaManagerCategories: ReturnType<typeof createRESTModule$3<_publicGetMediaManagerCategoriesType>>;
|
|
409
454
|
|
|
410
455
|
type _publicOnEnterpriseCategoryCreatedType = typeof onEnterpriseCategoryCreated$1;
|
|
456
|
+
/** */
|
|
411
457
|
declare const onEnterpriseCategoryCreated: ReturnType<typeof createEventModule$3<_publicOnEnterpriseCategoryCreatedType>>;
|
|
412
458
|
|
|
413
459
|
type _publicOnEnterpriseCategoryDeletedType = typeof onEnterpriseCategoryDeleted$1;
|
|
460
|
+
/** */
|
|
414
461
|
declare const onEnterpriseCategoryDeleted: ReturnType<typeof createEventModule$3<_publicOnEnterpriseCategoryDeletedType>>;
|
|
415
462
|
|
|
416
463
|
type _publicOnEnterpriseCategoryUpdatedType = typeof onEnterpriseCategoryUpdated$1;
|
|
464
|
+
/** */
|
|
417
465
|
declare const onEnterpriseCategoryUpdated: ReturnType<typeof createEventModule$3<_publicOnEnterpriseCategoryUpdatedType>>;
|
|
418
466
|
|
|
419
467
|
type context$3_CreateCategoryRequest = CreateCategoryRequest;
|
|
@@ -1296,17 +1344,94 @@ interface OverwriteItemCategoriesOptions {
|
|
|
1296
1344
|
categoryIds?: string[];
|
|
1297
1345
|
}
|
|
1298
1346
|
|
|
1299
|
-
declare function itemUploadCallback$1(httpClient: HttpClient):
|
|
1300
|
-
|
|
1301
|
-
|
|
1302
|
-
|
|
1303
|
-
|
|
1304
|
-
|
|
1305
|
-
|
|
1306
|
-
declare function
|
|
1307
|
-
|
|
1308
|
-
|
|
1309
|
-
|
|
1347
|
+
declare function itemUploadCallback$1(httpClient: HttpClient): ItemUploadCallbackSignature;
|
|
1348
|
+
interface ItemUploadCallbackSignature {
|
|
1349
|
+
/**
|
|
1350
|
+
* Internal API called by the public media backend, notify about a file that was created enterprise public media server
|
|
1351
|
+
*/
|
|
1352
|
+
(options?: ItemUploadCallbackOptions | undefined): Promise<void>;
|
|
1353
|
+
}
|
|
1354
|
+
declare function generateFileUploadUrl$3(httpClient: HttpClient): GenerateFileUploadUrlSignature$1;
|
|
1355
|
+
interface GenerateFileUploadUrlSignature$1 {
|
|
1356
|
+
/**
|
|
1357
|
+
* Generate an upload url that will make public media to call the enterprise callback endpoint
|
|
1358
|
+
*/
|
|
1359
|
+
(options?: GenerateFileUploadUrlOptions$1 | undefined): Promise<GenerateFileUploadUrlResponse$1 & GenerateFileUploadUrlResponseNonNullableFields$1>;
|
|
1360
|
+
}
|
|
1361
|
+
declare function importFile$3(httpClient: HttpClient): ImportFileSignature$1;
|
|
1362
|
+
interface ImportFileSignature$1 {
|
|
1363
|
+
/**
|
|
1364
|
+
* Import a file using a url
|
|
1365
|
+
* @param - The url to the file to be imported
|
|
1366
|
+
*/
|
|
1367
|
+
(url: string, options?: ImportFileOptions$1 | undefined): Promise<ImportFileResponse$1 & ImportFileResponseNonNullableFields$1>;
|
|
1368
|
+
}
|
|
1369
|
+
declare function searchItems$1(httpClient: HttpClient): SearchItemsSignature;
|
|
1370
|
+
interface SearchItemsSignature {
|
|
1371
|
+
/**
|
|
1372
|
+
* Search items, all filters only support equality
|
|
1373
|
+
* Each query must contain a categoryId filter
|
|
1374
|
+
*/
|
|
1375
|
+
(options?: SearchItemsOptions | undefined): Promise<SearchItemsResponse & SearchItemsResponseNonNullableFields>;
|
|
1376
|
+
}
|
|
1377
|
+
declare function queryItems$1(httpClient: HttpClient): QueryItemsSignature;
|
|
1378
|
+
interface QueryItemsSignature {
|
|
1379
|
+
/**
|
|
1380
|
+
* Query items allowing to sort by specified fields, all filters only support equality
|
|
1381
|
+
* Each query must contain a categoryId filter
|
|
1382
|
+
*/
|
|
1383
|
+
(): ItemsQueryBuilder;
|
|
1384
|
+
}
|
|
1385
|
+
declare function updateItem$1(httpClient: HttpClient): UpdateItemSignature;
|
|
1386
|
+
interface UpdateItemSignature {
|
|
1387
|
+
/**
|
|
1388
|
+
* Update an item
|
|
1389
|
+
* @param - Id of the item in public media
|
|
1390
|
+
* @returns Updated item info
|
|
1391
|
+
*/
|
|
1392
|
+
(_id: string, item: UpdateItem): Promise<EnterpriseMediaItem & EnterpriseMediaItemNonNullableFields>;
|
|
1393
|
+
}
|
|
1394
|
+
declare function bulkUpdateItem$1(httpClient: HttpClient): BulkUpdateItemSignature;
|
|
1395
|
+
interface BulkUpdateItemSignature {
|
|
1396
|
+
/**
|
|
1397
|
+
* Bulk update an item
|
|
1398
|
+
* @param - Requests to update individual item
|
|
1399
|
+
*/
|
|
1400
|
+
(updateItemRequests: UpdateItemRequest[], options?: BulkUpdateItemOptions | undefined): Promise<BulkUpdateItemResponse & BulkUpdateItemResponseNonNullableFields>;
|
|
1401
|
+
}
|
|
1402
|
+
declare function getItem$1(httpClient: HttpClient): GetItemSignature;
|
|
1403
|
+
interface GetItemSignature {
|
|
1404
|
+
/**
|
|
1405
|
+
* Get item details
|
|
1406
|
+
* @param - Item id
|
|
1407
|
+
* @returns item info
|
|
1408
|
+
*/
|
|
1409
|
+
(itemId: string): Promise<EnterpriseMediaItem & EnterpriseMediaItemNonNullableFields>;
|
|
1410
|
+
}
|
|
1411
|
+
declare function linkItemToCategories$1(httpClient: HttpClient): LinkItemToCategoriesSignature;
|
|
1412
|
+
interface LinkItemToCategoriesSignature {
|
|
1413
|
+
/**
|
|
1414
|
+
* Link the item to multiple categories
|
|
1415
|
+
* @param - The item id
|
|
1416
|
+
*/
|
|
1417
|
+
(itemId: string, options?: LinkItemToCategoriesOptions | undefined): Promise<LinkItemToCategoriesResponse>;
|
|
1418
|
+
}
|
|
1419
|
+
declare function unlinkItemFromCategories$1(httpClient: HttpClient): UnlinkItemFromCategoriesSignature;
|
|
1420
|
+
interface UnlinkItemFromCategoriesSignature {
|
|
1421
|
+
/**
|
|
1422
|
+
* Unlink the item from multiple categories
|
|
1423
|
+
* @param - The item id
|
|
1424
|
+
*/
|
|
1425
|
+
(itemId: string, options?: UnlinkItemFromCategoriesOptions | undefined): Promise<UnlinkItemFromCategoriesResponse>;
|
|
1426
|
+
}
|
|
1427
|
+
declare function overwriteItemCategories$1(httpClient: HttpClient): OverwriteItemCategoriesSignature;
|
|
1428
|
+
interface OverwriteItemCategoriesSignature {
|
|
1429
|
+
/**
|
|
1430
|
+
* Overwrite item categories
|
|
1431
|
+
* @param - The item id
|
|
1432
|
+
*/
|
|
1433
|
+
(itemId: string, options?: OverwriteItemCategoriesOptions | undefined): Promise<OverwriteItemCategoriesResponse>;
|
|
1434
|
+
}
|
|
1310
1435
|
declare const onEnterpriseItemCreated$1: EventDefinition<EnterpriseItemCreatedEnvelope, "wix.media.enterprise_public_media.v1.enterprise_item_created">;
|
|
1311
1436
|
declare const onEnterpriseItemUpdated$1: EventDefinition<EnterpriseItemUpdatedEnvelope, "wix.media.enterprise_public_media.v1.enterprise_item_updated">;
|
|
1312
1437
|
declare const onEnterpriseItemItemCategoriesChanged$1: EventDefinition<EnterpriseItemItemCategoriesChangedEnvelope, "wix.media.enterprise_public_media.v1.enterprise_item_item_categories_changed">;
|
|
@@ -1340,15 +1465,27 @@ type _publicOverwriteItemCategoriesType = typeof overwriteItemCategories$1;
|
|
|
1340
1465
|
declare const overwriteItemCategories: ReturnType<typeof createRESTModule$2<_publicOverwriteItemCategoriesType>>;
|
|
1341
1466
|
|
|
1342
1467
|
type _publicOnEnterpriseItemCreatedType = typeof onEnterpriseItemCreated$1;
|
|
1468
|
+
/**
|
|
1469
|
+
* Triggered when an item is created.
|
|
1470
|
+
*/
|
|
1343
1471
|
declare const onEnterpriseItemCreated: ReturnType<typeof createEventModule$2<_publicOnEnterpriseItemCreatedType>>;
|
|
1344
1472
|
|
|
1345
1473
|
type _publicOnEnterpriseItemUpdatedType = typeof onEnterpriseItemUpdated$1;
|
|
1474
|
+
/**
|
|
1475
|
+
* Triggered when an item is updated, including when an item is archived or linked to a category
|
|
1476
|
+
*/
|
|
1346
1477
|
declare const onEnterpriseItemUpdated: ReturnType<typeof createEventModule$2<_publicOnEnterpriseItemUpdatedType>>;
|
|
1347
1478
|
|
|
1348
1479
|
type _publicOnEnterpriseItemItemCategoriesChangedType = typeof onEnterpriseItemItemCategoriesChanged$1;
|
|
1480
|
+
/**
|
|
1481
|
+
* Triggered when an is linked to a category or unlinked from a category
|
|
1482
|
+
*/
|
|
1349
1483
|
declare const onEnterpriseItemItemCategoriesChanged: ReturnType<typeof createEventModule$2<_publicOnEnterpriseItemItemCategoriesChangedType>>;
|
|
1350
1484
|
|
|
1351
1485
|
type _publicOnEnterpriseItemPublishStatusChangedType = typeof onEnterpriseItemPublishStatusChanged$1;
|
|
1486
|
+
/**
|
|
1487
|
+
* Triggered when an item is Published or Unpublished
|
|
1488
|
+
*/
|
|
1352
1489
|
declare const onEnterpriseItemPublishStatusChanged: ReturnType<typeof createEventModule$2<_publicOnEnterpriseItemPublishStatusChangedType>>;
|
|
1353
1490
|
|
|
1354
1491
|
type context$2_BulkItemUpdateResult = BulkItemUpdateResult;
|
|
@@ -2619,89 +2756,6 @@ interface GenerateFileDownloadUrlOptions {
|
|
|
2619
2756
|
*/
|
|
2620
2757
|
contentDisposition?: ContentDisposition;
|
|
2621
2758
|
}
|
|
2622
|
-
interface UpdateFileDescriptorOptions {
|
|
2623
|
-
file: {
|
|
2624
|
-
/**
|
|
2625
|
-
* File ID. Generated when a file is uploaded to the Media Manager.
|
|
2626
|
-
* @readonly
|
|
2627
|
-
*/
|
|
2628
|
-
_id?: string;
|
|
2629
|
-
/** File name as it appears in the Media Manager. */
|
|
2630
|
-
displayName?: string;
|
|
2631
|
-
/**
|
|
2632
|
-
* Static URL of the file.
|
|
2633
|
-
* @readonly
|
|
2634
|
-
*/
|
|
2635
|
-
url?: string;
|
|
2636
|
-
/** ID of the file's parent folder. */
|
|
2637
|
-
parentFolderId?: string | null;
|
|
2638
|
-
/**
|
|
2639
|
-
* File hash.
|
|
2640
|
-
* @readonly
|
|
2641
|
-
*/
|
|
2642
|
-
hash?: string;
|
|
2643
|
-
/**
|
|
2644
|
-
* Size of the uploaded file in bytes.
|
|
2645
|
-
* @readonly
|
|
2646
|
-
*/
|
|
2647
|
-
sizeInBytes?: string | null;
|
|
2648
|
-
/**
|
|
2649
|
-
* Whether the link to the uploaded file is public or private. Private links require a token.
|
|
2650
|
-
* @readonly
|
|
2651
|
-
*/
|
|
2652
|
-
private?: boolean;
|
|
2653
|
-
/**
|
|
2654
|
-
* Media file type.
|
|
2655
|
-
* @readonly
|
|
2656
|
-
*/
|
|
2657
|
-
mediaType?: MediaType;
|
|
2658
|
-
/**
|
|
2659
|
-
* Media file content.
|
|
2660
|
-
* @readonly
|
|
2661
|
-
*/
|
|
2662
|
-
media?: FileMedia;
|
|
2663
|
-
/**
|
|
2664
|
-
* Status of the file that was uploaded.
|
|
2665
|
-
* * `FAILED`: The file failed to upload, for example, during media post processing.
|
|
2666
|
-
* * `READY`: The file uploaded, finished all processing, and is ready for use.
|
|
2667
|
-
* * `PENDING`: The file is processing and the URLs are not yet available. This response is returned when importing a file.
|
|
2668
|
-
* @readonly
|
|
2669
|
-
*/
|
|
2670
|
-
operationStatus?: OperationStatus;
|
|
2671
|
-
/**
|
|
2672
|
-
* URL where the file was uploaded from.
|
|
2673
|
-
* @readonly
|
|
2674
|
-
*/
|
|
2675
|
-
sourceUrl?: string | null;
|
|
2676
|
-
/**
|
|
2677
|
-
* URL of the file's thumbnail.
|
|
2678
|
-
* @readonly
|
|
2679
|
-
*/
|
|
2680
|
-
thumbnailUrl?: string | null;
|
|
2681
|
-
/** Labels assigned to media files that describe and categorize them. Provided by the user, or generated by [Google Vision API](https://cloud.google.com/vision/docs/drag-and-drop) for images. */
|
|
2682
|
-
labels?: string[];
|
|
2683
|
-
/**
|
|
2684
|
-
* Date and time the file was created.
|
|
2685
|
-
* @readonly
|
|
2686
|
-
*/
|
|
2687
|
-
_createdDate?: Date;
|
|
2688
|
-
/**
|
|
2689
|
-
* Date and time the file was updated.
|
|
2690
|
-
* @readonly
|
|
2691
|
-
*/
|
|
2692
|
-
_updatedDate?: Date;
|
|
2693
|
-
/**
|
|
2694
|
-
* The Wix site ID where the media file is stored.
|
|
2695
|
-
* @readonly
|
|
2696
|
-
*/
|
|
2697
|
-
siteId?: string;
|
|
2698
|
-
/**
|
|
2699
|
-
* State of the file.
|
|
2700
|
-
* @readonly
|
|
2701
|
-
*/
|
|
2702
|
-
state?: State$1;
|
|
2703
|
-
};
|
|
2704
|
-
}
|
|
2705
2759
|
interface GenerateFileUploadUrlOptions {
|
|
2706
2760
|
/**
|
|
2707
2761
|
* Temporary file name used to identify the file type. For example, a file named "myFile.jpeg" identifies as an "image/jpeg" file type.
|
|
@@ -2899,22 +2953,294 @@ interface ListDeletedFilesOptions {
|
|
|
2899
2953
|
paging?: CursorPaging$1;
|
|
2900
2954
|
}
|
|
2901
2955
|
|
|
2902
|
-
declare function generateFilesDownloadUrl$1(httpClient: HttpClient):
|
|
2903
|
-
|
|
2904
|
-
|
|
2905
|
-
|
|
2906
|
-
|
|
2907
|
-
|
|
2908
|
-
|
|
2909
|
-
|
|
2910
|
-
|
|
2911
|
-
|
|
2912
|
-
|
|
2913
|
-
|
|
2914
|
-
|
|
2915
|
-
|
|
2916
|
-
|
|
2917
|
-
|
|
2956
|
+
declare function generateFilesDownloadUrl$1(httpClient: HttpClient): GenerateFilesDownloadUrlSignature;
|
|
2957
|
+
interface GenerateFilesDownloadUrlSignature {
|
|
2958
|
+
/**
|
|
2959
|
+
* Generates a URL for downloading a compressed file containing specific files in the Media Manager.
|
|
2960
|
+
*
|
|
2961
|
+
* The `generateFilesDownloadUrl()` function returns a Promise that resolves to a download URL.
|
|
2962
|
+
*
|
|
2963
|
+
* The compressed file can contain up to 1000 files.
|
|
2964
|
+
*
|
|
2965
|
+
* To generate one or more temporary URLs for downloading a specific file in the Media Manager, use the `generateFileDownloadUrl()` function.
|
|
2966
|
+
* You can use the `expirationInMinutes` parameter to set the URL expiration time, making it more secure than the `generateFilesDownloadUrl()` function.
|
|
2967
|
+
* Therefore, to download private files, use the `generateFileDownloadUrl` function for each private file that you want to generate a download URL for.
|
|
2968
|
+
* @param - IDs of the files to download.
|
|
2969
|
+
*
|
|
2970
|
+
* You can also pass the files' Wix media URLs. For example, `["wix:image://v1/0abec0_b291a9349a0b4da59067f76287e386fb~mv2.jpg/leon.jpg#originWidth=3024&originHeight=4032"]`.
|
|
2971
|
+
* Learn more in the File and Folder IDs article.
|
|
2972
|
+
*/
|
|
2973
|
+
(fileIds: string[]): Promise<GenerateFilesDownloadUrlResponse & GenerateFilesDownloadUrlResponseNonNullableFields>;
|
|
2974
|
+
}
|
|
2975
|
+
declare function generateFileDownloadUrl$1(httpClient: HttpClient): GenerateFileDownloadUrlSignature;
|
|
2976
|
+
interface GenerateFileDownloadUrlSignature {
|
|
2977
|
+
/**
|
|
2978
|
+
* Generates one or more temporary URLs for downloading a specific file in the Media Manager.
|
|
2979
|
+
*
|
|
2980
|
+
* The `generateFileDownloadUrl()` function returns a Promise that resolves to an array containing download URLs for the assets specified in the options parameter.
|
|
2981
|
+
*
|
|
2982
|
+
* To download different assets of the file, use the `assetKeys` parameter which generates a download URL for each asset.
|
|
2983
|
+
* If no asset key is specified, it defaults to `src`, which generates one download URL in the original file's format and quality.
|
|
2984
|
+
*
|
|
2985
|
+
* Use this function to grant external clients access to a private media file. Use the `expirationInMinutes` parameter to set the URL expiration time, and the `expirationRedirectUrl` parameter to add a redirect URL when the URL expires.
|
|
2986
|
+
*
|
|
2987
|
+
* To generate a permanent URL for downloading a compressed file that contains multiple files in the Media Manager, use the `generateFilesDownloadUrl()` function.
|
|
2988
|
+
* Since this is a permanent URL, it is less secure. Therefore, to download private files, use the `generateFileDownloadUrl()` function for each private file that you want to generate a download URL for.
|
|
2989
|
+
* @param - Options to use when generating a file's download URL.
|
|
2990
|
+
* @param - File ID.
|
|
2991
|
+
*
|
|
2992
|
+
* You can also pass the files' Wix media URLs. For example, `["wix:image://v1/0abec0_b291a9349a0b4da59067f76287e386fb~mv2.jpg/leon.jpg#originWidth=3024&originHeight=4032"]`.
|
|
2993
|
+
* Learn more in the File and Folder IDs article.
|
|
2994
|
+
*/
|
|
2995
|
+
(fileId: string, options?: GenerateFileDownloadUrlOptions | undefined): Promise<GenerateFileDownloadUrlResponse & GenerateFileDownloadUrlResponseNonNullableFields>;
|
|
2996
|
+
}
|
|
2997
|
+
declare function getFileDescriptor$1(httpClient: HttpClient): GetFileDescriptorSignature;
|
|
2998
|
+
interface GetFileDescriptorSignature {
|
|
2999
|
+
/**
|
|
3000
|
+
* Gets information about the specified file in the Media Manager.
|
|
3001
|
+
*
|
|
3002
|
+
*
|
|
3003
|
+
* The `getFileDescriptor()` function returns a Promise that resolves to the specified file's descriptor.
|
|
3004
|
+
*
|
|
3005
|
+
* Use `getFileDescriptors()` to get multiple file descriptors at once.
|
|
3006
|
+
* @param - File ID.
|
|
3007
|
+
*
|
|
3008
|
+
* You can also pass the files' Wix media URLs. For example, `["wix:image://v1/0abec0_b291a9349a0b4da59067f76287e386fb~mv2.jpg/leon.jpg#originWidth=3024&originHeight=4032"]`.
|
|
3009
|
+
* Learn more in the File and Folder IDs article.
|
|
3010
|
+
* @returns Information about the file.
|
|
3011
|
+
*/
|
|
3012
|
+
(fileId: string): Promise<FileDescriptor & FileDescriptorNonNullableFields>;
|
|
3013
|
+
}
|
|
3014
|
+
declare function getFileDescriptors$1(httpClient: HttpClient): GetFileDescriptorsSignature;
|
|
3015
|
+
interface GetFileDescriptorsSignature {
|
|
3016
|
+
/**
|
|
3017
|
+
* Gets information about the specified files in the Media Manager.
|
|
3018
|
+
*
|
|
3019
|
+
*
|
|
3020
|
+
* The `getFileDescriptors()` function returns a Promise that resolves to an array containing the specified files' descriptors.
|
|
3021
|
+
*
|
|
3022
|
+
* Use `getFileDescriptor()` to get a single file descriptor.
|
|
3023
|
+
* @param - File IDs.
|
|
3024
|
+
*
|
|
3025
|
+
* You can also pass the files' Wix media URLs. For example, `["wix:image://v1/0abec0_b291a9349a0b4da59067f76287e386fb~mv2.jpg/leon.jpg#originWidth=3024&originHeight=4032"]`.
|
|
3026
|
+
* Learn more in the File and Folder IDs article.
|
|
3027
|
+
*/
|
|
3028
|
+
(fileIds: string[]): Promise<GetFileDescriptorsResponse & GetFileDescriptorsResponseNonNullableFields>;
|
|
3029
|
+
}
|
|
3030
|
+
declare function updateFileDescriptor$1(httpClient: HttpClient): UpdateFileDescriptorSignature;
|
|
3031
|
+
interface UpdateFileDescriptorSignature {
|
|
3032
|
+
/**
|
|
3033
|
+
* Updates a file.
|
|
3034
|
+
*
|
|
3035
|
+
*
|
|
3036
|
+
* The `updateFileDescriptor()` function returns a Promise that resolves to the updated file's descriptor.
|
|
3037
|
+
*
|
|
3038
|
+
* You can use the `parentFolderId` parameter to move a file from its current folder to a different folder.
|
|
3039
|
+
* @param - The file to update.
|
|
3040
|
+
* @returns Information about the updated file.
|
|
3041
|
+
*/
|
|
3042
|
+
(file: FileDescriptor): Promise<FileDescriptor & FileDescriptorNonNullableFields>;
|
|
3043
|
+
}
|
|
3044
|
+
declare function generateFileUploadUrl$1(httpClient: HttpClient): GenerateFileUploadUrlSignature;
|
|
3045
|
+
interface GenerateFileUploadUrlSignature {
|
|
3046
|
+
/**
|
|
3047
|
+
* Generates an upload URL to allow external clients to upload a file to the Media Manager.
|
|
3048
|
+
*
|
|
3049
|
+
* The `generateFileUploadUrl()` function returns a Promise that resolves to an upload URL.
|
|
3050
|
+
*
|
|
3051
|
+
* To learn how external clients can use the generated upload URL in the response to upload a file to the Media Manager, see the Upload API article.
|
|
3052
|
+
*
|
|
3053
|
+
* > **Notes:**
|
|
3054
|
+
* > - When you upload a file, it's not immediately available, meaning you can't manage or use the file straight away. Learn more about [knowing when a file is ready](/files/importing-files).
|
|
3055
|
+
* > - Any interruption in the upload process stops the file upload. For files larger than 10MB, or when network connection is poor, use `generateFileResumableUploadUrl()` instead. With the resumable upload URL, any interruption in the upload process pauses the file upload, and resumes the file upload process after the interruption.
|
|
3056
|
+
* @param - File mime type.
|
|
3057
|
+
* @param - Options to use when generating a file's upload URL.
|
|
3058
|
+
*/
|
|
3059
|
+
(mimeType: string | null, options?: GenerateFileUploadUrlOptions | undefined): Promise<GenerateFileUploadUrlResponse & GenerateFileUploadUrlResponseNonNullableFields>;
|
|
3060
|
+
}
|
|
3061
|
+
declare function generateFileResumableUploadUrl$1(httpClient: HttpClient): GenerateFileResumableUploadUrlSignature;
|
|
3062
|
+
interface GenerateFileResumableUploadUrlSignature {
|
|
3063
|
+
/**
|
|
3064
|
+
* Generates a resumable upload URL to allow external clients to upload large files over 10MB to the Media Manager.
|
|
3065
|
+
*
|
|
3066
|
+
* The `generateFileResumableUploadUrl()` function returns a Promise that resolves to an upload URL, token, and protocol.
|
|
3067
|
+
*
|
|
3068
|
+
* When using the resumable upload URL, any interruptions will pause the file upload process, which automatically resumes once the interruption is resolved. The resumable upload URL is also helpful when network connection is poor.
|
|
3069
|
+
*
|
|
3070
|
+
* To learn how external clients can use the generated upload URL in the response to upload large files to the Media Manager, see the Resumable Upload API article.
|
|
3071
|
+
*
|
|
3072
|
+
* > **Note:** When you upload a file, it's not immediately available, meaning you can't manage or use the file straight away. Learn more about [knowing when a file is ready](/files/importing-files).
|
|
3073
|
+
* @param - File mime type.
|
|
3074
|
+
* @param - Options to use when generating a resumable upload URL.
|
|
3075
|
+
*/
|
|
3076
|
+
(mimeType: string | null, options?: GenerateFileResumableUploadUrlOptions | undefined): Promise<GenerateFileResumableUploadUrlResponse & GenerateFileResumableUploadUrlResponseNonNullableFields>;
|
|
3077
|
+
}
|
|
3078
|
+
declare function importFile$1(httpClient: HttpClient): ImportFileSignature;
|
|
3079
|
+
interface ImportFileSignature {
|
|
3080
|
+
/**
|
|
3081
|
+
* Imports a file to the Media Manager using an external URL.
|
|
3082
|
+
*
|
|
3083
|
+
* The `importFile()` function returns a Promise that resolves to the imported file's descriptor.
|
|
3084
|
+
*
|
|
3085
|
+
* This function returns information about the imported file. Importing a file is the method through which you can add files to the Media Manager.
|
|
3086
|
+
* Use the `parentFolderId` and `filePath` parameters to specify which folder you want the file to be imported to.
|
|
3087
|
+
* If no folder is specified, the file is imported to the `media-root` folder.
|
|
3088
|
+
*
|
|
3089
|
+
* > **Note:** When you import a file, it's not immediately available, meaning you can't manage or use the file straight away. Learn more about [knowing when a file is ready](/files/importing-files).
|
|
3090
|
+
*
|
|
3091
|
+
* To import a file, you need to do one of the following:
|
|
3092
|
+
* - Pass its [MIME type](https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/MIME_types) in the `mimeType` field of the request. For example, `mimeType: 'image/jpeg'`.
|
|
3093
|
+
* - Include its extension in either the `displayName` or `url` field of the request. For example, `displayName: 'Example Image.jpeg` or `url: https://www.example.com/image.jpeg`.
|
|
3094
|
+
* - Ensure the server hosting the file supports HEAD requests. In these cases the Wix servers can retrieve the MIME type from the hosting server.
|
|
3095
|
+
* > **Note:** If you want to validate the media type, pass the file's expected media type in the optional `mediaType` field of the request. For example, `mediaType: 'IMAGE'`.
|
|
3096
|
+
* @param - Publicly accessible external file URL.
|
|
3097
|
+
* @param - Options to use when importing a single file.
|
|
3098
|
+
*/
|
|
3099
|
+
(url: string, options?: ImportFileOptions | undefined): Promise<ImportFileResponse & ImportFileResponseNonNullableFields>;
|
|
3100
|
+
}
|
|
3101
|
+
declare function bulkImportFiles$1(httpClient: HttpClient): BulkImportFilesSignature;
|
|
3102
|
+
interface BulkImportFilesSignature {
|
|
3103
|
+
/**
|
|
3104
|
+
* > **Deprecated.**
|
|
3105
|
+
* > This function has been replaced with `bulkImportFile()`, and will be removed on March 31, 2024.
|
|
3106
|
+
*
|
|
3107
|
+
*
|
|
3108
|
+
* The `bulkImportFiles()` function returns a Promise that resolves to an array of the imported files' descriptors.
|
|
3109
|
+
*
|
|
3110
|
+
* Imports a bulk of files to the Media Manager using external urls.
|
|
3111
|
+
*
|
|
3112
|
+
* Returns information about the imported files. Use the `parentFolderId` and `filePath` parameters to specify in which folder you want each file to be imported.
|
|
3113
|
+
* If no folder is specified, the file is imported to the `media-root` folder.
|
|
3114
|
+
*
|
|
3115
|
+
* >**Note:** The `media` property isn't returned in the `files` response object.
|
|
3116
|
+
*
|
|
3117
|
+
* To import files, you need to do one of the following for each file:
|
|
3118
|
+
* - Pass its [MIME type](https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/MIME_types) in the `mimeType` field of the request. For example, `mimeType: 'image/jpeg'`.
|
|
3119
|
+
* - Include its extension in either the `displayName` or `url` field of the request. For example, `displayName: 'Example Image.jpeg` or `url: https://www.example.com/image.jpeg`.
|
|
3120
|
+
* - Ensure the server hosting the file supports HEAD requests. In these cases the Wix servers can retrieve the MIME type from the hosting server.
|
|
3121
|
+
* > **Note:** If you want to validate the media type, pass the file's expected media type in the optional `mediaType` field of the request. For example, `mediaType: 'IMAGE'`.
|
|
3122
|
+
* @param - Information about the files to import.
|
|
3123
|
+
* @param - Options to use when uploading multiple files.
|
|
3124
|
+
* @deprecated
|
|
3125
|
+
*/
|
|
3126
|
+
(importFileRequests: ImportFileRequest[]): Promise<BulkImportFilesResponse & BulkImportFilesResponseNonNullableFields>;
|
|
3127
|
+
}
|
|
3128
|
+
declare function bulkImportFile$1(httpClient: HttpClient): BulkImportFileSignature;
|
|
3129
|
+
interface BulkImportFileSignature {
|
|
3130
|
+
/**
|
|
3131
|
+
* Imports a bulk of files to the Media Manager using external urls.
|
|
3132
|
+
*
|
|
3133
|
+
* The `bulkImportFile()` function returns a Promise that resolves to an object containing bulk import metadata and an array of imported files' descriptors and metadata.
|
|
3134
|
+
*
|
|
3135
|
+
* Returns information about the imported files. Use the `parentFolderId` and `filePath` parameters to specify in which folder you want each file to be imported.
|
|
3136
|
+
* If no folder is specified, the file is imported to the `media-root` folder.
|
|
3137
|
+
*
|
|
3138
|
+
* > **Note:** When you import a file, it's not immediately available, meaning you can't manage or use the file straight away. Learn more about [knowing when a file is ready](/files/importing-files).
|
|
3139
|
+
*
|
|
3140
|
+
* To import files, you need to do one of the following for each file:
|
|
3141
|
+
* - Pass its [MIME type](https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/MIME_types) in the `mimeType` field of the request. For example, `mimeType: 'image/jpeg'`.
|
|
3142
|
+
* - Include its extension in either the `displayName` or `url` field of the request. For example, `displayName: 'Example Image.jpeg` or `url: https://www.example.com/image.jpeg`.
|
|
3143
|
+
* - Ensure the server hosting the file supports HEAD requests. In these cases the Wix servers can retrieve the MIME type from the hosting server.
|
|
3144
|
+
* > **Note:** If you want to validate the media type, pass the file's expected media type in the optional `mediaType` field of the request. For example, `mediaType: 'IMAGE'`.
|
|
3145
|
+
* @param - Information about the files to import.
|
|
3146
|
+
* @param - Options to include the file descriptor in the response.
|
|
3147
|
+
*/
|
|
3148
|
+
(importFileRequests: ImportFileRequest[], options?: BulkImportFileOptions | undefined): Promise<BulkImportFileResponse & BulkImportFileResponseNonNullableFields>;
|
|
3149
|
+
}
|
|
3150
|
+
declare function listFiles$1(httpClient: HttpClient): ListFilesSignature;
|
|
3151
|
+
interface ListFilesSignature {
|
|
3152
|
+
/**
|
|
3153
|
+
* Retrieves a list of files in the Media Manager.
|
|
3154
|
+
*
|
|
3155
|
+
* The `listFiles()` function returns a Promise that resolves to an array of the specified files' descriptors and cursor information.
|
|
3156
|
+
*
|
|
3157
|
+
* To retrieve a list of files within a specific folder in the Media Manager, pass the folder's ID in the `parentFolderId` parameter. If no folder is specified, the function retrieves only the files in the root folder of the Media Manager.
|
|
3158
|
+
*
|
|
3159
|
+
* To retrieve a list of (non-permanently) deleted files, use the `listDeletedFiles()` function.
|
|
3160
|
+
* @param - Options to use when listing media files.
|
|
3161
|
+
*/
|
|
3162
|
+
(options?: ListFilesOptions | undefined): Promise<ListFilesResponse & ListFilesResponseNonNullableFields>;
|
|
3163
|
+
}
|
|
3164
|
+
declare function searchFiles$1(httpClient: HttpClient): SearchFilesSignature;
|
|
3165
|
+
interface SearchFilesSignature {
|
|
3166
|
+
/**
|
|
3167
|
+
* Searches all folders in the Media Manager and returns a list of files that match the terms specified in the optional parameters.
|
|
3168
|
+
*
|
|
3169
|
+
* The `searchFiles()` function returns a Promise that resolves to an array of the specified files' descriptors and cursor information.
|
|
3170
|
+
*
|
|
3171
|
+
* If no parameters are specified, the function returns all files in the `MEDIA_ROOT` folder.
|
|
3172
|
+
* @param - Options to specify which folders to search.
|
|
3173
|
+
*/
|
|
3174
|
+
(options?: SearchFilesOptions | undefined): Promise<SearchFilesResponse & SearchFilesResponseNonNullableFields>;
|
|
3175
|
+
}
|
|
3176
|
+
declare function generateVideoStreamingUrl$1(httpClient: HttpClient): GenerateVideoStreamingUrlSignature;
|
|
3177
|
+
interface GenerateVideoStreamingUrlSignature {
|
|
3178
|
+
/**
|
|
3179
|
+
* Generates a URL for streaming a specific video file in the Media Manager.
|
|
3180
|
+
*
|
|
3181
|
+
*
|
|
3182
|
+
* The `generateVideoStreamingUrl()` function returns a Promise that resolves to a download URL and its asset key.
|
|
3183
|
+
*
|
|
3184
|
+
* To stream different assets of the file, use the `assetKeys` parameter which generates a video streaming URL for each asset. If no asset key is specified, it defaults to `src`, which generates one video streaming URL in the original file's format and quality.
|
|
3185
|
+
* @param - Options to use when generating a video file's streaming URL.
|
|
3186
|
+
* @param - File ID.
|
|
3187
|
+
*
|
|
3188
|
+
* You can also pass the files' Wix media URLs. For example, `["wix:image://v1/0abec0_b291a9349a0b4da59067f76287e386fb~mv2.jpg/leon.jpg#originWidth=3024&originHeight=4032"]`.
|
|
3189
|
+
* Learn more in the File and Folder IDs article.
|
|
3190
|
+
*/
|
|
3191
|
+
(fileId: string, options?: GenerateVideoStreamingUrlOptions | undefined): Promise<GenerateVideoStreamingUrlResponse & GenerateVideoStreamingUrlResponseNonNullableFields>;
|
|
3192
|
+
}
|
|
3193
|
+
declare function bulkDeleteFiles$1(httpClient: HttpClient): BulkDeleteFilesSignature;
|
|
3194
|
+
interface BulkDeleteFilesSignature {
|
|
3195
|
+
/**
|
|
3196
|
+
* Deletes the specified files from the Media Manager.
|
|
3197
|
+
*
|
|
3198
|
+
*
|
|
3199
|
+
* The `bulkDeleteFiles()` function returns a Promise that resolves when the files are deleted.
|
|
3200
|
+
*
|
|
3201
|
+
* The deleted files are moved to the Media Manager's trash bin (`TRASH_ROOT` folder) unless permanently deleted. To permanently delete files, pass the `permanent` parameter with the value `true`. Permanently deleting files isn't reversible, so make sure that these files aren't being used in a site or in any other way as the files will no longer be accessible.
|
|
3202
|
+
*
|
|
3203
|
+
* >**Notes:**
|
|
3204
|
+
* > - The specified files can be from different folders.
|
|
3205
|
+
* > - Moving multiple files at once is an asynchronous action, and may take time for the changes to appear in the Media Manager.
|
|
3206
|
+
* > - Attempting to delete files that are already in the trash bin doesn't result in an error.
|
|
3207
|
+
* > - If your site contains deleted media files, the deleted media files still appear on your site as the files are still in the Media Manager (in the trash bin).
|
|
3208
|
+
* > - You can use `bulkRestoreFilesFromTrashBin()` to restore files from the Media Manager's trash bin.
|
|
3209
|
+
* @param - Options to use when deleting files.
|
|
3210
|
+
* @param - IDs of the files to move to the Media Manager's trash bin.
|
|
3211
|
+
*
|
|
3212
|
+
* You can also pass the files' Wix media URLs. For example, `["wix:image://v1/0abec0_b291a9349a0b4da59067f76287e386fb~mv2.jpg/leon.jpg#originWidth=3024&originHeight=4032"]`.
|
|
3213
|
+
* Learn more in the File and Folder IDs article.
|
|
3214
|
+
*/
|
|
3215
|
+
(fileIds: string[], options?: BulkDeleteFilesOptions | undefined): Promise<void>;
|
|
3216
|
+
}
|
|
3217
|
+
declare function bulkRestoreFilesFromTrashBin$1(httpClient: HttpClient): BulkRestoreFilesFromTrashBinSignature;
|
|
3218
|
+
interface BulkRestoreFilesFromTrashBinSignature {
|
|
3219
|
+
/**
|
|
3220
|
+
* Restores the specified files from the Media Manager's trash bin, and moves them to their original locations in the Media Manager.
|
|
3221
|
+
*
|
|
3222
|
+
* The `bulkRestoreFilesFromTrashBin()` function returns a Promise that resolves when the files have been restored.
|
|
3223
|
+
* @param - IDs of the files to restore from the Media Manager's trash bin.
|
|
3224
|
+
*
|
|
3225
|
+
* You can also pass the files' Wix media URLs. For example, `["wix:image://v1/0abec0_b291a9349a0b4da59067f76287e386fb~mv2.jpg/leon.jpg#originWidth=3024&originHeight=4032"]`.
|
|
3226
|
+
* Learn more in the File and Folder IDs article.
|
|
3227
|
+
*/
|
|
3228
|
+
(fileIds: string[]): Promise<void>;
|
|
3229
|
+
}
|
|
3230
|
+
declare function listDeletedFiles$1(httpClient: HttpClient): ListDeletedFilesSignature;
|
|
3231
|
+
interface ListDeletedFilesSignature {
|
|
3232
|
+
/**
|
|
3233
|
+
* Retrieves a list of files in the Media Manager's trash bin.
|
|
3234
|
+
*
|
|
3235
|
+
* The `listDeletedFiles()` function returns a Promise that resolves to an array of the specified deleted files' descriptors and cursor information.
|
|
3236
|
+
*
|
|
3237
|
+
* >**Note:** The Media Manager's trash bin (`TRASH_ROOT` folder) only contains temporarily deleted files, not permanently deleted files.
|
|
3238
|
+
*
|
|
3239
|
+
* To retrieve a list of non-deleted files, use the `listFiles()` function.
|
|
3240
|
+
* @param - Options to use when listing deleted files from the trash bin.
|
|
3241
|
+
*/
|
|
3242
|
+
(options?: ListDeletedFilesOptions | undefined): Promise<ListDeletedFilesResponse & ListDeletedFilesResponseNonNullableFields>;
|
|
3243
|
+
}
|
|
2918
3244
|
declare const onFileDescriptorUpdated$1: EventDefinition<FileDescriptorUpdatedEnvelope, "wix.media.site_media.v1.file_descriptor_updated">;
|
|
2919
3245
|
declare const onFileDescriptorDeleted$1: EventDefinition<FileDescriptorDeletedEnvelope, "wix.media.site_media.v1.file_descriptor_deleted">;
|
|
2920
3246
|
declare const onFileDescriptorFileReady$1: EventDefinition<FileDescriptorFileReadyEnvelope, "wix.media.site_media.v1.file_descriptor_file_ready">;
|
|
@@ -2958,15 +3284,19 @@ type _publicListDeletedFilesType = typeof listDeletedFiles$1;
|
|
|
2958
3284
|
declare const listDeletedFiles: ReturnType<typeof createRESTModule$1<_publicListDeletedFilesType>>;
|
|
2959
3285
|
|
|
2960
3286
|
type _publicOnFileDescriptorUpdatedType = typeof onFileDescriptorUpdated$1;
|
|
3287
|
+
/** */
|
|
2961
3288
|
declare const onFileDescriptorUpdated: ReturnType<typeof createEventModule$1<_publicOnFileDescriptorUpdatedType>>;
|
|
2962
3289
|
|
|
2963
3290
|
type _publicOnFileDescriptorDeletedType = typeof onFileDescriptorDeleted$1;
|
|
3291
|
+
/** */
|
|
2964
3292
|
declare const onFileDescriptorDeleted: ReturnType<typeof createEventModule$1<_publicOnFileDescriptorDeletedType>>;
|
|
2965
3293
|
|
|
2966
3294
|
type _publicOnFileDescriptorFileReadyType = typeof onFileDescriptorFileReady$1;
|
|
3295
|
+
/** */
|
|
2967
3296
|
declare const onFileDescriptorFileReady: ReturnType<typeof createEventModule$1<_publicOnFileDescriptorFileReadyType>>;
|
|
2968
3297
|
|
|
2969
3298
|
type _publicOnFileDescriptorFileFailedType = typeof onFileDescriptorFileFailed$1;
|
|
3299
|
+
/** */
|
|
2970
3300
|
declare const onFileDescriptorFileFailed: ReturnType<typeof createEventModule$1<_publicOnFileDescriptorFileFailedType>>;
|
|
2971
3301
|
|
|
2972
3302
|
type context$1_ApplicationError = ApplicationError;
|
|
@@ -3060,7 +3390,6 @@ type context$1_SearchFilesResponse = SearchFilesResponse;
|
|
|
3060
3390
|
type context$1_SearchFilesResponseNonNullableFields = SearchFilesResponseNonNullableFields;
|
|
3061
3391
|
type context$1_StreamFormat = StreamFormat;
|
|
3062
3392
|
declare const context$1_StreamFormat: typeof StreamFormat;
|
|
3063
|
-
type context$1_UpdateFileDescriptorOptions = UpdateFileDescriptorOptions;
|
|
3064
3393
|
type context$1_UpdateFileDescriptorRequest = UpdateFileDescriptorRequest;
|
|
3065
3394
|
type context$1_UpdateFileDescriptorResponse = UpdateFileDescriptorResponse;
|
|
3066
3395
|
type context$1_UpdateFileDescriptorResponseNonNullableFields = UpdateFileDescriptorResponseNonNullableFields;
|
|
@@ -3110,7 +3439,7 @@ declare const context$1_onFileDescriptorUpdated: typeof onFileDescriptorUpdated;
|
|
|
3110
3439
|
declare const context$1_searchFiles: typeof searchFiles;
|
|
3111
3440
|
declare const context$1_updateFileDescriptor: typeof updateFileDescriptor;
|
|
3112
3441
|
declare namespace context$1 {
|
|
3113
|
-
export { type ActionEvent$1 as ActionEvent, type context$1_ApplicationError as ApplicationError, type context$1_Archive as Archive, type context$1_AudioV2 as AudioV2, type BaseEventMetadata$1 as BaseEventMetadata, type context$1_BulkActionMetadata as BulkActionMetadata, type context$1_BulkDeleteFilesOptions as BulkDeleteFilesOptions, type context$1_BulkDeleteFilesRequest as BulkDeleteFilesRequest, type context$1_BulkDeleteFilesResponse as BulkDeleteFilesResponse, type context$1_BulkImportFileOptions as BulkImportFileOptions, type context$1_BulkImportFileRequest as BulkImportFileRequest, type context$1_BulkImportFileResponse as BulkImportFileResponse, type context$1_BulkImportFileResponseNonNullableFields as BulkImportFileResponseNonNullableFields, type context$1_BulkImportFileResult as BulkImportFileResult, type context$1_BulkImportFilesRequest as BulkImportFilesRequest, type context$1_BulkImportFilesResponse as BulkImportFilesResponse, type context$1_BulkImportFilesResponseNonNullableFields as BulkImportFilesResponseNonNullableFields, type context$1_BulkRestoreFilesFromTrashBinRequest as BulkRestoreFilesFromTrashBinRequest, type context$1_BulkRestoreFilesFromTrashBinResponse as BulkRestoreFilesFromTrashBinResponse, type context$1_Color as Color, type context$1_ColorRGB as ColorRGB, type context$1_Colors as Colors, context$1_ContentDisposition as ContentDisposition, type CursorPaging$1 as CursorPaging, type Cursors$1 as Cursors, type DomainEvent$1 as DomainEvent, type DomainEventBodyOneOf$1 as DomainEventBodyOneOf, type context$1_DownloadUrl as DownloadUrl, type EntityCreatedEvent$1 as EntityCreatedEvent, type EntityDeletedEvent$1 as EntityDeletedEvent, type EntityUpdatedEvent$1 as EntityUpdatedEvent, type EventMetadata$1 as EventMetadata, type context$1_ExternalInfo as ExternalInfo, type context$1_FaceRecognition as FaceRecognition, type context$1_FileDescriptor as FileDescriptor, type context$1_FileDescriptorDeletedEnvelope as FileDescriptorDeletedEnvelope, type context$1_FileDescriptorFileFailedEnvelope as FileDescriptorFileFailedEnvelope, type context$1_FileDescriptorFileReadyEnvelope as FileDescriptorFileReadyEnvelope, type context$1_FileDescriptorNonNullableFields as FileDescriptorNonNullableFields, type context$1_FileDescriptorUpdatedEnvelope as FileDescriptorUpdatedEnvelope, type context$1_FileFailed as FileFailed, type context$1_FileMedia as FileMedia, type context$1_FileMediaMediaOneOf as FileMediaMediaOneOf, type context$1_FileReady as FileReady, type context$1_GenerateFileDownloadUrlOptions as GenerateFileDownloadUrlOptions, type context$1_GenerateFileDownloadUrlRequest as GenerateFileDownloadUrlRequest, type context$1_GenerateFileDownloadUrlResponse as GenerateFileDownloadUrlResponse, type context$1_GenerateFileDownloadUrlResponseNonNullableFields as GenerateFileDownloadUrlResponseNonNullableFields, type context$1_GenerateFileResumableUploadUrlOptions as GenerateFileResumableUploadUrlOptions, type context$1_GenerateFileResumableUploadUrlRequest as GenerateFileResumableUploadUrlRequest, type context$1_GenerateFileResumableUploadUrlResponse as GenerateFileResumableUploadUrlResponse, type context$1_GenerateFileResumableUploadUrlResponseNonNullableFields as GenerateFileResumableUploadUrlResponseNonNullableFields, type context$1_GenerateFileUploadUrlOptions as GenerateFileUploadUrlOptions, type context$1_GenerateFileUploadUrlRequest as GenerateFileUploadUrlRequest, type context$1_GenerateFileUploadUrlResponse as GenerateFileUploadUrlResponse, type context$1_GenerateFileUploadUrlResponseNonNullableFields as GenerateFileUploadUrlResponseNonNullableFields, type context$1_GenerateFilesDownloadUrlRequest as GenerateFilesDownloadUrlRequest, type context$1_GenerateFilesDownloadUrlResponse as GenerateFilesDownloadUrlResponse, type context$1_GenerateFilesDownloadUrlResponseNonNullableFields as GenerateFilesDownloadUrlResponseNonNullableFields, type context$1_GenerateVideoStreamingUrlOptions as GenerateVideoStreamingUrlOptions, type context$1_GenerateVideoStreamingUrlRequest as GenerateVideoStreamingUrlRequest, type context$1_GenerateVideoStreamingUrlResponse as GenerateVideoStreamingUrlResponse, type context$1_GenerateVideoStreamingUrlResponseNonNullableFields as GenerateVideoStreamingUrlResponseNonNullableFields, type context$1_GenerateWebSocketTokenRequest as GenerateWebSocketTokenRequest, type context$1_GenerateWebSocketTokenResponse as GenerateWebSocketTokenResponse, type context$1_GetFileDescriptorRequest as GetFileDescriptorRequest, type context$1_GetFileDescriptorResponse as GetFileDescriptorResponse, type context$1_GetFileDescriptorResponseNonNullableFields as GetFileDescriptorResponseNonNullableFields, type context$1_GetFileDescriptorsRequest as GetFileDescriptorsRequest, type context$1_GetFileDescriptorsResponse as GetFileDescriptorsResponse, type context$1_GetFileDescriptorsResponseNonNullableFields as GetFileDescriptorsResponseNonNullableFields, type IdentificationData$1 as IdentificationData, type IdentificationDataIdOneOf$1 as IdentificationDataIdOneOf, type context$1_IdentityInfo as IdentityInfo, context$1_IdentityType as IdentityType, type context$1_ImageMedia as ImageMedia, type context$1_ImportFileOptions as ImportFileOptions, type context$1_ImportFileRequest as ImportFileRequest, type context$1_ImportFileResponse as ImportFileResponse, type context$1_ImportFileResponseNonNullableFields as ImportFileResponseNonNullableFields, type context$1_ItemMetadata as ItemMetadata, type context$1_ListDeletedFilesOptions as ListDeletedFilesOptions, type context$1_ListDeletedFilesRequest as ListDeletedFilesRequest, type context$1_ListDeletedFilesResponse as ListDeletedFilesResponse, type context$1_ListDeletedFilesResponseNonNullableFields as ListDeletedFilesResponseNonNullableFields, type context$1_ListFilesOptions as ListFilesOptions, type context$1_ListFilesRequest as ListFilesRequest, type context$1_ListFilesResponse as ListFilesResponse, type context$1_ListFilesResponseNonNullableFields as ListFilesResponseNonNullableFields, context$1_MediaType as MediaType, type MessageEnvelope$1 as MessageEnvelope, type context$1_Model3D as Model3D, Namespace$1 as Namespace, context$1_OperationStatus as OperationStatus, type context$1_OtherMedia as OtherMedia, type PagingMetadataV2$1 as PagingMetadataV2, type RestoreInfo$1 as RestoreInfo, RootFolder$1 as RootFolder, type context$1_SearchFilesOptions as SearchFilesOptions, type context$1_SearchFilesRequest as SearchFilesRequest, type context$1_SearchFilesResponse as SearchFilesResponse, type context$1_SearchFilesResponseNonNullableFields as SearchFilesResponseNonNullableFields, SortOrder$1 as SortOrder, type Sorting$1 as Sorting, State$1 as State, context$1_StreamFormat as StreamFormat, type context$1_UpdateFileDescriptorOptions as UpdateFileDescriptorOptions, type context$1_UpdateFileDescriptorRequest as UpdateFileDescriptorRequest, type context$1_UpdateFileDescriptorResponse as UpdateFileDescriptorResponse, type context$1_UpdateFileDescriptorResponseNonNullableFields as UpdateFileDescriptorResponseNonNullableFields, type context$1_UpdateFileRequest as UpdateFileRequest, type context$1_UpdateFileResponse as UpdateFileResponse, context$1_UploadProtocol as UploadProtocol, type context$1_VideoResolution as VideoResolution, WebhookIdentityType$1 as WebhookIdentityType, type context$1__publicBulkDeleteFilesType as _publicBulkDeleteFilesType, type context$1__publicBulkImportFileType as _publicBulkImportFileType, type context$1__publicBulkImportFilesType as _publicBulkImportFilesType, type context$1__publicBulkRestoreFilesFromTrashBinType as _publicBulkRestoreFilesFromTrashBinType, type context$1__publicGenerateFileDownloadUrlType as _publicGenerateFileDownloadUrlType, type context$1__publicGenerateFileResumableUploadUrlType as _publicGenerateFileResumableUploadUrlType, type context$1__publicGenerateFileUploadUrlType as _publicGenerateFileUploadUrlType, type context$1__publicGenerateFilesDownloadUrlType as _publicGenerateFilesDownloadUrlType, type context$1__publicGenerateVideoStreamingUrlType as _publicGenerateVideoStreamingUrlType, type context$1__publicGetFileDescriptorType as _publicGetFileDescriptorType, type context$1__publicGetFileDescriptorsType as _publicGetFileDescriptorsType, type context$1__publicImportFileType as _publicImportFileType, type context$1__publicListDeletedFilesType as _publicListDeletedFilesType, type context$1__publicListFilesType as _publicListFilesType, type context$1__publicOnFileDescriptorDeletedType as _publicOnFileDescriptorDeletedType, type context$1__publicOnFileDescriptorFileFailedType as _publicOnFileDescriptorFileFailedType, type context$1__publicOnFileDescriptorFileReadyType as _publicOnFileDescriptorFileReadyType, type context$1__publicOnFileDescriptorUpdatedType as _publicOnFileDescriptorUpdatedType, type context$1__publicSearchFilesType as _publicSearchFilesType, type context$1__publicUpdateFileDescriptorType as _publicUpdateFileDescriptorType, context$1_bulkDeleteFiles as bulkDeleteFiles, context$1_bulkImportFile as bulkImportFile, context$1_bulkImportFiles as bulkImportFiles, context$1_bulkRestoreFilesFromTrashBin as bulkRestoreFilesFromTrashBin, context$1_generateFileDownloadUrl as generateFileDownloadUrl, context$1_generateFileResumableUploadUrl as generateFileResumableUploadUrl, context$1_generateFileUploadUrl as generateFileUploadUrl, context$1_generateFilesDownloadUrl as generateFilesDownloadUrl, context$1_generateVideoStreamingUrl as generateVideoStreamingUrl, context$1_getFileDescriptor as getFileDescriptor, context$1_getFileDescriptors as getFileDescriptors, context$1_importFile as importFile, context$1_listDeletedFiles as listDeletedFiles, context$1_listFiles as listFiles, context$1_onFileDescriptorDeleted as onFileDescriptorDeleted, context$1_onFileDescriptorFileFailed as onFileDescriptorFileFailed, context$1_onFileDescriptorFileReady as onFileDescriptorFileReady, context$1_onFileDescriptorUpdated as onFileDescriptorUpdated, onFileDescriptorDeleted$1 as publicOnFileDescriptorDeleted, onFileDescriptorFileFailed$1 as publicOnFileDescriptorFileFailed, onFileDescriptorFileReady$1 as publicOnFileDescriptorFileReady, onFileDescriptorUpdated$1 as publicOnFileDescriptorUpdated, context$1_searchFiles as searchFiles, context$1_updateFileDescriptor as updateFileDescriptor };
|
|
3442
|
+
export { type ActionEvent$1 as ActionEvent, type context$1_ApplicationError as ApplicationError, type context$1_Archive as Archive, type context$1_AudioV2 as AudioV2, type BaseEventMetadata$1 as BaseEventMetadata, type context$1_BulkActionMetadata as BulkActionMetadata, type context$1_BulkDeleteFilesOptions as BulkDeleteFilesOptions, type context$1_BulkDeleteFilesRequest as BulkDeleteFilesRequest, type context$1_BulkDeleteFilesResponse as BulkDeleteFilesResponse, type context$1_BulkImportFileOptions as BulkImportFileOptions, type context$1_BulkImportFileRequest as BulkImportFileRequest, type context$1_BulkImportFileResponse as BulkImportFileResponse, type context$1_BulkImportFileResponseNonNullableFields as BulkImportFileResponseNonNullableFields, type context$1_BulkImportFileResult as BulkImportFileResult, type context$1_BulkImportFilesRequest as BulkImportFilesRequest, type context$1_BulkImportFilesResponse as BulkImportFilesResponse, type context$1_BulkImportFilesResponseNonNullableFields as BulkImportFilesResponseNonNullableFields, type context$1_BulkRestoreFilesFromTrashBinRequest as BulkRestoreFilesFromTrashBinRequest, type context$1_BulkRestoreFilesFromTrashBinResponse as BulkRestoreFilesFromTrashBinResponse, type context$1_Color as Color, type context$1_ColorRGB as ColorRGB, type context$1_Colors as Colors, context$1_ContentDisposition as ContentDisposition, type CursorPaging$1 as CursorPaging, type Cursors$1 as Cursors, type DomainEvent$1 as DomainEvent, type DomainEventBodyOneOf$1 as DomainEventBodyOneOf, type context$1_DownloadUrl as DownloadUrl, type EntityCreatedEvent$1 as EntityCreatedEvent, type EntityDeletedEvent$1 as EntityDeletedEvent, type EntityUpdatedEvent$1 as EntityUpdatedEvent, type EventMetadata$1 as EventMetadata, type context$1_ExternalInfo as ExternalInfo, type context$1_FaceRecognition as FaceRecognition, type context$1_FileDescriptor as FileDescriptor, type context$1_FileDescriptorDeletedEnvelope as FileDescriptorDeletedEnvelope, type context$1_FileDescriptorFileFailedEnvelope as FileDescriptorFileFailedEnvelope, type context$1_FileDescriptorFileReadyEnvelope as FileDescriptorFileReadyEnvelope, type context$1_FileDescriptorNonNullableFields as FileDescriptorNonNullableFields, type context$1_FileDescriptorUpdatedEnvelope as FileDescriptorUpdatedEnvelope, type context$1_FileFailed as FileFailed, type context$1_FileMedia as FileMedia, type context$1_FileMediaMediaOneOf as FileMediaMediaOneOf, type context$1_FileReady as FileReady, type context$1_GenerateFileDownloadUrlOptions as GenerateFileDownloadUrlOptions, type context$1_GenerateFileDownloadUrlRequest as GenerateFileDownloadUrlRequest, type context$1_GenerateFileDownloadUrlResponse as GenerateFileDownloadUrlResponse, type context$1_GenerateFileDownloadUrlResponseNonNullableFields as GenerateFileDownloadUrlResponseNonNullableFields, type context$1_GenerateFileResumableUploadUrlOptions as GenerateFileResumableUploadUrlOptions, type context$1_GenerateFileResumableUploadUrlRequest as GenerateFileResumableUploadUrlRequest, type context$1_GenerateFileResumableUploadUrlResponse as GenerateFileResumableUploadUrlResponse, type context$1_GenerateFileResumableUploadUrlResponseNonNullableFields as GenerateFileResumableUploadUrlResponseNonNullableFields, type context$1_GenerateFileUploadUrlOptions as GenerateFileUploadUrlOptions, type context$1_GenerateFileUploadUrlRequest as GenerateFileUploadUrlRequest, type context$1_GenerateFileUploadUrlResponse as GenerateFileUploadUrlResponse, type context$1_GenerateFileUploadUrlResponseNonNullableFields as GenerateFileUploadUrlResponseNonNullableFields, type context$1_GenerateFilesDownloadUrlRequest as GenerateFilesDownloadUrlRequest, type context$1_GenerateFilesDownloadUrlResponse as GenerateFilesDownloadUrlResponse, type context$1_GenerateFilesDownloadUrlResponseNonNullableFields as GenerateFilesDownloadUrlResponseNonNullableFields, type context$1_GenerateVideoStreamingUrlOptions as GenerateVideoStreamingUrlOptions, type context$1_GenerateVideoStreamingUrlRequest as GenerateVideoStreamingUrlRequest, type context$1_GenerateVideoStreamingUrlResponse as GenerateVideoStreamingUrlResponse, type context$1_GenerateVideoStreamingUrlResponseNonNullableFields as GenerateVideoStreamingUrlResponseNonNullableFields, type context$1_GenerateWebSocketTokenRequest as GenerateWebSocketTokenRequest, type context$1_GenerateWebSocketTokenResponse as GenerateWebSocketTokenResponse, type context$1_GetFileDescriptorRequest as GetFileDescriptorRequest, type context$1_GetFileDescriptorResponse as GetFileDescriptorResponse, type context$1_GetFileDescriptorResponseNonNullableFields as GetFileDescriptorResponseNonNullableFields, type context$1_GetFileDescriptorsRequest as GetFileDescriptorsRequest, type context$1_GetFileDescriptorsResponse as GetFileDescriptorsResponse, type context$1_GetFileDescriptorsResponseNonNullableFields as GetFileDescriptorsResponseNonNullableFields, type IdentificationData$1 as IdentificationData, type IdentificationDataIdOneOf$1 as IdentificationDataIdOneOf, type context$1_IdentityInfo as IdentityInfo, context$1_IdentityType as IdentityType, type context$1_ImageMedia as ImageMedia, type context$1_ImportFileOptions as ImportFileOptions, type context$1_ImportFileRequest as ImportFileRequest, type context$1_ImportFileResponse as ImportFileResponse, type context$1_ImportFileResponseNonNullableFields as ImportFileResponseNonNullableFields, type context$1_ItemMetadata as ItemMetadata, type context$1_ListDeletedFilesOptions as ListDeletedFilesOptions, type context$1_ListDeletedFilesRequest as ListDeletedFilesRequest, type context$1_ListDeletedFilesResponse as ListDeletedFilesResponse, type context$1_ListDeletedFilesResponseNonNullableFields as ListDeletedFilesResponseNonNullableFields, type context$1_ListFilesOptions as ListFilesOptions, type context$1_ListFilesRequest as ListFilesRequest, type context$1_ListFilesResponse as ListFilesResponse, type context$1_ListFilesResponseNonNullableFields as ListFilesResponseNonNullableFields, context$1_MediaType as MediaType, type MessageEnvelope$1 as MessageEnvelope, type context$1_Model3D as Model3D, Namespace$1 as Namespace, context$1_OperationStatus as OperationStatus, type context$1_OtherMedia as OtherMedia, type PagingMetadataV2$1 as PagingMetadataV2, type RestoreInfo$1 as RestoreInfo, RootFolder$1 as RootFolder, type context$1_SearchFilesOptions as SearchFilesOptions, type context$1_SearchFilesRequest as SearchFilesRequest, type context$1_SearchFilesResponse as SearchFilesResponse, type context$1_SearchFilesResponseNonNullableFields as SearchFilesResponseNonNullableFields, SortOrder$1 as SortOrder, type Sorting$1 as Sorting, State$1 as State, context$1_StreamFormat as StreamFormat, type context$1_UpdateFileDescriptorRequest as UpdateFileDescriptorRequest, type context$1_UpdateFileDescriptorResponse as UpdateFileDescriptorResponse, type context$1_UpdateFileDescriptorResponseNonNullableFields as UpdateFileDescriptorResponseNonNullableFields, type context$1_UpdateFileRequest as UpdateFileRequest, type context$1_UpdateFileResponse as UpdateFileResponse, context$1_UploadProtocol as UploadProtocol, type context$1_VideoResolution as VideoResolution, WebhookIdentityType$1 as WebhookIdentityType, type context$1__publicBulkDeleteFilesType as _publicBulkDeleteFilesType, type context$1__publicBulkImportFileType as _publicBulkImportFileType, type context$1__publicBulkImportFilesType as _publicBulkImportFilesType, type context$1__publicBulkRestoreFilesFromTrashBinType as _publicBulkRestoreFilesFromTrashBinType, type context$1__publicGenerateFileDownloadUrlType as _publicGenerateFileDownloadUrlType, type context$1__publicGenerateFileResumableUploadUrlType as _publicGenerateFileResumableUploadUrlType, type context$1__publicGenerateFileUploadUrlType as _publicGenerateFileUploadUrlType, type context$1__publicGenerateFilesDownloadUrlType as _publicGenerateFilesDownloadUrlType, type context$1__publicGenerateVideoStreamingUrlType as _publicGenerateVideoStreamingUrlType, type context$1__publicGetFileDescriptorType as _publicGetFileDescriptorType, type context$1__publicGetFileDescriptorsType as _publicGetFileDescriptorsType, type context$1__publicImportFileType as _publicImportFileType, type context$1__publicListDeletedFilesType as _publicListDeletedFilesType, type context$1__publicListFilesType as _publicListFilesType, type context$1__publicOnFileDescriptorDeletedType as _publicOnFileDescriptorDeletedType, type context$1__publicOnFileDescriptorFileFailedType as _publicOnFileDescriptorFileFailedType, type context$1__publicOnFileDescriptorFileReadyType as _publicOnFileDescriptorFileReadyType, type context$1__publicOnFileDescriptorUpdatedType as _publicOnFileDescriptorUpdatedType, type context$1__publicSearchFilesType as _publicSearchFilesType, type context$1__publicUpdateFileDescriptorType as _publicUpdateFileDescriptorType, context$1_bulkDeleteFiles as bulkDeleteFiles, context$1_bulkImportFile as bulkImportFile, context$1_bulkImportFiles as bulkImportFiles, context$1_bulkRestoreFilesFromTrashBin as bulkRestoreFilesFromTrashBin, context$1_generateFileDownloadUrl as generateFileDownloadUrl, context$1_generateFileResumableUploadUrl as generateFileResumableUploadUrl, context$1_generateFileUploadUrl as generateFileUploadUrl, context$1_generateFilesDownloadUrl as generateFilesDownloadUrl, context$1_generateVideoStreamingUrl as generateVideoStreamingUrl, context$1_getFileDescriptor as getFileDescriptor, context$1_getFileDescriptors as getFileDescriptors, context$1_importFile as importFile, context$1_listDeletedFiles as listDeletedFiles, context$1_listFiles as listFiles, context$1_onFileDescriptorDeleted as onFileDescriptorDeleted, context$1_onFileDescriptorFileFailed as onFileDescriptorFileFailed, context$1_onFileDescriptorFileReady as onFileDescriptorFileReady, context$1_onFileDescriptorUpdated as onFileDescriptorUpdated, onFileDescriptorDeleted$1 as publicOnFileDescriptorDeleted, onFileDescriptorFileFailed$1 as publicOnFileDescriptorFileFailed, onFileDescriptorFileReady$1 as publicOnFileDescriptorFileReady, onFileDescriptorUpdated$1 as publicOnFileDescriptorUpdated, context$1_searchFiles as searchFiles, context$1_updateFileDescriptor as updateFileDescriptor };
|
|
3114
3443
|
}
|
|
3115
3444
|
|
|
3116
3445
|
interface Folder {
|
|
@@ -3610,15 +3939,127 @@ interface ListDeletedFoldersOptions {
|
|
|
3610
3939
|
paging?: CursorPaging;
|
|
3611
3940
|
}
|
|
3612
3941
|
|
|
3613
|
-
declare function createFolder$1(httpClient: HttpClient):
|
|
3614
|
-
|
|
3615
|
-
|
|
3616
|
-
|
|
3617
|
-
|
|
3618
|
-
|
|
3619
|
-
|
|
3620
|
-
|
|
3621
|
-
|
|
3942
|
+
declare function createFolder$1(httpClient: HttpClient): CreateFolderSignature;
|
|
3943
|
+
interface CreateFolderSignature {
|
|
3944
|
+
/**
|
|
3945
|
+
* Creates a new folder in the Media Manager.
|
|
3946
|
+
*
|
|
3947
|
+
* The `createFolder()` function returns a Promise that resolves to the created folder.
|
|
3948
|
+
*
|
|
3949
|
+
* Use the `parentFolderId` parameter to specify in which existing folder you want the new folder to be created.
|
|
3950
|
+
* If no folder is specified, the new folder is created in the `media-root` folder.
|
|
3951
|
+
* @param - Folder name that appears in the Media Manager.
|
|
3952
|
+
* @param - Options for specifying where to create a folder.
|
|
3953
|
+
*/
|
|
3954
|
+
(displayName: string, options?: CreateFolderOptions | undefined): Promise<CreateFolderResponse & CreateFolderResponseNonNullableFields>;
|
|
3955
|
+
}
|
|
3956
|
+
declare function getFolder$1(httpClient: HttpClient): GetFolderSignature;
|
|
3957
|
+
interface GetFolderSignature {
|
|
3958
|
+
/**
|
|
3959
|
+
* Gets information from the specified folder in the Media Manager.
|
|
3960
|
+
*
|
|
3961
|
+
* The `getFolder()` function returns a Promise that resolves to information about the specified folder.
|
|
3962
|
+
* @param - Folder ID.
|
|
3963
|
+
* @returns Information about the folder.
|
|
3964
|
+
*/
|
|
3965
|
+
(folderId: string): Promise<Folder & FolderNonNullableFields>;
|
|
3966
|
+
}
|
|
3967
|
+
declare function listFolders$1(httpClient: HttpClient): ListFoldersSignature;
|
|
3968
|
+
interface ListFoldersSignature {
|
|
3969
|
+
/**
|
|
3970
|
+
* Retrieves a list of folders in the Media Manager.
|
|
3971
|
+
*
|
|
3972
|
+
* The `listFolders()` function returns a Promise that resolves to information about the specified folders and cursor information.
|
|
3973
|
+
*
|
|
3974
|
+
* To retrieve a list of folders within a specific folder in the Media Manager, pass the specific folder's ID in the `parentFolderId` parameter. If no folder is specified, the function retrieves only the list of folders within the root folder of the Media Manager.
|
|
3975
|
+
*
|
|
3976
|
+
* To retrieve a list of (non-permanently) deleted folders, use the `listDeletedFolders()` function.
|
|
3977
|
+
* @param - Options to use when listing folders from the Media Manager.
|
|
3978
|
+
*/
|
|
3979
|
+
(options?: ListFoldersOptions | undefined): Promise<ListFoldersResponse & ListFoldersResponseNonNullableFields>;
|
|
3980
|
+
}
|
|
3981
|
+
declare function searchFolders$1(httpClient: HttpClient): SearchFoldersSignature;
|
|
3982
|
+
interface SearchFoldersSignature {
|
|
3983
|
+
/**
|
|
3984
|
+
* Searches the Media Manager and returns a list of folders that match the terms specified in the parameters.
|
|
3985
|
+
*
|
|
3986
|
+
* The `searchFolders()` function returns a Promise that resolves to information about the specified folders and cursor information.
|
|
3987
|
+
*
|
|
3988
|
+
* If no parameters are specified, the function returns all folders in the `MEDIA_ROOT` folder.
|
|
3989
|
+
* @param - Options specifying which folders to search.
|
|
3990
|
+
*/
|
|
3991
|
+
(options?: SearchFoldersOptions | undefined): Promise<SearchFoldersResponse & SearchFoldersResponseNonNullableFields>;
|
|
3992
|
+
}
|
|
3993
|
+
declare function updateFolder$1(httpClient: HttpClient): UpdateFolderSignature;
|
|
3994
|
+
interface UpdateFolderSignature {
|
|
3995
|
+
/**
|
|
3996
|
+
* Updates a folder.
|
|
3997
|
+
*
|
|
3998
|
+
* The `updateFolder()` function returns a Promise that resolves to information about the updated folder.
|
|
3999
|
+
*
|
|
4000
|
+
* You can use the `parentFolderId` parameter to move a folder from its current parent folder to a different parent folder.
|
|
4001
|
+
* @param - Folder ID. Generated when a folder is created in the Media Manager.
|
|
4002
|
+
* @param - Folder to update.
|
|
4003
|
+
* @returns Information about the updated folder.
|
|
4004
|
+
*/
|
|
4005
|
+
(_id: string, folder: UpdateFolder): Promise<Folder & FolderNonNullableFields>;
|
|
4006
|
+
}
|
|
4007
|
+
declare function generateFolderDownloadUrl$1(httpClient: HttpClient): GenerateFolderDownloadUrlSignature;
|
|
4008
|
+
interface GenerateFolderDownloadUrlSignature {
|
|
4009
|
+
/**
|
|
4010
|
+
* Generates a URL for downloading a compressed file containing a specific folder in the Media Manager.
|
|
4011
|
+
*
|
|
4012
|
+
* The `generateFolderDownloadUrl()` function returns a Promise that resolves to a download URL.
|
|
4013
|
+
*
|
|
4014
|
+
* The compressed file can contain sub-folders, and up to 1000 files.
|
|
4015
|
+
* @param - Folder ID.
|
|
4016
|
+
*/
|
|
4017
|
+
(folderId: string): Promise<GenerateFolderDownloadUrlResponse & GenerateFolderDownloadUrlResponseNonNullableFields>;
|
|
4018
|
+
}
|
|
4019
|
+
declare function bulkDeleteFolders$1(httpClient: HttpClient): BulkDeleteFoldersSignature;
|
|
4020
|
+
interface BulkDeleteFoldersSignature {
|
|
4021
|
+
/**
|
|
4022
|
+
* Temporarily deletes the specified folders from the Media Manager.
|
|
4023
|
+
*
|
|
4024
|
+
* The `bulkDeleteFolders()` function returns a Promise that resolves when the folders are deleted.
|
|
4025
|
+
*
|
|
4026
|
+
* The deleted folders are moved to the Media Manager's `TRASH_ROOT` folder (trash bin) unless permanently deleted. To permanently delete folders, pass the `permanent` parameter with the value `true`. Permanently deleting folders isn't reversible, so make sure that the files in these folders aren't being used in a site or in any other way as the files will no longer be accessible.
|
|
4027
|
+
*
|
|
4028
|
+
* >**Notes:**
|
|
4029
|
+
* > - When a folder is deleted, the files in that folder are deleted.
|
|
4030
|
+
* > - The specified folders can be from different parent folders.
|
|
4031
|
+
* > - Moving multiple folders at once is an asynchronous action, and may take time for the changes to appear in the Media Manager.
|
|
4032
|
+
* > - Attempting to delete folders that are already in the trash bin doesn't result in an error.
|
|
4033
|
+
* > - If your site contains files from a non-permanently deleted media folder, the files still appear on your site as the deleted folder is still in the Media Manager (in the trash bin).
|
|
4034
|
+
* > - You can use the `bulkRestoreFoldersFromTrashBin()` function to restore folders from the Media Manager's trash bin.
|
|
4035
|
+
* @param - IDs of the folders to move to the Media Manager's trash bin.
|
|
4036
|
+
* @param - Options to use when deleting folders.
|
|
4037
|
+
*/
|
|
4038
|
+
(folderIds: string[], options?: BulkDeleteFoldersOptions | undefined): Promise<void>;
|
|
4039
|
+
}
|
|
4040
|
+
declare function bulkRestoreFoldersFromTrashBin$1(httpClient: HttpClient): BulkRestoreFoldersFromTrashBinSignature;
|
|
4041
|
+
interface BulkRestoreFoldersFromTrashBinSignature {
|
|
4042
|
+
/**
|
|
4043
|
+
* Restores the specified folders from the Media Manager's trash bin, and moves them to their original locations in the Media Manager.
|
|
4044
|
+
*
|
|
4045
|
+
*
|
|
4046
|
+
* The `bulkRestoreFoldersFromTrashBin()` function returns a Promise that resolves when the folders have been restored.
|
|
4047
|
+
* @param - IDs of the folders to restore from the Media Manager's trash bin.
|
|
4048
|
+
*/
|
|
4049
|
+
(folderIds: string[]): Promise<void>;
|
|
4050
|
+
}
|
|
4051
|
+
declare function listDeletedFolders$1(httpClient: HttpClient): ListDeletedFoldersSignature;
|
|
4052
|
+
interface ListDeletedFoldersSignature {
|
|
4053
|
+
/**
|
|
4054
|
+
* Retrieves a list of deleted folders from the trash bin.
|
|
4055
|
+
*
|
|
4056
|
+
* The `listDeletedFolders()` function returns a Promise that resolves to information about the specified deleted folders and cursor information.
|
|
4057
|
+
*
|
|
4058
|
+
* To retrieve a list of non-deleted folders, use the `listFolders()` function.
|
|
4059
|
+
* @param - Options to use when listing deleted folders from the trash bin.
|
|
4060
|
+
*/
|
|
4061
|
+
(options?: ListDeletedFoldersOptions | undefined): Promise<ListDeletedFoldersResponse & ListDeletedFoldersResponseNonNullableFields>;
|
|
4062
|
+
}
|
|
3622
4063
|
declare const onFolderCreated$1: EventDefinition<FolderCreatedEnvelope, "wix.media.site_media.v1.folder_created">;
|
|
3623
4064
|
declare const onFolderUpdated$1: EventDefinition<FolderUpdatedEnvelope, "wix.media.site_media.v1.folder_updated">;
|
|
3624
4065
|
declare const onFolderDeleted$1: EventDefinition<FolderDeletedEnvelope, "wix.media.site_media.v1.folder_deleted">;
|
|
@@ -3647,12 +4088,15 @@ type _publicListDeletedFoldersType = typeof listDeletedFolders$1;
|
|
|
3647
4088
|
declare const listDeletedFolders: ReturnType<typeof createRESTModule<_publicListDeletedFoldersType>>;
|
|
3648
4089
|
|
|
3649
4090
|
type _publicOnFolderCreatedType = typeof onFolderCreated$1;
|
|
4091
|
+
/** */
|
|
3650
4092
|
declare const onFolderCreated: ReturnType<typeof createEventModule<_publicOnFolderCreatedType>>;
|
|
3651
4093
|
|
|
3652
4094
|
type _publicOnFolderUpdatedType = typeof onFolderUpdated$1;
|
|
4095
|
+
/** */
|
|
3653
4096
|
declare const onFolderUpdated: ReturnType<typeof createEventModule<_publicOnFolderUpdatedType>>;
|
|
3654
4097
|
|
|
3655
4098
|
type _publicOnFolderDeletedType = typeof onFolderDeleted$1;
|
|
4099
|
+
/** */
|
|
3656
4100
|
declare const onFolderDeleted: ReturnType<typeof createEventModule<_publicOnFolderDeletedType>>;
|
|
3657
4101
|
|
|
3658
4102
|
type context_ActionEvent = ActionEvent;
|