SubmitDynamicImageJob

更新时间:
复制 MD 格式

Use this API to submit a task to generate a dynamic image.

Operation description

This is an asynchronous interface. When you submit a task, you will immediately receive a task ID while the task is queued for asynchronous execution in the background. The final result is sent via a callback notification, or you can poll the task status by querying the dynamic image task details.

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

ice:SubmitDynamicImageJob

*All Resource

*

None None

Request parameters

Parameter

Type

Required

Description

Example

Name

string

No

The job name.

SampleJob

Input

object

Yes

The job input.

Type

string

Yes

The type of the job input. Valid values:

  • OSS: An Object Storage Service (OSS) file URL.

  • Media: A media asset ID.

Valid values:

  • Media :

    A media asset ID.

  • OSS :

    An OSS URL.

OSS

Media

string

Yes

The input media resource.

  • If Type is set to OSS, specify the OSS URL of the input file.

  • If Type is set to Media, specify the media asset ID.

An OSS URL must be in one of the following formats:

  1. oss://bucket/object

  2. http(s)://bucket.oss-[RegionId].aliyuncs.com/object

In these formats, bucket is the name of an OSS bucket in the same region as the current project, and object is the file path.

Note

The specified OSS bucket must be registered in IMS storage management.

oss://bucket/object.mp4

Output

object

Yes

The job output.

Type

string

Yes

The type of the job output. Valid values:

  • OSS: The output is an OSS file.

  • Media: The output is a new media asset.

Valid values:

  • Media :

    A new media asset is created.

  • OSS :

    An OSS file.

Media

Media

string

Yes

The destination OSS URL for the output file. This parameter is required when Type is set to OSS. The URL must be in one of the following formats:

  • oss://bucket/object

  • http(s)://bucket.oss-[regionId].aliyuncs.com/object

In these formats, bucket is the name of an OSS bucket in the same region as the current project, and object is the file path.

Note

The specified OSS bucket must be registered in IMS storage management.

****96e8864746a0b6f3****

TemplateConfig

object

Yes

The snapshot template configuration.

TemplateId

string

Yes

The template ID.

****96e8864746a0b6f3****

OverwriteParams

object

No

The overwrite parameters.

Format

string

No

The animated image format. Valid values:

  • gif

  • webp

Valid values:

  • gif :

    gif

  • webp :

    webp

gif

Width

integer

No

The width of the output animated image. Valid range: [128, 4096].

1024

Height

integer

No

The height of the output animated image. Valid range: [128, 4096].

720

Fps

integer

No

The frame rate. Valid range: [1, 60].

15

ScanMode

string

No

The scan mode. Valid values:

  • interlaced: Interlaced scanning.

  • progressive: Progressive scanning. This is the default value.

Valid values:

  • progressive :

    Progressive scanning.

  • interlaced :

    Interlaced scanning.

progressive

LongShortMode

boolean

No

Specifies whether to enable adaptive orientation based on the long and short edges of the video. Valid values:

  • true: Enables adaptive orientation.

  • false: Disables adaptive orientation.

Default value: true.

Note

When enabled, this mode sets the output width to the source video's long edge and the output height to its short edge. For a portrait video, its height is treated as the long edge and its width as the short edge.

Valid values:

  • true :

    true

  • false :

    false

false

TimeSpan

object

No

Specifies the time range of the video to process for the animated image.

Seek

string

No

The start time of the video segment to be processed.

  • Format: hh:mm:ss[.SSS] or sssss[.SSS].

  • Valid range: [00:00:00.000,23:59:59.999] or [0.000,86399.999].

01:59:59.999 或 32000.23

Duration

string

No

The duration of the video segment to be processed.

  • Format: hh:mm:ss[.SSS] or sssss[.SSS].

  • Valid range: [00:00:00.000,23:59:59.999] or [0.000,86399.999].

01:59:59.999 或 32000.23

End

string

No

The end time of the video segment to be processed. If this parameter is set, the Duration parameter is ignored.

  • Format: hh:mm:ss[.SSS] or sssss[.SSS].

  • Valid range: [00:00:00.000,23:59:59.999] or [0.000,86399.999].

01:59:59.999 或 32000.23

ScheduleConfig

object

No

The scheduling configuration.

PipelineId

string

No

The pipeline ID.

****96e8864746a0b6f3****

Priority

integer

No

The priority of the job. Valid range: [1, 10]. A higher value indicates a higher priority. Default value: 6.

6

UserData

string

No

The user-defined data.

{"SampleKey": "SampleValue"}

Response elements

Element

Type

Description

Example

object

PlainResponse

RequestId

string

The ID of the request.

******11-DB8D-4A9A-875B-275798******

JobId

string

The ID of the job.

****20b48fb04483915d4f2cd8ac****

Examples

Success response

JSON format

{
  "RequestId": "******11-DB8D-4A9A-875B-275798******",
  "JobId": "****20b48fb04483915d4f2cd8ac****"
}

Error codes

See Error Codes for a complete list.

Release notes

See Release Notes for a complete list.