All Products
Search
Document Center

ApsaraVideo Live:Live stream snapshots

Last Updated:Jun 03, 2026

The Snapshots feature captures periodic images from live streams and stores them as JPG files in Object Storage Service (OSS), giving you a durable record of stream content for content review, thumbnail generation, and compliance archiving.

How it works

  1. Configure — Set up a snapshot template for your streaming domain in the ApsaraVideo Live console or through the API.

  2. Push — Start or restart stream ingest to activate the template.

  3. Capture and store — ApsaraVideo Live captures snapshots at the configured interval and saves them as JPG files in your OSS bucket.

  4. View and manage — Browse, download, or delete snapshots from the console, the API, or directly in OSS.

Prerequisites

Before you begin, make sure you have:

  • An activated OSS instance. For more information, see Activate OSS.

  • An OSS bucket to store snapshot files, located in the same region as the live center of your streaming domain. For more information, see Create a bucket.

Important

The OSS bucket must be in the same region as the live center of the streaming domain. Cross-region snapshots are not supported.

Configure snapshot settings

Snapshots are configured per AppName. A snapshot rule applies to all stream ingests under the specified AppName. Set AppName to an asterisk (\*) to apply the rule to all stream ingests under the domain.

Select one or both storage modes — at least one is required:

Storage mode

Behavior

Overwrite

Each new snapshot replaces the previous one. Use this to always have the latest frame available at a fixed URL.

Real-time

Each new snapshot is saved alongside previous ones. Snapshots accumulate incrementally. Use this to retain the full history.

Only the JPG format is supported.

Note

A newly configured snapshot template does not apply to ongoing live streams. Restart stream ingest for the template to take effect.

Console

  1. Log on to the ApsaraVideo Live console.

  2. In the left navigation pane, choose Feature Management > Snapshots. On the Snapshots page, click the Snapshot Settings tab.

  3. Select the streaming domain to configure.

  4. Click Add.

  5. Configure the snapshot template parameters.

    Parameter

    Description

    Application Name

    The application name. Must match the AppName used for stream ingest. Enter an asterisk (\*) to apply to all streams under the domain.

    Snapshot Interval

    How often a snapshot is captured, in seconds. Valid values: 5 to 3600.

    Storage Location

    The OSS bucket where snapshot files are stored. Must be in the same region as the live center of the streaming domain.

    Storage Mode

    Select one or both modes: Overwrite — Each new snapshot replaces the previous one. New — Snapshots are stored sequentially in N+1 (N>=0) order. If both modes are selected, snapshots are captured using both methods.

  6. Click OK.

API

Call the AddLiveAppSnapshotConfig operation to configure snapshot settings.

View snapshot files

Console

  1. Log on to the ApsaraVideo Live console.

  2. In the left navigation pane, choose Feature Management > Snapshots. On the Snapshots page, click Snapshot Management.

  3. Select the domain name and time range, then enter or select the AppName and StreamName.

  4. Click Search to list snapshots within the selected time range.

    Note

    If snapshots are not visible, verify that the access control list (ACL) of the OSS bucket is set to public-read. For more information, see Configure the ACL of an OSS bucket.

  5. Hover over an image to view a larger version or copy the snapshot URL.

API

Call the DescribeLiveStreamSnapshotInfo operation to query snapshot files.

OSS

Open the OSS bucket you specified when configuring the snapshot feature and browse snapshot files directly. For more information, see List objects in OSS.

Delete snapshot files

ApsaraVideo Live stores snapshot metadata (such as AppName, StreamName, and the OSS storage path). The actual snapshot files reside in OSS. To delete files from OSS when deleting snapshots through the console, first authorize ApsaraVideo Live to access OSS by creating a service role.

Authorize ApsaraVideo Live to delete OSS files

Create the AliyunMTSVideoLifecycleRole service role and attach the AliyunMTSVideoLifecycleRolePolicy system policy. This authorization is required before deleting snapshots or recordings from the ApsaraVideo Live console.

Create the service role

  1. Log on to the Resource Access Management (RAM) console as a RAM administrator.

  2. In the left navigation pane, choose Identities > Roles.

  3. On the Roles page, click Create Role.

  4. Set Principal Type to Cloud Service.

  5. From the Principal Name drop-down list, select ApsaraVideo Media Processing.

  6. Click OK.

  7. In the Create Role dialog box, enter AliyunMTSVideoLifecycleRole in the Role Name field, then click OK.

Attach the system policy

  1. After the role is created, go to its Basic Information page and click the Permissions tab.

  2. Click Precise Permission.

  3. Configure the following parameters:

    • Policy Type: System Policy

    • Policy Name: AliyunMTSVideoLifecycleRolePolicy

  4. Click OK.

Console

  1. Log on to the ApsaraVideo Live console.

  2. In the left navigation pane, choose Feature Management > Snapshots. On the Snapshots page, click Snapshot Management.

  3. Select the domain name and time range, then enter or select the AppName and StreamName.

  4. To delete a single snapshot, hover over the image and click the delete icon.

  5. To delete multiple snapshots at once, select the snapshots and click Batch Delete.

Note

A maximum of 200 snapshots can be deleted at a time.

API

Call the DeleteSnapshotFiles operation to delete snapshot files. This operation also deletes the corresponding files from OSS.

Schedule automatic deletion

Configure snapshot callbacks to save snapshot metadata (including timestamps) to your own system, then delete files on a custom schedule. For more information, see Live stream snapshot callbacks.

See also