All Products
Search
Document Center

Delete media files

Last Updated: Oct 18, 2021

ApsaraVideo VOD may generate multiple types of media files. ApsaraVideo VOD allows you to delete media files at different granularities. You can delete media files in the console, by calling API operations, or by using SDKs. This topic describes how to delete media files.

Features

  • Delete all audio or video files, including uploaded mezzanine files, transcoded stream files, thumbnail snapshots, and image sprites.

  • Delete audio or video streams. Those are transcoded stream files in a specified definition.

  • Delete audio or video mezzanine files that are uploaded.

  • Delete uploaded image files. After the image files are deleted, image URLs that use audio and video thumbnails, snapshots, and watermarks cannot be accessed.

Note
  • When you delete files from OSS, the files are deleted but the media asset information is retained. When you delete files stored in ApsaraVideo VOD, both files and the media asset information are deleted.

  • All delete operations cannot be recovered. We recommend that you use caution when you use delete operations.

  • By default, audio or video mezzanine files that are uploaded without transcoding cannot be deleted. This is because they are also used as stream files for original-quality playback. If you want to delete these files, set Force to true when you call the delete operation.

  • All delete operations are manually performed by users.

Delete media files in the console

On the Video and Audio page or the Image page in the ApsaraVideo VOD console, find the media file that you want to delete, and choose More > Delete in the Actions column. For more information, see Manage media assets.

Delete media files by calling API operations or by using SDKs

You can use the APIs or SDKs to delete all audio or video files, audio or video streams, audio or video mezzanine files, and image files.

The following table lists APIs that are used to delete media files.

File

Description

Reference

All audio or video files

Deletes all video files, including their mezzanine files, transcoded stream files, and thumbnail snapshots. You can delete multiple video files at a time.

DeleteVideo

Audio or video streams

Deletes media streams such as video or audio streams and their storage files. You can delete multiple media streams at a time.

DeleteStream

Mezzanine files

Deletes mezzanine files and their storage files.

DeleteMezzanines

Image files

Deletes uploaded images and automatic snapshots of videos.

DeleteImage

Call methods:

  • We recommend that you use a server SDK to obtain media asset information by calling API operations. This method is simpler and more efficient. For more information about server SDKs, see Usage notes. For more information about API operations, see the "SDK example" section of API references.

  • For more information about how to generate HTTP or HTTPS requests, see Common parameters and Call examples.