Google Drive Download used as a Tool in Ai Agent doesn't provide binary data

Describe the problem/error/question

Adding Google Drive to download a file as a Tool to AI Agent doesn’t provide any binary data. The only thing returned back is a json with fileId that was used for download, but no binary payload is present.

I have tried to force it putting the download results into a field, doesn’t work.

This was already discussed in a couple topics, but without an answer:

What is the error message (if any)?

No error messages

Please share your workflow

Can’t provide, private self hosted workflow

Share the output returned by the last node

Information on your n8n setup

  • n8n version: 1.89.2
  • Database (default: SQLite):
  • n8n EXECUTIONS_PROCESS setting (default: own, main):
  • Running n8n via (Docker, npm, n8n cloud, desktop app): portainer
  • Operating system: macps

Hello @Aivery , welcome

Could you share your workflow so we can see how we can help you?

There isn’t much to share to be honest.

Just connect Google Drive Download as a tool to AI Agent.

Just to add a bit more context.

For debuging, what I did is instead of wiring just Google Drive download, I made a sub-workflow execution that does download file and supposed to return it back.

In sub-workflow execution I can see binary data downloaded and returned from Google Drive.

But when I am back in the parent workflow with ai agent, it doesn’t get that binary file and doesn’t pass it through to other tools or as an execution result:

Still not resolved

Same issue. I’ve been trying to implement a multi-step sub-workflow as a tool for my AI agent for analyzing WhatsApp chat export zip files, along with all the media files, but only the JSON fields are getting passed back into the AI agent, not binary, even though I can see at the last step of the execution that the binary is indeed being output from the last node, but gets lost when returning to the main workflow.

Edit: managed to workaround it by basically reimplementing tool calling via structured outputs. The workflow checks if the AI agent requests that tool via the structured output fields, runs that sub-workflow, and then passes all the outputs, including binary data, back into the AI agent node. Works flawlessly, so it must actually be an issue with how tools are implemented.