Google drive parent folder specification problems

Describe the issue/error/question

My apologies, I am extremely new at this.

I am trying to move Google Drive files from one folder to another. I seem to be able to download them without issue. However, when I try to upload them to the new folder location, it only works if the specified parent folder ID in the upload node is not an expression. As in, a string in the parent field of the folder ID appears to execute without issue. But when I try to change the input to an expression (which evaluates to the exact same as the string in the viewer window) it fails.

What is the error message (if any)?

It fails with the following error:

ERROR: Forbidden - perhaps check your credentials?
The specified parent is not a folder.

Share the output returned by the last node

Information on your n8n setup

  • n8n version:
  • Database you’re using (default: SQLite):
  • Running n8n with the execution process [own(default), main]:
  • Running n8n via [Docker, npm,, desktop app]:

Hi @Danny_C1B, welcome to the community!

From quickly looking at your workflow the “Upload files to new archive folder” node is called not just for the bottom branch (with the “Download files from list” node) but also for items coming from the top branch with the “Create new folder in archive”. This is probably not intended.

So in a first step you might want to change your workflow into a sequential one without parallel branches. For example, first create the new folder, then list the files, then download them, then upload them to the new folder.

Then it’s important to understand that expressions will resolve for every single item you’re processing in n8n. So if you want all items to be uploaded into a single parent folder (instead of several different folders) you probably want to update your expression specifying the parent folder to something like {{ $item(0).$node["Create new folder in archive"].json["id"] }} (assuming the Create new folder in archive node returns a field named id, otherwise you might need to adjust the expression accordingly).

Hope this helps!