HTTP File put as Attachment in SendMail

Following Problem:
I have a http-rechest which get an attachment from Ninox-Database.
You can see in pict2 the result.
How to put these data to SendMail as attachment?

Thanks in advice.
UweG

1 Like

Hey @UweG!

Welcome to the community :slightly_smiling_face:

After configuring the credentials, From Email, To Email and other parameters, in the Attachment field enter data. We are referring the file as data in the HTTP Request node. If it was something else, you would have to enter that in the Attachement field.

Hope this helps :slightly_smiling_face:

Thank’s for your answer.
I tried to use data as attachment.
Eher will be an error:
ERROR: attachmentPropertyString.split is not a function

TypeError: attachmentPropertyString.split is not a function at Object.executeSingle (/usr/local/lib/node_modules/n8n/node_modules/n8n-nodes-base/dist/nodes/EmailSend.node.js:160:67)
    at Workflow.runNode (/usr/local/lib/node_modules/n8n/node_modules/n8n-workflow/dist/src/Workflow.js:474:60)
    at /usr/local/lib/node_modules/n8n/node_modules/n8n-core/dist/src/WorkflowExecute.js:395:62

Weird, I just tested it, and it’s working fine for me. Can you share your workflow? Just select and copy the nodes, then paste them here.

Hello All.
Thank you for your answers.
I thought too complicated and entered the wrong GET request output in the attachment field of the SendMail node. Now it works fine with one attachment. However, the GET request returns sometimes several files. How can I combine them to send them in one mail? I am a beginner with N8N and English is not my mother tongue.

Hello :rocket::technologist:t3:Thanks for these info I have the same issue but dont work for me: Just attach a file with sendgrid node.

Send works but error with attachment:

:rocket:The binary:


:robot:The log:

Any idea? :thinking:

You do not need to set an expression in attachments, only the name of the binary property, which is’ data according to the images you shared.`

3 Likes

Works!!! :beers::zap::love_you_gesture:t2::sweat_smile:. thanks @RicardoE105

2 Likes

Hello @RicardoE105 , I have tried the same
I have data which gets sent to spreadsheet and from there i’m using sendGrid node to send email
I’m getting email but the attachment is empty with zero size

can you check this? also if you have any example with sendGrid node to send attachment with dummy data please share. thank you



Welcome to the community @Paddy_Pohare

If you click on “Show Binary Data” can you see the file? Because if it’s empty then the issue might be creating the binary data.

hi @RicardoE105 yes i’m able to see data in binary file,
interesting thing we notice is if we use same workflow on local n8n app on mac its working fine
but giving empty attachment on n8n cloud app on browser

here is example

Just tested the workflow you shared and it worked fine for me. I even received the attachment in the email as expected.

Thank you @RicardoE105 for response. We have shared our issue to support team and we got reply and It says that this is know issue and has not been fixed yet.

So for now we are using sendEmail instead of sendGrid node.

Got fixed and will be available in the next release.