FTP Component
Manage files and directories on an FTP server
Component key: ftp
Description
The FTP (File Transfer Protocol) component allows uploading, downloading, moving and deleting files on an FTP server.
A common integration pattern involves listing files in a file store, and performing a series of actions on the array of files that are returned. See our looping over files quickstart for information about how to create a loop over an array of files.
Connections
Basic Authentication
key: basicThis component supports basic authentication, meaning that a username and password can be entered for authentication, or if the FTP server allows anonymous access, those values can be left blank.
Prerequisites
- An FTP or FTPS server with accessible credentials
- Server hostname or IP address
- Port number (typically 21 for FTP or 990 for FTPS)
- SSL/TLS configuration details (if using FTPS)
Configure the Connection
Create a connection of type Basic Authentication and configure the following:
- Username: Enter the FTP username (leave blank for anonymous access)
- Password: Enter the FTP password (leave blank for anonymous access)
- Host: You can enter either an IP address (e.g.
1.2.3.4) or FQDN (e.g.ftp.example.com) for the FTP's host name - Port: Most FTP servers run on port 21 and most FTPS (secure) servers run on port 990, though ports are configurable and server administrators can choose to operate on different ports
- Secure: Some FTP servers are secure (indicating that they use FTPS rather than FTP). If you are using plain, unsecured FTP select false for secure (though, we recommend encrypting your connection if possible). If your FTP server is set up to use SSL/TLS, you can select true (meaning use "explicit" FTPS) or implicit to use "implicit" FTPS. For information on "implicit" and "explicit" FTPS, see this documentation
If the connection fails, verify the hostname, port and security information with the server administrator.
On-prem enabled: this connection can be configured to connect to an on-prem resource on a private network. Learn more.
| Input | Notes | Example |
|---|---|---|
| Host | The address of the FTP server. This should be an IP address or hostname. | ftp.example.com |
| Ignore SSL Errors | When true, ignores SSL certificate validation errors such as self-signed certificates. | false |
| Password | The password for FTP authentication. | p@s$W0Rd |
| Port | The port of the FTP server. Default is 21 for FTP or 990 for implicit FTPS. | 21 |
| Secure | Whether to use FTPS over TLS. Set to 'true' for explicit FTPS, 'false' for plain FTP, or 'implicit' for legacy implicit FTPS. | false |
| Username | The username for FTP authentication. | john.doe |
Triggers
New or Modified Files
Checks for new and modified files in a directory on an FTP server on a configured schedule. | key: newOrModifiedFiles
| Input | Notes | Example |
|---|---|---|
| Connection | ||
| Include Subdirectories | When true, recursively monitors files in all subdirectories. When false, only monitors files in the specified directory. | false |
| Path | Path of directory on FTP server to monitor for new or modified files. | /path/to/directory |
| Pattern | Glob-style string for filtering specific files. | *.csv |
| Verbose Logging | Enables verbose logging for debugging purposes. | false |
This trigger polls an FTP server for new and modified files on a scheduled basis.
The trigger checks for:
- New files: Files that did not exist in the previous poll
- Modified files: Files whose modification timestamp or size has changed since the last poll
How It Works
- The trigger runs on the configured schedule (e.g., every 5 minutes)
- It lists all files in the specified directory on the FTP server
- Files are compared against the previous poll's file map (stored in state)
- Files are categorized as "new" or "modified" based on their presence and attributes
- The trigger updates its state with the current file map for the next poll
Configuration
Configure the following inputs:
- Connection: The FTP connection with server credentials
- Path: The directory path to monitor on the FTP server
- Pattern: Optional glob pattern to filter files (e.g.,
*.csv) - Include Subdirectories: Enable to recursively monitor subdirectories
Returned Data
The trigger returns an object with two arrays:
{
"data": {
"newFiles": [
{
"path": "/uploads/incoming/report-2026-02-11.csv",
"size": 24576,
"modifiedAt": 1739308800000
}
],
"modifiedFiles": [
{
"path": "/uploads/incoming/daily-log.txt",
"size": 102400,
"modifiedAt": 1739312400000
}
]
}
}
Notes
- Files are tracked by path, size, and modification timestamp
- The first poll will return all files as "new"
- Polling frequency should balance freshness with server load
- A common integration pattern involves looping over the returned files to perform actions on each file
Actions
Delete File
Deletes a file from an FTP server. | key: deleteFile
| Input | Notes | Example |
|---|---|---|
| Connection | ||
| Path | The full path of the file on the FTP server to delete. | /path/to/file.txt |
| Verbose Logging | Enables verbose logging for debugging purposes. | false |
List Directory
List the contents of a directory | key: listDirectory
| Input | Notes | Example |
|---|---|---|
| Connection | ||
| Path | The full path of the directory on the FTP server to list. | /path/to/directory |
| Verbose Logging | Enables verbose logging for debugging purposes. | false |
{
"data": [
{
"name": "reports",
"type": 2,
"size": 0,
"rawModifiedAt": "Feb 8 22:16",
"permissions": {
"user": 7,
"group": 5,
"world": 5
},
"hardLinkCount": 2,
"group": "ftpusers",
"user": "deploy",
"isDirectory": true,
"isFile": false,
"isSymbolicLink": false
},
{
"name": "invoice-2024-001.pdf",
"type": 1,
"size": 245760,
"rawModifiedAt": "Jan 23 16:38",
"permissions": {
"user": 6,
"group": 4,
"world": 4
},
"hardLinkCount": 1,
"group": "ftpusers",
"user": "deploy",
"isDirectory": false,
"isFile": true,
"isSymbolicLink": false
}
]
}
Move File
Moves a file on an FTP server. | key: moveFile
| Input | Notes | Example |
|---|---|---|
| Connection | ||
| Destination Path | The new path where the file will be moved on the FTP server. | /my/destination/path.txt |
| Source Path | The current path of the file on the FTP server to move. | /my/starting/path.txt |
| Verbose Logging | Enables verbose logging for debugging purposes. | false |
Read File
Reads a file from an FTP server. | key: readFile
| Input | Notes | Example |
|---|---|---|
| Connection | ||
| Path | The full path of the file on the FTP server to read. | /path/to/file.txt |
| Verbose Logging | Enables verbose logging for debugging purposes. | false |
{
"data": {
"type": "Buffer",
"data": [
101,
120,
97,
109,
112,
108,
101
]
},
"contentType": "application/octet-stream"
}
Write File
Writes a file to an FTP server. | key: writeFile
| Input | Notes | Example |
|---|---|---|
| Connection | ||
| Data | The text or binary data to write to the file on the FTP server. | |
| Path | The full path on the FTP server where the file will be written. | /we/love/commas.csv |
| Verbose Logging | Enables verbose logging for debugging purposes. | false |
Changelog
2026-02-24
- Added New or Modified Files polling trigger that detects new and modified files in a directory on a configured schedule