ffmpeg Node icon

ffmpeg Node

n8n Node for some Ffmpeg functionality

Actions11

Overview

This node provides video and audio processing capabilities using ffmpeg. Specifically, the "Cut Video/Audio" operation allows users to trim a segment from a given video or audio file by specifying start and end times in seconds. This is useful for extracting highlights, removing unwanted sections, or creating clips from longer media files.

Common scenarios include:

  • Extracting a specific scene from a recorded video.
  • Trimming silence or noise from an audio recording.
  • Creating short promotional clips from longer videos.

For example, if you have a 10-minute video but only want the segment from 2:00 to 3:30, this node can cut that portion and output it as a new media file.

Properties

Name Meaning
Video or Audio Input A valid URL pointing to the input video or audio file, or the name of the binary field containing the media.
Cut Start Time (in Sec) The starting point (in seconds) from which to begin cutting the media. Must be ≥ 0.
Cut End Time (in Sec) The ending point (in seconds) at which to stop cutting the media. Must be ≥ 0.
Video or Audio Output Name The name of the output binary field where the resulting trimmed media file will be stored.

Output

The node outputs the trimmed video or audio segment in a binary field named as specified by the user (default is "data"). The json output typically contains metadata about the processed file, such as filename, mime type, or other relevant information. The binary data represents the actual media content of the cut segment.

Dependencies

  • Requires an API key credential for accessing ffmpeg functionality via an external service.
  • The node depends on ffmpeg being available through this service to perform media processing.
  • No additional environment variables are explicitly required beyond the API authentication.

Troubleshooting

  • Invalid Input: If the input URL or binary field name is incorrect or inaccessible, the node will fail to load the media. Ensure the input source is valid and reachable.
  • Start/End Times: Setting the start time greater than or equal to the end time will cause errors. Verify that the start time is less than the end time and both are within the media duration.
  • Unsupported Formats: If the input media format is not supported by ffmpeg, the node may throw an error. Use common formats like MP4, MP3, WAV, etc.
  • Output Field Conflicts: Make sure the output binary field name does not conflict with existing fields in the workflow to avoid overwriting data unintentionally.

Links and References

Discussion