Skip to content

Ideogram V3 混合 ​

接口 ​

POST /images/generations

完整 URL: https://modelfold.ai/v1/images/generations

鉴权:所有请求都需要 Authorization: Bearer <API_KEY> 请求头。

模型参数直接放在 JSON 请求体中,不要套 input。请求等待生成完成后返回 data[].url;支持的媒体模型也可使用 异步创建、轮询及回调。示例素材地址须替换为自己的公开可访问文件。计费及错误说明见 API 网关。

图像重绘任务的输入参数。

请求参数 ​

请求体 (application/json) ​

参数类型必填说明
modelstring是用于生成任务的模型名称。必填字段。
- 该端点必须使用 ideogram/v3-remix 模型 默认值:"ideogram/v3-remix"。 可选值:ideogram/v3-remix。 示例:ideogram/v3-remix。
expand_promptboolean否是否在生成请求中启用 MagicPrompt。
- 布尔值:true / false 示例:true。
image_sizestring否生成图像的分辨率。
- square: 方图
- square_hd: 高清方图
- portrait_4_3: 竖图 3:4
- portrait_16_9: 竖图 9:16
- landscape_4_3: 横图 4:3
- landscape_16_9: 横图 16:9 可选值:square / square_hd / portrait_4_3 / portrait_16_9 / landscape_4_3 / landscape_16_9。 示例:square_hd。
image_urlstring是用于重绘的图像 URL。
- 请提供上传后文件的 URL,而非文件内容
- 支持类型:image/jpeg、image/png、image/webp
- 最大文件大小:10.0MB 示例:https://file.aiquickdraw.com/custom-page/akr/section-images/17550782013854ykfihxv.webp。
negative_promptstring否描述图像中需要排除的内容。若正向提示词与负向提示词冲突,以正向提示词为准。最大长度:5000 字符。 maxLength: 5000.
promptstring是本站网关要求传入 prompt,最长 2000 字。用于重绘图像的提示词(最大长度:5000 字符)。 maxLength: 2000. 示例:把这个立方体改成一个球体。
rendering_speedstring否生成时使用的渲染速度。
- TURBO: 极速
- BALANCED: 均衡
- QUALITY: 高质量 可选值:TURBO / BALANCED / QUALITY。 示例:BALANCED。
seedinteger否随机数生成器的种子值。
strengthnumber否输入图像在重绘中的影响强度。
- 最小值:0.01
- 最大值:1
- 步长:0.01 minimum: 0.01. maximum: 1. 示例:0.8。
stylestring否生成时使用的风格类型。
- AUTO: 自动
- GENERAL: 通用
- REALISTIC: 写实
- DESIGN: 设计 可选值:AUTO / GENERAL / REALISTIC / DESIGN。 示例:AUTO。

请求示例 ​

bash
curl -X POST "https://modelfold.ai/v1/images/generations" \
  -H "Authorization: Bearer $MODELFOLD_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
  "model": "ideogram/v3-remix",
  "image_url": "https://file.aiquickdraw.com/custom-page/akr/section-images/17550782013854ykfihxv.webp",
  "prompt": "把这个立方体改成一个球体"
}'
json
{
  "model": "ideogram/v3-remix",
  "image_url": "https://file.aiquickdraw.com/custom-page/akr/section-images/17550782013854ykfihxv.webp",
  "prompt": "把这个立方体改成一个球体"
}

响应 ​

200 — 生成完成。usage 返回实际计费明细;结果地址仅作结构示例。 ​

json
{
  "ok": true,
  "created": 1792134000,
  "data": [
    {
      "url": "https://modelfold.ai/uploads/outputs/result.png"
    }
  ],
  "usage": {}
}

ModelFold — 一个 API,接入所有主流 AI 模型。