curl examples for GPT Image 2.6: text-to-image, variants, n>1, reference image, polling.
👉 Try GPT Image 2.6 on APIMart
https://gola.apimart.ai/k-7u8Ndb
Each example below is a complete request you can paste into a terminal.
curl -X POST https://api.apimart.ai/v1/images/generations \
-H "Authorization: Bearer $APIMART_API_KEY" -H "Content-Type: application/json" \
-d '{"model":"gpt-image-2.6-flare","prompt":"cinematic close-up of a marble statue","n":1,"size":"1024x1024"}'-d '{"model":"gpt-image-2.6-sunburst","prompt":"...","n":1}'-d '{"model":"gpt-image-2.6-flare","prompt":"...","n":4}'-d '{"model":"gpt-image-2.6-flare","prompt":"same product, studio lighting","reference_image":"https://.../in.jpg","n":1}'curl https://api.apimart.ai/v1/tasks/$TASK_ID -H "Authorization: Bearer $APIMART_API_KEY"curl -s https://api.apimart.ai/v1/tasks/$TASK_ID -H "Authorization: Bearer $APIMART_API_KEY" | jq '.data.cost'- Prompt library: gpt-image-2-6-prompts
- More image models: awesome prompt collections
CC BY 4.0
