Hello, I would like to send a single email using basic Email Node but with multiple attachments I generate during the workflow with Spreadsheet Node. I can’t manage to do so and get all binaries merge into a single results (array first item).
Could you help me please ?
Best regards,
Antoine
Hello @mediana, welcome to the community.
Sorry, I do not understand exactly what you mean so I hope this example is helpful. I used now for simplicity reason HTTP Request nodes. All I did is to write each of the files to different binary properties and then set them it to the Send EMail node.
If it is not helpful please supply a simple example workflow. I can then use that as a base and make it work. Thanks!
Hello Jan,
Thank you for your answer.
My need is a bit different.
Here is the example workflow.
At the end, I would like to send a single email with both files and therefore ‘merge’ the 2 binaries, without having them ‘inline’ like in your example.
Best regards,
Antoine
{
"nodes": [
{
"parameters": {},
"name": "Start",
"type": "n8n-nodes-base.start",
"typeVersion": 1,
"position": [
250,
300
]
},
{
"parameters": {
"attachments": "[1]data,[2]data",
"options": {}
},
"name": "Send Email",
"type": "n8n-nodes-base.emailSend",
"typeVersion": 1,
"position": [
800,
300
],
"disabled": true
},
{
"parameters": {},
"name": "Merge",
"type": "n8n-nodes-base.merge",
"typeVersion": 1,
"position": [
640,
300
]
},
{
"parameters": {
"url": "https://via.placeholder.com/300",
"responseFormat": "file",
"options": {}
},
"name": "HTTP Request #1",
"type": "n8n-nodes-base.httpRequest",
"typeVersion": 1,
"position": [
460,
220
]
},
{
"parameters": {
"url": "https://via.placeholder.com/400",
"responseFormat": "file",
"options": {}
},
"name": "HTTP Request #2",
"type": "n8n-nodes-base.httpRequest",
"typeVersion": 1,
"position": [
460,
370
]
}
],
"connections": {
"Start": {
"main": [
[
{
"node": "HTTP Request #1",
"type": "main",
"index": 0
},
{
"node": "HTTP Request #2",
"type": "main",
"index": 0
}
]
]
},
"Merge": {
"main": [
[
{
"node": "Send Email",
"type": "main",
"index": 0
}
]
]
},
"HTTP Request #1": {
"main": [
[
{
"node": "Merge",
"type": "main",
"index": 0
}
]
]
},
"HTTP Request #2": {
"main": [
[
{
"node": "Merge",
"type": "main",
"index": 1
}
]
]
}
}
}
Sorry but do not understand what you mean. My example above sends one email with both attachments.
And what do you mean with “without having them inline”? If your example would work, what would be different and what would not be “inline” anymore?
Also do not understand “merging” two binaries? The only thing I can think of there is to combine two images into one (to have one larger image) or combining multiple random files by making a zip file out of them.
Use a Merge with By Index.
Welcome to the community @GMoore!
Thanks a lot but that would not work as both binary properties have the same name and would so overwrite each other. Meaning one would get lost. So the binary property names would have to additionally be set to unique values. Also, would the value on the SendEmail-Node for Attachments still have to get fixed like in the example I posted above for it to work.
He was asking for two files to be attached. With separate binary property names he can accomplishment that.
Exactly, that is why I pointed it out in my clarification.
If he would only change the Merge-Node in his workflow to “Merge By Index” it would not work. For it to work he would have to give the binary properties different names.
We have to make sure that the answers we provide are complete. If multiple steps are required all of them should be mentioned. Like if somebody asks for the directions to the store. If we just say “Go down the road.” But we do then not mention that he then has to turn left and go also down that street, that person would be closer to its destination but he would still not be able to reach it.
Hi @GMoore and @jan, I’m stuck with this issue. How can I send multiple binaries files into one using the gmail node?
Merge multiple binaries from 4 items into 1 to send an email - Questions - n8n
Thanks!