HTTP Request Tool not Returning Binary data

Describe the problem/error/question

Perhaps I am overlooking something obvious, but I am attempting to add an HTTP Request Tool to my Agent.

My testing correctly has the LLM invoke the Tool, but even with the tool configured to return a file, the node returns the output shown below. I was expecting the binary of the PDF. What is interesting is that the HTTP Request node, for the same URL, returns the binary as expected, as the URL points to a PDF.

What could I be doing wrong? The idea was to have a set of tools that allows my agent to reason about URLs, GET the resource (html, file, etc.) and then write the binary to Google Cloud Storage.

Share the output returned by the last node

1 item[

{

"action":"sendMessage",

"sessionId":"9f1axxxxxxxxx",

"chatInput":"https://arxiv.org/pdf/2608.02569",

"URL":"https://arxiv.org/pdf/2608.02569",

"toolCallId":"call_TptExEnexxxxxxxxxxx"

}]

Information on your n8n setup

  • n8n version: Cloud 2.32.1

Hi @datanerdery3 Welcome!

keep the binary out of the agent. Swap the HTTP Request Tool for a Call n8n Workflow Tool. The agent passes a URL, the sub-workflow does the download and upload with real nodes, and only a short JSON receipt goes back to the model

Hi @datanerdery3

The AI Agent node cannot process raw binary streams because tools attached to LLMs are designed to pass text string context back to the model, which causes binary data from the HTTP Request Tool to be dropped or converted into tool invocation metadata.

To download a PDF and write it to Google Cloud Storage (GCS) via an Agent, the agent should only manage control flow and URLs, while a sub-workflow or tool handles the binary stream directly in memory/storage and returns metadata to the LLM.

Thanks for the feedback. I was thinking of n8n as the orchestrator that is controlling how nodes are called, or in this case, how the context is managed within the state of the run. I wasn’t thinking about the agent having to do anything with the binary file other than knowing its available within the session and can tell n8n how to handle the binary with another tool. @anon71933009 I was thinking about this approach, so thank you for recommending it. I simply wasn’t sure if this was “overkill” but I now understand this as the pattern. Thank you.

Welcome @datanerdery3