Actions15
Overview
This node, named "File Manager," provides a versatile set of file and folder management operations on the local disk. It supports common filesystem tasks such as moving, copying, renaming, compressing, extracting, reading, writing, deleting files or directories, changing permissions, listing contents, checking existence, retrieving metadata, and searching files by pattern.
The Move operation specifically moves a file or folder from a source path to a destination path. This is useful for reorganizing files, archiving data, or automating workflows that require relocating files after processing.
Practical examples:
- Moving processed files from an "incoming" folder to an "archive" folder.
- Renaming files by moving them to a new path with a different filename.
- Organizing images or documents into categorized folders automatically.
Properties
| Name | Meaning |
|---|---|
| Source Path | The full path of the source file or folder to move. |
| Destination Path | The target path where the file or folder will be moved to. |
Output
The node outputs JSON data containing information about the performed operation:
operation: The name of the operation executed, here always"move".success: A boolean indicating if the operation succeeded (true).sourcePath: The original path of the file or folder before moving.destinationPath: The new path where the file or folder was moved.
No binary data output is produced by this operation.
Example output JSON:
{
"operation": "move",
"success": true,
"sourcePath": "/path/to/source/file.txt",
"destinationPath": "/path/to/destination/file.txt"
}
Dependencies
- Requires access to the local filesystem where n8n is running.
- Uses Node.js built-in
fs(filesystem) module for file operations. - No external API keys or services are needed.
- Ensure the n8n process has appropriate read/write permissions for the involved paths.
Troubleshooting
Common issues:
- Insufficient permissions to read the source or write to the destination path.
- Source path does not exist or is incorrect.
- Destination path points to a location where a file/folder already exists, causing conflicts.
- Moving across different mounted drives or filesystems may fail depending on OS support.
Error messages and resolutions:
ENOENT(No such file or directory): Verify the source path exists and is correctly specified.EACCESor permission denied errors: Check and update filesystem permissions for the user running n8n.EXDEVerror (cross-device link not permitted): Moving files across different devices may require copying and deleting instead of rename; consider using the Copy + Remove operations as a workaround.