logo
RunComfy
  • ComfyUI
  • EntraîneurNouveau
  • Modèles
  • API
  • Tarification
discord logo
MODÈLES
Explorer
Tous les modèles
BIBLIOTHÈQUE
Générations
APIS DE MODÈLES
Documentation API
Clés API
COMPTE
Utilisation

Flux 2 Flash : synthèse texte-image réaliste et édition visuelle précise | RunComfy

blackforestlabs/flux-2/flash/text-to-image

Générez des visuels de conception réalistes à partir de texte avec un rendu rapide et des contrôles précis pour l'adhésion, la répétabilité, la taille de l'image et le format de sortie du prompt.

Table des matières

1. Démarrage2. Authentification3. Référence APISoumettre une requêteStatut de la requêteRécupérer les résultatsAnnuler une requête4. Fichiers en entréeFichier hébergé (URL)5. SchémaSchéma d'entréeSchéma de sortie

1. Démarrage

Utilisez l'API RunComfy pour exécuter blackforestlabs/flux-2/flash/text-to-image. Pour les entrées et sorties acceptées, voir le schéma.

curl --request POST \
  --url https://model-api.runcomfy.net/v1/models/blackforestlabs/flux-2/flash/text-to-image \
  --header "Content-Type: application/json" \
  --header "Authorization: Bearer <token>" \
  --data '{
    "prompt": "A photorealistic still life scene featuring a large bundle of fully bloomed, soft yellow-orange English garden roses with lush, layered petals arranged in a clear cylindrical glass vase filled with water. The vase is placed on a slightly wrinkled black cloth-covered table. A human hand with medium skin tone is gently grasping a glossy ceramic yellow cup beside the vase. The background consists of a moody, dimly lit wall with subtle texture and cracks, partially cast in shadow, creating a softly dramatic atmosphere. The lighting is natural and low-key, coming from the left side, casting gentle highlights and shadows across the flowers and vase. The person in the frame is dressed in a black top and is mostly cropped out of the image. Dark, modern aesthetic with warm and muted tones, shallow depth of field. Shot from a close-up, eye-level angle. Style is cinematic and atmospheric, in 8k ultra high-resolution, photorealistic, unreal engine rendering quality."
  }'

2. Authentification

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.

3. Référence API

Soumettre une requête

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/blackforestlabs/flux-2/flash/text-to-image \
  --header "Content-Type: application/json" \
  --header "Authorization: Bearer <token>" \
  --data '{
    "prompt": "A photorealistic still life scene featuring a large bundle of fully bloomed, soft yellow-orange English garden roses with lush, layered petals arranged in a clear cylindrical glass vase filled with water. The vase is placed on a slightly wrinkled black cloth-covered table. A human hand with medium skin tone is gently grasping a glossy ceramic yellow cup beside the vase. The background consists of a moody, dimly lit wall with subtle texture and cracks, partially cast in shadow, creating a softly dramatic atmosphere. The lighting is natural and low-key, coming from the left side, casting gentle highlights and shadows across the flowers and vase. The person in the frame is dressed in a black top and is mostly cropped out of the image. Dark, modern aesthetic with warm and muted tones, shallow depth of field. Shot from a close-up, eye-level angle. Style is cinematic and atmospheric, in 8k ultra high-resolution, photorealistic, unreal engine rendering quality."
  }'

Statut de la requête

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érer les résultats

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>"

Annuler une requête

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>"

4. Fichiers en entrée

Fichier hébergé (URL)

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.

5. Schéma

Schéma d'entrée

{
  "type": "object",
  "title": "Schéma d'entrée",
  "required": [
    "prompt"
  ],
  "properties": {
    "prompt": {
      "title": "Rapide",
      "description": "",
      "type": "string",
      "default": "A photorealistic still life scene featuring a large bundle of fully bloomed, soft yellow-orange English garden roses with lush, layered petals arranged in a clear cylindrical glass vase filled with water. The vase is placed on a slightly wrinkled black cloth-covered table. A human hand with medium skin tone is gently grasping a glossy ceramic yellow cup beside the vase. The background consists of a moody, dimly lit wall with subtle texture and cracks, partially cast in shadow, creating a softly dramatic atmosphere. The lighting is natural and low-key, coming from the left side, casting gentle highlights and shadows across the flowers and vase. The person in the frame is dressed in a black top and is mostly cropped out of the image. Dark, modern aesthetic with warm and muted tones, shallow depth of field. Shot from a close-up, eye-level angle. Style is cinematic and atmospheric, in 8k ultra high-resolution, photorealistic, unreal engine rendering quality."
    },
    "guidance_scale": {
      "title": "Échelle de guidage",
      "description": "Dans quelle mesure le modèle doit-il respecter l'invite.",
      "type": "float",
      "minimum": 0,
      "maximum": 20,
      "default": 2.5
    },
    "seed": {
      "title": "Graine",
      "description": "",
      "type": "integer",
      "default": null
    },
    "image_size": {
      "title": "Taille de l'image",
      "description": "",
      "type": "string",
      "enum": [
        "square_hd",
        "square",
        "portrait_4_3",
        "portrait_16_9",
        "landscape_4_3",
        "landscape_16_9"
      ],
      "default": "landscape_4_3"
    },
    "output_format": {
      "title": "Format de sortie",
      "description": "Le format de l'image générée.",
      "type": "string",
      "enum": [
        "jpeg",
        "png",
        "webp"
      ],
      "default": "png"
    }
  }
}

Schéma de sortie

{
  "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"
        }
      }
    }
  }
}
Suivez-nous
  • LinkedIn
  • Facebook
  • Instagram
  • Twitter
Support
  • Discord
  • Email
  • État du système
  • affilié
Modèles vidéo
  • Wan 2.6 Flash
  • Wan 2.6 Text to Video
  • Hailuo 2.3 Fast Standard
  • Happy Horse 1.1 reference to video
  • Seedance 2.5 Reference to Video
  • Seedance 2.0 Pro
  • Voir tous les modèles →
Modèles d'images
  • Seedream 5.0 Pro Image Edit
  • seedream 4.0
  • Flux 2 Flash Edit
  • Nano Banana Pro
  • Nano Banana 2 Edit
  • GPT Image 2 Image Edit
  • Voir tous les modèles →
Légal
  • Conditions d'utilisation
  • Politique de confidentialité
  • Politique relative aux cookies
RunComfy
Droits d'auteur 2026 RunComfy. Tous droits réservés.

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.