Skip to main content

Folder Creation (v2)

The Folder Creation trigger in Automations v2 starts a workflow when a new folder is created in the path you choose. Use it when creating a folder represents a business event, such as opening a client onboarding folder and notifying the team responsible for that client.

The trigger responds to successful folder creations recorded by Files.com. Each matching creation supplies one data item describing that folder, rather than the folder or its contents. Creating a folder does not establish that uploads into it have finished. For work that processes arriving files, use a File Action trigger on those uploads instead.

Folder Selection

Folder Path identifies where new folders start the workflow. It can use wildcards to cover several paths. The incoming pattern narrows which newly created folders match, and Exclude Pattern removes matching paths. These patterns are static; they do not evaluate TransformScript templates.

With no incoming pattern, matching includes new folders at every depth below the folder path. The pattern * limits matching to immediate children. For example, with Folder Path Clients and pattern *, creating Clients/Acme starts the workflow, while creating Clients/Acme/Contracts does not. This choice lets one client folder represent one onboarding event without each of its subfolders producing another notification.

Exclusions match the full recorded path, including the folder path. For a site-owned Automation watching Clients, an exclusion of Clients/Test* removes immediate child folders whose names begin with Test.

Folder copies create destination folders and subfolders, so each matching new folder supplies its own item. With descendants included and no exclusions, copying a new template folder with five subfolders into the watched path produces six items. Some folder moves also recreate subfolders and record their creation. The trigger responds to those new-folder records; an operation recorded only as a move or copy does not match. Choose immediate children when only the top-level addition should notify your team.

Folder Data and Email Messages

Each item retains the folder's recorded path and name as attributes.path and attributes.name, with attributes.is_directory set to true. A later rename or removal does not discard the creation event or change these recorded values. The workflow can therefore report which folder was created even if another process has already changed it.

A Send Email node can use New client folder: {{ attributes.name }} as its Subject and The folder {{ attributes.path }} was created. as its Message Body. These fields insert the path as ordinary text, so double braces are sufficient. Send Email requires Custom SMTP and sends one message per incoming item: the six matching folders in the template example produce six emails.

The items are data about the event, so a file-only node cannot process them as files. An Automation with this trigger cannot be started manually, because it needs the recorded folder creation that supplies its input.