All Products
Search
Document Center

ApsaraVideo Media Processing:QuerySnapshotJobList

Last Updated:Jan 16, 2026

Queries snapshot jobs.

Operation description

  • You can query snapshot jobs by specifying one or more snapshot job IDs (SnapshotJobIds). You can also perform a paged query and filter jobs by status, creation time, or MPS queue without specifying job IDs.

  • This operation queries a maximum of 10 snapshot jobs per call.

  • The return values of this operation are sorted by CreationTime in descending order by default.

QPS limits

This operation is limited to 100 queries per second (QPS) per user. If you exceed this limit, API calls are throttled, which may affect your business. To prevent throttling, you can call this operation at a reasonable rate. For more information, see QPS limits.

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

mts:QuerySnapshotJobList

list

*All Resource

*

None None

Request parameters

Parameter

Type

Required

Description

Example

SnapshotJobIds

string

No

The list of snapshot job IDs.

  • You can query up to 10 jobs at a time. Separate multiple IDs with commas (,).

  • You can obtain the job IDs from the MPS console by choosing Task Management > Snapshots. You can also obtain them from the response parameters of the SubmitSnapshotJob operation.

72dfa5e679ab4be9a3ed9974c736****

NextPageToken

string

No

The token for the next page. It is a 32-bit universally unique identifier (UUID).

  • If the query result is truncated, the NextPageToken parameter is returned. The value of this parameter is updated for each query. Use this token in the next query to retrieve the next page of results.

cc6cbef8e8d5481ca536f5d2a466****

MaximumPageSize

integer

No

The maximum number of entries to return on each page of a paged query.

  • Valid values: [1, 300].

  • Default value: 30.

30

State

string

No

The state of the snapshot jobs to query.

  • Submitted: The job is submitted.

  • Snapshoting: The job is in progress.

  • Success: The job is successful.

  • Fail: The job failed.

Snapshoting

StartOfJobCreatedTimeRange

string

No

The beginning of the job creation time range.

  • The date format must follow the ISO 8601 standard and use Coordinated Universal Time (UTC).

  • The format is YYYY-MM-DDThh:mm:ssZ.

2014-01-10T12:00:00Z

EndOfJobCreatedTimeRange

string

No

The end of the job creation time range.

  • The date format must follow the ISO 8601 standard and use Coordinated Universal Time (UTC).

  • The format is YYYY-MM-DDThh:mm:ssZ.

2014-01-12T12:00:00Z

PipelineId

string

No

The ID of the MPS queue. For more information, see Terms.

  • You can view and create MPS queues in the MPS console by choosing Global Settings > Pipelines.

  • If you want to receive asynchronous notification messages, attach an MNS queue or topic to the MPS queue. For more information, see Receive message notifications.

b11c171cced04565b1f38f1ecc39****

Response elements

Element

Type

Description

Example

object

The response parameters.

SnapshotJobList

object

SnapshotJob

array<object>

The list of snapshot jobs.

array<object>

The response parameters.

CreationTime

string

The time the job was created.

2021-06-30T12:34:29Z

SnapshotConfig

object

The snapshot configuration.

Time

string

The start time for the snapshot. Unit: milliseconds.

4

TileOut

object

The mosaic configuration.

Padding

string

The spacing between images.

  • Default: 0.

  • Unit: px.

0

Color

string

The background color.

  • Default: black.

  • Valid values: color keyword, random.

Note

Color keywords support three formats. For example, black can be specified as Black, black, or #000000.

black

CellSelStep

string

The step size for selecting a single image.

3

CellHeight

string

The height of a single image. The default is the height of the snapshot output.

8

CellWidth

string

The width of a single image. The default is the width of the snapshot output.

8

Margin

string

The width of the outer border.

  • Default: 0.

  • Unit: px.

0

Columns

string

The number of columns in the mosaic. Default: 10.

10

IsKeepCellPic

string

Indicates whether to keep the individual images. Default: true.

false

Lines

string

The number of rows in the mosaic. Default: 10.

10

Interval

string

The snapshot interval.

  • If specified, it indicates a sequence of snapshots, and the value must be greater than 0.

  • Unit: seconds.

  • Default value: 10.

10

FrameType

string

The snapshot type.

  • normal: Normal frame.

  • intra: I-frame.

  • Default value: intra.

intra

Width

string

The width of the output snapshot image.

8

Height

string

The height of the output snapshot image.

8

OutputFile

object

The OSS configuration for the snapshot output.

RoleArn

string

The ARN of the specified role. Format: acs:ram::$accountID:role/$roleName.

acs:ram::1:role/testrole

Object

string

The output file (OSS Object) for the snapshot.

example.png

Location

string

The data center where the output OSS bucket is located (OSS Location).

example-location

Bucket

string

The OSS bucket where the output file is stored.

example

Num

string

The number of snapshots. If specified, it indicates a sequence of snapshots.

10

TileOutputFile

object

The OSS configuration for the large image output of the mosaic job.

RoleArn

string

The ARN of the specified role. Format: acs:ram::$accountID:role/$roleName.

acs:ram::1:role/testrole

Object

string

The output file (OSS Object).

example.png

Location

string

The data center where the output OSS bucket is located (OSS Location).

example-location

Bucket

string

The OSS bucket where the output file is stored.

example

TimeArray

object

TimePointList

array

The array of specified time points.

integer

The array of specified time points. Unit: milliseconds. This is a floating-point number with two decimal places. The time points can be repeated and submitted in any order. MPS sorts them. A maximum of 100 time points are supported. If you specify this parameter, do not specify Num, Time, or Interval. Otherwise, an InvalidParameter.Ambiguity error is returned.

[10050, 50000, 110000, 1000500, 1100500]

State

string

The state of the snapshot job.

  • Submitted: The job is submitted.

  • Snapshoting: The job is in progress.

  • Success: The job is successful.

  • Fail: The job failed.

Snapshoting

Message

string

The error message returned when the analysis fails. This parameter is not returned if the job is successful.

The resource operated InputFile is bad

MNSMessageResult

object

The result of the MNS notification sent to the user when the job is complete.

MessageId

string

The ID of the message. This parameter is not returned if the job fails.

799454621135656C7F815F198A76****

ErrorMessage

string

The error message. This parameter is not returned if the job is successful.

The resource operated InputFile is bad

ErrorCode

string

The error code. This parameter is not returned if the job is successful.

InvalidParameter

Input

object

The job input.

RoleArn

string

The ARN of the specified role. Format: acs:ram::$accountID:role/$roleName.

acs:ram::1:role/testrole

Object

string

The input file (OSS Object).

example.flv

Location

string

The data center where the input OSS bucket is located (OSS Location).

example-location

Bucket

string

The OSS bucket where the input file is stored.

example

Count

string

The number of captured images.

1

TileCount

string

The number of images in the mosaic.

7

UserData

string

The user-defined data.

testid-001

Code

string

The error code returned when the analysis fails. This parameter is not returned if the job is successful.

InvalidParameter

PipelineId

string

The pipeline ID.

b11c171cced04565b1f38f1ecc39****

Id

string

The ID of the snapshot job.

cc6cbef8e8d5481ca536f5d2a466****

RequestId

string

The ID of the request.

34BCAB31-2833-43A7-9FBD-B34302AB23EQ

NonExistSnapshotJobIds

object

String

array

The list of non-existent snapshot job IDs.

string

The details of a non-existent snapshot job ID. This parameter is not returned if no data exists.

c6d973c33d1c4b21bc39907d3b29****

NextPageToken

string

The token for the next page. It is a 32-bit UUID. This parameter is returned when the query result is truncated. The value of this parameter is updated for each query.

b11c171cced04565b1f38f1ecc39****

Examples

Success response

JSON format

{
  "SnapshotJobList": {
    "SnapshotJob": [
      {
        "CreationTime": "2021-06-30T12:34:29Z",
        "SnapshotConfig": {
          "Time": "4",
          "TileOut": {
            "Padding": "0",
            "Color": "black",
            "CellSelStep": "3",
            "CellHeight": "8",
            "CellWidth": "8",
            "Margin": "0",
            "Columns": "10",
            "IsKeepCellPic": "false",
            "Lines": "10"
          },
          "Interval": "10",
          "FrameType": "intra",
          "Width": "8",
          "Height": "8",
          "OutputFile": {
            "RoleArn": "acs:ram::1:role/testrole",
            "Object": "example.png",
            "Location": "example-location",
            "Bucket": "example"
          },
          "Num": "10",
          "TileOutputFile": {
            "RoleArn": "acs:ram::1:role/testrole",
            "Object": "example.png",
            "Location": "example-location",
            "Bucket": "example"
          },
          "TimeArray": {
            "TimePointList": [
              0
            ]
          }
        },
        "State": "Snapshoting",
        "Message": "The resource operated InputFile is bad",
        "MNSMessageResult": {
          "MessageId": "799454621135656C7F815F198A76****",
          "ErrorMessage": "The resource operated InputFile is bad",
          "ErrorCode": "InvalidParameter"
        },
        "Input": {
          "RoleArn": "acs:ram::1:role/testrole",
          "Object": "example.flv",
          "Location": "example-location",
          "Bucket": "example"
        },
        "Count": "1",
        "TileCount": "7",
        "UserData": "testid-001",
        "Code": "InvalidParameter",
        "PipelineId": "b11c171cced04565b1f38f1ecc39****",
        "Id": "cc6cbef8e8d5481ca536f5d2a466****"
      }
    ]
  },
  "RequestId": "34BCAB31-2833-43A7-9FBD-B34302AB23EQ",
  "NonExistSnapshotJobIds": {
    "String": [
      "c6d973c33d1c4b21bc39907d3b29****"
    ]
  },
  "NextPageToken": "b11c171cced04565b1f38f1ecc39****"
}

Error codes

See Error Codes for a complete list.

Release notes

See Release Notes for a complete list.