GPT Image 2.5 API documentation
Integrate GPT Image 2.5 with your VezAPI key. The operations below share the same authentication and account balance.
https://api.vezapi.comSend Authorization: Bearer YOUR_VEZAPI_KEY. Use a unique Idempotency-Key for each submission; reuse it only when checking the same request.
GPT Image 2.5 Flare - Image To Image
/api/v1/jobs/createTaskModel IDs: gpt-image-2-5-flare-image-to-image
| Parameter | Type | Description & constraints |
|---|---|---|
modelrequired | string | The model name used for generation. This field is required. This endpoint must use the `gpt-image-2-5-flare-image-to-image` model. Values: Default: |
callBackUrloptional | string | Callback URL for task completion notifications. Optional parameter. If provided, the system will send a POST request to this URL when the task completes, whether it succeeds or fails. If omitted, no callback notification will be sent. To ensure callback security, see [Webhook Verification Guide](/common-api/webhook-verification). |
inputrequired | object | Input parameters for the image-to-image task. |
input.promptrequired | string | Text prompts, up to 20,000 characters. |
input.input_urlsoptional | array | Array of input image URLs.
|
input.aspect_ratiooptional | string | The aspect ratio of the generated image is set to auto by default. The 27:16, 16:27, 9:8 and 8:9 aspect ratios support 1K only. 2K and 4K are available for other aspect ratios. Values: |
input.resolutionoptional | string | Image resolution. The background parameter is only available at 1K. Values: |
input.backgroundoptional | string | Image background Note: This parameter is only supported when the resolution is 1K. Values: |
Request example
curl -X POST 'https://api.vezapi.com/api/v1/jobs/createTask' \
-H 'Authorization: Bearer YOUR_VEZAPI_KEY' \
-H 'Idempotency-Key: your-unique-request-id' \
-H 'Content-Type: application/json' \
-d '{
"model": "gpt-image-2-5-flare-image-to-image",
"input": {
"prompt": "Transform this product image into a premium e-commerce poster style.",
"aspect_ratio": "auto",
"resolution": "1K"
}
}'Responses and errors
HTTP 200
Request successful
| Parameter | Type | Description & constraints |
|---|---|---|
codeoptional | integer | Status code of the request. The HTTP status is 200 even when the request fails, so always check this field: 200 means success; any other value means the request failed and msg describes the reason. Common values: 401 invalid or missing API key; 402 insufficient credits; 429 rate limit exceeded; 422 or 500 the request could not be processed (read msg and check your parameters before retrying). Values: |
msgoptional | string | Response message, error description upon failure |
datarequired | object | |
data.taskIdrequired | string | The task ID can be used with the "Get Task Details" endpoint to query the task status. |
GPT Image 2.5 Flare - Text to Image
/api/v1/jobs/createTaskModel IDs: gpt-image-2-5-flare-text-to-image
| Parameter | Type | Description & constraints |
|---|---|---|
modelrequired | string | The model name used for generation. This field is required. This endpoint must use the `gpt-image-2-5-flare-text-to-image` model. Values: Default: |
callBackUrloptional | string | Callback URL for task completion notifications. Optional parameter. If provided, the system will send a POST request to this URL when the task completes, whether it succeeds or fails. If omitted, no callback notification will be sent. To ensure callback security, see [Webhook Verification Guide](/common-api/webhook-verification). |
inputrequired | object | Input parameters for the text-to-image task. |
input.promptrequired | string | Text prompt. Required, maximum 20,000 characters.
|
input.aspect_ratiooptional | string | The aspect ratio of the generated image is set to auto by default. The 27:16, 16:27, 9:8 and 8:9 aspect ratios support 1K only. 2K and 4K are available for other aspect ratios. Values: |
input.resolutionoptional | string | Image resolution. The background parameter is only available at 1K. Values: |
input.backgroundoptional | string | Image background Note: This parameter is only supported when the resolution is 1K. Values: |
Request example
curl -X POST 'https://api.vezapi.com/api/v1/jobs/createTask' \
-H 'Authorization: Bearer YOUR_VEZAPI_KEY' \
-H 'Idempotency-Key: your-unique-request-id' \
-H 'Content-Type: application/json' \
-d '{
"model": "gpt-image-2-5-flare-text-to-image",
"input": {
"prompt": "A cinematic night city poster with neon reflections on a rainy street.",
"aspect_ratio": "auto",
"resolution": "1K"
}
}'Responses and errors
HTTP 200
Request successful
| Parameter | Type | Description & constraints |
|---|---|---|
codeoptional | integer | Status code of the request. The HTTP status is 200 even when the request fails, so always check this field: 200 means success; any other value means the request failed and msg describes the reason. Common values: 401 invalid or missing API key; 402 insufficient credits; 429 rate limit exceeded; 422 or 500 the request could not be processed (read msg and check your parameters before retrying). Values: |
msgoptional | string | Response message, error description upon failure |
datarequired | object | |
data.taskIdrequired | string | The task ID can be used with the "Get Task Details" endpoint to query the task status. |
GPT Image 2.5 Sunburst - Image To Image
/api/v1/jobs/createTaskModel IDs: gpt-image-2-5-sunburst-image-to-image
| Parameter | Type | Description & constraints |
|---|---|---|
modelrequired | string | The model name used for generation. This field is required. This endpoint must use the `gpt-image-2-5-sunburst-image-to-image` model. Values: Default: |
callBackUrloptional | string | Callback URL for task completion notifications. Optional parameter. If provided, the system will send a POST request to this URL when the task completes, whether it succeeds or fails. If omitted, no callback notification will be sent. To ensure callback security, see [Webhook Verification Guide](/common-api/webhook-verification). |
inputrequired | object | Input parameters for the image-to-image task. |
input.promptrequired | string | Text prompts, up to 20,000 characters. |
input.input_urlsoptional | array | Array of input image URLs.
|
input.aspect_ratiooptional | string | The aspect ratio of the generated image is set to auto by default. The 27:16, 16:27, 9:8 and 8:9 aspect ratios support 1K only. 2K and 4K are available for other aspect ratios. Values: |
input.resolutionoptional | string | Image resolution. The background parameter is only available at 1K. Values: |
input.backgroundoptional | string | Image background Note: This parameter is only supported when the resolution is 1K. Values: |
Request example
curl -X POST 'https://api.vezapi.com/api/v1/jobs/createTask' \
-H 'Authorization: Bearer YOUR_VEZAPI_KEY' \
-H 'Idempotency-Key: your-unique-request-id' \
-H 'Content-Type: application/json' \
-d '{
"model": "gpt-image-2-5-sunburst-image-to-image",
"input": {
"prompt": "Transform this product image into a premium e-commerce poster style.",
"aspect_ratio": "auto",
"resolution": "1K"
}
}'Responses and errors
HTTP 200
Request successful
| Parameter | Type | Description & constraints |
|---|---|---|
codeoptional | integer | Status code of the request. The HTTP status is 200 even when the request fails, so always check this field: 200 means success; any other value means the request failed and msg describes the reason. Common values: 401 invalid or missing API key; 402 insufficient credits; 429 rate limit exceeded; 422 or 500 the request could not be processed (read msg and check your parameters before retrying). Values: |
msgoptional | string | Response message, error description upon failure |
datarequired | object | |
data.taskIdrequired | string | The task ID can be used with the "Get Task Details" endpoint to query the task status. |
GPT Image 2.5 Sunburst - Text to Image
/api/v1/jobs/createTaskModel IDs: gpt-image-2-5-sunburst-text-to-image
| Parameter | Type | Description & constraints |
|---|---|---|
modelrequired | string | The model name used for generation. This field is required. This endpoint must use the `gpt-image-2-5-sunburst-text-to-image` model. Values: Default: |
callBackUrloptional | string | Callback URL for task completion notifications. Optional parameter. If provided, the system will send a POST request to this URL when the task completes, whether it succeeds or fails. If omitted, no callback notification will be sent. To ensure callback security, see [Webhook Verification Guide](/common-api/webhook-verification). |
inputrequired | object | Input parameters for the text-to-image task. |
input.promptrequired | string | Text prompt. Required, maximum 20,000 characters.
|
input.aspect_ratiooptional | string | The aspect ratio of the generated image is set to auto by default. The 27:16, 16:27, 9:8 and 8:9 aspect ratios support 1K only. 2K and 4K are available for other aspect ratios. Values: |
input.resolutionoptional | string | Image resolution. The background parameter is only available at 1K. Values: |
input.backgroundoptional | string | Image background Note: This parameter is only supported when the resolution is 1K. Values: |
Request example
curl -X POST 'https://api.vezapi.com/api/v1/jobs/createTask' \
-H 'Authorization: Bearer YOUR_VEZAPI_KEY' \
-H 'Idempotency-Key: your-unique-request-id' \
-H 'Content-Type: application/json' \
-d '{
"model": "gpt-image-2-5-sunburst-text-to-image",
"input": {
"prompt": "A cinematic night city poster with neon reflections on a rainy street.",
"aspect_ratio": "auto",
"resolution": "1K"
}
}'Responses and errors
HTTP 200
Request successful
| Parameter | Type | Description & constraints |
|---|---|---|
codeoptional | integer | Status code of the request. The HTTP status is 200 even when the request fails, so always check this field: 200 means success; any other value means the request failed and msg describes the reason. Common values: 401 invalid or missing API key; 402 insufficient credits; 429 rate limit exceeded; 422 or 500 the request could not be processed (read msg and check your parameters before retrying). Values: |
msgoptional | string | Response message, error description upon failure |
datarequired | object | |
data.taskIdrequired | string | The task ID can be used with the "Get Task Details" endpoint to query the task status. |
Task status and callbacks
For asynchronous tasks, keep the returned taskId. Query GET /api/v1/jobs/recordInfo?taskId=... or provide callBackUrl when creating the task. Only the account that created a task can access it or derive new resources from it.
A timeout can mean the submission was accepted. Inspect the existing request in your dashboard; do not create another task automatically. Callback delivery is retried and may arrive more than once. Deduplicate with X-VezAPI-Event-Id.
Files, logs and billing
Generated media normally follows a 14-day provider lifetime; uploaded files expire after 24 hours. Save the files you need before expiration. VezAPI streams registered files without keeping a permanent media library. Request logs are retained for two calendar months.
Credits are reserved before submission. Final deductions match actual discounted consumption one for one. Unknown usage pauses new paid requests. If available funds cannot cover final usage while protecting other reservations, settlement stays pending until funded; model usage cannot make the wallet negative. Time-based inputs require server-side metadata reads; a failed read prevents submission.