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

# 图片编辑

> 图片编辑接口。

## 用途

用于基于已有图片执行编辑或重绘。

## 请求头

<ParamField header="Authorization" type="string" default="Bearer YOUR_API_KEY" required>
  Bearer 鉴权请求头。
</ParamField>

## 请求体

<ParamField body="model" type="string" default="gpt-image-1" required>
  图片编辑模型名称。
</ParamField>

<ParamField body="prompt" type="string" default="保留主体，增强画面细节与光影" required>
  编辑指令。
</ParamField>

<ParamField body="image" type="file" required>
  原始图片文件。该接口通常以 `multipart/form-data` 上传。
</ParamField>

<ParamField body="mask" type="file">
  可选，遮罩图片。
</ParamField>

<ParamField body="size" type="string" default="1024x1024">
  可选，输出图片尺寸。
</ParamField>

<ParamField body="n" type="integer" default="1">
  可选，生成图片张数。
</ParamField>

## 响应

<ResponseField name="data" type="object[]">
  编辑后的图片结果。
</ResponseField>
