# ProductAI Product Photography (`productai-photo/productai-product-photography`) Actor

Generate on-brand product photos and short videos from your product images. Uses your ProductAI account and credits. Batch listing shots, ads, and lifestyle scenes.

- **URL**: https://apify.com/productai-photo/productai-product-photography.md
- **Developed by:** [ProductAI](https://apify.com/productai-photo) (community)
- **Categories:** AI, E-commerce, Videos
- **Features:** Limited permissions
- **Stats:** 1 total users, 0 monthly users, 0.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

Pay per usage

This Actor is paid per platform usage. The Actor is free to use, and you only pay for the Apify platform usage, which gets cheaper the higher subscription plan you have.

Learn more: https://docs.apify.com/actors/running/actors-in-store.md#pay-per-usage

## What's an Apify Actor?

An Actor is a serverless cloud program that runs on the Apify platform. It has two run modes.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.

Apify vocabulary and the platform model are defined once, in the agent quickstart at https://apify.com/agents.md.

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.

Do not guess an integration path. Every one of them is in the agent quickstart at https://apify.com/agents.md: the Apify MCP server, Agent Skills with the Apify CLI, the JavaScript and Python clients, the REST API, and the account-free path for an agent with no human to sign in. It also carries the rule on stating cost before the first paid run.

For examples already wired to this Actor's own input schema, see the [API](#api) section below.

Each client library has reference documentation the quickstart does not restate: [JavaScript/TypeScript](https://docs.apify.com/api/client/js/docs.md) (`npm install apify-client`) and [Python](https://docs.apify.com/api/client/python/docs.md) (`pip install apify-client`).

# README

Turn product photos into listing images and short product videos with **ProductAI**. Paste a public image link, describe the scene, and this Actor submits the jobs, waits for them, and saves a result row for every shot.

It uses **your** ProductAI account. Generations spend ProductAI credits. This Actor does not include credits of its own.

### What you can make

ProductAI is an AI product-photography service at [productai.photo](https://www.productai.photo). You give it a product photo and a description of the scene. It returns a finished picture, or a short video, with the product still looking like your product.

Teams use it for:

- Marketplace and store listing photos, including a clean studio look or a lifestyle setting
- Ad creatives and social crops (square, portrait, landscape)
- A whole catalog: many SKUs, one scene, or one product in several scenes
- A short clip of a product for the product page

### Get an API key

1. Create an account at [productai.photo](https://www.productai.photo).
2. Open [API Access](https://www.productai.photo/dashboard/api-access) and copy your key.
3. Paste it into **ProductAI API key** on this Actor.

The field is a secret. Apify encrypts it, and this Actor never writes the key to the log or the dataset. Keep the key private. If ProductAI says the key is invalid, create a new one on that same page.

Your product images must be public `http` or `https` links (JPEG, PNG, or WebP, up to 10 MB). ProductAI downloads them itself, so a private, expiring, or localhost link will fail. If a file is not public yet, host it with ProductAI's [upload endpoint](https://www.productai.photo/docs/api/assets) and paste the URL you get back.

### Pricing

**Each generation spends ProductAI credits when the job is submitted**, before the picture is ready. A failed or timed-out job can still have been charged. This Actor does not refund credits. Check the ProductAI dashboard if a submit returns a server error, then decide whether to send that item again.

Apify charges only for the compute time of this run. The run mostly waits on ProductAI, so that part is small next to the credits.

Image credit costs shown in the model menu (from the [ProductAI docs](https://www.productai.photo/docs/api/generate); ProductAI can change them):

| Model | Credits | Notes |
| --- | --- | --- |
| Nano Banana 2 (`nanobanana2`) | 5 | Default. Best balance for most listing photos |
| Nano Banana 2.1 | 5 | Newer Nano Banana 2 |
| Nano Banana Pro | 8 | Highest quality |
| Nano Banana | 3 | Fast previews |
| Seedream 5 Pro / Lite | 8 / 3 | Up to 10 reference images |
| Seedream 4 | 3 | |
| FLUX Kontext Pro / Max | 2 / 3 | One reference image |
| GPT Image 2.6 and Precise | 10 | Can run from a prompt, with no photo |
| GPT Image 2.5, 2, 1.5 | 10 | Older GPT image models, also text-to-image |
| GPT Image High / Medium / Low | 8 / 3 / 2 | One reference. Low is for cheap drafts |

**4K doubles the credit cost** of a Nano Banana model. Other image models ignore the resolution setting.

Video is billed per second ([video pricing](https://www.productai.photo/docs/api/generate-video)):

| Model | Credits per second |
| --- | --- |
| Seedance 480p / 720p / 1080p / 4k | 6 / 12 / 26 / 60 |
| Gemini Omni Flash | 5 (720p) |

A 5 second Seedance clip at 720p is about 60 credits. `auto` duration lets Seedance pick the length (the length named in your prompt, otherwise 5 seconds) and you are billed for that length. The run log prints a rough estimate before it submits anything. It is an estimate, not a quote.

Variants multiply the bill. Two variants of ten products is twenty jobs.

### How a run works

1. The Actor checks the API key with ProductAI.
2. It builds one job per product image, per prompt, per variant. **One job per image URL** is the normal catalog batch. **All URLs as references** sends every link together, for example a front and a side of the same product.
3. It submits at most 15 new jobs per minute, which is ProductAI's limit, and waits until each job finishes or hits **Max wait**.
4. It writes one dataset row per job.

Photos usually finish within a minute. Videos often take a few minutes. For a long batch, raise the run timeout in the Start dialog so Apify does not stop the Actor while it is still waiting.

If ProductAI returns **out of credits** (`OUT_OF_TOKENS`), the Actor stops submitting. Rows already finished stay in the dataset. Later rows are marked skipped and were not sent. Add credits, then run the remaining items.

### Input example

A two-scene batch for one product. Replace the key. The sample image in the form is a demo watch photo; running it spends credits.

```json
{
  "apiKey": "paste-your-productai-api-key",
  "mode": "image",
  "imageUrls": ["https://cdn.example.com/mug.jpg"],
  "prompts": [
    "Product on a clean white studio background with a soft shadow",
    "Lifestyle photo on a sunlit wooden desk"
  ],
  "model": "nanobanana2",
  "aspectRatio": "SQUARE",
  "resolution": "2K",
  "outputFormat": "png",
  "variants": 1
}
```

A five-second video:

```json
{
  "apiKey": "paste-your-productai-api-key",
  "mode": "video",
  "imageUrls": ["https://cdn.example.com/mug.jpg"],
  "prompt": "@Image1 slowly rotating on a marble pedestal, studio lighting",
  "videoModel": "seedance",
  "videoResolution": "720p",
  "videoAspectRatio": "1:1",
  "videoDuration": "5"
}
```

Numeric aspect ratios such as `16:9` and `4:5` are for Nano Banana models. Other image models take Square, Landscape, or Portrait. Gemini Omni video is `16:9` or `9:16` and needs at least one reference image. Seedance can run from a prompt alone.

Leave **Save result files** off unless you want a copy in the run's key-value store. The dataset always keeps the result URL. Use at least 1024 MB of memory when saving files. Files over 100 MB stay as URLs only.

### Output example

One dataset row per job:

```json
{
  "taskIndex": 0,
  "sourceImageUrl": "https://cdn.example.com/mug.jpg",
  "sourceImageUrls": ["https://cdn.example.com/mug.jpg"],
  "prompt": "Product on a clean white studio background with a soft shadow",
  "model": "nanobanana2",
  "mode": "image",
  "variant": 1,
  "jobId": 287344,
  "status": "COMPLETED",
  "resultUrl": "https://example.s3.amazonaws.com/generations/287344/result.png",
  "error": null,
  "aspectRatio": "SQUARE",
  "resolution": "2K",
  "outputFormat": "png",
  "durationSeconds": null,
  "generateAudio": null,
  "storedFileKey": null,
  "storeError": null,
  "submittedAt": "2026-04-01T12:00:00.000Z",
  "finishedAt": "2026-04-01T12:00:28.000Z"
}
```

`resultUrl` is the photo, or the video file when the mode is video. Open **Results** for links and errors, or **Gallery** for a side-by-side preview.

| Status | Meaning |
| --- | --- |
| `COMPLETED` | The file URL is in `resultUrl` |
| `ERROR` | ProductAI marked the job as failed. `error` has the detail when ProductAI sent one |
| `TIMEOUT` | Still running when Max wait ended. `jobId` is set, so you can check it in ProductAI |
| `FAILED` | Rejected before a file came back (bad input, out of credits, or a ProductAI error on submit) |
| `SKIPPED` | Not sent. Usually because an earlier job in this run hit the credit limit |
| `STOPPED` | The Apify run was aborted while this job was in flight |

A JSON summary is saved as `SUMMARY` in the key-value store: how many finished, failed, timed out, or were skipped, and whether credits ran out.

### When something goes wrong

**No API key.** The run finishes successfully and generates nothing. Paste a key from [API Access](https://www.productai.photo/dashboard/api-access) to create photos. This is also how Apify's daily check runs the Actor.

**Invalid API key.** The run stops before spending credits, and the message points at [API Access](https://www.productai.photo/dashboard/api-access). A key that looks encrypted (`ENCRYPTED_VALUE:…`) means a local run could not decrypt the secret. Put the plain key in local input, or run on Apify.

**Out of credits.** ProductAI answers with HTTP 400 and `OUT_OF_TOKENS`. Add credits, then run again. Skipped rows in this run were not submitted.

**The image URL failed.** The link has to be public, under 10 MB, and a JPEG, PNG, or WebP. ProductAI has to be able to download it from the internet.

**Rate limit.** ProductAI allows 15 generation requests per minute per IP. This Actor waits and retries. If it still gets HTTP 429, run again in a minute or lower **Max requests per minute**.

**A job timed out.** Raise **Max wait**. Video needs more time than a photo. The job may still finish in the ProductAI dashboard; the row keeps the job id.

**Max jobs.** If images × prompts × variants is above the cap, the Actor stops before calling ProductAI. Lower the batch or raise **Max jobs**. The default cap is 500.

### Learn more

- [ProductAI](https://www.productai.photo)
- [API overview](https://www.productai.photo/docs/api)
- [Quick start](https://www.productai.photo/docs/quick-start)
- [Generate image](https://www.productai.photo/docs/api/generate)
- [Generate video](https://www.productai.photo/docs/api/generate-video)
- [Jobs](https://www.productai.photo/docs/api/jobs)
- [API Access](https://www.productai.photo/dashboard/api-access)

Precision upscale (a flat 20 credits per image) is a separate ProductAI endpoint. This Actor does not call it.

### For developers

The Actor is TypeScript on the [Apify SDK](https://docs.apify.com/sdk/js). Node.js 22 or newer.

```bash
npm install
npm test
npm run dry-run
npm run build
```

`npm test` checks input parsing, the rate limiter, submit and poll against a fake ProductAI API, and the Apify schema files. `npm run dry-run` runs a four-job batch against that fake and prints the dataset rows. Neither one needs a real key.

To run against ProductAI on your machine, copy `examples/input.json` into the local key-value store, replace the key, and do not commit it:

```bash
npm run build
mkdir -p storage/key_value_stores/default
cp examples/input.json storage/key_value_stores/default/INPUT.json
npm start
```

Or, with the Apify CLI: `apify login`, then `apify run`.

#### Publish to Apify

From this directory, after `apify login`:

```bash
apify push
```

The first push creates the Actor from `.actor/actor.json` (`productai-product-photography`, version `1.1`, build tag `latest`). Later pushes build a new version. Suggested Store title, categories, and keywords are in `STORE_LISTING.md`. Fill those in on the Apify publishing form, set a price (compute only — do not resell ProductAI credits here), add an icon, and run once with your own key before you make it public.

Do not put a real API key in the repo, in the default input, or in the README.

# Actor input Schema

## `apiKey` (type: `string`):

Required for real generations. Create or copy your key at https://www.productai.photo/dashboard/api-access. It is stored encrypted and is never written to the log or the dataset. A run with no key finishes successfully and does not call ProductAI.

## `mode` (type: `string`):

Product photo calls the image API. Product video calls the video API and is billed per second.

## `imageUrls` (type: `array`):

Public http(s) links to product photos (JPEG, PNG, or WebP, max 10 MB each). ProductAI downloads them, so private or localhost links will fail. One link per product is the usual batch. The sample photo is only a demo — running it spends credits. Leave this empty only for a text-to-image model, or for a Seedance video that has no reference frame.

## `imageGrouping` (type: `string`):

One job per image URL shoots every product on its own. All URLs as references sends every link together (front and side of one product, or a style reference). Single-image models accept only one reference.

## `prompt` (type: `string`):

What the shot should look like: surface, background, lighting, and mood. Used for every image unless Prompts is filled in. For Seedance video you can write @Image1 to point at the first reference. Gemini Omni uses \<IMAGE_REF_0>. If you leave the marker out, ProductAI binds the first image for you.

## `prompts` (type: `array`):

Optional list of scenes. When this has any line, it replaces the single scene prompt. Every product is generated once for each prompt, and each of those is a separate billed job.

## `variants` (type: `integer`):

How many generations to request for each image and prompt. Each variant is its own ProductAI job and spends credits when it is submitted. Use 2 or 3 when you want a few takes of the same scene.

## `model` (type: `string`):

Used when Mode is Product photo. Credit costs are ProductAI's and can change. 4K resolution doubles the cost of a Nano Banana model. GPT Image 2.6, 2.5, 2, and 1.5 can run with no product image.

## `aspectRatio` (type: `string`):

Square, Landscape, and Portrait work on every image model. The numeric ratios (16:9, 4:5, and the others) are for Nano Banana models only.

## `resolution` (type: `string`):

Nano Banana models only. 1K, 2K, or 4K. 4K costs twice that model's credits. Other image models ignore this field.

## `outputFormat` (type: `string`):

png keeps sharper edges. jpg is smaller. Applies to product photos.

## `videoModel` (type: `string`):

Used when Mode is Product video. Seedance can run from a prompt alone. Gemini Omni needs 1 to 9 reference images. Price is credits per second of output.

## `videoAspectRatio` (type: `string`):

Seedance: auto, 21:9, 16:9, 4:3, 1:1, 3:4, or 9:16. Gemini Omni: 16:9 or 9:16. If you leave auto and pick Gemini Omni, the Actor uses 16:9.

## `videoResolution` (type: `string`):

Seedance only. Gemini Omni videos are 720p. Credits per second for Seedance: 480p is 6, 720p is 12, 1080p is 26, 4k is 60.

## `videoDuration` (type: `string`):

auto lets Seedance follow the length named in your prompt, or 5 seconds if the prompt names none. You are billed for the length it renders. Or type a whole number: 4–15 for Seedance, 3–10 for Gemini Omni. Gemini Omni does not support auto; the Actor uses 8 seconds in that case.

## `generateAudio` (type: `boolean`):

Seedance only. When on, Seedance adds a soundtrack in the same pass. Gemini Omni ignores this.

## `maxWaitSecs` (type: `integer`):

How long to wait for each job after it is submitted. Photos often finish in under a minute. Videos can take several minutes. If a job is still running when this ends, the dataset row is marked timed out and keeps the job id.

## `pollIntervalSecs` (type: `integer`):

How often to ask ProductAI if a job is done. 3–5 seconds is plenty for photos. 8–15 seconds is plenty for video.

## `maxRequestsPerMinute` (type: `integer`):

Cap on new generation jobs per minute. ProductAI's own limit is 15 per minute per IP, so this cannot go higher. Lower it if you want a gentler batch.

## `maxConcurrentJobs` (type: `integer`):

How many jobs to keep in flight while earlier ones render. New jobs are still limited by Max requests per minute.

## `saveFiles` (type: `boolean`):

Also download each finished file into this run's key-value store (image-{jobId} or video-{jobId}). The dataset always stores the result URL either way. Leave this off for large videos. Turn it on with at least 1024 MB of memory. Files over 100 MB are left as URLs.

## `maxTasks` (type: `integer`):

Safety cap on jobs submitted in one run (images × prompts × variants). The Actor stops before calling ProductAI if the batch is larger, so you do not spend credits by accident.

## Actor input object example

```json
{
  "mode": "image",
  "imageUrls": [
    "https://images.unsplash.com/photo-1523275335684-37898b6baf30?auto=format&fit=crop&w=1200&q=80"
  ],
  "imageGrouping": "each",
  "prompt": "Place the product on a marble table with soft natural lighting and a minimalist background",
  "variants": 1,
  "model": "nanobanana2",
  "aspectRatio": "SQUARE",
  "resolution": "2K",
  "outputFormat": "png",
  "videoModel": "seedance",
  "videoAspectRatio": "auto",
  "videoResolution": "720p",
  "videoDuration": "auto",
  "generateAudio": true,
  "maxWaitSecs": 360,
  "pollIntervalSecs": 5,
  "maxRequestsPerMinute": 15,
  "maxConcurrentJobs": 8,
  "saveFiles": false,
  "maxTasks": 500
}
```

# Actor output Schema

## `results` (type: `string`):

Dataset rows with the source image, prompt, model, job id, status, result URL, and error.

## `gallery` (type: `string`):

The same rows, with source and result shown as images.

## `images` (type: `string`):

Photo files copied into the key-value store when Save result files is on.

## `videos` (type: `string`):

Video files copied into the key-value store when Save result files is on.

## `summary` (type: `string`):

Counts for this run: completed, failed, timed out, skipped, and whether ProductAI ran out of credits.

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {
    "imageUrls": [
        "https://images.unsplash.com/photo-1523275335684-37898b6baf30?auto=format&fit=crop&w=1200&q=80"
    ],
    "prompt": "Place the product on a marble table with soft natural lighting and a minimalist background"
};

// Run the Actor and wait for it to finish
const run = await client.actor("productai-photo/productai-product-photography").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = {
    "imageUrls": ["https://images.unsplash.com/photo-1523275335684-37898b6baf30?auto=format&fit=crop&w=1200&q=80"],
    "prompt": "Place the product on a marble table with soft natural lighting and a minimalist background",
}

# Run the Actor and wait for it to finish
run = client.actor("productai-photo/productai-product-photography").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print(f"💾 Check your data here: https://console.apify.com/storage/datasets/{run.default_dataset_id}")
for item in client.dataset(run.default_dataset_id).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{
  "imageUrls": [
    "https://images.unsplash.com/photo-1523275335684-37898b6baf30?auto=format&fit=crop&w=1200&q=80"
  ],
  "prompt": "Place the product on a marble table with soft natural lighting and a minimalist background"
}' |
apify call productai-photo/productai-product-photography --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,productai-photo/productai-product-photography"
        }
    }
}
```

The hosted server signs you in with OAuth on first connect, so no API token belongs in this config. Clients without OAuth support can send an `Authorization: Bearer <APIFY_API_TOKEN>` header instead, using a token from API & Integrations in Apify Console (https://console.apify.com/settings/integrations).

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/actors/u5BI98Qhd4nvhBFsU/builds/FVkzSU57qNCMwlZYv/openapi.json
