Nodes/comfyui-sora-node/Sora Text-To-Video
ComfyUI Node

Sora Text-To-Video

Type a prompt, get a clip — provided you've got the key

By maxczc·Created 9 months ago·Updated 9 months ago· 0
Sora Text-To-Video
    • job_id
    • status
    • result
    promptA cinematic drone shot of waves crashing.
    api_key
    negative_prompt
    duration_seconds5.0
    aspect_ratio16:9
    seed
    fps24
    guidance_scale7.5
    base_urlhttps://api.openai.com/v1/sora
    endpoint/videos
    metadata
    webhook_url
    wait_for_resulttrue
    poll_interval3.00
    max_wait_seconds120.00
    download_path

    SoraTextToVideo is the simplest node in the comfyui-sora-node pack, and the one to reach for when you have a prompt and nothing else. Give it text, it hands the job to a Sora-compatible API, and a short generated clip comes back. The catch is right there in the name: nothing runs locally. This is an API client, not a model - no weights, no VRAM, no downloads, and no way around needing an API key. If you expected a local alternative to Wan or LTX Video, that's not what this is.

    The honest use case: you already have a Sora key (or access to a Sora-compatible backend) and want to fire off clips from inside a ComfyUI graph instead of a separate website. It's also the least fiddly of the three nodes in the pack because there's no file to upload - it's a pure JSON request, so the only thing that can go wrong on your side is the prompt or the key. Text-to-video is where prompt quality matters most, too; the model has nothing but your words to anchor on.

    How it works

    The whole pack is a thin REST client written in Python's standard library (urllib, no requests, no torch), and this node is its simplest mode. It builds a JSON payload with your prompt and settings, POSTs it to base_url + endpoint (defaults: https://api.openai.com/v1/sora and /videos), gets a job id back, then polls GET /videos/<job_id> until the status flips to succeeded. If you set download_path, it grabs the resulting video and saves it as <job_id>.mp4.

    Key resolution follows a strict priority: the api_key field, then the SORA_API_KEY env var, then OPENAI_API_KEY. Since a text prompt is the only required input, this node is effectively "one prompt string in, one JSON status blob out."

    The inputs that matter

    • prompt (required) - the only thing you must supply. The default, "A cinematic drone shot of waves crashing.", is a fine starting point to prove the plumbing works.
    • duration_seconds (5), aspect_ratio (16:9), fps (24), guidance_scale (7.5) - the generation knobs. Want a 9:16 clip for reels? Change aspect_ratio.
    • negative_prompt - forwarded to the API, though whether the backend actually honors it is up to the backend, not the node.
    • seed - a string field, so type your seed as text. Leave blank for random.
    • api_key - set the env var instead; more on that below.
    • max_wait_seconds and download_path - the two that will actually bite you.

    The outputs are three strings: job_id, status, and result. result is JSON containing the job id, status, downloaded file path (if any), and the raw API response. There's no preview - you open the file the node saved.

    Install

    cd ComfyUI/custom_nodes
    git clone https://github.com/maxczc/comfyui-sora-node sora
    

    Then fully restart ComfyUI - closing and reopening the server, not refreshing the browser tab, per the README. ComfyUI Manager can install it too if you search the pack title. There's no requirements.txt and nothing to download; Pillow and numpy are optional and only matter for the sibling nodes that handle images.

    Where people get burned

    • Timeout. Generation rarely finishes within the default 120-second max_wait_seconds. Hit a TimeoutError? Raise it. Long prompts and long durations make this more likely.
    • No key. You'll see Provide a Sora API key via the node input or SORA_API_KEY/OPENAI_API_KEY env vars. Nothing runs until that's sorted.
    • Key in the workflow. Pasting the key into the field stores it in plaintext in your saved workflow. Prefer the env var; it keeps the key out of any .json you share.
    • Expecting local control. This isn't Wan - no sampler overrides, no ControlNet, no local LoRAs. You get what the API gives you. If you want to actually steer generation, you're on the wrong pack.

    It's a small, anonymous pack with essentially no community footprint, but the code is clean and dependency-free. As a way to call Sora from a graph, it works. Just don't confuse it with the local video ecosystem that most of r/comfyui actually runs on.

    CategorySora

    Inputs (16)

    NameTypeDefaultDescription
    promptSTRINGA cinematic drone shot of waves crashing.
    api_keyoptSTRING
    negative_promptoptSTRING
    duration_secondsoptFLOAT5.0
    aspect_ratiooptSTRING16:9
    seedoptSTRING
    fpsoptINT24
    guidance_scaleoptFLOAT7.5
    base_urloptSTRINGhttps://api.openai.com/v1/sora
    endpointoptSTRING/videos
    metadataoptSTRING
    webhook_urloptSTRING
    wait_for_resultoptBOOLEANtrue
    poll_intervaloptFLOAT3.00
    max_wait_secondsoptFLOAT120.00
    download_pathoptSTRING

    Outputs (3)

    NameTypeDescription
    job_idSTRING
    statusSTRING
    resultSTRING