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

# happyhorse-1.0-video-edit

> 提交视频编辑任务（视频 + 参考图）。**必须使用** native 格式（`input.media[]` 数组）， 不支持顶层简化写法。立即返回 `task_id`。


<script src="/feedback.js" />


## OpenAPI

````yaml api-reference/model-api/alibaba/openapi/happyhorse-1.0-video-edit/openapi.yaml POST /v1/video/generations
openapi: 3.1.0
info:
  title: HappyHorse 1.0 Video Edit
  description: 通过 Anyfast API 使用阿里 DashScope HappyHorse 1.0 视频编辑模型
  version: 1.0.0
servers:
  - url: https://www.anyfast.com.cn
security:
  - bearerAuth: []
paths:
  /v1/video/generations:
    post:
      summary: 创建视频编辑任务
      description: >
        提交视频编辑任务（视频 + 参考图）。**必须使用** native 格式（`input.media[]` 数组），
        不支持顶层简化写法。立即返回 `task_id`。
      operationId: createHappyhorse10VideoEdit
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              required:
                - model
                - input
              properties:
                model:
                  type: string
                  enum:
                    - happyhorse-1.0-video-edit
                  description: 模型 ID。
                  example: happyhorse-1.0-video-edit
                input:
                  type: object
                  required:
                    - prompt
                    - media
                  properties:
                    prompt:
                      type: string
                      description: 编辑描述文本。
                      example: 让视频中的角色穿上图片中的条纹毛衣
                    media:
                      type: array
                      minItems: 2
                      maxItems: 2
                      description: 恰好 2 个元素：1 个视频 + 1 个参考图。
                      items:
                        type: object
                        required:
                          - type
                          - url
                        properties:
                          type:
                            type: string
                            enum:
                              - video
                              - reference_image
                            description: 媒体类型。
                          url:
                            type: string
                            description: 视频或参考图的公开 URL。
                      example:
                        - type: video
                          url: https://example.com/source.mp4
                        - type: reference_image
                          url: https://example.com/cloth.webp
                parameters:
                  type: object
                  description: 生成参数（DashScope 原生风格）。
                  properties:
                    resolution:
                      type: string
                      enum:
                        - 720P
                        - 1080P
                      default: 1080P
                      example: 720P
                    watermark:
                      type: boolean
                      default: true
                      example: false
                    seed:
                      type: integer
                      minimum: 0
                      maximum: 2147483647
      responses:
        '200':
          description: 任务创建成功
          content:
            application/json:
              schema:
                type: object
                properties:
                  id:
                    type: string
                    example: asyntask_jwgfhsG0m2aDjLmiiELRf74eoWmss6ya
                  task_id:
                    type: string
                    example: asyntask_jwgfhsG0m2aDjLmiiELRf74eoWmss6ya
                  object:
                    type: string
                    example: video
                  model:
                    type: string
                    example: happyhorse-1.0-video-edit
                  status:
                    type: string
                    example: queued
                  progress:
                    type: integer
                    example: 0
                  created_at:
                    type: integer
                    example: 1777343862
        '400':
          description: 请求参数错误
        '401':
          description: 未授权
        '429':
          description: 频率限制
components:
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer

````