Create Sub Folder in Google Drive


I have a question for google drive node.

I want to create a sub folder under an existing folder in google drive.

Can I specify a parent folder when creating a folder in google drive?

Just checked. That is currently not possible. That would have to get programmed first but should not be too complicated.

Did just commit something which should make it possible. Will be released with the next version:

I will try it in next version. thanks for your working!

Got released with [email protected]

Thanks. I tried.

I set parent folder id.
But folder was made in Root folder.
Is wrong how to set parent id?

Excuse me @jan

I think the following is correct.

line 1080

const fileMetadata = {
	mimeType: 'application/',		// -> comma
	parents: options.parents || [],						// -> move here

const response = await drive.files.create({
	// @ts-ignore
	resource: fileMetadata,
	fields: queryFields,
	//parents: options.parents || [],					// -> move out

please check.

Hello @obana! Welcome to the community.

That makes sense and that was the problem. Did make the change and committed it:

Thanks a lot for helping out here!

Will release it with the next version.

Got released with [email protected]

@jan Sorry for the late reply.

I confirmed it.

1 Like