Grok Imagine Image
Model Overview
Setup your API Key
API Schema
post
Body
modelstring · enumRequiredPossible values:
promptstringRequired
The text prompt describing the content, style, or composition of the image to be generated.
nnumber · min: 1 · max: 10OptionalDefault:
The number of images to generate.
1response_formatstring · enumOptionalDefault:
The format in which the generated images are returned.
urlPossible values: aspect_ratiostring · enumOptionalDefault:
The aspect ratio of the generated image.
16:9Possible values: resolutionstring · enumOptionalDefault:
The resolution of the output image.
2kPossible values: Responses
200Success
application/json
post/v1/images/generations
200Success
Quick Example

"A T-Rex relaxing on a beach, lying on a sun lounger and wearing sunglasses."Last updated
Was this helpful?