Utilisez l'API RunComfy pour exécuter kling/kling-3.0/pro/image-to-video. Pour les entrées et sorties acceptées, voir le schéma.
curl --request POST \
--url https://model-api.runcomfy.net/v1/models/kling/kling-3.0/pro/image-to-video \
--header "Content-Type: application/json" \
--header "Authorization: Bearer <token>" \
--data '{
"prompt": "Bring this still photograph to life with premium cinematic motion. The young American couple ride their two chestnut quarter horses side-by-side across the golden Montana plains at sunset — hooves rhythmically stepping forward, kicking up soft golden dust, horse manes and tails flowing in the prairie wind. The man in the cowboy hat and denim shirt glances over and laughs warmly; the woman in the cream cable-knit sweater laughs back, her wavy auburn hair whipping in the breeze. Tall amber prairie grass sways across the foreground in slow waves, distant Rocky Mountain silhouettes shimmer in heat haze, wispy pink-orange clouds drift slowly across the sky, a few birds wheel overhead. The camera follows in a smooth lateral tracking shot, parallax revealing the vastness of the open plains, then gently pushes in to a tighter two-shot of their faces. Natural ambient sound: rhythmic hoofbeats on dirt trail, leather creaking, wind through tall grass, distant meadowlark calls, and a soft acoustic country guitar score. Photoreal motion realism — every horse muscle flexing, hair strand moving, dust particle drifting, fabric folding — golden-hour rim lighting, lens flare, shot on Arri Alexa 35, 85mm anamorphic, shallow depth of field, premium cinematic color grade, Yellowstone-style.",
"start_image_url": "https://playgrounds-storage-public.runcomfy.net/tools/7351/media-files/input.png"
}'Définissez la variable d'environnement YOUR_API_TOKEN avec votre clé API (gestion dans Profil) et incluez à chaque requête un jeton Bearer dans l'en-tête Authorization : Authorization: Bearer $YOUR_API_TOKEN.
Soumettez une tâche de génération asynchrone et recevez immédiatement un request_id ainsi que des URLs pour le statut, les résultats et l'annulation.
curl --request POST \
--url https://model-api.runcomfy.net/v1/models/kling/kling-3.0/pro/image-to-video \
--header "Content-Type: application/json" \
--header "Authorization: Bearer <token>" \
--data '{
"prompt": "Bring this still photograph to life with premium cinematic motion. The young American couple ride their two chestnut quarter horses side-by-side across the golden Montana plains at sunset — hooves rhythmically stepping forward, kicking up soft golden dust, horse manes and tails flowing in the prairie wind. The man in the cowboy hat and denim shirt glances over and laughs warmly; the woman in the cream cable-knit sweater laughs back, her wavy auburn hair whipping in the breeze. Tall amber prairie grass sways across the foreground in slow waves, distant Rocky Mountain silhouettes shimmer in heat haze, wispy pink-orange clouds drift slowly across the sky, a few birds wheel overhead. The camera follows in a smooth lateral tracking shot, parallax revealing the vastness of the open plains, then gently pushes in to a tighter two-shot of their faces. Natural ambient sound: rhythmic hoofbeats on dirt trail, leather creaking, wind through tall grass, distant meadowlark calls, and a soft acoustic country guitar score. Photoreal motion realism — every horse muscle flexing, hair strand moving, dust particle drifting, fabric folding — golden-hour rim lighting, lens flare, shot on Arri Alexa 35, 85mm anamorphic, shallow depth of field, premium cinematic color grade, Yellowstone-style.",
"start_image_url": "https://playgrounds-storage-public.runcomfy.net/tools/7351/media-files/input.png"
}'Récupère l'état actuel pour un request_id (« in_queue », « in_progress », « completed » ou « cancelled »).
curl --request GET \
--url https://model-api.runcomfy.net/v1/requests/{request_id}/status \
--header "Authorization: Bearer <token>"Récupère les sorties finales et métadonnées pour le request_id ; si le travail n'est pas terminé, la réponse indique l'état actuel pour poursuivre le polling.
curl --request GET \
--url https://model-api.runcomfy.net/v1/requests/{request_id}/result \
--header "Authorization: Bearer <token>"Annule un travail en file d'attente via request_id ; les travaux en cours ne peuvent pas être annulés.
curl --request POST \
--url https://model-api.runcomfy.net/v1/requests/{request_id}/cancel \
--header "Authorization: Bearer <token>"Fournissez une URL HTTPS accessible publiquement. L'hôte doit autoriser les récupérations côté serveur (sans login/cookies), sans limitation de débit ni blocage des bots. Recommandé : images ≤ 50 Mo (~4K), vidéos ≤ 100 Mo (~2–5 min en 720p). Préférez des URL stables ou pré-signées pour les actifs privés.
{
"type": "object",
"title": "Schéma d'entrée",
"required": [
"prompt",
"start_image_url"
],
"properties": {
"prompt": {
"title": "Prompt",
"description": "",
"type": "string",
"default": "Bring this still photograph to life with premium cinematic motion. The young American couple ride their two chestnut quarter horses side-by-side across the golden Montana plains at sunset — hooves rhythmically stepping forward, kicking up soft golden dust, horse manes and tails flowing in the prairie wind. The man in the cowboy hat and denim shirt glances over and laughs warmly; the woman in the cream cable-knit sweater laughs back, her wavy auburn hair whipping in the breeze. Tall amber prairie grass sways across the foreground in slow waves, distant Rocky Mountain silhouettes shimmer in heat haze, wispy pink-orange clouds drift slowly across the sky, a few birds wheel overhead. The camera follows in a smooth lateral tracking shot, parallax revealing the vastness of the open plains, then gently pushes in to a tighter two-shot of their faces. Natural ambient sound: rhythmic hoofbeats on dirt trail, leather creaking, wind through tall grass, distant meadowlark calls, and a soft acoustic country guitar score. Photoreal motion realism — every horse muscle flexing, hair strand moving, dust particle drifting, fabric folding — golden-hour rim lighting, lens flare, shot on Arri Alexa 35, 85mm anamorphic, shallow depth of field, premium cinematic color grade, Yellowstone-style."
},
"multi_prompt": {
"title": "Plusieurs segments de prompt",
"description": "Fournissez plusieurs segments de prompt pour les transitions de scène. La somme de toutes les durées des segments doit être égale à la durée totale de la vidéo.",
"type": "array",
"items": {
"type": "object",
"properties": {
"prompt": {
"type": "string",
"format": "str"
},
"duration": {
"type": "integer",
"format": "int_slider_with_range",
"minimum": 3,
"maximum": 15,
"default": 5
}
}
},
"maxItems": 20,
"minItems": 0
},
"start_image_url": {
"title": "Image de départ",
"description": "Image de départ de la vidéo. Prend en charge les formats jpg, jpeg, png, bmp, webp.",
"type": "string",
"default": "https://playgrounds-storage-public.runcomfy.net/tools/7351/media-files/input.png"
},
"end_image_url": {
"title": "Image de fin",
"description": "Image de fin facultative pour des transitions contrôlées entre deux images. Prend en charge les formats jpg, jpeg, png, bmp, webp.",
"type": "string"
},
"duration": {
"title": "Durée",
"description": "Durée totale de la vidéo générée en secondes.",
"type": "integer",
"minimum": 3,
"maximum": 15,
"default": 10
},
"generate_audio": {
"title": "Générer de l'audio",
"description": "Activez cette option pour générer de l'audio pour la vidéo.",
"type": "boolean",
"default": true
},
"elements": {
"title": "Éléments",
"description": "Actifs d'entrée utilisés pour la génération, y compris les images de référence et les segments vidéo.",
"type": "array",
"items": {
"type": "object",
"properties": {
"frontal_image_url": {
"type": "string",
"format": "image_uri",
"description": "Référence d'image frontale pour le sujet."
},
"reference_image_urls": {
"type": "array",
"format": "image_uris",
"items": {
"type": "string",
"format": "image_uri"
},
"description": "URL d’images de référence supplémentaires utilisées pour guider le rendu."
},
"video_url": {
"type": "string",
"format": "video_uri",
"description": "Vidéo source facultative utilisée pour la référence de mouvement."
}
}
},
"minItems": 0,
"maxItems": 3
},
"shot_type": {
"title": "Type de plan",
"description": "Définit la manière dont la prise de vue de la caméra ou le cadrage de la scène est géré.",
"type": "string",
"enum": [
"customize"
],
"default": "customize"
},
"negative_prompt": {
"title": "Negative Prompt",
"description": "",
"type": "string"
},
"cfg_scale": {
"title": "Échelle CFG",
"description": "Échelle CFG sans classificateur contrôlant le respect du prompt.",
"type": "float",
"minimum": 0,
"maximum": 1,
"default": 0.5
}
}
}{
"output": {
"type": "object",
"properties": {
"image": {
"type": "string",
"format": "uri",
"description": "URL d'une seule image"
},
"video": {
"type": "string",
"format": "uri",
"description": "URL d'une seule vidéo"
},
"images": {
"type": "array",
"description": "plusieurs URLs d'images",
"items": {
"type": "string",
"format": "uri"
}
},
"videos": {
"type": "array",
"description": "plusieurs URLs de vidéos",
"items": {
"type": "string",
"format": "uri"
}
}
}
}
}RunComfy est la première ComfyUI plateforme, offrant des ComfyUI en ligne environnement et services, ainsi que des workflows ComfyUI proposant des visuels époustouflants. RunComfy propose également AI Models, permettant aux artistes d'utiliser les derniers outils d'IA pour créer des œuvres d'art incroyables.