Actions74
- ai Actions
- array Actions
- audiovideo Actions
- carbone Actions
- charts Actions
- code Actions
- data Actions
- datetime Actions
- events Actions
- files Actions
- geo Actions
- hellospaces Actions
- images Actions
- Get Metadata of an Image
- Scale an Image
- Overlay an Image on another Image
- Scale an Image to Fit Given Dimensions
- Resize an Image
- Mask an Image with Another Image
- Mask an Image with a Circle Mask
- Crops an image by the given x, y, width and height paramters.
- Convert Texts to an Image
- Convert HTML String or URL to an Image
- Generates a QRCode with given text and color.
- Get EXIF from Image
- Remove EXIF from Image
- Modify Image EXIF
- playground Actions
- spreadsheet Actions
- stripe Actions
- youtube Actions
data → Generate HTML Email Body with MJML
AI-generatedOverview
This node allows you to generate an HTML email body from an MJML template using the "Generate HTML Email Body with MJML" operation under the "data" resource. MJML is a markup language designed for responsive email design, and this node converts your MJML code into ready-to-send HTML. This is particularly useful for automating the creation of visually appealing, mobile-friendly emails in workflows such as marketing campaigns, notifications, or transactional messages.
Example scenarios:
- Automating the generation of personalized newsletters.
- Creating dynamic notification emails based on workflow data.
- Converting designer-provided MJML templates into HTML for mass mailing.
Properties
| Name | Meaning |
|---|---|
| MJML | MJML Template. The source MJML code to be converted to HTML. See MJML documentation for more information. |
| Validation Level | Determines how strictly the MJML is validated before rendering: - skip: No validation. - soft: Validate but render even if errors exist. - strict: Validate and do not render if any error is found. Defaults to skip. |
Output
The output will be a JSON object containing the result of the MJML-to-HTML conversion. Typically, it includes:
{
"html": "<!DOCTYPE html>...converted HTML content...",
"errors": [] // Array of validation errors, if any (may be empty)
}
html: The generated HTML string ready for use in email clients.errors: An array listing any issues found during validation (present if validation is enabled).
Note: This operation does not output binary data.
Dependencies
- External Service: Requires access to the 1001fx API at
https://api.1001fx.com. - API Key: You must configure the
1001fxApicredential in n8n. - Environment: No special environment variables are required beyond standard n8n setup.
Troubleshooting
Common Issues:
- Invalid MJML Syntax: If your MJML template contains errors and you select "strict" validation, the node will not render the HTML and may return an error.
- Authentication Errors: If the
1001fxApicredential is missing or invalid, requests will fail. - API Connectivity: Network issues or incorrect base URL configuration can prevent successful API calls.
Error Messages:
"error": "MJML syntax error": Indicates a problem with your MJML code. Review the template and correct any mistakes."error": "Unauthorized": Check your API credentials."error": "Network Error": Ensure that n8n can reachhttps://api.1001fx.com.