Skip to main content
POST

Authorizations

string
required
All endpoints require Bearer Token authentication.Visit the API Key management page to get the API key, and add it to the request header:

Body

string
required
Model name, fixed value: "grok_imagine_2_0_ext".
object
required
Model parameter object.
string
required
Caller-defined custom task ID, used for idempotent submission and result querying.
  • 1-64 characters in length
  • Only letters, numbers, underscores, and hyphens are supported
  • Cannot be reused under the same API Key
This model only supports text-to-image. Do not pass image_url, resolution, quality, size, or output format parameters.

Response

string
Caller task ID, which can be used to query task status and results.
string
Initial status, typically "pending".
number
Estimated credit consumption for this task.
string
Task creation time, in ISO 8601 format.

Query Results

After successful submission, call Get Task Status and query using the same out_task_id. After the task is completed, the image results are located in data.output.