Auto Video API (workflow)
This API generates a full video automatically from a listing (description + images). The server will:- pick up to 5 images (depending on how many you provide)
- generate a short marketing text per selected image
- generate video clips (one per selected image)
- render the final video
- 1) POST
"/api/video-editor/generate/video/auto": starts a generation and returns anid - 2) GET
"/api/video-editor/generate/video/auto/{id}": polls the status (and triggers next server-side steps)
Authentication
All requests must include:x-api-key: YOUR_API_KEY
1) Start a generation
Headers
Request body
Responses
201 — Started
List of clips/sequences being generated (one per selected image). Each item
contains
id, url, effect, format, category, text, status.400 — Validation error
Returned when the request body is invalid (e.g. emptyimage_urls, invalid URL, description too short, etc.).
401 — Unauthorized
Returned whenx-api-key is missing or invalid.
500 — Server error
Server-side failure.Example (curl)
2) Poll a generation
Headers
Main responses
This endpoint is idempotent and can be polled. It returns a JSON object with astatus field and, depending on the status, additional fields.
200 — status: "GENERATING_VIDEO"
Clips are being generated. Also returns credits and generatedContent.
200 — status: "START_RENDERING_VIDEO"
All sequences are ready; final render starts.
progress: 0
200 — status: "RENDERING_VIDEO"
Final render in progress.
progress: a number you can display as-is.
200 — status: "DONE"
Final video is ready.
url: video URLgeneratedContentcreditsTotal,creditsUsed
200 — status: "PENDING"
Transient state; may be returned if the server needs to re-generate errored sequences.
4xx/5xx
401if API key is missing/invalid404ifidis not found500on server errors
Example (curl)
Webhook (optional)
IfwebhookUrl is provided in the POST, IACrea will call your endpoint when the final video is ready:
- Method:
POST - Header:
Content-Type: application/json - Body:
Integration recommendations
- Polling: call
GET /api/video-editor/generate/video/auto/{id}every 2–5 seconds untilDONE(orERROR). - Timeout: implement a client timeout (e.g. 10–20 minutes) depending on render times.
- Resilience: if you get
"PENDING"after"GENERATING_VIDEO", keep polling; the server may retry failed sequences.
