Generate Product Image
FreshPOSTPOST https://api.creatify.ai/api/product_to_videos/{id}/gen_image/Generate an AI product image from a product video task. The generated image can then be used to create a product video.
Path Parameters
| Name | Type | Required | Description |
|---|---|---|---|
id | string | Yes | The product video task ID |
Headers
| Header | Type | Required | Description |
|---|---|---|---|
X-API-ID | string | Yes | Your Creatify API ID |
X-API-KEY | string | Yes | Your Creatify API key |
Example Request
bash
curl -X POST 'https://api.creatify.ai/api/product_to_videos/ptv-001/gen_image/' \
-H 'X-API-ID: your-api-id' \
-H 'X-API-KEY: your-api-key'Response
json
{
"id": "ptv-001",
"status": "processing",
"image_url": null,
"created_at": "2024-01-15T10:30:00Z"
}When processing completes:
json
{
"id": "ptv-001",
"status": "done",
"image_url": "https://cdn.creatify.ai/product/ptv-001-gen.jpg",
"created_at": "2024-01-15T10:30:00Z"
}Status Codes
| Code | Description |
|---|---|
200 | Image generation started |
401 | Unauthorized -- invalid API credentials |
402 | Insufficient credits |
404 | Task not found |
500 | Internal server error |
TIP
Generate the image first, then use gen_video to create a video from that image. You can regenerate the image with regen_image if the first result is not satisfactory.