FTP - List directory
FTP - List directory
Lists every file and folder in a directory of the FTP server, returning the collection of items found. Ideal for checking a directory's content before downloading files, processing items in batch or checking whether certain files exist.
Options
Connection
Select the FTP: Connect action that will be used to reach the server.
Path
Enter the path of the directory to list on the FTP server. Use a single slash for the root directory.
Returns
Custom code
js
actions["action-id"].items // list of items found in the directory (List)
actions["action-id"].count // number of items found (Number)
Field selection
- items — list of items (files and folders) found in the directory (List)
- count — total number of items found (Number)
Rules and Conditions
- The Connection and Path fields are required.
- To iterate over the returned items, use FTP: For each directory item.
- To reach a specific item by its position, use FTP: Get directory item.