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

This node operation converts Microsoft Visio files into various output formats such as PDF, JPG, PNG, or TIFF. It supports multiple input methods for the Visio file: binary data from a previous node, a base64 encoded string, or a URL pointing to the Visio file. The conversion process includes options to specify pages to convert, whether to include hidden pages, and other formatting preferences like auto-fitting content or including toolbars.

This node is beneficial in workflows where Visio diagrams need to be converted into more widely accessible formats for sharing, archiving, or further processing. For example, converting a Visio diagram to PDF for easy distribution or to an image format for embedding in presentations.

Properties

Name Meaning
Input Data Type How the input Visio file is provided. Options: Binary Data (from previous node), Base64 String (encoded content), URL (link to the file).
Binary Property Name of the binary property containing the Visio file when using Binary Data input type.
Input File Name Name of the input Visio file including extension. Used when input is Binary Data or required for Base64/String and URL inputs.
Base64 Content Base64 encoded content of the Visio file to convert (required if input type is Base64).
File URL URL of the Visio file to convert (required if input type is URL).
Output File Name Desired name for the output file after conversion (e.g., "converted_diagram.pdf"). Defaults to "output.pdf".
Output Format Desired output format of the converted file. Options: PDF, JPG, PNG, TIFF.
Is PDF Compliant Whether to make the output PDF compliant with standards (true/false). Applies only if output format is PDF.
Page Index Zero-based index indicating the first page to start conversion from.
Page Count Number of pages to convert starting from Page Index. Range: 1-100.
Include Hidden Pages Whether to include hidden pages in the conversion (true/false).
Save Foreground Page Whether to save foreground elements on pages (true/false).
Save Tool Bar Whether to include toolbar elements in the output (true/false).
Auto Fit Whether to auto-fit content to the page size (true/false).
Async Enable asynchronous processing of the conversion (true/false).
Advanced Options Collection for additional custom options, e.g., custom JSON profiles to adjust API call properties.
Binary Data Output Name Custom name for the binary data property in the node's output. Defaults to "data".

Output

The node outputs the converted file as binary data under the specified binary data output name (default "data"). The json output contains metadata about the conversion result, typically including file information. The binary data represents the converted Visio file in the chosen output format (PDF, JPG, PNG, or TIFF).

Dependencies

  • Requires access to an external Visio conversion service or API capable of handling Visio file conversions.
  • Needs appropriate API credentials or authentication tokens configured in n8n to authorize requests to the conversion service.
  • Network access to URLs if input is provided via URL.

Troubleshooting

  • Common Issues:

    • Incorrect input file name or missing file extension may cause conversion failures.
    • Providing invalid base64 content or inaccessible URLs will result in errors.
    • Requesting page indices or counts outside the valid range can cause errors.
    • Output format not supported by the conversion service may fail.
  • Error Messages & Resolutions:

    • "File not found": Check that the binary property or URL points to a valid Visio file.
    • "Invalid base64 content": Verify the base64 string is correctly encoded and complete.
    • "Page index/count out of range": Adjust pageIndex and pageCount to valid values within the document.
    • "Unauthorized" or "Authentication failed": Ensure API credentials are correctly set up in n8n.
    • Timeouts or async processing errors: Try disabling async or check network connectivity.

Links and References

Discussion