PDF4me icon

PDF4me

Comprehensive PDF and document processing: generate barcodes, convert files, extract data, manipulate images, and automate workflows with the PDF4ME API

Actions80

Overview

The node provides an image flipping operation that allows users to flip images either horizontally, vertically, or both. It supports multiple input methods for the image file: binary data from a previous node, a base64 encoded string, or a URL pointing to the image. This flexibility makes it useful in workflows where images need to be programmatically flipped before further processing or storage.

Common scenarios include:

  • Flipping user-uploaded images for correct orientation.
  • Preparing images for visual effects or layout adjustments.
  • Automating image transformations in document processing pipelines.

For example, a user could take an image uploaded via a form (binary data), flip it vertically, and then save or send the flipped image downstream.

Properties

Name Meaning
Input Data Type Choose how to provide the image file to flip. Options: Binary Data, Base64 String, URL
Input Binary Field Name of the binary property containing the image file (used if Input Data Type is Binary Data)
Base64 Image Content Base64 encoded image content (used if Input Data Type is Base64 String)
Image URL URL to the image file to flip (used if Input Data Type is URL)
Output File Name Name for the output flipped image file
Orientation Type Orientation to flip the image. Options: Horizontal, Vertical, Horizontal and Vertical
Async Enable asynchronous processing (boolean)

Output

The node outputs the flipped image as binary data under the specified output binary property. The JSON output contains metadata about the processed image, including the filename set by the user. If the input was provided as base64 or URL, the node converts and outputs the flipped image in binary format suitable for further n8n processing or saving.

If the node supports binary data output, this typically means the flipped image can be passed on to other nodes that accept binary files, such as upload or storage nodes.

Dependencies

  • Requires access to the image source depending on the input type:
    • For URL input, the node needs network access to fetch the image.
    • For binary or base64 input, no external dependencies are needed beyond the node itself.
  • No explicit external API keys or credentials are required for the flip operation itself.
  • The node relies on internal image processing libraries bundled within the node's codebase.

Troubleshooting

  • Common issues:

    • Providing an incorrect binary property name will cause the node to fail to find the image data.
    • Invalid base64 strings or inaccessible URLs will result in errors fetching or decoding the image.
    • Unsupported image formats might cause processing failures.
  • Error messages and resolutions:

    • "Binary property not found": Verify the binary field name matches the actual input binary property.
    • "Failed to fetch image from URL": Check the URL accessibility and network connectivity.
    • "Invalid base64 content": Ensure the base64 string is correctly formatted without extra characters.
    • "Unsupported image format": Use supported image types like JPEG, PNG, etc.

Enabling the "Async" option may help with large images or slow network responses by processing the flip operation asynchronously.

Links and References

Discussion