XAGrok Imagine Image 2.0
xAI · Image · about $0.055 a request · 11 routes
Grok Imagine Image 2.0 is an image generation and editing model from xAI. It is suited for creating images from text prompts and editing images from references, with low and...
Model ID x-ai/grok-imagine-image-2.0
Quick try
Quickstart · API, SDK & MCP
curl https://gizstack.com/v1/generations \
-H "Authorization: Bearer $GIZSTACK_API_KEY" \
-H "Content-Type: application/json" \
-d '{"model": "x-ai/grok-imagine-image-2.0", "prompt": "A cinematic shot of a sunlit studio", "wait": 30}'from openai import OpenAI
client = OpenAI(base_url="https://gizstack.com/v1", api_key="$GIZSTACK_API_KEY")
res = client.images.generate(model="x-ai/grok-imagine-image-2.0", prompt="A sunlit studio")
print(res.data[0].url)claude mcp add --transport http gizstack https://gizstack.com/v1/mcp \
--header "Authorization: Bearer $GIZSTACK_API_KEY"Request fields
| Field | Values | Default |
|---|---|---|
| prompt | long | |
| outputFormat | png, jpeg, webp, JPG, PNG, WEBP | JPG |
| resolution | 1K, 2K, 1k, 2k, 4k | 1k |
| aspectRatio | 1:1, 3:4, 4:3, 9:16, 16:9, 2:3, 3:2, 9:19.5, 19.5:9, 9:20, 20:9, 1:2, 2:1, auto, 21:9, 5:2 | auto |
| quality | low, medium, auto, high | low |
| numberResults | 1 | 1 |
| inputReferences | files | |
| size | auto, 1024x1024, 1536x1024, 1024x1536, 2048x2048, 2048x1152, 1152x2048, 1:1, 2:3, 3:2, 3:4, 4:3, 9:16, 16:9, 1024x1792, 1792x1024, 720x1280, 1280x720, 1:2, 2:1, 4:5 | 1024x1024 |
| image | files | |
| images | files | |
| width | number | 1024 |
| height | number | 1024 |
| outputQuality | number | |
| format | JPG, PNG, WEBP | JPG |