Kling 2.6 Image to Video
Endpoint
POST /videos/generations
Full URL: https://modelfold.ai/v1/videos/generations
Authentication: every request must include the
Authorization: Bearer <API_KEY>header.
Send model parameters directly in the JSON body. Do not wrap them in input. This request waits for generation to finish and returns data[].url; supported media models also offer async jobs, polling and callbacks. Replace example media URLs with your own publicly accessible files. See API gateway for billing and errors.
Input parameters for the generation task
Request Parameters
Body (application/json)
| Parameter | Type | Required | Description |
|---|---|---|---|
model | string | Yes | Name of the model used for the generation task. Required field. - This endpoint must use the kling-2.6/image-to-video model Default:"kling-2.6/image-to-video"。 Allowed values:kling-2.6/image-to-video。 Example:kling-2.6/image-to-video。 |
prompt | string | Yes | Prompt required by the ModelFold gateway; at most 2000 characters. Text prompt (max 2,500 characters). maxLength: 2000. Example:In a bright rehearsal room, sunlight streams through the windows, and a standing microphone is placed in the center of the room. [Campus band female lead singer] stands in front of the microphone with her eyes closed, and other members stand around her. [Campus band female lead singer, singing loudly] Lead vocal: "I will do my best to heal you, with all my heart and soul..." The background is a cappella harmonies, and the camera slowly pans around the band members.。 |
image_urls | array<string> | Yes | Image URLs for video generation. (Uploaded file URLs, not file content; supported types: image/jpeg, image/png; maximum file size: 10.0MB) maxItems: 1. |
sound | boolean | Yes | Required. This parameter specifies whether the generated video contains sound (boolean: true/false) Example:false。 |
duration | string | Yes | Required. Video duration (unit: seconds) Allowed values:5 / 10。 Example:5。 |
Request Example
bash
curl -X POST "https://modelfold.ai/v1/videos/generations" \
-H "Authorization: Bearer $MODELFOLD_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "kling-2.6/image-to-video",
"prompt": "In a bright rehearsal room, sunlight streams through the windows, and a standing microphone is placed in the center of the room. [Campus band female lead singer] stands in front of the microphone with her eyes closed, and other members stand around her. [Campus band female lead singer, singing loudly] Lead vocal: \"I will do my best to heal you, with all my heart and soul...\" The background is a cappella harmonies, and the camera slowly pans around the band members.",
"image_urls": [
"https://example.com/reference.png"
],
"sound": false,
"duration": "5"
}'json
{
"model": "kling-2.6/image-to-video",
"prompt": "In a bright rehearsal room, sunlight streams through the windows, and a standing microphone is placed in the center of the room. [Campus band female lead singer] stands in front of the microphone with her eyes closed, and other members stand around her. [Campus band female lead singer, singing loudly] Lead vocal: \"I will do my best to heal you, with all my heart and soul...\" The background is a cappella harmonies, and the camera slowly pans around the band members.",
"image_urls": [
"https://example.com/reference.png"
],
"sound": false,
"duration": "5"
}Response
200 — Generation completed. usage contains actual billing details; result URLs are illustrative.
json
{
"ok": true,
"created": 1792134000,
"data": [
{
"url": "https://modelfold.ai/uploads/outputs/result.mp4"
}
],
"usage": {}
}