Hey
I’m POSTing data from Mailgun to a Webhook; the POST includes an XLSX attachment.
How can I access the attachment to use it in an HTTP POST further down the workflow?
Thanks!
Hey
I’m POSTing data from Mailgun to a Webhook; the POST includes an XLSX attachment.
How can I access the attachment to use it in an HTTP POST further down the workflow?
Thanks!
It looks like your topic is missing some important information. Could you provide the following if applicable.
In your webhook specify the field to store the file:
Then in the following node you can access it from {{ $binary.data }}
Thanks, @JayF
I did try that, but I seem to be getting the details of the attachment, not the binary file:
in Input Data Field Name, just write the string ‘data’ . No expression needed
This is because your webhook is giving the data in field data0
.
To make sure you get the file regardless of the name, you can set Input Data Field Name to expression: Object.keys($binary)[0]
, which will automatically use the right field as given by the previous node.
I think I can see what’s happening.
My workflow is:
I can get to the file immediately after the Webhook, but it’s unavailable later in the flow. I tried a merge node to see if that would fix the problem, but it didn’t
What is the best practice to use a binary file later in a flow?
$('nodename').item.binary['data0']
Hi Jay
I really appreciate all your help here, but this still isn’t working as expected.
The frustration is we are evaluating to take an enterprise contract with n8n, an this use case has been achieved in minutes using make.com.
Here are the screenshots.
I’d be more than happy to pay for a consultant to help with this.
This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.