Skip to main content

Documentation Index

Fetch the complete documentation index at: https://docs.akool.com/llms.txt

Use this file to discover all available pages before exploring further.

Endpoint

GET https://openapi.akool.com/api/open/v3/content/image/infobymodelid?image_model_id={{image_model_id}}

Request Headers

ParameterValueDescription
x-api-keyAPI KeyYour API Key used for request authorization. If both Authorization and x-api-key have values, Authorization will be used first and x-api-key will be discarded.
AuthorizationBearer {token}Your API Key used for request authorization.Get Token

Query Parameters

ParameterTypeRequiredDescription
image_model_idStringtrueThe _id returned from the Create By Prompt API or Generate 4K or Variations API

Response Attributes

ParameterTypeDescription
codeIntegerInterface returns business status code (1000:success)
msgStringInterface returns status information
dataObjectResponse data object
- _idStringDocument ID
- create_timeLongCreation timestamp
- uidIntegerUser ID
- typeIntegerType identifier
- image_statusIntegerStatus: 1=queueing, 2=processing, 3=completed, 4=failed
- imageStringImage result URL (available when image_status = 3)
- deduction_creditIntegerCredits deducted
- buttonsArrayAvailable operation buttons (U1-U4 for 4K upscale, V1-V4 for variations)
- used_buttonsArrayAlready used buttons
- upscaled_urlsArrayUpscaled image URLs

Example

Request

curl --location 'https://openapi.akool.com/api/open/v3/content/image/infobymodelid?image_model_id=662a10df4197b3af58532e89' \
--header 'x-api-key: {{API Key}}'

Response

Completed Status (image_status = 3)

{
  "code": 1000,
  "msg": "OK",
  "data": {
    "faceswap_quality": 2,
    "deduction_credit": 2,
    "buttons": [
      "U1", "U2", "U3", "U4",
      "V1", "V2", "V3", "V4"
    ],
    "used_buttons": [],
    "upscaled_urls": [],
    "_id": "662a10df4197b3af58532e89",
    "create_time": 1714032863272,
    "uid": 378337,
    "type": 3,
    "image_status": 3,
    "image": "https://***.cloudfront.net/1714032892336-e0ec9305-e217-4b79-8704-e595a822c12b-8013.png"
  }
}

Image Status

StatusDescription
1In Queue - Your request is waiting to be processed
2Processing - Image is currently being generated
3Success - Image completed, result URL is available in the image field
4Failed - Image generation failed, check your input

Important Notes

  • Use the _id field from the Create By Prompt API or Generate 4K or Variations API response as the image_model_id parameter
  • Poll this endpoint periodically to check the image generation status
  • When image_status is 3 (Success), the image field will contain the URL of the generated image
  • The buttons field lists available operations (U1-U4 for 4K upscale, V1-V4 for variations) - use these with the Generate 4K or Variations API
  • Generated images are valid for 7 days, download and save them promptly
  • If a webhook URL was provided during creation, you will receive a callback when the task completes (no need to poll)