Skip to main content

FTP Component

Manage files and directories on an FTP server

Component key: ftp

Description#

The FTP component lets you upload, download, move and delete files on a 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.

Authorization Methods#

FTP can use the following authorization methods, though no authorization method is required:

Auth TypeKeyDescriptionFields
Basic AuthbasicBasic authorization using a username/password combination

Password |  password

Username |  username

This component supports basic auth (username/password) and private key authentication, with basic auth being more common for FTP servers.

Actions#

Delete File#

Delete a file from a FTP server | key: deleteFile

InputKeyDefaultNotesExample

Host

string
/ Required
hostThe address of the FTP server. This should be either an IP address or hostname.ftp.prismatic.io

Path

string
/ Required
pathPath of file to delete/path/to/file.txt

Port

string
port21The port of the FTP server.21

Secure

string
securefalseSpecifies whether to use FTPS over TLS. Can be true, false, or implicit, which is for legacy implicit FTPS.false

Verbose Logging

boolean
verbosefalseSpecifies whether to enable verbose logging in the underlying FTP library, which may be useful for debugging.false

List Directory#

List the contents of a directory | key: listDirectory

InputKeyDefaultNotesExample

Host

string
/ Required
hostThe address of the FTP server. This should be either an IP address or hostname.ftp.prismatic.io

Path

string
/ Required
pathPath of directory on FTP server to list/path/to/directory

Port

string
port21The port of the FTP server.21

Secure

string
securefalseSpecifies whether to use FTPS over TLS. Can be true, false, or implicit, which is for legacy implicit FTPS.false

Verbose Logging

boolean
verbosefalseSpecifies whether to enable verbose logging in the underlying FTP library, which may be useful for debugging.false

Output Example Payload#

{  "data": [    {      "date": "Wed, 01 Jan 2020 00:00:00 GMT",      "name": "example.txt",      "size": 123456,      "isFile": true,      "isDirectory": true,      "rawModifiedAt": "Wed, 01 Jan 2020 00:00:00 GMT",      "isSymbolicLink": true    }  ]}

Move File#

Move a file on an FTP server | key: moveFile

InputKeyDefaultNotesExample

Destination Path

string
/ Required
destinationPathPath of file to move/my/destination/path.txt

Host

string
/ Required
hostThe address of the FTP server. This should be either an IP address or hostname.ftp.prismatic.io

Port

string
port21The port of the FTP server.21

Secure

string
securefalseSpecifies whether to use FTPS over TLS. Can be true, false, or implicit, which is for legacy implicit FTPS.false

Source Path

string
/ Required
sourcePathPath of file to move/my/starting/path.txt

Verbose Logging

boolean
verbosefalseSpecifies whether to enable verbose logging in the underlying FTP library, which may be useful for debugging.false

Read File#

Read a file from FTP | key: readFile

InputKeyDefaultNotesExample

Host

string
/ Required
hostThe address of the FTP server. This should be either an IP address or hostname.ftp.prismatic.io

Path

string
/ Required
inputPathPath of file on FTP server to read data from/path/to/file.txt

Port

string
port21The port of the FTP server.21

Secure

string
securefalseSpecifies whether to use FTPS over TLS. Can be true, false, or implicit, which is for legacy implicit FTPS.false

Verbose Logging

boolean
verbosefalseSpecifies whether to enable verbose logging in the underlying FTP library, which may be useful for debugging.false

Output Example Payload#

{  "data": {    "data": [      101,      120,      97,      109,      112,      108,      101    ],    "type": "Buffer"  },  "contentType": "application/octet"}

Write File#

Write a file to FTP | key: writeFile

InputKeyDefaultNotesExample

Data

text
/ Required
dataText to write into the file

Host

string
/ Required
hostThe address of the FTP server. This should be either an IP address or hostname.ftp.prismatic.io

Path

string
/ Required
outputPathPath on FTP server to write file/we/love/commas.csv

Port

string
port21The port of the FTP server.21

Secure

string
securefalseSpecifies whether to use FTPS over TLS. Can be true, false, or implicit, which is for legacy implicit FTPS.false

Verbose Logging

boolean
verbosefalseSpecifies whether to enable verbose logging in the underlying FTP library, which may be useful for debugging.false