Skip to main content
Identify Face is the first step of the Kling lip sync workflow. It analyzes the faces in a video and returns a session_id you must pass to the Advanced Lip Sync endpoint.

Workflow overview

identify-face  →  session_id  →  advanced-lip-sync  →  task_id  →  poll result
The session_id binds the video and its face analysis together. Without it, lip sync generation cannot proceed.

Video requirements

For best results:
  • The video must contain at least one clearly visible human face facing the camera
  • Use a video where the face is well-lit and not heavily occluded
  • The video must be accessible via a public URL, or use a video_id from a previous Kling generation result

Quick example

curl https://www.anyfast.ai/kling/v1/videos/identify-face \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "video_url": "https://example.com/person-speaking.mp4"
  }'

Parameters

ParameterTypeRequiredDescription
video_urlstringOne ofPublic URL of the source video
video_idstringOne ofID of a video generated by Kling

Response

This endpoint is synchronous — the result is returned immediately without polling.
FieldDescription
data.session_idPass this to the lip sync endpoint
data.face_list[]All detected faces in the video
face_list[].face_idIdentifier for each individual face
face_list[].face_rectBounding box {x, y, width, height} in pixels
If the video contains multiple people, face_list will include one entry per detected face.

Next step: Advanced Lip Sync

Use the session_id to generate a lip-synced video.

API Reference

View the interactive API playground for Kling Identify Face.