> ## 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.

# Minimax Hailuo-02

Minimax Hailuo-02 是一款支持文本生成视频和图片生成视频的 AI 视频生成模型。它可以生成 6 秒的 768P 或 1080P 分辨率视频，以及 10 秒的 768P 分辨率视频。

<Tip>
  这是一个**异步**API，只会返回异步任务的 task\_id。您应该使用该 task\_id 请求 [查询任务结果 API](/docs/models/reference-get-async-task-result) 来检索视频生成结果。
</Tip>

## 请求头

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

<ParamField header="Authorization" type="string" required={true}>
  Bearer 身份验证格式: Bearer \{\{API 秘钥}}。
</ParamField>

## 请求体

<ParamField body="prompt" type="string" required={true}>
  指导生成所需的提示词文本。

  范围: `1 <= x <= 2000`。
</ParamField>

<ParamField body="image" type="string" required={false}>
  用于视频生成的首帧图片。支持公网 URL 或 Base64 编码（如 `data:image/jpeg;base64,...`）。
</ParamField>

<ParamField body="end_image" type="string" required={false}>
  用于视频生成的结束帧图片。支持公网 URL 或 Base64 编码（如 `data:image/jpeg;base64,...`）。
</ParamField>

<ParamField body="duration" type="integer" required={false}>
  生成视频的时长（秒）。默认值：`6`<br />
  可选值：`6`、`10`
</ParamField>

<ParamField body="resolution" type="string" required={false}>
  生成视频的分辨率。默认值：`768P`

  * 6 秒视频支持：`768P`、`1080P`
  * 10 秒视频仅支持：`768P`
</ParamField>

<ParamField body="enable_prompt_expansion" type="boolean" required={false}>
  是否启用提示词优化。

  默认值: `true`。
</ParamField>

<ParamField body="fast_pretreatment" type="boolean" required={false} default={false}>
  是否缩短提示词优化的耗时。

  默认值: `false`。
</ParamField>

## 响应信息

<ResponseField name="task_id" type="string" required={true}>
  异步任务的 task\_id。您应该使用该 task\_id 请求 [查询任务结果 API](/docs/models/reference-get-async-task-result) 以获取生成结果
</ResponseField>
