Evolution Media Downloader icon

Evolution Media Downloader

Utility node to download media from Evolution API messages

Overview

The Evolution Media Downloader node is designed to extract and download media files (specifically audio and image messages) from data received via the Evolution API. It decrypts the media content and makes it available for further processing within n8n workflows. This node is particularly useful when you need to automate the handling of media attachments sent through messaging platforms integrated with the Evolution API.

Practical examples:

  • Automatically saving images or voice notes received in WhatsApp chats to cloud storage.
  • Processing incoming media for moderation, analysis, or archiving.
  • Forwarding decrypted media to other services or users.

Properties

Display Name Type Description
Evolution Message Data JSON The node data from Evolution API message. This should contain the full message object as provided by the Evolution API, including media metadata if present.

Output

  • If the input contains a supported media message (audioMessage or imageMessage), the output will include a binary field with the following structure:
{
  "key": {
    "data": "<base64-encoded file contents>",
    "mimeType": "<MIME type of the file, e.g., 'image/jpeg'>",
    "fileSize": <size in bytes>,
    "fileName": "file.<extension>",
    "fileExtension": "<file extension, e.g., 'jpg'>",
    "fileType": "<type, e.g., 'image' or 'audio'>"
  }
}
  • If the input does not contain a supported media message, the output will not include the binary field.

Dependencies

  • External Service: Requires access to the Evolution API and valid message data containing media information.
  • API Key/Environment Variables: None required directly by this node, but the Evolution API integration may require authentication.
  • n8n Configuration: No special configuration needed beyond standard n8n setup.

Troubleshooting

  • Common Issues:

    • Unsupported Message Types: Only audioMessage and imageMessage are processed. Other types will be ignored.
    • Decryption Errors: If decryption fails (e.g., due to missing or invalid keys), the node throws an error:
      "Could not decrypt media message"
    • Malformed Input: If the Evolution Message Data property does not match the expected structure, the node may fail or skip processing.
  • Error Handling:

    • If "Continue On Fail" is enabled, failed items will be appended with an error field and processing will continue.
    • Otherwise, the workflow will stop on the first error.

Links and References

Discussion