All Products
Search
Document Center

ApsaraVideo VOD:Overview

Last Updated:Oct 11, 2024

Media assets must be registered with ApsaraVideo VOD before you can use the features provided by ApsaraVideo VOD to manage, process, deliver, and play these media assets. When you upload media assets to ApsaraVideo VOD, they are automatically registered with ApsaraVideo VOD. This topic describes the supported formats, upload methods, upload settings, and usage notes for media assets in ApsaraVideo VOD.

Supported media file formats

ApsaraVideo VOD allows you to upload various media files such as videos, audio files, images, and auxiliary media assets including watermark files, subtitle files, and material files. You can upload local files or online files. You can upload online files to ApsaraVideo VOD by using the URLs of these files. The following table describes the supported file formats.

Note

The file name extension must be included in the name of a media file to be uploaded to ApsaraVideo VOD. File name extensions are not case-sensitive. For example, both MP4 and mp4 are valid file name extensions.

Media type

Supported format

Video

  • MPEG formats: MP4, TS, 3GP, MPG, MPEG, MPE, DAT, VOB, and ASF.

  • AVI format: AVI.

  • Windows Media Video formats: WMV and ASF.

  • Flash Video formats: FLV and F4V.

  • Real Video formats: RM and RMVB.

  • QuickTime format: MOV.

  • Matroska format: MKV.

  • HTTP-Live-Streaming (HLS) format: M3U8.

    Note

    If you use the ApsaraVideo VOD console to upload M3U8 files, you can upload them only by using their URLs. You can use the ApsaraVideo VOD API or SDK to upload M3U8 files from your on-premises devices. For more information, see Upload media files by calling the ApsaraVideo VOD API.

  • Other formats: DV, GIF, M2T, M4V, MJ2, MJPEG, MTS, OGG, QT, SWF, and WEBM.

Audio

MP3, WMA, WAV, AAC, RA, M4A, FLAC, APE, AC3, AMR, CAF, and ACM.

Image

PNG, JPG, JPEG, GIF, and HEIC.

Auxiliary media asset

  • Watermark files: PNG, GIF, APNG, and MOV.

  • Subtitle files: SRT, ASS, STL, TTML, and VTT.

  • Material files: JPG, GIF, PNG, MP4, MAT, and ZIP.

Upload methods

You can upload media assets by using GUI tools and developer tools.

GUI tools

ApsaraVideo VOD provides two GUI tools: ApsaraVideo VOD console and PC client. GUI tools allow you to quickly upload files or upload large files and are suitable for general-use scenarios where no strong requirements on production are imposed. The following table describes two GUI tools.

Upload method

Scenario

Description

ApsaraVideo VOD console

The ApsaraVideo VOD console is a quick and convenient method to upload media files.

Note

However, the length of console sessions is controlled by security policies. When you upload large files that require a long time to complete, your console session may expire before the upload is complete. In this case, we recommended that you use a PC client tool to upload large files.

  • After you activate ApsaraVideo VOD, you can log on to the ApsaraVideo VOD console in a browser to upload media files.

  • You can upload audio and video files from your on-premises devices or by using the URLs of the files.

PC client

PC clients are suitable for uploading large files that take a long time to complete, or scenarios where you do not have strong requirements on production.

  • You must download and install a PC client. ApsaraVideo VOD provides the PC clients for the Windows operating system.

  • Only local files can be uploaded.

Developer tools

To meet the requirements of developers, ApsaraVideo VOD provides developer tools in the form of upload SDKs and API operations. The following steps describe the basic procedure for uploading media files by using developer tools:

  1. Obtain an upload URL and an upload credential from ApsaraVideo VOD.

  2. Call an OSS API operation to upload a media file.

ApsaraVideo VOD provides the following developer tools:

  • Upload SDK: Upload SDKs (both server- and client-side) encapsulate the logic for obtaining upload URLs and credentials and calling API operations of OSS to upload media files. This method is easy to use and requires simple configurations. We recommend that you use this upload method.

  • API operation for URL-based batch upload: ApsaraVideo VOD provides the UploadMediaByURL operation that you can use to upload media files to a storage address of ApsaraVideo VOD by using the URLs that can be accessed over the Internet. This way, you do not need to download the media files to your servers or devices and then upload the media files to ApsaraVideo VOD by using upload SDKs.

    Note

    The URL-based upload jobs are asynchronous. After you submit a URL-based upload job, it may take hours, even days to complete. If you have high requirements on the upload speed, we recommended that you upload the media files by using the upload SDKs.

  • OSS SDK: If the upload SDKs cannot meet your business requirements, you can use an ApsaraVideo VOD SDK and an OSS SDK together to upload media files. For example, you can use this upload method if the upload SDKs are unavailable in the programming language that you use. You can use an ApsaraVideo VOD SDK to obtain upload URLs and credentials, use an OSS SDK to decode the Base64-encoded upload URLs and credentials that you obtain, and then call API operations of OSS to upload media files.

  • OSS API: If you use this upload method, you must call API operations of ApsaraVideo VOD to obtain upload URLs and credentials and then call API operations of OSS to upload media files. We recommend that you do not use this upload method due to its low upload efficiency and high error probability.

Note

For more information about how to select an upload method, see Select an upload method.

The following table provides a summary about the various developer tools for upload.

Upload method

Scenario

Description

Upload from servers

  • Scenarios in which you require automatic upload or you want to upload a large number of video files.

  • Scenarios in which you want to upload online media files.

Note

We recommend that you use upload SDKs to upload media files. If upload SDKs of ApsaraVideo VOD do not support your favored programming language, you can upload media files by using OSS SDKs.

  • Server upload SDKs of ApsaraVideo VOD encapsulate the logic for obtaining upload URLs and credentials and calling API operations of OSS to upload media files. You only need to complete simple configurations before you can upload media files.

  • Server upload SDKs support the Java, Python, PHP, C, and C++ programming languages.

Upload from clients

Scenarios in which you want to upload user generated content (UGC) and professionally generated content (PGC).

  • Client upload SDKs of ApsaraVideo VOD encapsulate the logic for calling API operations of OSS to upload media files.

  • You must obtain upload URLs and credentials yourself. We recommend that you obtain upload URLs and credentials by integrating an ApsaraVideo VOD SDK on your application server. You do not need to decode the obtained upload URLs or credentials. You only need to deliver them to clients.

  • You can use client upload SDKs for Web (JavaScript), Android, iOS, and WeChat mini programs to upload media files.

UploadMediaByURL

Scenarios in which you want to upload files that are not stored on your servers or devices. You can upload such files by using the URLs that can be accessed over the Internet.

  • You can upload media files only to the storage addresses in the China (Shanghai) and Singapore regions by using this upload method.

  • You cannot upload local files.

Upload media files by using OSS SDKs

  • Scenarios in which you require automatic upload or you want to upload a large number of video files.

  • Scenarios in which you want to upload online media files.

  • To upload media files by using OSS SDKs, you must implement the logic for the entire upload process. You need to obtain upload URLs and credentials from ApsaraVideo VOD, decode the Base64-encoded upload URLs and credentials, and then use OSS SDKs to upload media files.

  • OSS SDKs support the Java, Python, PHP, .NET, Node.js, C, C++, and Go programming languages.

    Note

    We recommend that you use upload SDKs if you use the Java, Python, PHP, C, or C++ programming language.

Upload OSS objects

Not recommended

  • Scenarios in which you require automatic upload or you want to upload a large number of video files.

  • Scenarios in which you want to upload online media files.

  • You must call API operations of ApsaraVideo VOD to obtain upload URLs and credentials.

  • You must decode the Base64-encoded upload URLs and credentials and call API operations of OSS to upload media files.

Media asset storage

Storage regions

ApsaraVideo VOD stores media assets in Object Storage Service (OSS). The storage nodes of ApsaraVideo VOD are globally distributed. Each storage node represents a storage region. Each storage region is assigned a storage address by ApsaraVideo VOD.

Storage addresses

Note

ApsaraVideo VOD does not allow cross-region data access, even if the data belongs to the same account. Before you upload media files, make sure that you select the region in which your business is located. Otherwise, you may not be able to use the media files in the intended location.

Storage address setting

Description

Enable the default storage address

After you activate ApsaraVideo VOD, you are assigned an independent VOD bucket in each region. You must enable the bucket before you can upload and manage media resources in a region. Other configurations are not required. For more information, see Enable VOD buckets.

Add a new storage address

You can add OSS buckets to ApsaraVideo VOD. This way, you can perform operations such as transcoding, snapshot capture, and playback on media files that are stored in the OSS buckets. For more information, see Add user-created OSS buckets.

Modify the default storage address

After you enable storage addresses in multiple regions, you can change the default storage address. You can specify a storage address for a media file to be uploaded. If you do not specify the storage address, the media file is uploaded to the default storage address. For more information, see Specify a default bucket.

The following table describes the storage regions that ApsaraVideo VOD supports and the corresponding region IDs.

Note

When you upload media files by using the ApsaraVideo VOD console or PC clients, the storage address in the region in which you access the ApsaraVideo VOD service is used. When you upload media files by using the SDK or API, you can specify the storage address. For example, you can specify the storage address by setting the StorageLocation parameter when you call the UploadMediaByURL operation.

Storage region

Storage region ID

China (Shanghai)

cn-shanghai

China (Beijing)

cn-beijing

China (Shenzhen)

cn-shenzhen

China (Hong Kong)

cn-hongkong

Japan (Tokyo)

ap-northeast-1

Singapore

ap-southeast-1

Indonesia (Jakarta)

ap-southeast-5

Germany (Frankfurt)

eu-central-1

US (Silicon Valley)

us-west-1

Billing for media asset storage

ApsaraVideo VOD charges you for consumed storage resources based on the pay-as-you-go or subscription billing method (resource plan).

Upload settings

ApsaraVideo VOD allows you to configure upload settings, such as settings for media asset management, audio and video transcoding, upload event notifications, and upload management.

Features

The following table describes the upload settings supported by different upload methods.

Group

Feature

Upload media files by using the ApsaraVideo VOD console

Upload media files by using PC clients

Upload from servers

Upload from clients

UploadMediaByURL

Upload media files by using OSS SDKs

Upload OSS objects

Media asset management

Set the title of a media asset

Supported

Supported

Supported

Supported

Supported

Supported

Supported

Set the category of a media asset

Supported

Supported

Supported

Supported

Supported

Supported

Supported

Set the tags of a media asset

Not supported

Supported

Supported

Supported

Supported

Supported

Supported

Set the thumbnail of a video file

Not supported

Not supported

Supported

Supported

Supported

Supported

Supported

Audio and video transcoding

Specify a transcoding template group

Supported

Supported

Supported

Supported

Supported

Supported

Supported

Specify a media workflow

Supported

Not supported

Supported

Supported

Supported

Supported

Supported

No transcoding

Supported

Supported

Supported

Supported

Supported

Supported

Supported

Upload management

Obtain the upload progress

Supported

Supported

Supported

Supported

Supported

Supported

Supported

Perform resumable upload

Not supported

Not supported

Only the upload SDK for Java supports this feature.

Supported

Not supported

Only OSS SDK for Java supports this feature.

Not supported

Perform multipart upload

Enabled by default

Enabled by default

Enabled by default

Enabled by default

Enabled by default

Enabled by default

Enabled by default

Media asset management during upload

  • Set the title of a media asset. You can set the title of the audio, video, or image file to be uploaded.

  • Set the category of a media asset. After you create media categories, you can specify a category for the media file to be uploaded.

  • Set the tags of a media asset. You can add tags to the media file to be uploaded.

  • Set the thumbnail of a video file. When you upload a video file, you can specify an image as the thumbnail of the video file.

Audio and video transcoding

You can specify a transcoding template group or a media workflow to transcode audio and video files when you configure upload settings. Transcoding is automatically triggered after the upload is complete. You can also configure no transcoding. Only videos in the following formats can be played without transcoding: MP4, FLV, M3U8, MP3, and WEBM.

  • Specify a transcoding template group. By default, ApsaraVideo VOD asks you to specify a transcoding template group when you upload media files. Transcoding is automatically triggered after the upload is complete.

  • Specify a media workflow. After you create a media workflow that contains one or more transcoding jobs, you can specify the media workflow to be used for transcoding when you upload media files. After the upload is complete, ApsaraVideo VOD automatically runs the specified media workflow to complete the transcoding jobs.

  • Disable transcoding. If transcoding is not required, you can specify the No Transcoding template when you upload media files.

Upload management

  • Perform multipart upload. ApsaraVideo VOD splits a media file into multiple parts during upload and combines the uploaded parts together after the upload is complete. By default, all media files are uploaded to ApsaraVideo VOD in multipart upload mode.

    Note

    During multipart upload, useless parts may be retained if the upload fails. These useless parts are automatically deleted after seven days. You can also call the DeleteMultipartUpload operation to manually clear useless parts.

  • Obtain the upload progress and status.

  • Perform resumable upload. If the upload of a media file fails due to network errors, ApsaraVideo VOD resumes the upload from the last successfully uploaded part.

    Note

    Resumable upload is implemented inside the client upload SDK. If a media file fails to be uploaded due to an exception, the upload is resumed from the recorded position without user interference.

Upload event notifications

You can configure callbacks to receive event notifications about the upload progress and status after you upload media files. ApsaraVideo VOD allows you to configure HTTP or HTTPS and Message Service (MNS) callbacks to obtain event notifications. For more information about callback configurations, see Overview. For more information about how to configure callbacks, see Configure callbacks. All upload methods support event notifications. The following table describes the upload events.

Note

For more information about each event, see Events.

Event name

Event type

Description

FileUploadComplete

FileUploadComplete

The FileUploadComplete event is generated when the upload of audio and video files is complete.

Note

If you specify the No Transcoding template for audio or video files, you can obtain the streaming URLs after you receive a notification for the FileUploadComplete event.

You can also call the SubmitTranscodeJobs operation to transcode the audio or video files as needed after you receive a notification for the FileUploadComplete event.

ImageUploadComplete

ImageUploadComplete

The ImageUploadComplete event is generated when the upload of image files is complete.

AttachedMediaUploadComplete

AttachedMediaUploadComplete

The AttachedMediaUploadComplete event is generated when the upload of auxiliary media assets is complete.

UploadByURLComplete

UploadByURLComplete

The UploadByURLComplete event is generated after you call the UploadMediaByURL operation to upload media files by using the URLs of source files.

StreamTranscodeComplete

StreamTranscodeComplete

The StreamTranscodeComplete event is generated after a video stream is transcoded in a specific definition and format, such as an SD stream in the MP4 format.

Note

For transcoded audio and video files, you can obtain the playback URLs after you receive a notification for the StreamTranscodeComplete event. Playback failures may occur if you play an audio or video file before a callback is received.

TranscodeComplete

TranscodeComplete

The TranscodeComplete event is generated after all transcoded streams of a video are generated.

Note

To ensure that video streams in all definitions can be played, you can play a video file after you receive a notification for the TranscodeComplete event. Playback failures may occur if you play a video file before a callback is received.

Upload authorization

You can use upload credentials or Security Token Service (STS) tokens to perform authorization and ensure security when you upload media files by using developer tools. This prevents unauthorized users from uploading or playing media files.

Upload acceleration

Feature description

ApsaraVideo VOD provides the upload acceleration feature to speed up file transfer over a long distance and upload of files of gigabytes or terabytes in size. Upload acceleration is applicable to scenarios in which media files are transferred across regions. For example, you upload media files that are stored in the Chinese mainland to the storage address in the Singapore region.

Enable upload acceleration

You must submit a ticket to enable the upload acceleration feature. You must include your Alibaba Cloud account ID and the storage address for which you want to enable the upload acceleration feature in your request.

Billing

You are charged for using the upload acceleration feature, which is a value-added feature provided by ApsaraVideo VOD. For more information about billing, see Transfer acceleration.

Note

No fees are charged if you enable upload acceleration but do not use the feature.

Limits and supported upload methods

The upload acceleration feature applies only to video files. The following table describes the support for the upload acceleration feature by different upload methods.

Upload method

Upload acceleration

Upload media files by using the ApsaraVideo VOD console

Not supported

Upload media files by using PC clients

Supported

Upload from servers

Supported

Upload from clients

Supported

UploadMediaByURL

Supported

Upload media files by using OSS SDKs

Supported

Upload OSS objects

Supported

Usage notes for uploaded media files

Note

After media files are uploaded to ApsaraVideo VOD, the files are in different statuses based on the processing progress. You can perform different operations on media files in different statuses. For example, you can only delete media files that are in the Uploading, Upload Failed, or Blocked status. However, you can perform all supported operations such as transcoding, snapshot capture, review, and playback on media files that are in the Normal status. For more information about the media status, see the "Status: the status of a video" and the Status: the status of an image sections of the Basic data types topic.

The following table describes the usage notes for the features of ApsaraVideo VOD that are related to uploaded media files.

Feature

Description

References

Media asset management after upload

You can manage uploaded media files such as source video files, transcoded stream files, and image files in ApsaraVideo VOD.

Media asset management

Media Processing

ApsaraVideo VOD supports audio and video transcoding, automated review, online editing, and AI processing for uploaded media files.

Note

ApsaraVideo VOD automatically extracts the metadata of uploaded audio and video files, such as the video resolution, duration, and bitrate. By default, ApsaraVideo VOD also captures snapshots from videos as thumbnails. Metadata extraction and thumbnail snapshots are free of charge.

Media processing

Audio and video playback

After audio and video files are uploaded, they must be received on ApsaraVideo VOD before they can be played. You can determine whether the audio and video files can be played by checking event notifications.

  • If you specify the No Transcoding template for audio or video files, you can obtain the playback URLs after you receive a notification for the FileUploadComplete event.

  • For transcoded audio and video files, you can obtain the playback URLs after you receive a notification for the StreamTranscodeComplete event. To ensure that video streams in all definitions can be played, you can play a video file after you receive a notification for the TranscodeComplete event.