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 (
audioMessageorimageMessage), the output will include abinaryfield 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
binaryfield.
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
audioMessageandimageMessageare 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 Dataproperty does not match the expected structure, the node may fail or skip processing.
- Unsupported Message Types: Only
Error Handling:
- If "Continue On Fail" is enabled, failed items will be appended with an
errorfield and processing will continue. - Otherwise, the workflow will stop on the first error.
- If "Continue On Fail" is enabled, failed items will be appended with an
Links and References
- n8n Documentation
- @open-wa/wa-decrypt GitHub
- mime-types npm package
- Evolution API documentation (link to your specific API documentation, if available)