Call it
curl https://api.peume.com/v1/call/youtube-google-gemini-3-8-flash-video-understanding \
-H "Authorization: Bearer $PEUME_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"input": {
"model": "gemini-3.8-flash",
"contents": [
{
"parts": [
{
"fileData": {
"fileUri": "https://www.youtube.com/watch?v=jNQXAC9IVRw"
}
},
{
"text": "Shot list as JSON: shot, start, end, framing, camera_move, visual, dialogue_sfx."
}
]
}
]
}
}'const res = await fetch("https://api.peume.com/v1/call/youtube-google-gemini-3-8-flash-video-understanding", {
method: "POST",
headers: {
Authorization: `Bearer ${process.env.PEUME_API_KEY}`,
"Content-Type": "application/json",
},
body: JSON.stringify({
"input": {
"model": "gemini-3.8-flash",
"contents": [
{
"parts": [
{
"fileData": {
"fileUri": "https://www.youtube.com/watch?v=jNQXAC9IVRw"
}
},
{
"text": "Shot list as JSON: shot, start, end, framing, camera_move, visual, dialogue_sfx."
}
]
}
]
}
}),
});
const { output, cost_usd } = await res.json();import os, requests
res = requests.post(
"https://api.peume.com/v1/call/youtube-google-gemini-3-8-flash-video-understanding",
headers={"Authorization": f"Bearer {os.environ['PEUME_API_KEY']}"},
json={
"input": {
"model": "gemini-3.8-flash",
"contents": [
{
"parts": [
{
"fileData": {
"fileUri": "https://www.youtube.com/watch?v=jNQXAC9IVRw"
}
},
{
"text": "Shot list as JSON: shot, start, end, framing, camera_move, visual, dialogue_sfx."
}
]
}
]
}
},
)
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: youtube-google-gemini-3-8-flash-video-understanding.
Parameters
modelRequiredstring's key runs only gemini-3.8-flash; your own key can name another model.
Example: gemini-3.8-flash
contentsRequiredarrayOne user turn, video part first, then the text prompt. A video part is {fileData: {mimeType, fileUri}}. fileUri is a public https URL Google fetches (15 MB per file; set mimeType, video/mp4 for an mp4; ` host <file>` prints a URL) or a public YouTube URL (preview; private and unlisted videos are refused; mimeType may be omitted). A file already uploaded with this same key is a File API URI, and a file under 100 MB can be {inlineData: {mimeType, data: <base64>}}. Up to 10 videos. On the video part: videoMetadata {fps, startOffset, endOffset} samples more or fewer frames than 1 a second and
Example: [{"parts":[{"fileData":{"fileUri":"https://www.youtube.com/watch?v=jNQXAC9IVRw"}},{"text":"Shot list as JSON: shot, start, end, framing, camera_m
generationConfigobject