tongflow-router-fal
August 27, 2026 · View on GitHub
A TongFlow API plugin for fal.ai — a generative-media platform hosting 1000+ image / video / audio / 3D models behind a uniform queue API. Each node picks its underlying fal model via a model picker.
Setup
Add FAL_KEY in TongFlow Settings (create one at
fal.ai/dashboard/keys).
| Env | Default | Purpose |
|---|---|---|
FAL_KEY | — | Required. fal API key. |
FAL_TTS_VOICE | — | Default voice id/name for TTS. |
FAL_POLL_TIMEOUT_S | 600 | Max seconds to wait for a generation. |
How it works
Every fal model runs through the same queue transport (POST queue.fal.run/{model} → poll status → fetch result). Only the per-model input
schema differs; this plugin builds the canonical input (prompt, image_url,
image_urls, audio_url, video_url, …) and normalizes the output by shape
(image / video / audio / 3D mesh / text).
Slots
Image: image-gen, image-edit, image-fusion, image-upscale,
image-matting, image-pose, image-normal, image-body-seg.
Video: text-gen-video, image-gen-video, image-image-gen-video
(first+last frame), audio-image-gen-video (talking head),
audio-video-lip-sync, video-upscale.
Audio: transcribe, transcribe-timestamp, text-gen-speech-preset,
text-gen-speech-clone, gen-music, separate-sound.
3D: image-gen-model (image → GLB).
Each slot exposes 1–7 fal endpoints; the first is the default. fal model version numbers churn monthly — verify endpoint ids against fal.ai/models before relying on a specific one.
H3 Max (minimax/h3-max/*) is the default for text-gen-video,
image-gen-video and image-image-gen-video: fal's post-trained MiniMax H3,
768p/480p, 5–15 s, with native synchronized audio in the same pass, and a
5 s 768p clip in under 3 seconds. Note the endpoint id has no fal-ai/
prefix. Its closing-keyframe field is end_image_url where Kling uses
tail_image_url; _FIELD_ALIASES maps that per model. The ABI duration is
forwarded only to endpoints that take an integer duration (_DURATION_MODELS)
— the others keep their own fixed or enum durations.
LLM/VLM text generation is intentionally not exposed (fal only routes those; use a dedicated LLM provider plugin instead).
Licence
See the TongFlow repository.