> ## Documentation Index
> Fetch the complete documentation index at: https://docs.creatify.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Overview

> APIs for creating short-form video ads from a product image by uploading, generating previews, and converting to videos.

<iframe width="100%" height="400" src="https://www.youtube.com/embed/tW6zptYUmko" title="Product Video Demo" frameBorder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture" allowFullScreen style={{ borderRadius: '12px', marginBottom: '24px' }} />

## 🚀 Introduction

With this **Product Video API**, you can transform a product image into a customized short-form video ad. The workflow includes:

* Uploading a product image to create a record and generate a preview image.
* Converting the preview image into a video using a specified record ID.
* Regenerating a new record from an existing preview image or video for further customization.

***

## ⚙️ Quickstart Guide

### ✅ Prerequisites

Before you begin, ensure you have:

* A [Creatify](https://app.creatify.ai) account with **API access**
* Your **API credentials** (see [Quickstart](/quickstart))

***

## 🖼️ Step 1: Upload Product Image and Create Record

Use this endpoint to upload a product image, create a record, and generate a preview image.

### 🎧 Example Response from `POST /api/product_to_videos/gen_image/`

<CodeGroup>
  ```bash Example Request theme={null}
  curl --request POST \
    --url https://api.creatify.ai/api/product_to_videos/gen_image/ \
    --header 'Content-Type: application/json' \
    --header 'X-API-ID: your-api-id' \
    --header 'X-API-KEY: your-api-key' \
    --data '{
      "product_url": "https://m.media-amazon.com/images/I/71xUtGqbKQL._SL1500_.jpg",
      "webhook_url": "https://webhook.example"
    }'
  ```

  ```json Example Response [expandable] theme={null}
  {
    "id": "7e5e8a6f-d0d5-4736-b390-03e696ffc969",
    "type": "product_anyshot",
    "product_url": "https://m.media-amazon.com/images/I/71xUtGqbKQL._SL1500_.jpg",
    "aspect_ratio": "16x9",
    "override_avatar": null,
    "motion_style": "",
    "product_showcase_url": null,
    "image_prompt": null,
    "video_prompt": null,
    "status": "initializing",
    "generated_video_url": null,
    "generated_photo_url": null,
    "created_at": "2025-05-30T06:51:34.826975-07:00",
    "updated_at": "2025-05-30T06:51:34.827001-07:00",
    "regen_source_id": "<string>",
    "regen_type": "<string>",
    "failed_reason": "<string>",
    "webhook_url": "https://webhook.example"
  }
  ```
</CodeGroup>

> ⚠️ Save the `id` — you’ll need it to generate the video or regen the image.

***

### Step 1.1: Check the generating image status.

Use this endpoint to check if the image is generated and retrieve the final output.

<CodeGroup>
  ```bash Example Request theme={null}
  curl --request GET \
    --url https://api.creatify.ai/api/product_to_videos/7e5e8a6f-d0d5-4736-b390-03e696ffc969/ \
    --header 'Content-Type: application/json' \
    --header 'X-API-ID: your-api-id' \
    --header 'X-API-KEY: your-api-key'\
  ```

  ```json Example Response theme={null}
  {
    "id": "7e5e8a6f-d0d5-4736-b390-03e696ffc969",
    "type": "product_anyshot",
    "product_url": "https://m.media-amazon.com/images/I/71xUtGqbKQL._SL1500_.jpg",
    "aspect_ratio": "16x9",
    "override_avatar": null,
    "motion_style": "",
    "product_showcase_url": null,
    "image_prompt": null,
    "video_prompt": null,
    "status": "image_generated",
    "generated_video_url": null,
    "generated_photo_url": "https://creatify-user-uploads.s3.amazonaws.com/",
    "created_at": "2025-05-30T04:11:05.449603-07:00",
    "updated_at": "2025-05-30T04:11:05.751592-07:00",
    "regen_source_id": "<string>",
    "regen_type": "<string>",
    "failed_reason": "<string>",
    "webhook_url": "https://webhook.example"
  }
  ```
</CodeGroup>

> ⏳ ProductToVideo is generating preview image status starts as `initializing`, and the status is `image_generating` when image generating, it’s will return `image_generated` until the image generated successful.

#### 🔄 Webhook Callback Example

If you provide a `webhook_url`, Creatify will notify your backend of the generation result:

```json [expandable] theme={null}
{
  "id": "7e5e8a6f-d0d5-4736-b390-03e696ffc969",
  "type": "product_anyshot",
  "failed_reason": "<string>",
  "regen_source_id": "<string>",
  "regen_type": "<string>",
  "product_url": "https://m.media-amazon.com/images/I/71xUtGqbKQL._SL1500_.jpg",
  "aspect_ratio": "16x9",
  "override_avatar": null,
  "motion_style": "",
  "product_showcase_url": null,
  "image_prompt": null,
  "video_prompt": null,
  "status": "image_generated",
  "generated_video_url": null,
  "generated_photo_url": "https://creatify-user-uploads.s3.amazonaws.com/",
  "created_at": "2025-05-30T04:11:05.449603-07:00",
  "updated_at": "2025-05-30T04:11:05.751592-07:00",
  "webhook_url": "https://webhook.example"
}
```

***

### Step 1.2:(Optional) Regen the image.

Use this endpoint to regen the preview image using a task ID. It will return a new `ProductToVideo` task ID, allowing you to select different tasks for the next step.

<CodeGroup>
  ```bash Example Request theme={null}
  curl --request POST \
    --url https://api.creatify.ai/api/product_to_videos/7e5e8a6f-d0d5-4736-b390-03e696ffc969/regen_image/ \
    --header 'Content-Type: application/json' \
    --header 'X-API-ID: your-api-id' \
    --header 'X-API-KEY: your-api-key'\
    --data '{
      "image_prompt": "update image",
      "webhook_url": "https://webhook.example"
  }'
  ```

  ```json Example Response theme={null}
  {
    "id": "45c9b7ec-f60b-4773-b298-7660328c0fb0",
    "type": "product_anyshot",
    "product_url": "https://m.media-amazon.com/images/I/71xUtGqbKQL._SL1500_.jpg",
    "aspect_ratio": "16x9",
    "override_avatar": null,
    "motion_style": "talking",
    "product_showcase_url": "https://d35ghwdno3nak3.cloudfront.net/",
    "image_prompt": "update image",
    "video_prompt": null,
    "status": "image_generating",
    "generated_video_url": null,
    "generated_photo_url": null,
    "created_at": "2025-05-30T07:04:51.334269-07:00",
    "updated_at": "2025-05-30T07:04:51.363524-07:00",
    "regen_source_id": "<string>",
    "regen_type": "<string>",
    "failed_reason": "<string>",
    "webhook_url": "https://webhook.example"
  }
  ```
</CodeGroup>

> ⏳ This response will keep the same as first step you had invoke `gen_image` to generated image.

#### 🔄 Webhook Callback Example

If you provide a `webhook_url`, Creatify will notify your backend of the generation result:

```json [expandable] theme={null}
{
  "regen_source_id": "7e5e8a6f-d0d5-4736-b390-03e696ffc969",
  "regen_type": "regen_image",
  "failed_reason": "<string>",
  "id": "6754f806-59d6-4c22-85ce-6cc030d86b48",
  "type": "product_anyshot",
  "product_url": "https://m.media-amazon.com/images/I/71xUtGqbKQL._SL1500_.jpg",
  "aspect_ratio": "16x9",
  "override_avatar": null,
  "motion_style": "",
  "product_showcase_url": null,
  "image_prompt": null,
  "video_prompt": null,
  "status": "image_generated",
  "generated_video_url": null,
  "generated_photo_url": "https://creatify-user-uploads.s3.amazonaws.com/",
  "created_at": "2025-05-30T04:11:05.449603-07:00",
  "updated_at": "2025-05-30T04:11:05.751592-07:00",
  "webhook_url": "https://webhook.example"
}
```

***

## 🎞️ Step 2: Generate Video from Preview Image Task.

Use this endpoint to convert the preview image associated with a task ID into a video.

### 🎧 Example Response from `POST /api/product_to_videos/{id}/gen_video/`

<CodeGroup>
  ```bash Example Request theme={null}
  curl --request POST \
    --url https://api.creatify.ai/api/product_to_videos/7e5e8a6f-d0d5-4736-b390-03e696ffc969/gen_video/ \
    --header 'Content-Type: application/json' \
    --header 'X-API-ID: your-api-id' \
    --header 'X-API-KEY: your-api-key'\
    --data '{
      "video_prompt": "product example",
      "webhook_url": "https://webhook.example"
    }'
  ```

  ```json Example Response theme={null}
  {
    "id": "7e5e8a6f-d0d5-4736-b390-03e696ffc969",
    "type": "product_anyshot",
    "product_url": "https://m.media-amazon.com/images/I/71xUtGqbKQL._SL1500_.jpg",
    "aspect_ratio": "16x9",
    "override_avatar": null,
    "motion_style": "talking",
    "product_showcase_url": null,
    "image_prompt": null,
    "video_prompt": "product example",
    "status": "video_generating",
    "generated_video_url": null,
    "generated_photo_url": "https://creatify-user-uploads.s3.amazonaws.com/user/2/2025-05-30/823e2a39.jpg?AWSAccessKeyId=AKIA57I2VJP5NEUPBZBL&Signature=SSxEggaefxbFxFIKDVlo8ObCWJU%3D&Expires=1748617603",
    "created_at": "2025-05-30T07:06:14.981415-07:00",
    "updated_at": "2025-05-30T07:06:43.533566-07:00",
    "regen_source_id": "<string>",
    "regen_type": "<string>",
    "failed_reason": "<string>",
    "webhook_url": "https://webhook.example"
  }
  ```
</CodeGroup>

> ⚠️ Save the `id` — you’ll need it to regen video.

#### 🔄 Webhook Callback Example

If you provide a `webhook_url`, Creatify will notify your backend of the generation result:

```json [expandable] theme={null}
{
  "id": "7e5e8a6f-d0d5-4736-b390-03e696ffc969",
  "type": "product_anyshot",
  "failed_reason": "<string>",
  "regen_source_id": "<string>",
  "regen_type": "<string>",
  "product_url": "https://m.media-amazon.com/images/I/71xUtGqbKQL._SL1500_.jpg",
  "aspect_ratio": "16x9",
  "override_avatar": null,
  "motion_style": "",
  "product_showcase_url": null,
  "image_prompt": null,
  "video_prompt": null,
  "status": "video_generated",
  "generated_video_url": "https://creatify-user-uploads.s3.amazonaws.com/xx.mp4",
  "generated_photo_url": "https://creatify-user-uploads.s3.amazonaws.com/xx.jpg",
  "created_at": "2025-05-30T04:11:05.449603-07:00",
  "updated_at": "2025-05-30T04:11:05.751592-07:00",
  "webhook_url": "https://webhook.example"
}
```

***

### Step 2.1: Check the generating video status.

Use this endpoint to check if the video is generated and retrieve the final output.

<CodeGroup>
  ```bash Example Request theme={null}
  curl --request GET \
    --url https://api.creatify.ai/api/product_to_videos/7e5e8a6f-d0d5-4736-b390-03e696ffc969/ \
    --header 'Content-Type: application/json' \
    --header 'X-API-ID: your-api-id' \
    --header 'X-API-KEY: your-api-key'\
  ```

  ```json Example Response theme={null}
  {
    "id": "7e5e8a6f-d0d5-4736-b390-03e696ffc969",
    "type": "product_anyshot",
    "product_url": "https://m.media-amazon.com/images/I/71xUtGqbKQL._SL1500_.jpg",
    "aspect_ratio": "16x9",
    "override_avatar": null,
    "motion_style": "",
    "product_showcase_url": null,
    "image_prompt": null,
    "video_prompt": null,
    "status": "video_generating",
    "generated_video_url": null,
    "generated_photo_url": "https://creatify-user-uploads.s3.amazonaws.com/",
    "created_at": "2025-05-30T04:11:05.449603-07:00",
    "updated_at": "2025-05-30T04:11:05.751592-07:00",
    "regen_source_id": "<string>",
    "regen_type": "<string>",
    "failed_reason": "<string>",
    "webhook_url": "https://webhook.example"
  }
  ```
</CodeGroup>

> ⏳ ProductToVideo is generating video status starts as `video_generating`, it’s will return `video_generated` until the video generated successful.

> Also can wait the webhook response about this id backing result if you had sent `webhook_url` on API request.

***

### Step 2.2:(Optional) Regenerate the video.

Use this endpoint to regen the video using a task ID. It will return a new `ProductToVideo` task ID.

<CodeGroup>
  ```bash Example Request theme={null}
  curl --request POST \
    --url https://api.creatify.ai/api/product_to_videos/7e5e8a6f-d0d5-4736-b390-03e696ffc969/regen_video/ \
    --header 'Content-Type: application/json' \
    --header 'X-API-ID: your-api-id' \
    --header 'X-API-KEY: your-api-key'\
    --data '{
      "video_prompt": "",
      "webhook_url": "https://webhook.example"
  }'
  ```

  ```json Example Response theme={null}
  {
    "id": "45c9b7ec-f60b-4773-b298-7660328c0fb0",
    "type": "product_anyshot",
    "product_url": "https://m.media-amazon.com/images/I/71xUtGqbKQL._SL1500_.jpg",
    "aspect_ratio": "16x9",
    "override_avatar": null,
    "motion_style": "talking",
    "product_showcase_url": null,
    "image_prompt": null,
    "video_prompt": "",
    "status": "video_generated",
    "generated_video_url": null,
    "generated_photo_url": "https://creatify-user-uploads.s3.amazonaws.com/xx",
    "created_at": "2025-05-30T07:06:14.981415-07:00",
    "updated_at": "2025-05-30T07:06:43.533566-07:00",
    "regen_source_id": "<string>",
    "regen_type": "<string>",
    "failed_reason": "<string>",
    "webhook_url": "https://webhook.example"
  }
  ```
</CodeGroup>

> ⏳ This response will keep the same as first step you had invoke `gen_video` to generated video.

#### 🔄 Webhook Callback Example

If you provide a `webhook_url`, Creatify will notify your backend of the generation result:

```json [expandable] theme={null}
{
  "regen_source_id": "7e5e8a6f-d0d5-4736-b390-03e696ffc969",
  "regen_type": "regen_video",
  "failed_reason": "<string>",
  "id": "6754f806-59d6-4c22-85ce-6cc030d86b49",
  "type": "product_anyshot",
  "product_url": "https://m.media-amazon.com/images/I/71xUtGqbKQL._SL1500_.jpg",
  "aspect_ratio": "16x9",
  "override_avatar": null,
  "motion_style": "",
  "product_showcase_url": null,
  "image_prompt": null,
  "video_prompt": null,
  "status": "video_generated",
  "generated_video_url": null,
  "generated_photo_url": "https://creatify-user-uploads.s3.amazonaws.com/",
  "created_at": "2025-05-30T04:11:05.449603-07:00",
  "updated_at": "2025-05-30T04:11:05.751592-07:00",
  "webhook_url": "https://webhook.example"
}
```

***

## 🎯 Summary

| Step             | Endpoint                                                                                          |
| ---------------- | ------------------------------------------------------------------------------------------------- |
| Generate image   | `POST /api/product_to_videos/gen_image/`                                                          |
| Check Status     | `GET /api/product_to_videos/{id}/`                                                                |
| Generate Video   | `POST /api/product_to_videos/{id}/gen_video/`                                                     |
| Regenerate image | `POST /api/product_to_videos/{id}/regen_image/`                                                   |
| Regenerate video | `POST /api/product_to_videos/{id}/regen_video/`                                                   |
| API Reference    | [Product-to-Video Reference](/api-reference/product_to_video/post-apiproduct_to_videos-gen_image) |

***

## 🤝 Need Help?

If you run into any issues, check out our [API Reference](/api-reference) or contact [api@creatify.ai](mailto:api@creatify.ai).
