GPT Image 1 Edit
gpt_image_1_edit
High-quality image editing model for generating edited images from input images and text prompts.
Эндпоинты
Заголовок раздела «Эндпоинты»POST /v1/queue/gpt_image_1_edit # Создать задачуGET /v1/queue/gpt_image_1_edit/requests/{request_id}/status # Проверить статусGET /v1/queue/gpt_image_1_edit/requests/{request_id}/response # Получить результатPUT /v1/queue/gpt_image_1_edit/requests/{request_id}/cancel # Отменить задачуПараметры запроса
Заголовок раздела «Параметры запроса»curl --location "https://odirouter.ai/model/v1/queue/gpt_image_1_edit" \ --header "Authorization: Bearer YOUR_API_KEY" \ --header "Content-Type: application/json" \ --data '{ "prompt": "A clean product photo of a red apple on a white table, soft studio lighting.", "images": ["https://example.com/input.png"], "input_fidelity": "low", "n": 1, "size": "1024x1024", "quality": "medium", "background": "auto", "output_format": "jpeg", "output_compression": 90, "moderation": "auto" }'Text description of the desired edited image, with a maximum length of 32000 characters.
Input images for editing.
Mask image for selecting editable regions. Transparent areas are treated as editable. The mask should match the edited image format and dimensions and include an alpha channel. If omitted, the whole image can be edited.
Controls how strongly input image details are preserved during editing.
Options: high, low
Default: low
Number of edited images to generate.
Range: 1 - 10
Default: 1
Output image size.
Options: 1024x1024, 1024x1536, 1536x1024, auto
Default: auto
Image quality level.
Options: low, medium, high, auto
Default: auto
Background transparency setting. Transparent backgrounds require an output format with alpha channel support, such as png or webp.
Options: transparent, opaque, auto
Default: auto
Returned image format.
Options: png, jpeg, webp
Default: png
Output compression level. Only applies when output_format is jpeg or webp. For example, output_compression=50 compresses the output image by 50%.
Range: 0 - 100
Default: 100
Content moderation strictness for GPT Image generation requests.
Options: auto, low
Default: auto
Unique identifier representing the end user.
Параметры ответа
Заголовок раздела «Параметры ответа»{ "request_id": "mmsu_01hxyz...", "response_url": "https://odirouter.ai/model/v1/queue/gpt_image_1_edit/requests/mmsu_01hxyz.../response", "status_url": "https://odirouter.ai/model/v1/queue/gpt_image_1_edit/requests/mmsu_01hxyz.../status", "cancel_url": "https://odirouter.ai/model/v1/queue/gpt_image_1_edit/requests/mmsu_01hxyz.../cancel", "queue_position": 0}| Поле | Тип | Описание |
|---|---|---|
request_id | string | Идентификатор задачи, используемый во всех последующих операциях. |
response_url | string | URL для получения итогового результата. |
status_url | string | URL для проверки статуса задачи. |
cancel_url | string | URL для отмены задачи. |
queue_position | int | Текущая позиция в очереди. |