Overview
Create dynamic product showcase videos that pair a product image with an AI avatar or custom background scene.
Primary Endpoint
POST
/api/v1/productAvatar/startGenerate product avatar with AI (Async)
Request Parameters
| Name | Type | Required | Description |
|---|---|---|---|
| name | string | No | Name for the product avatar generation task (optional) |
| image_urls | array<string> | Yes | Array of image URLs - [0] product image, [1] person image |
| product_rect | object | Yes | Product positioning and transformation parameters |
| prompt | string | No | Additional prompt for AI generation (optional) |
| timeout | number | No | Processing timeout in seconds |
| webhook_url | string | No | HTTPS URL to receive task.completed / task.failed notifications. Best-effort delivery, single attempt, no retries; clients should treat the detail API as the source of truth. |
| webhook_token | string | No | Optional plaintext token returned in the X-A2e-Webhook-Token header so receivers can verify the request originated from a2e. |
Request Example
curl -X POST "https://www.a2e.com.cn/api/v1/productAvatar/start" \
-H "Authorization: Bearer YOUR_API_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"name": "My Product Avatar",
"image_urls": [
"https://example.com/product.jpg",
"https://example.com/person.jpg"
],
"product_rect": {},
"prompt": "Professional product showcase",
"timeout": 120,
"webhook_url": "https://your-server.example.com/a2e/webhook",
"webhook_token": "a-shared-secret"
}'Related Endpoints
POST
/api/v1/productAvatar/startGenerate product avatar with AI (Async)
GET
/api/v1/productAvatar/allRecordsList all product avatar tasks
POST
/api/v1/productAvatar/batchDetailBatch query task details
GET
/api/v1/productAvatar/{_id}Query task status and get result
DELETE
/api/v1/productAvatar/{_id}Delete a product avatar task
Responses
200
Product avatar generation started successfully
400
Bad Request - Invalid parameters or missing required fields
401
Unauthorized - Invalid or missing bearer token