POST
/api/v1/imagine2 creditsSynchronousGPT-4o Image
Provider · OpenAIType · T2I / EditModel ID ·
gpt-4o-imageUpstream ID · gpt-4o-imageReverse-engineered ChatGPT image generation (not the official OpenAI API). Same price as GPT-Image-1 but uses the ChatGPT internal pipeline. May have stricter and less predictable content moderation.
Request Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| prompt | string | Required | The text prompt describing the image to generate. |
| model | string | Optional | Set to `gpt-4o-image` to use this model.Default: gpt-4o-image |
| image_url | string | Optional | Reference image URL for image-to-image generation. Optional — omit for pure text-to-image. |
| aspect_ratio | string | Optional | Output aspect ratio. Allowed: 1:1 · 16:9 · 9:16 · 4:3 · 3:4 · 3:2 · 2:3.Default: 1:1 |
| webhook_url | string | Optional | URL where we POST the completed task result. |
| webhook_secret | string | Optional | Sent as x-webhook-secret header in webhook delivery for verification. |
Example Request
cURL
curl -X POST https://api.journeyapi.com/api/v1/imagine \
-H "Authorization: YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "gpt-4o-image",
"prompt": "a whimsical illustration of a cat astronaut floating in space",
"aspect_ratio": "1:1"
}'Response
This model is synchronous — the response includes the finished image_url directly. No polling required.
200 OK
{
"task_id": "550e8400-e29b-41d4-a716-446655440000",
"status": "finished",
"image_url": "https://cdn.example.com/output.png"
}Quirks & Gotchas
This uses the unofficial ChatGPT pipeline, not the official OpenAI API. Content policy enforcement is stricter and more unpredictable than gpt-image-1.
If your prompt gets rejected unexpectedly, try gpt-image-1 instead.