All Products
Search
Document Center

ApsaraVideo VOD:UpdateMediaStorageClass

Last Updated:Jul 21, 2026

Modifies the storage class of a media asset.

Operation description

  • Before using this operation, make sure that you fully understand the billing methods and pricing of ApsaraVideo VOD. Modifying the storage class of a media asset incurs storage fees. For billing details, see Media asset storage billing.

  • Modifying the storage class is an asynchronous operation. A callback is sent to you after the entire operation is complete.

  • If the current storage class of a media asset is Archive or ColdArchive, calling this operation automatically triggers a restore. After the restore is complete, the storage class is modified. You do not need to manually call the RestoreMedia operation to restore the media asset. For ColdArchive media assets, you need to specify the restore priority. The default value is RestoreTier=Standard.

  • A media asset that is being modified cannot be modified again or be used for production or processing.

  • Media assets in non-Standard storage classes have minimum storage duration requirements: Infrequent Access/source file Infrequent Access requires at least 30 days. Archive/source file Archive requires at least 60 days. ColdArchive/source file ColdArchive requires at least 180 days. If the storage duration is insufficient, modifying the storage class incurs storage fees for the remaining days. For example, if you modify the storage class from Infrequent Access to Standard after 10 days of storage, you are charged for the remaining 20 days of Infrequent Access storage, totaling 30 days of Infrequent Access storage fees.

  • Modifying the storage class of a self-managed bucket is not supported.

Try it now

Try this API in OpenAPI Explorer, no manual signing needed. Successful calls auto-generate SDK code matching your parameters. Download it with built-in credential security for local usage.

Test

RAM authorization

The table below describes the authorization required to call this API. You can define it in a Resource Access Management (RAM) policy. The table's columns are detailed below:

  • Action: The actions can be used in the Action element of RAM permission policy statements to grant permissions to perform the operation.

  • API: The API that you can call to perform the action.

  • Access level: The predefined level of access granted for each API. Valid values: create, list, get, update, and delete.

  • Resource type: The type of the resource that supports authorization to perform the action. It indicates if the action supports resource-level permission. The specified resource must be compatible with the action. Otherwise, the policy will be ineffective.

    • For APIs with resource-level permissions, required resource types are marked with an asterisk (*). Specify the corresponding Alibaba Cloud Resource Name (ARN) in the Resource element of the policy.

    • For APIs without resource-level permissions, it is shown as All Resources. Use an asterisk (*) in the Resource element of the policy.

  • Condition key: The condition keys defined by the service. The key allows for granular control, applying to either actions alone or actions associated with specific resources. In addition to service-specific condition keys, Alibaba Cloud provides a set of common condition keys applicable across all RAM-supported services.

  • Dependent action: The dependent actions required to run the action. To complete the action, the RAM user or the RAM role must have the permissions to perform all dependent actions.

Action

Access level

Resource type

Condition key

Dependent action

vod:UpdateMediaStorageClass

update

*All Resource

*

None None

Request parameters

Parameter

Type

Required

Description

Example

MediaIds

string

Yes

The media IDs, which are audio or video IDs (VideoId). Separate multiple IDs with commas (,). A maximum of 20 IDs are supported. You can obtain the IDs by using the following methods:

  • For audio or video files uploaded through the console, log on to the ApsaraVideo VOD console and choose Media Files > Audio/Video to view the audio or video ID.

  • When you call the CreateUploadVideo operation to obtain the upload URL and credential, the video ID is the value of the VideoId response parameter.

  • After the audio or video file is uploaded, you can call the SearchMedia operation to query the video ID, which is the value of the VideoId response parameter.

d56c2ac0cee271ed80004710b5ba****

Scope

string

No

The scope of the modification. If this parameter is not specified, the default value All is used. Valid values:

  • All (default): Applies tiered storage to all resources (source files and transcoded streams) of the media asset.

  • SourceFile: Applies tiered storage only to the source file of the media asset. Resources other than the source file use Standard storage.

All

StorageClass

string

Yes

The storage class. Valid values:

  • Standard: Standard

  • IA: Infrequent Access

  • Archive: Archive

  • ColdArchive: Cold Archive

Archive

RestoreTier

string

No

The restore priority (required only for ColdArchive media assets). If this parameter is not specified, the default value Standard is used. Valid values:

  • Expedited: Expedited

  • Standard (default): Standard

  • Bulk: Bulk

Standard

AllowUpdateWithoutTimeLimit

boolean

No

Specifies whether to allow storage class modification for media assets that have not met the minimum storage duration requirement. Valid values:

  • true: Allowed.

  • false (default): Not allowed.

Note

If the storage duration of a media asset is insufficient and you force a storage class modification, additional retrieval fees are incurred.

false

For ColdArchive media assets, you can specify the restore duration and restore priority. The restore duration ranges from 1 day to 365 days. The retrieval time for different restore priorities is as follows:

  • Expedited: The restore is completed within 1 hour.

  • Standard: The restore is completed within 2 to 5 hours.

  • Bulk: The restore is completed within 5 to 12 hours.

Response elements

Element

Type

Description

Example

object

The response parameters.

RequestId

string

The request ID.

30FA0B7C-3A81-5449-93CD-ACA149E6****

Status

string

The task status. Valid values:

  • Processing: Processing.

  • Failed: Failed.

Processing

IgnoredList

object

MediaId

array

The list of media asset IDs that failed to be retrieved.

string

The media asset ID that failed to be retrieved.

['19e231ee6e3e417fbf2e92ec2680****']

ForbiddenList

object

MediaForbiddenReasonDTO

array<object>

The list of media asset IDs that failed to be processed.

object

The information about the media asset that failed to be processed.

MediaId

string

The ID of the media asset.

19e231ee6e3e417fbf2e92ec2680****

Reason

string

The reason for the failure.

TargetStorageClassInconsistent

Examples

Success response

JSON format

{
  "RequestId": "30FA0B7C-3A81-5449-93CD-ACA149E6****",
  "Status": "Processing",
  "IgnoredList": {
    "MediaId": [
      "['19e231ee6e3e417fbf2e92ec2680****']"
    ]
  },
  "ForbiddenList": {
    "MediaForbiddenReasonDTO": [
      {
        "MediaId": "19e231ee6e3e417fbf2e92ec2680****",
        "Reason": "TargetStorageClassInconsistent"
      }
    ]
  }
}

Error codes

See Error Codes for a complete list.

Release notes

See Release Notes for a complete list.