All models

Grok Imagine Image Quality

xai/grok-imagine-image-quality
xAI Image GenerationImage EditingMultimodalText RenderingHigh Quality

xAI's higher-fidelity text-to-image model optimized for sharper details, more accurate compositions, and stronger text rendering. Supports image editing via reference images and masks. Trades speed for quality compared to grok-imagine-image. Default output at 2k resolution.

Quick start

# Inspect the price — a plain request returns the 402 challenge:
curl -i https://api.glianalabs.com/v1/infer \
  -H "content-type: application/json" \
  -d '{
    "model": "xai/grok-imagine-image-quality",
    "image": <object>,
    "prompt": <string>
  }'

# Pay + run in one step with the mppx CLI (create a wallet: npx mppx account create):
npx mppx https://api.glianalabs.com/v1/infer \
  -J '{"model": "xai/grok-imagine-image-quality", "image": "<object>", "prompt": "<string>"}'

Examples

example
example
example
example
example

Parameters

Input
aspect_ratio string
image object
images array
mask object
n integer
prompt string required
quality string
resolution string
response_format string
user string
Output
image: Generated image. Either a base64 data URI (`data:image/png;base64,...`) or an `https://` URL, depending on the upstream `response_format` (defaults to base64).