Templates / Smart nested folder creation in OneDrive with existence checking

Smart nested folder creation in OneDrive with existence checking

Unknown

by Marko Korhonen · 630 views · created 2025-08-15 · File Management, Multimodal AI

Unknown. This template uses community nodes we can't verify statically. Uses community nodes that can't be verified statically (unverified community packages are off by default in 3.0). Static check, last run 2026-10-19.

What this workflow does

This workflow has 11 nodes and runs when another workflow calls it. Along the way it connects Microsoft OneDrive and Datastore (community).

How it runs

Trigger: When another workflow calls it.

  1. Paths (Code): runs custom JavaScript code
  2. clearParent (Datastore): clear
  3. Split Out: splits a list into separate items
  4. Loop Over Items (Loop Over Items (Split in Batches)): loops over the items in batches
  5. Search (Microsoft OneDrive): search (folder)
  6. Exists (If): checks a condition and branches into true / false
  7. setParentFound (Datastore): uses Datastore
  8. getParent (Datastore): get
  9. Create a folder (Microsoft OneDrive): create (folder)
  10. setParentCreated (Datastore): uses Datastore

Services it uses

Microsoft OneDriveDatastore (community)

Before you upgrade to n8n 3.0

We can't fully verify this one: it relies on 1 community package, and n8n 3.0 turns unverified community packages off by default (N8N_UNVERIFIED_PACKAGES_ENABLED=false).

  • Check that n8n-nodes-datastore is verified or supports 3.0 (used in setParentFound, setParentCreated, getParent).

Nodes used (7)

From the author

This workflow contains community nodes that are only compatible with the self-hosted version of n8n. How it works - It creates a nested folder in your OneDrive's My Files - You could be creating folders like: Foobar Foobar/Barfur Foobar/Barfur/Furbar Workflow…

Excerpt from Marko Korhonen's description on n8n.io.

View the original on n8n.io → Check your own copy

Get the weekly “what broke” email

New templates, newly broken ones, and n8n release changes. One short email a week.

Form not loading? Subscribe here.