Basic FTP icon

Basic FTP

Implement the operations from the "basic-ftp" library

Overview

The Basic FTP node's "Make Directory" operation allows you to create a new directory (folder) on a remote FTP server. This is useful in workflows where you need to organize files, prepare upload destinations, or automate the setup of folder structures before transferring files.

Common scenarios:

  • Automatically creating dated folders for file uploads.
  • Preparing project-specific directories as part of an onboarding workflow.
  • Ensuring required folder structures exist before batch file transfers.

Example:
You could use this node to create a /reports/2024/06 directory on your FTP server before uploading monthly reports.

Properties

Name Type Meaning
Folder Path String The path to the folder on the server that should be created.

Output

The output is a JSON object indicating the success of the operation:

{
  "success": true
}

If the operation fails and "Continue On Fail" is enabled, the output will include an error message:

{
  "error": "Error message here"
}

Dependencies

  • External Service: Requires access to an FTP server.
  • Credentials: Needs valid FTP credentials configured in n8n under "basicFtpApi".
  • Environment Variables: None required by default, but secure connections may require certificate/key data.

Troubleshooting

Common Issues:

  • Invalid Credentials: If the FTP login details are incorrect, the node will fail to connect.
  • Permission Denied: If the user does not have permission to create directories at the specified path, the operation will fail.
  • Path Already Exists: Some FTP servers may return an error if the directory already exists.

Error Messages:

  • "The operation \"mkdir\" is not supported!" – This should not occur unless the node is misconfigured.
  • Errors from the FTP server (e.g., "550 Permission denied") will appear in the error field if "Continue On Fail" is enabled.

How to resolve:

  • Double-check FTP credentials and permissions.
  • Ensure the target path does not already exist, or handle existing directories gracefully.
  • Check network/firewall settings if connection issues persist.

Links and References

Discussion