List files on a SFTP/FTP server

Parameters:
*, *.csv, 2025-*-orders-*.zip.* to validate the connection returns rows.See dedicated page for more information.
scanDir is a scripted action. Embedded code is accessible and customizable through this tab.
See dedicated page for more information.
sftpListFiles lists files in a remote SFTP directory and returns them as rows in the data stream. It wraps cURL under the hood (using SFTP) and supports simple wildcard filters (e.g., *, *.csv, 2025-10-*.zip). Use it to discover files before downloading or archiving them.
Typical uses
Caveats
/).Partitioning
--list-only).What the action emits
file) listing matched names.. and ..; you can filter these out downstream.sftp://test.rebex.net/pub/example/*demopasswordsftp://test.rebex.net/pub/example/.*.demo, Password = password.
Data: a list of files from the remote directory. In the demo run you should see entries like:
imap-console-client.pngKeyGenerator.pngreadme.txt
Post-Run Validation
* filter.*.txt, only .txt names should remain.0).Auth failed (status 67)
Re-enter Login/Password; confirm the account can list that directory.
Couldn’t connect (status 7) or timeout (28)
Port 22 blocked or host unreachable. Test from another network or ask to allowlist the host.
No rows returned
/ and points to a folder you can access.* to test.. and ..; filter them out downstream if needed.TLS/hostkey warnings
Rare with SFTP via cURL; if you see strict hostkey messages in your environment, contact infra or test with Debug information level = verbose to capture details.
sftpListFiles → filter/regex → downloadFile to pull only the newest files.Files names filter remains stable (YYYY-MM-DD_*.csv, etc.).