[HTTP request] download PDF (binary) not working after last 3 updates

Describe the problem/error/question

I used to run this workflow flawlessly for several months, it simply adds a product number and batch number into a url and a PDF file can be obtained using a HTTP request node, the file comes back as a binary and then is dealt with after.

I updated the N8N version about a week ago because i noticed i was 3 updates behind and the problem started happening instead of outputting a pdf file it just gets this error message instead .

At first I thought they had changed the website and the URL wasnt quite right, but using the same url in a browser returns the requested pdf file fine.

After that i thought perhaps running n8n through a VPN was the problem so I changed the VPN server and it still gives the same problem.

I also tried to change the credentials for the authentication, i was running custom header auth to try and replicate a google bot, but changed it to just no authentication and it was still the same.

Also tried to change Http request method but it is also still the same

What could it be? I would really appreciate if some others could copy and paste the workflow and try to run it and see if you get the desired PDF??

What is the error message (if any)?

    "error": {
      "options": {
        "url": " https://www.merckmillipore.com/Web-TH-Site/en_US/-/THB/ShowDocument-GetCOACOQ?COAOrderNumber=1198970500&BatchNumber=HC20297897&Origin=FINDER_COA ",
        "method": "get",
        "headers": {
          "Accept": "application/json,text/html,application/xhtml+xml,application/xml,text/*;q=0.9, image/*;q=0.8, */*;q=0.7",
          "User-Agent": "axios/0.21.4"

Please share your workflow

Share the output returned by the last node

Information on your n8n setup

Latest version running on docker container

I managed to get the PDF 1 or 2 times without any authentication, but the rest of the times it fails? is it the website? the browser gets the pdf 10/10 times

Hey @Josh-Ghazi,

I just ran the workflow a bunch of times and it didn’t fail at all for me, It could just be the site. It might be worth enabling the full response option and seeing if that shows any extra detail when it fails.


thank you so much for your validation.

also why do the credentials look like this now, particularly for header auth which i used to emulate a google bot, im sure it wasnt like this before

Hey @Josh-Ghazi,

We masked the values as a lot of users had secrets in them like API tokens so it is was a quick security improvement.

1 Like

thanks for that update, its a little bit too secure now i guess because i don’t even know what ive put in there.

1 Like

okay sorry to accuse the update, i just disconnected the VPN and it works reliably.

Thank you all for your time

1 Like

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.