Skip to main content
POST
画像生成を作成して結果を待機

承認

Authorization
string
header
必須

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

ボディ

application/json
model
string
必須
Allowed value: "gpt-image-2"
prompt
string
必須
size
string

Accepts auto, a positive WIDTHxHEIGHT target, or ratio shorthand such as 16:9. Every non-auto target is mapped to the nearest official popular size: 1024x1024, 1536x1024, 1024x1536, 2048x2048, 2048x1152, 3840x2160, or 2160x3840.

:

"auto"

"1024x1024"

"1280x720"

"16:9"

quality
enum<string>
デフォルト:auto

GPT-Image 2 rendering quality.

利用可能なオプション:
auto,
low,
medium,
high
n
integer
デフォルト:1

Number of images to generate. Billing scales with the image count.

必須範囲: 1 <= x <= 10
aspect_ratio
string
非推奨

Deprecated ratio shorthand. The ratio and compatibility tier are mapped to the nearest official popular size.

resolution
enum<string>
非推奨

Deprecated compatibility tier used to form the target size before nearest-official-size mapping.

利用可能なオプション:
1K,
2K,
4K
input_images
string<uri>[]
callback_url
string<uri>

レスポンス

OpenAI 互換の画像生成結果。

created
integer
必須
data
object[]
必須
usage
object