Call it
curl https://api.peume.com/v1/call/photo-to-talking-video \
-H "Authorization: Bearer $PEUME_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"input": {
"model": "heygen-avatar-6",
"audio": "your audio",
"resolution": "1080p",
"reference_images": []
}
}'const res = await fetch("https://api.peume.com/v1/call/photo-to-talking-video", {
method: "POST",
headers: {
Authorization: `Bearer ${process.env.PEUME_API_KEY}`,
"Content-Type": "application/json",
},
body: JSON.stringify({
"input": {
"model": "heygen-avatar-6",
"audio": "your audio",
"resolution": "1080p",
"reference_images": []
}
}),
});
const { output, cost_usd } = await res.json();import os, requests
res = requests.post(
"https://api.peume.com/v1/call/photo-to-talking-video",
headers={"Authorization": f"Bearer {os.environ['PEUME_API_KEY']}"},
json={
"input": {
"model": "heygen-avatar-6",
"audio": "your audio",
"resolution": "1080p",
"reference_images": []
}
},
)
print(res.json()["output"])Answer: {"id": "run_…", "status": "completed", "cost_usd": …, "output": {…}}. Long jobs answer 202 with a run id to read later. From an AI agent, connect the MCP server and ask for this by name: photo-to-talking-video.
Parameters
modelRequiredstringheygen-avatar-6, or heygen-avatar-6-turbo at a lower price. Both take the same inputs. Sets the per-second price together with resolution.
heygen-avatar-6 · heygen-avatar-6-turbo
audioRequiredobjectThe speech the avatar performs: { "type": "url", "url": "" } — WAV or MP3, 1 second to 5 minutes, at most 32 MB. The video runs the length of the audio.
resolutionRequiredstringOutput resolution: 1080p (short edge 1080 px) or 2k (short edge 1620 px). Sets the per-second price together with model.
1080p · 2k
motion_promptstringDirection for the take in plain language: gestures, expression, posture and camera. Up to 1,200 characters. Takes precedence over motion_expressiveness where they overlap.
motion_expressivenessstringdefault, or less for fewer, smaller gestures and calmer expressions. Does not disable motion.
default · less
expected_duration_secondsnumberonly billing hint (NOT sent to): the audio's length in seconds, decimals allowed (pass the duration /text-to-speech returns). Sizes the amount held before the run. At least 120 seconds are held, so it only matters for longer audio. Audio longer than the seconds held is refused at no cost. The run is billed on the real video length.
reference_imagesRequiredarrayExactly one photo or illustration of the character, JPEG or PNG up to 32 MB; the video keeps its proportions: [{ "type": "url", "url": "" }].
