It looks like you may prefer a different language. Switch anytime.

Image OpenAI

GPT Image 2 API

透過 RunAPI 使用 GPT Image 2 API,包含 model skill、統一驗證與按用量計費。

runapi.ai
curl -X POST https://runapi.ai/api/v1/gpt_image_2/text_to_image \
  -H "Authorization: Bearer $RUNAPI_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
  "model": "gpt-image-2",
  "prompt": "Generate a greeting card with '新年快乐 Happy New Year' in decorative calligraphy, gold and red theme."
}'
import { GptImage2Client } from "@runapi.ai/gpt-image-2";

const client = new GptImage2Client();
const result = await client.textToImage.run({
    model: "gpt-image-2",
    prompt: "Generate a greeting card with '新年快乐 Happy New Year' in decorative calligraphy, gold and red theme.",
});
<?php

require __DIR__ . "/vendor/autoload.php";

use RunApi\GptImage2\GptImage2Client;

$client = new GptImage2Client();
$result = $client->textToImage->run([
        'model' => 'gpt-image-2',
        'prompt' => 'Generate a greeting card with \'新年快乐 Happy New Year\' in decorative calligraphy, gold and red theme.',
]);
require "runapi/gpt_image_2"

client = RunApi::GptImage2::Client.new
result = client.text_to_image.run(
    model: "gpt-image-2",
    prompt: "Generate a greeting card with '新年快乐 Happy New Year' in decorative calligraphy, gold and red theme."
)
npx skills add runapi-ai/gpt-image-2 -g
# Claude Code
claude mcp add runapi -s user -- npx -y @runapi.ai/mcp

# Codex
codex plugin install runapi-mcp@agents

# Cursor / Windsurf / VS Code
npx @runapi.ai/mcp init cursor
@runapi.ai/gpt-image-2 v1
OVERVIEW

關於 GPT Image 2

GPT Image 2 is OpenAI's latest image generation model featuring near-perfect multilingual text rendering within generated images. It improves on instruction following and fine-grained visual detail over its predecessor.

供應商
OpenAI
模式
Image
PRICING

收費

失敗的生成不會收費
Text to image
$0.06-$0.16 / image
Output resolution: 1k $0.06
Output resolution: 2k $0.10
Output resolution: 4k $0.16
Edit image
$0.16 / image
規格說明

技術詳情

模型 ID gpt-image-2
供應商 OpenAI
模式 image
任務類型 asynchronous
計費單位 call
API endpoint /api/v1/gpt_image_2/text_to_image
商業授權 是 — 已透過 API 包含
目錄狀態 可正常運作
Agent 整合

透過 Agent 執行 GPT Image 2

運作方式

開始使用 GPT Image 2

  1. 選擇模型

    挑選符合輸出類型、品質門檻與延遲目標的模型與變體。

  2. 設定

    設定 RunAPI key,並在 coding workspace 安裝 model skill。

  3. 開發

    使用 skill 指引,在你的 app 內加入模型功能。

  4. 接收

    透過 task ID 查詢、在支援時串流,或處理 webhook callback。

CONTEXT

GPT Image 2 API 是甚麼?

GPT Image 2 is OpenAI's newest image model, notable for near-perfect multilingual text rendering. Through RunAPI, both text-to-image and image editing endpoints share one key.

供應商
OpenAI
查看全部 →
模式
Image
瀏覽模型 →

為何透過 RunAPI 使用 GPT Image 2 API

一個驗證,對應所有 provider

一組 RunAPI key 即可解鎖整個 catalog。無需分開帳戶,亦無需為每個整合輪換密鑰。

統一定價與計費

按次以 USD 收費,每月結算。失敗的生成不會收費。

內含 schema 的 skill

型別化 schema 與 setup 備註打包在 model skill 內,讓實作從正確契約開始。

GPT Image 2 常見問題

How accurate is the multilingual text rendering?

GPT Image 2 可以渲染多種語言嘅文字——英文同拉丁字母準確率大約 99%,中文、日文、韓文、阿拉伯文等非拉丁字母約 95% 以上。

What is the maximum output resolution?

Up to 4K resolution (in beta); standard output is 2K. Both text-to-image and image editing endpoints support high-resolution output.

What is Thinking mode for image generation?

Thinking mode lets the model reason about composition and layout before generating, improving accuracy for complex multi-element scenes and precise text placement.

How does GPT Image 2 handle text in non-Latin scripts?

It renders CJK characters, Arabic, Cyrillic, and other scripts with near-native accuracy — a significant improvement over prior image generation models.

Can I generate and edit in the same workflow?

Yes — generate from text, then refine with image editing. Both endpoints share the same API shape.

我應該先用邊個版本?

先選最平而且符合你質素要求的版本。大多數團隊會先用快速版本,之後再升級到 pro 用於正式生產。

相似模型

如果你鍾意 GPT Image 2 API,可以試吓呢些

開始用 GPT Image 2 API 開發。

Endpoints

  • text_to_image
  • edit_image

同類別

來自此供應商

文件