Seedance 2.0 API — 即将上线Get early access

GPT-4o 图像 API

利用 GPT-4o 图像生成能力构建文生图、图生图及局部重绘工作流。EvoLink 提供异步路由,返回任务 ID,并交付有时限的图像 URL。
77 (suggested: 2,000)

Upload reference images

Click to upload or drag and drop

Supported formats: JPG, JPEG, PNG, WEBP
Maximum file size: 10MB; Maximum files: 10

Generated image 1

History

最多保留20条

0 运行中 · 0 已完成

您的生成历史将显示在这里

GPT-4o 图像 API:精准的文本视觉与可控的编辑

通过改进的文本渲染和指令遵循能力,创建营销图形、产品图和设计资产。使用蒙版进行精确编辑,通过图生图进行迭代,并选择 1024x1024、1024x1536 或 1536x1024 等尺寸。

GPT-4o 图像 API 功能展示

Pricing

Popular
GPT-4o Image
Image Generation
Price:
$0.0208/ image
(1.5 Credits)

If it's down, we automatically use the next cheapest available—ensuring 99.9% uptime at the best possible price.

利用 GPT-4o 图像 API 可以构建什么?

真实设计中的可读文本

生成海报、菜单、UI 原型和幻灯片,确保文案清晰可读并与布局对齐。

可读文本示例

规模化的产品与品牌图像

创建一致的产品图和生活化场景,然后通过图生图进行快速变体迭代。

品牌图像示例

基于蒙版的针对性编辑

提交底图加透明蒙版,仅替换或精修您需要的区域。

蒙版编辑示例

为什么开发者选择 GPT-4o 图像 API

由 GPT-4o 图像生成驱动的单一生成与编辑端点。异步任务 ID、灵活的尺寸以及参考图引导帮助团队更快交付。

真实资产的文本保真度

GPT-4o 图像生成旨在提高生产级视觉素材的文本渲染和指令遵循能力。

单一 API 中的统一模式

文生图、图生图和图像编辑工作流共享同一个端点和简单的负载结构。

参考图引导

使用上传的图像作为视觉参考,在迭代过程中保持细节和风格对齐。

如何集成 GPT-4o 图像 API

通过异步任务流创建、编辑和获取图像。

1

第 1 步 - 选择模式与尺寸

将模型设置为 `gpt-4o-image`,然后选择 `1:1`、`2:3`、`3:2` 或具体的像素尺寸,如 `1024x1024`、`1024x1536` 和 `1536x1024`。

2

第 2 步 - 提供提示词与输入

发送详细指令。对于编辑任务,请包含底图和蒙版,以便仅更改目标区域。

3

第 3 步 - 轮询任务并下载

接收任务 ID,查询状态并下载结果。图像链接是临时的,请及时保存。

核心 API 能力

由 GPT-4o 图像生成驱动

文本

文本精准渲染

旨在提高图像中文字的可读性并减少拼写错误。

编辑

图生图与编辑

在单一端点中支持文生图、图生图及基于蒙版的编辑。

尺寸

灵活的纵横比

支持 `1:1`、`2:3`、`3:2` 或显式的像素尺寸,如 `1024x1536`。

异步

异步任务工作流

为生成和编辑接收任务 ID,然后轮询完成状态。

控制

参考图引导

使用上传的图像作为参考,引导构图和细节。

限制

提示词长度控制

提示词支持多达 2000 个 Token,用于详细指令。

GPT-4o 图像 API - 常见问题

Everything you need to know about the product and billing.

通过单一端点支持文生图、图生图和图像编辑工作流。
发送底图加一张标记了修改区域的蒙版图;模型将仅编辑该区域。
可以。提供输入图像和提示词,通过图生图生成来保留构图或风格。
支持 `1:1`、`2:3`、`3:2` 或像素尺寸,如 `1024x1024`、`1024x1536` 和 `1536x1024`。
是的。API 返回一个任务 ID,您可以轮询其状态。
生成的图像链接有效期为 24 小时,请及时下载并存储。
提示词支持多达 2000 个 Token。
定价基于用量,并随尺寸和计划而异。请查看您的 EvoLink 控制台获取当前费率。
POST
/v1/images/generations

Generate Image

Create an image generation task using text prompts or reference images. Supports text-to-image, image-to-image, and image editing modes.

Asynchronous processing mode, use the returned task ID to .

Generated image links are valid for 24 hours, please save them promptly.

Request Parameters

modelstringRequiredDefault: gpt-4o-image

Image generation model name.

Examplegpt-4o-image
promptstringRequired

Prompt describing the image to be generated or how to edit the input image.

Notes
  • Limited to 2000 tokens
ExampleA cat playing in the grass
sizestringOptional

Size of the generated image. Supports ratio format and pixel format.

ValueDescription
1:1Square ratio
2:3Portrait ratio
3:2Landscape ratio
1024x1024Square (1024×1024)
1024x1536Portrait (1024×1536)
1536x1024Landscape (1536×1024)
Example1024x1024
nintegerOptional

Number of images to generate.

ValueDescription
1Generate 1 image
2Generate 2 images
4Generate 4 images
Notes
  • Pre-charged based on n value, actual charge based on generated count
Example1
image_urlsarrayOptional

Reference image URL list for image-to-image and image editing functions.

Notes
  • Max 5 images per request
  • Max size: 10MB per image
  • Formats: .jpeg, .jpg, .png, .webp
  • URLs must be directly accessible by the server
Examplehttps://example.com/image1.png
mask_urlstringOptional

Mask image URL for image editing.

Notes
  • Mask and reference image must be PNG format with same dimensions
  • Max size: 4MB
  • Cannot be used when image_urls contains more than 1 image
Examplehttps://example.com/mask.png
callback_urlstringOptional

HTTPS callback address after task completion.

Notes
  • Triggered on completion, failure, or cancellation
  • Sent after billing confirmation
  • HTTPS only, no internal IPs
  • Max length: 2048 chars
  • Timeout: 10s, Max 3 retries
Examplehttps://your-domain.com/webhooks/image-task-completed

Request Example

{
  "model": "gpt-4o-image",
  "prompt": "A beautiful sunset over the ocean with vibrant colors",
  "size": "1024x1024",
  "n": 1
}

Response Example

{
  "created": 1757165031,
  "id": "task-unified-1757165031-uyujaw3d",
  "model": "gpt-4o-image",
  "object": "image.generation.task",
  "progress": 0,
  "status": "pending",
  "task_info": {
    "can_cancel": true,
    "estimated_time": 45
  },
  "type": "image",
  "usage": {
    "billing_rule": "per_call",
    "credits_reserved": 2.5,
    "user_group": "default"
  }
}