Hi Everyone,
Could I get some help on my file name issue on google drive please?
Issue Summary
Aim:
I’m using a GPT-powered Personal Assistant workflow (v6, August 7) to save Tavily search results to Google Drive as a .txt file. The file name should be automatically generated based on the search topic or a heading in the Tavily answer.
What’s going wrong?
The file saves correctly with the full content, but the file name is always ‘Untitled’ instead of the dynamic name returned by the AI. The expected behaviour is that it should extract a title like “6 August emails.txt” or “Weather in London.txt” from the AI output.
Error Message or Unexpected Behavior: there is no error thrown by the Google Drive node itself.
But the expected file name is not applied. Instead of: “6 August Weather.txt”
The saved file appears as: Untitled.txt
Workflow logic:
The AI agent returns a valid JSON with fileName and fileContent
Google Drive node is set to Create file from text
File name expression used:
{{ $json.fileName || ‘WebSearch’ }}_{{ $now.format(“YYYY-MM-DD_HH-mm”) }}.txt
What’s happening:
The fileContent works perfectly — it includes full, formatted Tavily output.
But the fileName is not read, even though it exists in the JSON output from the GPT node.
Troubleshooting Tried:
Checked node credentials
Rebuilt the Drive node from scratch
Verified that GPT node returns fileName correctly
Tried both fileName and title fields
Ran test executions — confirmed fileName is in the JSON
Searched community posts
Verified fileContent mapping works
Switched from GPT-4 to GPT-4o
Tried fallback expressions like {{ $json.title }}
Even removed “File Name” field to test raw fallback behavior
Still stuck on: Dynamic file name not being applied even when present
Workflow Snippet:
Tool structure:
Tavily (tool node)
↓
Personal Assistant (GPT Agent)
↓
Google Drive (tool node) – “Create file from text”
GPT output:
{
“fileName”: “6 August emails.txt”,
“fileContent”: “Here are your last 3 emails:\n1. From Chloe…”
}
Google Drive node config: Mode: Create file from text
File Name:
{{ $json.fileName || ‘WebSearch’ }}_{{ $now.format(“YYYY-MM-DD_HH-mm”) }}.txt
File Content: {{ $json.fileContent }}
Output of the Last Node:
{
“fileName”: “6 August emails.txt”,
“fileContent”: “Here are your last 3 emails:\n1. From Chloe…”
}
But in Google Drive, the saved file shows: Untitled.txt
Environment Details:
n8n version: 1.104.1 (Cloud)
Database: Default (SQLite)
EXECUTIONS_PROCESS: Cloud (unknown, likely main)
Hosting method: n8n Cloud
OS: Cloud (n8n hosted)
Qustions:
Is this a bug in how tool output maps to file name in the Drive node?
How can I ensure the fileName field from GPT is correctly used?
Are there any known issues with tool node file name expressions in agent-triggered flows?
Thank you all for your help.



