> ## Documentation Index
> Fetch the complete documentation index at: https://docs.jiekou.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# VIDU Q2 Pro Fast Start and End Frames

Generate a coherent video from the first and last frames (fast mode). Supports two resolutions: 720p and 1080p. Fast mode can significantly reduce generation time and is suitable for scenarios with higher speed requirements.

<Tip>
  This is an **asynchronous** API and will only return the task\_id of the asynchronous task. You should use this task\_id to request the [Get Task Result API](/en/docs/models/reference-get-async-task-result) to retrieve the generation result.
</Tip>

## Request Headers

<ParamField header="Content-Type" type="string" required={true}>
  Enum value: `application/json`
</ParamField>

<ParamField header="Authorization" type="string" required={true}>
  Bearer authentication format: Bearer \{\{API Key}}.
</ParamField>

## Request Body

<ParamField body="bgm" type="boolean" default={false}>
  Whether to add background music to the generated video. true: the system will automatically select suitable music from the preset BGM library and add it; false: no BGM will be added. BGM has no duration limit; the system automatically adapts it to the video duration.
</ParamField>

<ParamField body="seed" type="integer">
  Random seed. When omitted by default or set to 0, a random number will be used instead; if set manually, the specified seed will be used.
</ParamField>

<ParamField body="images" type="string[]" required={true}>
  Image array. The first image is treated as the first-frame image, and the second image is treated as the last-frame image. The model will generate the video using the images passed in this parameter. Two input images are supported. Note 1: The resolutions of the first-frame and last-frame input images must be close; the first-frame image resolution / last-frame image resolution must be between 0.8 and 1.25. Note 2: Supports image Base64 encoding or image URLs (ensure they are accessible). Note 3: Supported image formats are png, jpeg, jpg, and webp. Note 4: Image size must not exceed 50M. Note 5: Base64 encoding must include the appropriate content type string, for example: data:image/png;base64,{base64_encode}

  Array length: 2 - 2
</ParamField>

<ParamField body="is_rec" type="boolean" default={false}>
  Whether to use recommended prompts. true: yes, the system automatically recommends prompts and uses the prompt content to generate the video (each task consumes an additional 10 credits); false: no, generate the video based on the input prompt.
</ParamField>

<ParamField body="prompt" type="string">
  Text prompt, a text description for generating the video. Note 1: The character length cannot exceed 2000 characters. Note 2: If the is\_rec recommended prompt parameter is used, the model will not consider the prompt entered in this parameter.

  Length limit: 0 - 2000
</ParamField>

<ParamField body="wm_url" type="string">
  Watermark content, specified here as an image URL. If not provided, the default watermark is used: content generated by AI.
</ParamField>

<ParamField body="payload" type="string">
  Pass-through parameter. It is not processed in any way and is only used for data transmission. Up to 1048576 characters.

  Length limit: 0 - 1048576
</ParamField>

<ParamField body="duration" type="integer" default={5}>
  Video duration (seconds), supports 1-8 seconds.

  Allowed values: `1`, `2`, `3`, `4`, `5`, `6`, `7`, `8`
</ParamField>

<ParamField body="off_peak" type="boolean" default={false}>
  Off-peak mode. true: generate the video during off-peak hours (consumes fewer credits, generated within 48 hours); false: generate the video immediately. Note: For tasks submitted in off-peak mode, tasks that are not completed will be automatically canceled and credits will be refunded; you can also manually cancel off-peak tasks.
</ParamField>

<ParamField body="meta_data" type="string">
  Metadata identifier, a JSON-format string and pass-through field. You can customize the format or use the example format. When this parameter is empty, the metadata identifier generated by vidu is used by default.
</ParamField>

<ParamField body="watermark" type="boolean" default={false}>
  Whether to add a watermark. No watermark is added by default. You can query the watermarked video content via the watermarked\_url parameter.
</ParamField>

<ParamField body="resolution" type="string" default="720p">
  Output video resolution. Supports 720p and 1080p. The default value is 720p.

  Allowed values: `720p`, `1080p`
</ParamField>

<ParamField body="wm_position" type="integer" default={3}>
  Watermark position, indicating where the watermark appears on the image. 1: top-left; 2: top-right; 3: bottom-right (default); 4: bottom-left

  Allowed values: `1`, `2`, `3`, `4`
</ParamField>

<ParamField body="movement_amplitude" type="string" default="auto">
  Movement amplitude, controlling the motion intensity of objects in the video.

  Allowed values: `auto`, `small`, `medium`, `large`
</ParamField>

## Response Information

<ResponseField name="task_id" type="string" required={true}>
  Use task\_id to request the [Get Task Result API](/en/docs/models/reference-get-async-task-result) to retrieve the generated output.
</ResponseField>

<ResponseField name="provider_request_id" type="string" required={false}>
  Provider request ID (optional)
</ResponseField>
