Run FTP Commands
Description
Runs a list of FTP commands on the specified FTP server.
You can enter commands in the action’s Expression Editor, one command per line.
FTP protocol is designed to use raw commands, but most common
implementations comes with a set of higher-level commands.
For instance, there is a set of command aliases supported in Windows,
another with Linux, such as dir'' or
ls'', which are transformed to
the same raw FTP commands behind the scenes.
This action supports both using commands alias such as cd', and raw
FTP commands, such as `CWD
.
FTP is not the same as SFTP (SSH File Transfer Protocol). SFTP is a network protocol related to SSH and SCP. For SFTP commands, see Run SFTP Commands. |
Supported commands
The Run FTP Commands action supports these commands:
Command | Description | Supported aliases | Examples |
---|---|---|---|
active |
Enter active transfer mode. |
active |
|
append |
Append to a remote file. |
appe |
append [local_file]append [local_file] [remote_file] |
ascii |
Switch to ASCII transfer mode. |
ascii |
|
binary |
Switches to binary transfer mode. |
binary |
|
bye |
Terminate ftp session and exit. |
close, disconnect, exit, quit |
bye |
cd |
Changes remote working directory. |
cwd |
cd [remote_folder] |
cdup |
Change remote working directory to parent directory. |
cdup |
|
connect |
Connect to remote ftp. |
open |
connect [hostname] [port] |
delete |
Deletes a remote file. |
dele |
delete [remote_file] |
dir |
List contents of remote directory. |
list, ls, mlsd, mlst, nlst |
dirdir [remote_directory] |
get |
Get file from the remote computer. |
recv, retr |
get [remote_file]get [remote_file] [local_file] |
help |
Accesses the Help screen and displays information about the command if the command is typed after help. |
rhelp |
help |
lcd |
Displays local directory if typed alone or if path typed after lcd will change the local directory. |
lcdlcd [local_directory] |
|
login |
Send new login information. |
login [user] [password] |
|
mdelete |
Delete multiple remote files. |
mdelete [remote_pattern] |
|
mdtm |
Show last modification time of remote file. |
modtime |
mdtm [remote_file] |
mget |
Get multiple files. |
mget[remote_pattern] |
|
mkd |
Make directory on remote computer. |
mkdir, xmkd |
mkd [remote_directory] |
mput |
Send multiple files to remote computer. |
mput[local_pattern]mput[local_pattern][remote_pattern] |
|
newer |
Get file if remote file is newer than local file.Timezone is like : GMT-2 or GMT+2 |
newer [remote_file]newer [remote_file] [local_file]newer [remote_file] [local_file] [local_timezone] |
|
pass |
Send new password information. |
password |
pass [thy_password] |
passive |
Enter passive transfer mode. |
pasv |
passive |
put |
Send one file to remote computer. |
send, stor |
put [local_file][remote_file] |
pwd |
Print working directory on remote machine. |
pwd |
|
rename |
Renames a remote file. |
rnfr & rnto |
rename [remote_actual_name][remote_expected_name] |
rmd |
Removes a directory on the remote computer. |
rmdir |
rmd [remote_file] |
site |
Send site specific command to remote computer. |
site [command] [args…]site help |
|
size |
Show size of remote file. |
size [remote_file] |
|
stat |
Show current status of remote computer. |
status |
statstat [remote_file] |
stou |
Store file uniquely. |
stou [local_file]stou [local_file] [remote_file] |
|
syst |
Show remote system type. |
system |
syst |
type |
Set file transfer type. |
type binarytype ascii |
|
user |
Send new user information. |
user [thy_user] |
|
verbose |
Sets verbose on or off. |
verbose |
|
<RAW COMMAND> |
Any raw command is sent as is to the FTP server. |
CWD |
Unknown or raw commands are sent to the FTP server as-is. Commands that are not listed on this page may still work, depending on the FTP server.
Some FTP servers can add a three-digit response code at the beginning of a response message. It can be confusing to read some command results. For example, take a 98 bytes file named |
Parameters
Name | Mandatory | Default | Description |
---|---|---|---|
FTP Hostname |
Yes |
FTP host name or IP address. |
|
FTP Port |
No |
21 in normal mode, 990 in secure mode. |
FTP host port. |
FTP User |
Yes |
FTP user. |
|
FTP Password |
This user’s encrypted password. |
||
FTP Unencrypted Password |
This user’s password in plain text. |
||
FTP Passive Mode |
No |
true |
Use FTP passive (PASV) mode. |
FTP File Mode |
No |
ascii |
FTP file transfer mode: ascii or binary. |
FTP Remote Path |
No |
Remote FTP path. |
|
FTP Disable Login |
No |
false |
If true, the connection to the server will be performed anonymously, without using the login credentials. |
FTP Implicit FTPs |
No |
true |
Use FTPs Implicit mode. |
FTP Secured Protocol |
No |
None |
Protocol used for FTPs communication: none, tls, ssl. |
FTP Protection Buffer Size |
No |
Defines the size to use for the Protection Buffer. Please refer to your FTP server provider for the possible values. |
|
FTP System Type |
No |
Specifies the system type of the FTP Server. This helps to better treat the responses of the server. By default, the Runtime will try to auto-detect it. The following types are supported: UNIX,VMS,WINDOWS,OS/2,OS/400,AS/400,MVS,TYPE: L8,NETWARE |
|
Ignore Trust Store |
No |
false |
If true, the specified Trust Store will be ignored. |
Proxy Host |
No |
Host name for the proxy server. |
|
Proxy Port |
No |
1080 |
Port of the proxy server. |
Proxy User |
No |
Proxy server user. |
|
Proxy Password |
No |
Proxy server user password, encrypted. |
|
Proxy Unencrypted Password |
No |
Proxy server user password in plain text. |
|
Proxy Protocol |
No |
Protocol used for the proxy server: HTTP, SOCKS, SOCKS4 or SOCKS5 . |
|
Socket Timeout |
No |
Timeout of the command on the socket. |
|
Connection Timeout |
No |
Timeout of the FTP connection. |
|
Data Timeout |
No |
Data Timeout of the FTP connection. |
|
Key Store |
No |
Full path to the Java Key Store to use when connecting to the server. |
|
Key Store Type |
No |
JKS |
Type of the Java Key Store. |
Key Store Password |
No |
Encrypted password of the Java Key Store. |
|
Trust Store |
No |
Full path to the Java Trust Store to use when connecting to the server. |
|
Trust Store Type |
No |
JKS |
Type of the Java Trust Store. |
Trust Store Password |
No |
Encrypted password of the Java Trust Store. |
Passwords are encrypted using the encrypt <password> command
on the Runtime engine console (engine command line tool).
|
Published variables
Name |
Description |
Command |
APPEND_ADDED_FILE_SIZE |
Size of the added data |
Append |
DELETED_FILES_SIZE |
Size of the deleted file |
Deleted |
DELETED_FILES_SIZE |
Size of deleted files |
MDeleted |
DELETED_FILES_NUMBER |
Number of deleted files |
MDeleted |
LISTED_FILES_NUMBER |
Number of files listed |
Dir |
LISTED_FILES_SIZE |
Size of files listed |
Dir |
RETRIEVED_FILES_SIZE |
Size of the file received |
Get |
RETRIEVED_FILES_SIZE |
Size of files received |
MGet |
RETRIEVED_FILES_NUMBER |
Number of files received |
MGet |
STORED_FILES_SIZE |
Size of the file sent |
Put |
STORED_FILES_SIZE |
Size of files sent |
MPut |
STORED_FILES_NUMBER |
Number of files sent |
MPut |
STORED_FILES_SIZE |
Size of the file sent |
Stou |