Quickstart
Get up and running with Nara Lens Active Speaker Detection.
Step 1: Get Your API Key
Sign up at naralens.com/auth/signup and create an API key from your dashboard.
Step 2: Submit a Video
Send a POST request with your video URL:
Bash
# Submit video for analysis
curl -X POST https://naralens.com/api/vad/analyze \
-H "Authorization: Bearer $NARA_API_KEY" \
-H "Content-Type: application/json" \
-d '{"video_url": "https://example.com/video.mp4"}'
# Response: {"task_id": "abc123", "status": "pending"}Step 3: Poll for Results
Use the task_id from the response to check for results:
Bash
# Poll for results
curl https://naralens.com/api/vad/result/{task_id} \
-H "Authorization: Bearer $NARA_API_KEY"
# Response when complete:
# {
# "task_id": "abc123",
# "status": "completed",
# "video_duration": 30.5,
# "frames": [{"frame": 0, "faces": [...], "active": true}]
# }Step 4: Parse the Response
When processing is complete, you'll receive frame-by-frame analysis:
JSON
{
"task_id": "abc123",
"status": "completed",
"video_duration": 30.5,
"start_time": 1706000000.0,
"end_time": 1706000045.0,
"frames": [
{
"frame": 0,
"faces": [
{
"bbox": [100, 50, 200, 180],
"person_id": 1,
"speaking_score": 0.95,
"active": true
}
]
}
]
}Billing
Credits are charged based on video duration: 1 credit = 1 second of video. For example, a 30-second video costs 30 credits.
Next Steps
- Learn about Understanding Results
- Read Best Practices for optimal results
- Explore the full API Reference