Queries the information about snapshot jobs.
Usage notes
You can call this operation to query up to 10 snapshot jobs at a time.
Limits on QPS
You can call this operation up to 100 times per second per account. If the number of calls per second exceeds the limit, throttling is triggered. As a result, your business may be affected. We recommend that you take note of the limit when you call this operation. For more information, see QPS limit.
Debugging
Request parameters
Parameter | Type | Required | Example | Description |
---|---|---|---|---|
Action | String | Yes | QuerySnapshotJobList |
The operation that you want to perform. Set the value to QuerySnapshotJobList. |
SnapshotJobIds | String | No | 72dfa5e679ab4be9a3ed9974c736**** |
The IDs of the snapshot jobs that you want to query. To obtain the IDs, you can log on to the ApsaraVideo Media Processing (MPS) console, click Tasks in the left-side navigation pane, and then view the IDs on the Snapshot tab. You can query up to 10 snapshot jobs at a time. Separate the IDs with commas (,). |
NextPageToken | String | No | cc6cbef8e8d5481ca536f5d2a466**** |
The token that is used to retrieve the next page of the query results. The value is a 32-bit UUID. If the returned query results cannot be displayed within one page, this parameter is returned. The value of this parameter is updated for each query. |
MaximumPageSize | Long | No | 30 |
The maximum number of entries to return on each page.
|
State | String | No | Snapshoting |
The status of the snapshot jobs that you want to query.
|
StartOfJobCreatedTimeRange | String | No | 2014-01-10T12:00:00Z |
The beginning of the time range within which the creation time of snapshot jobs to be queried is.
|
EndOfJobCreatedTimeRange | String | No | 2014-01-12T12:00:00Z |
The end of the time range within which the creation time of snapshot jobs to be queried is.
|
PipelineId | String | No | b11c171cced04565b1f38f1ecc39**** |
The ID of the MPS queue to which the snapshot jobs that you want to query are submitted. To obtain the ID, you can log on to the MPS console and choose Global Settings > Pipelines in the left-side navigation pane. |
Response parameters
Parameter | Type | Example | Description |
---|---|---|---|
SnapshotJobList | Array of SnapshotJob |
The information about the snapshot jobs. |
|
SnapshotJob | |||
CreationTime | String | 2021-06-30T12:34:29Z |
The time when the job was created. |
SnapshotConfig | Object |
The snapshot configuration. |
|
Time | String | 4 |
The start time for taking snapshots. Unit: milliseconds. |
TileOut | Object |
The tiling configuration. |
|
Padding | String | 0 |
The distance between images.
|
Color | String | black |
The background color.
Note If you want to set the background color to black, you can specify the color keyword
in one of the following three formats: Black, black, and #000000.
|
CellSelStep | String | 3 |
The stride of a single image. |
CellHeight | String | 8 |
The height of a single image. The default value is the height of the output snapshot. |
CellWidth | String | 8 |
The width of a single image. The default value is the width of the output snapshot. |
Margin | String | 0 |
The margin width of the tiled image.
|
Columns | String | 10 |
The number of columns that the tiled image can contain. Default value: 10. |
IsKeepCellPic | String | false |
Indicates whether the single images are retained. Default value: true. |
Lines | String | 10 |
The number of rows that the tiled image can contain. Default value: 10. |
Interval | String | 10 |
The interval for taking snapshots.
|
FrameType | String | intra |
The type of the snapshot. Valid values:
|
Width | String | 8 |
The width of the output snapshot. |
Height | String | 8 |
The height of the output snapshot. |
OutputFile | Object |
The Object Storage Service (OSS) output file of the snapshot job. |
|
RoleArn | String | acs:ram::1:role/testrole |
The Alibaba Cloud Resource Name (ARN) of the specified RAM role. Format: acs:ram::$accountID:role/$roleName. |
Object | String | example.png |
The OSS object that is generated as the output file of the snapshot job. |
Location | String | example-location |
The ID of the region in which the output OSS bucket is located. |
Bucket | String | example |
The OSS bucket that stores the output file. |
Num | String | 10 |
The number of snapshots to take. If the Num parameter is set in the request, snapshots are taken at intervals. |
TileOutputFile | Object |
The OSS output file of the tiling job. |
|
RoleArn | String | acs:ram::1:role/testrole |
The ARN of the specified RAM role. Format: acs:ram::$accountID:role/$roleName. |
Object | String | example.png |
The OSS object that is generated as the output file of the tiling job. |
Location | String | example-location |
The ID of the region in which the output OSS bucket is located. |
Bucket | String | example |
The OSS bucket that stores the output file. |
State | String | Snapshoting |
The status of the snapshot job.
|
Message | String | The resource operated InputFile is bad |
The error message returned when the job fails. This parameter is not returned if the job is successfully processed. |
MNSMessageResult | Object |
The message sent by MNS to notify the user of the job result. |
|
MessageId | String | 799454621135656C7F815F198A76**** |
The ID of the message. This parameter is not returned if the job fails. |
ErrorMessage | String | The resource operated InputFile is bad |
The error message returned when the job fails. This parameter is not returned if the job is successfully processed. |
ErrorCode | String | InvalidParameter |
The error code returned when the job fails. This parameter is not returned if the job is successfully processed. |
Input | Object |
The information about the job input. |
|
RoleArn | String | acs:ram::1:role/testrole |
The ARN of the specified RAM role. Format: acs:ram::$accountID:role/$roleName. |
Object | String | example.flv |
The OSS object that is used as the input file. |
Location | String | example-location |
The ID of the region in which the input OSS bucket is located. |
Bucket | String | example |
The OSS bucket that stores the input file. |
Count | String | 1 |
The number of snapshots that were taken. |
TileCount | String | 7 |
The number of snapshots that are contained in the tiled image. |
UserData | String | testid-001 |
The custom data. |
Code | String | InvalidParameter |
The error code returned when the job fails. This parameter is not returned if the job is successfully processed. |
PipelineId | String | b11c171cced04565b1f38f1ecc39**** |
The ID of the MPS queue to which the snapshot job was submitted. |
Id | String | cc6cbef8e8d5481ca536f5d2a466**** |
The ID of the snapshot job. |
RequestId | String | 34BCAB31-2833-43A7-9FBD-B34302AB23EQ |
The ID of the request. |
NonExistSnapshotJobIds | Array of String | c6d973c33d1c4b21bc39907d3b29**** |
The snapshot job IDs that do not exist. This parameter is not returned if all specified snapshot jobs are found. |
NextPageToken | String | b11c171cced04565b1f38f1ecc39**** |
The token that is used to retrieve the next page of the query results. The value is a 32-bit UUID. If the returned query results cannot be displayed within one page, this parameter is returned. The value of this parameter is updated for each query. |
Examples
Sample requests
http(s)://mts.cn-hangzhou.aliyuncs.com/?Action=QuerySnapshotJobList
&SnapshotJobIds=72dfa5e679ab4be9a3ed9974c736****
&NextPageToken=cc6cbef8e8d5481ca536f5d2a466****
&MaximumPageSize=30
&State=Snapshoting
&StartOfJobCreatedTimeRange=2014-01-10T12:00:00Z
&EndOfJobCreatedTimeRange=2014-01-12T12:00:00Z
&PipelineId=b11c171cced04565b1f38f1ecc39****
&<Common request parameters>
Sample success responses
XML
format
HTTP/1.1 200 OK
Content-Type:application/xml
<QuerySnapshotJobListResponse>
<SnapshotJobList>
<CreationTime>2021-06-30T12:34:29Z</CreationTime>
<SnapshotConfig>
<Time>4</Time>
<TileOut>
<Padding>0</Padding>
<Color>black</Color>
<CellSelStep>3</CellSelStep>
<CellHeight>8</CellHeight>
<CellWidth>8</CellWidth>
<Margin>0</Margin>
<Columns>10</Columns>
<IsKeepCellPic>false</IsKeepCellPic>
<Lines>10</Lines>
</TileOut>
<Interval>10</Interval>
<FrameType>intra</FrameType>
<Width>8</Width>
<Height>8</Height>
<OutputFile>
<RoleArn>acs:ram::1:role/testrole</RoleArn>
<Object>example.png</Object>
<Location>example-location</Location>
<Bucket>example</Bucket>
</OutputFile>
<Num>10</Num>
<TileOutputFile>
<RoleArn>acs:ram::1:role/testrole</RoleArn>
<Object>example.png</Object>
<Location>example-location</Location>
<Bucket>example</Bucket>
</TileOutputFile>
</SnapshotConfig>
<State>Snapshoting</State>
<MNSMessageResult>
<MessageId>799454621135656C7F815F198A76****</MessageId>
</MNSMessageResult>
<Input>
<RoleArn>acs:ram::1:role/testrole</RoleArn>
<Object>example.flv</Object>
<Location>example-location</Location>
<Bucket>example</Bucket>
</Input>
<Count>1</Count>
<TileCount>7</TileCount>
<UserData>testid-001</UserData>
<PipelineId>b11c171cced04565b1f38f1ecc39****</PipelineId>
<Id>cc6cbef8e8d5481ca536f5d2a466****</Id>
</SnapshotJobList>
<RequestId>34BCAB31-2833-43A7-9FBD-B34302AB23EQ</RequestId>
<NonExistSnapshotJobIds>c6d973c33d1c4b21bc39907d3b29****</NonExistSnapshotJobIds>
<NextPageToken>b11c171cced04565b1f38f1ecc39****</NextPageToken>
</QuerySnapshotJobListResponse>
JSON
format
HTTP/1.1 200 OK
Content-Type:application/json
{
"SnapshotJobList": [
{
"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"
}
},
"State": "Snapshoting",,
"MNSMessageResult": {
"MessageId": "799454621135656C7F815F198A76****",
},
"Input": {
"RoleArn": "acs:ram::1:role/testrole",
"Object": "example.flv",
"Location": "example-location",
"Bucket": "example"
},
"Count": "1",
"TileCount": "7",
"UserData": "testid-001",
"PipelineId": "b11c171cced04565b1f38f1ecc39****",
"Id": "cc6cbef8e8d5481ca536f5d2a466****"
}
],
"RequestId": "34BCAB31-2833-43A7-9FBD-B34302AB23EQ",
"NonExistSnapshotJobIds": [
"c6d973c33d1c4b21bc39907d3b29****"
],
"NextPageToken": "b11c171cced04565b1f38f1ecc39****"
}
Error codes
For a list of error codes, visit the API Error Center.