Product Overview
Feature Description
Product Strengths
Use Cases
Basic Concept
try{let result = await SMHRecycledApis.listRecycled({libraryId:"libraryId",spaceId:"spaceId"})}catch (e) {// Exception handling}
Request parameters. | Description | Type | Required or Not |
libraryId | Media Library ID, obtained after creating a media library in the media hosting console. See Create Media Library | String | Yes |
spaceId | Space ID. If the media library is in single-tenant mode, this parameter is fixed as hyphen (`-`). If the media library is in multi-tenant mode, you must specify this parameter. Please refer to Create Tenant Space | String | No |
marker | Identification used for sequential listing with pagination, cannot be used with both page and page_size parameters | String | No |
limit | Limited number of locally listed projects for sequential pagination, cannot be used with both page and page_size parameters | String | No |
page | pagination code, default first page, optional parameter, cannot be used with both marker and limit parameters | Number | No |
pageSize | page size, default 20, optional parameter, cannot be used with both marker and limit parameters | Number | No |
orderBy | Sorting field: name for sort by name, modificationTime for sort by modification time, size for sort by file size, removalTime for sort by removal time, remainingTime for sort by remaining time | SMHFileListOrderBy | No |
orderByType | Sorting method, asc for ascending, desc for descending | SMHOrderByType | No |
try{let result = await SMHRecycledApis.restoreRecycledObject({libraryId:"libraryId",spaceId:"spaceId",recycledItemId:312})}catch(e){// Exception handling}
Request parameters. | Description | Type | Required or Not |
libraryId | Media Library ID, obtained after creating a media library in the media hosting console. See Create Media Library | String | Yes |
spaceId | Space ID. If the media library is in single-tenant mode, this parameter is fixed as hyphen (`-`). If the media library is in multi-tenant mode, you must specify this parameter. Please refer to Create Tenant Space | String | No |
recycledItemId | Recycle Bin Project ID | Number | Yes |
conflictResolutionStrategy | Handling method when path conflict, default is ask ask: returns HTTP 409 Conflict and error code SameNameDirectoryOrFileExists when conflicts with rename: automatically renames the file when conflicts with overwrite: returns HTTP 409 Conflict and error code SameNameDirectoryOrFileExists when the target is a directory, otherwise overwrites the existing file | SMHConflictResolutionStrategy | No |
restorePathStrategy | Restoration project source path processing method, defaults to originalPath originalPath: restore to original path, error will be reported if original path does not exist fallbackToRoot: restore to original path, fall back to root directory if original path does not exist | SMHRestorePathStrategy | No |
try{let result = await SMHRecycledApis.batchRestoreRecycledObject({libraryId:"libraryId",spaceId:"spaceId",restorePathStrategy:SMHRestorePathStrategy.fallbackToRoot,recycledItemIds:[1,2,3,4]})}catch(e){// Exception handling}
Request parameters. | Description | Type | Required or Not |
libraryId | Media Library ID, obtained after creating a media library in the media hosting console. See Create Media Library | String | Yes |
spaceId | Space ID. If the media library is in single-tenant mode, this parameter is fixed as hyphen (`-`). If the media library is in multi-tenant mode, you must specify this parameter. Please refer to Create Tenant Space | String | No |
recycledItemIds | Batch recover the collection of recycledItemId | Array | Yes |
restorePathStrategy | Restoration project source path processing method, defaults to originalPath originalPath: restore to original path, error will be reported if original path does not exist fallbackToRoot: restore to original path, fall back to root directory if original path does not exist | SMHRestorePathStrategy | No |
try{let result = await SMHRecycledApis.deleteRecycledObject({libraryId:"libraryId",spaceId:"spaceId",recycledItemId:312})}catch(e){// Exception handling}
Request parameters. | Description | Type | Required or Not |
libraryId | Media Library ID, obtained after creating a media library in the media hosting console. See Create Media Library | String | Yes |
spaceId | Space ID. If the media library is in single-tenant mode, this parameter is fixed as hyphen (`-`). If the media library is in multi-tenant mode, you must specify this parameter. Please refer to Create Tenant Space | String | No |
recycledItemId | Recycle Bin Project ID | Number | Yes |
try{let result = await SMHRecycledApis.batchDeleteRecycledObject({libraryId:"libraryId",spaceId:"spaceId",recycledItemIds:[1,2,3,4]})}catch(e){// Exception handling}
Request parameters. | Description | Type | Required or Not |
libraryId | Media Library ID, obtained after creating a media library in the media hosting console. See Create Media Library | String | Yes |
spaceId | Space ID. If the media library is in single-tenant mode, this parameter is fixed as hyphen (`-`). If the media library is in multi-tenant mode, you must specify this parameter. Please refer to Create Tenant Space | String | No |
recycledItemIds | Batch delete the collection of recycledItemId | Array | Yes |
try{let result = await SMHRecycledApis.clearRecycled({libraryId:"libraryId",spaceId:"spaceId"})}catch(e){// Exception handling}
Request parameters. | Description | Type | Required or Not |
libraryId | Media Library ID, obtained after creating a media library in the media hosting console. See Create Media Library | String | Yes |
spaceId | Space ID. If the media library is in single-tenant mode, this parameter is fixed as hyphen (`-`). If the media library is in multi-tenant mode, you must specify this parameter. Please refer to Create Tenant Space | String | No |
try{let reuslt = await SMHRecycledApis.fileDetail({libraryId:"libraryId",spaceId:"spaceId",recycledItemId:312})}catch(e){// Exception handling}
Request parameters. | Description | Type | Required or Not |
libraryId | Media Library ID, obtained after creating a media library in the media hosting console. See Create Media Library | String | Yes |
spaceId | Space ID. If the media library is in single-tenant mode, this parameter is fixed as hyphen (`-`). If the media library is in multi-tenant mode, you must specify this parameter. Please refer to Create Tenant Space | String | No |
recycledItemId | Recycle Bin Project ID | Number | Yes |
try{let reuslt = await SMHRecycledApis.preview({libraryId:"libraryId",spaceId:"spaceId",recycledItemId:312})}catch(e){// Exception handling}
Request parameters. | Description | Type | Required or Not |
libraryId | Media Library ID, obtained after creating a media library in the media hosting console. See Create Media Library | String | Yes |
spaceId | Space ID. If the media library is in single-tenant mode, this parameter is fixed as hyphen (`-`). If the media library is in multi-tenant mode, you must specify this parameter. Please refer to Create Tenant Space | String | No |
recycledItemId | Recycle Bin Project ID | Number | Yes |
type | The preview method for document files: if set to "pic", preview the document homepage in JPG format; otherwise, preview it in HTML format. | SMHPreviewType | No |
size | Scaling of image or video cover size. For related notes, see API description. | String | No |
scale | Proportional scaling percentage for image or video cover. This parameter is valid only when Size is not specified. | String | No |
widthSize | Scaling width for image or video cover. The height is scaled proportionally when not specified. This parameter is valid only when neither Size nor Scale is provided. | String | No |
heightSize | Scaling height for image or video cover. The width is scaled proportionally when not specified. This parameter is valid only when neither Size nor Scale is provided. | String | No |
frameNumber | Number of frames in a GIF file, frame processing targeting GIFs. This parameter is valid only when previewing GIF files. | String | No |
フィードバック