Note: You are looking at a static snapshot of documentation related to Robot Framework automations. The most recent documentation is at https://robocorp.com/docs

RPA.FTP

FTP library can be used to access an FTP server, and interact with files.

The library is based on Python's built-in ftplib.

Examples

Robot Framework

*** Settings *** Library RPA.FTP *** Variables *** ${HOST} 127.0.0.1 ${PORT} 27345 ${USER} user ${PASS} 12345 *** Tasks *** List files on the server directory Connect ${HOST} ${PORT} ${USER} ${PASS} @{files} List Files FOR ${file} IN @{files} Log ${file} END

Python

from RPA.FTP import FTP library = FTP() library.connect('127.0.0.1', 27345, 'user', '12345') files = library.list_files() for f in files: print(f)