API Stock
/IMAGE/Grok Imagine/grok-imagine-1.5-image
Image
xAI

Grok Imagine 1.5 Image API

Generate or transform images from a prompt and optional reference image.

  • Text to image
  • Image editing

Starting at

$0.021

per generation

3 parameters · 1 price options

Grok Imagine 1.5 Image playground

Input

Text description for image generation

Reference image URLs for image-to-image mode

Sign in to run

Runs are charged to your balance.

Output

Output will appear here.

Check the price and run the model. Your result will appear here; browser use does not need an API key.

Grok Imagine 1.5 Image API pricing

OptionPrice per generation
Standard$0.021
1curl -X POST https://api.api-stock.com/api/v1/generation/create \
2 -H "Authorization: Bearer $API_STOCK_KEY" \
3 -H "Content-Type: application/json" \
4 -d '{
5 "model": "grok-imagine-1.5-image",
6 "input": {
7 "prompt": "A cinematic shot of a city at dusk",
8 "size": "1:1"
9 }
10 }'

Parameters

NameTypeRequiredDefaultDescription
promptstringYes—Text description for image generation
sizestringNo1:1Image aspect ratioOne of: 1:1, 16:9, 9:16, 3:2, 2:3
urlsstring[]No—Reference image URLs for image-to-image mode

Frequently asked questions

How much does Grok Imagine 1.5 Image cost?

Grok Imagine 1.5 Image starts at $0.021 per generation on API Stock. The final charge depends on the selected settings.

How do I get an API key for Grok Imagine 1.5 Image?

Create an account and API key on API Stock, then fund your balance. The same key works with Grok Imagine 1.5 Image and other catalog models.

How do I call the Grok Imagine 1.5 Image API?

POST to https://api.api-stock.com/api/v1/generation/create with your API key and model "grok-imagine-1.5-image". Use the returned task id for polling or receive a webhook.

What input parameters does Grok Imagine 1.5 Image accept?

Grok Imagine 1.5 Image accepts 3 input parameters, including the required field(s) prompt. See their types, defaults and allowed values above.

What happens if a Grok Imagine 1.5 Image request fails?

API Stock automatically retries the request on a reserve provider. If every provider fails, the charge is refunded to your balance.

Can I use Grok Imagine 1.5 Image with the same API key as other models?

Yes. Use your API Stock API key and balance for Grok Imagine 1.5 Image and other catalog models.

Read next