Reference · Tools

OpenAI Video

Generate videos using OpenAI Sora 2.

Action (binary) AI v1 Binary data

OpenAI Video generates video from a text prompt using Sora, submitting the job and polling until it completes, then returning the finished MP4 as binary. Aspect ratio is selectable and clip length is fixed to 4, 8 or 12 seconds. A typical build is producing a short clip per approved script line in a content pipeline.

Node type
Action (binary)
Parameters
5
Outputs
Output, Error
Credentials
OpenAI

OpenAI Video

Generate videos using OpenAI Sora.

Overview

OpenAI Video uses the OpenAI Sora 2 API (POST /videos) to generate videos from text prompts. Supports model selection (sora-2, sora-2-pro), size (720x1280 portrait, 1280x720 landscape, 1024x1024 square), and duration (4 / 8 / 12 seconds). The tool submits a generation job, polls for completion, downloads the resulting video, and stores it as binary data on the output item.

Category: AI
Tool Name: openai_video
Version: 1

Appearance: Icon: openai | Color: #10a37f

Node Type

Action (Binary) — handles file/binary data operations

Input / Output

DirectionPort(s)
InputInput
OutputOutput, Error

Credentials

This tool requires OpenAI credentials. See the Credentials Guide for setup instructions.

Parameters

ParameterTypeRequiredDefaultDescription
ModeloptionsNosora-2The video generation model to use.
Options: sora-2 (standard video generation model), sora-2-pro (higher quality, longer / larger outputs)
PromptstringYesText prompt describing the video to generate. Supports expressions like {{fieldName}}.
OptionscollectionNo{}Optional generation and polling settings — add only the fields you need.
— SizeoptionsNo1280x720Video dimensions. Sora 2 Pro additionally supports 1024x1792 and 1792x1024.
Options: 1280x720 (standard 16:9 landscape), 720x1280 (vertical 9:16 portrait), 1024x1024 (square 1:1)
— Duration (seconds)optionsNo8Duration of the generated video. Sora 2 supports 4 / 8 / 12 seconds. The API expects the value as a string (“4” / “8” / “12”), not an integer.
Options: 4 (shortest — fastest, cheapest), 8 (balanced default), 12 (longest — highest cost)
— Wait For CompletionbooleanNotrueWhether to poll until the video generation is complete. If false, returns the job ID immediately.
— Poll Interval (ms)numberNo10000Milliseconds between poll requests when waiting for completion.
— Max Poll Duration (ms)numberNo600000Maximum total time to spend polling before timing out (default: 10 minutes).
— Binary Property NamestringNodataProperty name that carries the generated video binary. Each item produces exactly one MP4, so this is the only binary slot written. Names are case-sensitive.
— Response Field NamestringNovideoOutput field name for the API response data.
Include InputbooleanNofalseWhether to include the original input item fields in the output.
Max ConcurrencynumberNo3Maximum number of items to process concurrently. Keep low for video generation due to heavy resource usage.

Output Data

One output item per input item. The job details land on the field named by Response Field Name (video by default), with jobId, model and status at the top level. The rest of the input item JSON is dropped unless Include Input is on.

{
  "jobId": "video_abc123",
  "model": "sora-2",
  "video": { "id": "video_abc123", "status": "completed" },
  "status": "completed"
}
  • With Wait For Completion on (the default), the node polls until the job finishes and the item carries the final job object. On success the rendered MP4 is attached as binary data under Binary Property Name (data by default), named after the job ID, and merged with any binary the input item already carried.
  • With Wait For Completion off, the node returns as soon as the job is submitted: status is pending and the response field holds just the job ID. Feed jobId into a later step to collect the result.
  • Generation takes minutes, not seconds. Raise Max Poll Duration (ms) for long or high-resolution renders rather than letting the node time out.

Reference the result downstream by expression, e.g. {{ $json.jobId }}.

Usage Examples

  • Generate a video of a sunset over the ocean using Sora
  • Create a portrait-format video for a social media post
  • Generate a video variation from a prompt built out of item data
  • Create a 12-second video with a detailed scene description
  • Generate a square video for an Instagram post

Example Configuration

Generate a landscape clip with the defaults:

{
  "type": "openai_video",
  "parameters": {
    "prompt": "A slow drone shot over a misty pine forest at sunrise."
  }
}

Vertical short-form video built from item data:

{
  "type": "openai_video",
  "parameters": {
    "prompt": "{{ $json.scene }}, cinematic lighting, shallow depth of field",
    "includeInput": true,
    "options": {
      "size": "720x1280",
      "seconds": "12",
      "maxPollDurationMs": 1200000,
      "binaryPropertyName": "clip"
    }
  }
}

Submit without waiting, and collect the result later:

{
  "type": "openai_video",
  "parameters": {
    "prompt": "{{ $json.prompt }}",
    "options": {
      "waitForCompletion": false
    }
  }
}

Error Handling

ModeBehavior
stopHalts workflow on first error
continueSkips failed items, passes successful ones through
errorPortRoutes failed items to Error output port

Tips

OpenAI Video generates videos from text prompts by submitting generation jobs to the OpenAI Sora API and polling until completion. Use it when a workflow requires AI-generated video content with control over aspect ratio (landscape, portrait, or square) and clip length, which is fixed to 4, 8, or 12 seconds. Each input item produces exactly one MP4 — there is no variation-count parameter. It produces binary video file data on the main output, with generation or polling errors routed to the error output.

Frequently asked questions

How long can the video be?

Clip length is fixed to 4, 8 or 12 seconds — it is a selection, not a free value.

Can one item produce several variations?

No. Each input item produces exactly one MP4; there is no variation-count parameter. Run the node again if you want alternatives.

Do I have to poll for the result myself?

No — the node submits the generation job and polls until it completes, then returns the binary video.

What aspect ratios are available?

Landscape, portrait and square, so output can match the platform it is destined for.

Build with the OpenAI Video node

Drop it into a workflow, wire it to an agent, or call it on a schedule. You'll need OpenAI credentials first.

Open BusyBot

Last updated . Spotted something wrong? Tell us.