Templated icon

Templated

n8n node to automate the generation of images and PDFs with Templated (https://templated.io).

Overview

This node integrates with the Templated service to automate the generation of images and PDFs based on predefined templates. It is particularly useful for scenarios where you need to dynamically create visual content such as marketing materials, personalized documents, or reports by filling in template layers with custom text, images, colors, and styles.

For example, you can use this node to:

  • Generate customized flyers or posters by replacing text and images in a design template.
  • Create branded PDF reports with dynamic data and styling.
  • Produce social media graphics with personalized messages and visuals.

The "Create a Render" operation allows you to specify a template ID, choose the output format (JPG, PNG, WEBP, or PDF), and define multiple layers with detailed customization options like text replacement, image URLs, colors, fonts, borders, and visibility.

Properties

Name Meaning
Template ID The identifier of the template you want to use for rendering.
Format The output format of the render. Options are JPG, PNG, WEBP, or PDF. Default is JPG.
Layers A collection of layers to customize within the template. Each layer can be individually configured with:
- Layer Name: Reference name of the layer in the template.
- Text: Replacement text for text layers.
- Image URL: Replacement image URL for image layers.
- Color: Text color in hex format.
- Background: Background color in hex format.
- Border Color: Border color in hex format.
- Border Width: Width of the border.
- Font Family: Font family to apply.
- Fill: Shape fill color in hex format.
- Stroke: Shape stroke (border) color in hex format.
- Hide: Boolean to hide the layer.
Transparent Background Whether to make the background transparent when the output format is PNG. Default is false.

Output

The node outputs JSON data representing the result of the render request. This typically includes metadata about the generated file such as its URL or binary data reference depending on the integration specifics.

If the node supports binary data output (e.g., the rendered image or PDF file), it will provide the binary content that can be used downstream in workflows for saving files, sending emails, or further processing.

Dependencies

  • Requires an API key credential for authenticating with the Templated service.
  • Needs the base URL of the Templated API, which is configured via credentials.
  • The node sends HTTP requests to the Templated API endpoint to perform rendering operations.

Troubleshooting

  • Invalid Template ID: If the template ID does not exist or is incorrect, the API will return an error. Verify the template ID in your Templated account.
  • Authentication Errors: Ensure the API key credential is correctly set up and has the necessary permissions.
  • Unsupported Format: Using a format other than JPG, PNG, WEBP, or PDF may cause errors. Confirm the format value matches one of the allowed options.
  • Layer Configuration Issues: Incorrect layer names or invalid color codes might lead to rendering failures. Double-check layer names against the template and ensure color values are valid hex codes.
  • Transparent Background Setting: This only applies when the format is PNG; setting it for other formats will have no effect.

Links and References

Discussion