No description available
GPT Image 2 APIActive
AI Code With channel availability
The same model is billed by channel discount. Copy a channel code to set your preference.
Related Models
More models from 图片生成
GPT Image 2 API: price, model ID, and how to call it
Call GPT Image 2 through AI Code With. Use model ID gpt-image-2 with 200K context. list price about $5.00 / $30.00 per 1M tokens before channel discounts. About $0.8000 for 100,000 input / 10,000 output tokens at the cheapest live channel.
Next: Get API key · Image model setup · All model prices · All model prices
Cost calculator
Estimate at the cheapest live channel: $5.00 / $30.00 per 1M tokens. Billed usage follows your prepaid balance.
cURL example
Set model to gpt-image-2. The page slug is only the URL, not the API parameter.
curl https://api.aicodewith.ai/v1/chat/completions \
-H "Content-Type: application/json" \
-H "Authorization: Bearer $AICODEWITH_API_KEY" \
-d '{
"model": "gpt-image-2",
"messages": [
{ "role": "user", "content": "What is the meaning of life?" }
]
}'FAQ
What is the GPT Image 2 model ID?
Send model "gpt-image-2" in the API request. The page path /gpt-image-2 is only the URL, not the model parameter.
How do I call the GPT Image 2 API?
Use one AI Code With API key against https://api.aicodewith.ai/v1/chat/completions, and set model to gpt-image-2. Supported protocols: OpenAI Chat Completions. See Image model setup.
How is GPT Image 2 priced?
GPT Image 2 is list price about $5.00 / $30.00 per 1M tokens before channel discounts. The public page shows available channel discounts; billed usage follows your prepaid balance and the live channel. About $0.8000 for 100,000 input / 10,000 output tokens at the cheapest live channel.
How long is the GPT Image 2 context window?
GPT Image 2 has about 200K input context and up to 65.54K output tokens. Treat that as capacity, not a reason to fill every request.