Endpoint
Request Headers
| Parameter | Value | Description |
|---|---|---|
| x-api-key | API Key | Request authorization. Get Token for Bearer alternative. |
| Authorization | Bearer {token} | Optional Bearer token |
Query Parameters
| Parameter | Type | Required | Description |
|---|---|---|---|
| _id | String | true | _id returned from Submit Person Analysis |
Response Attributes
| Parameter | Type | Description |
|---|---|---|
| code | Integer | Business status code (1000 = success) |
| msg | String | Status message |
| data | Object | Same shape as analyze submit response when successful |
| - _id | String | Analysis record id |
| - status | Integer | 1 queue, 2 processing, 3 completed, 4 failed |
| - progress | Number | Approximate 0–100 |
| - analysis_result | Object | null | When status is 3, contains detection output (see below) |
| - error_reason | String | Failure or status text |
| - error_code | Number | Error code if any |
analysis_result (when ready)
| Parameter | Type | Description |
|---|---|---|
| detected_objects | Number | Detected person count (if returned) |
| media | Array | List of detected subjects |
| - obj_id | Number | Zero-based id — use in mappings[].obj_id when creating a task |
| - img_url | String | Preview image URL for that person in the source video |
| - media_type | String | Media type label (e.g. images) |
| video_info | Object | Optional source metadata |
| - width | Number | Frame width (px) |
| - height | Number | Frame height (px) |
| - fps | Number | Frames per second |
| - frame_count | Number | Total frames |
analysis_result may exist for forward compatibility.
Example
Request
Response (analysis completed)
Analysis Status
| Status | Description |
|---|---|
| 1 | In queue — analysis_result may be empty |
| 2 | Processing — keep polling |
| 3 | Completed — use analysis_result.media for obj_id |
| 4 | Failed |
Important Notes
- Poll until
statusis3or4before creating a head swap task (unless your product flow allows otherwise). - Wrong
_idor no team access may yield not-found style errors (e.g.1014/Resource not founddepending on environment). mappings[].img_urlat task creation is your reference face image; it does not have to match the analysis preview URL, but eachobj_idmust match an entry frommedia.