Skip to main content

Connect

Connects to a remote FTP server

Common Properties

Name - The custom name of the node.

  • Color - The custom color of the node.
  • Delay Before (sec) - Waits in seconds before executing node.
  • Delay After (sec) - Waits in seconds after executing node.
  • Continue On Error - Automation will continue regardless of any error. The default value is false.
info

if ContinueOnError property is true, no error is caught when the project is executed even if Catch node is used.

Input

  • Host - FTP server host address
  • Port - FTP server port number

Output

  • Session id - FTP session id

Options

  • FTP Type - Check whether it is FTP, sFTP or FTPS server.
  • Login Credentials - Username and Password credentials from a Vault.
  • Skip TLS Verification - Ignore SSL verifications that prevent a connection.

How It Works

The Connect node establishes a connection to a remote FTP server and creates a session that can be used by other FTP nodes:

  1. Credential Validation: Retrieves username and password from the specified Vault
  2. Session Creation: Creates a new session based on the selected FTP type (FTP, FTPS, or SFTP)
  3. Connection Establishment: Connects to the server using the provided host and port
  4. Authentication: Logs in using the credentials and any additional security parameters
  5. Session ID Generation: Returns a unique session ID for use with subsequent FTP operations

Requirements

  • Valid FTP server hostname or IP address
  • Port number (default: 21 for FTP, 990 for FTPS, 22 for SFTP)
  • Login credentials stored in a Robomotion Vault
  • Network connectivity to the FTP server
  • For SFTP: SSH access enabled on the server
  • For FTPS: TLS/SSL support on the server

Error Handling

Error CodeDescriptionCause
Core.FTP.Connect.ErrOnCreateConfig parse errorNode configuration is malformed
Core.FTP.Connect.OnMessageMessage parse errorInput message cannot be parsed
Core.FTP.Connect.ErrCredentialsInvalid credentialsCredentials cannot be retrieved from vault or decoded
Core.FTP.Connect.OnMessageVault has to be selectedNo vault selected in configuration
Core.FTP.Connect.OnMessageVault item has to be selectedNo vault item selected in configuration
Core.FTP.Connect.ErrUsernameUsername can not be emptyUsername is missing in vault credentials
Core.FTP.Connect.ErrHostHost can not be emptyHost field is empty
Core.FTP.Connect.ErrPortPort can not be emptyPort field is empty or zero
Core.FTP.Connect.ErrFtpTypeUnknown ftp typeInvalid FTP type specified
Core.FTP.Connect.ErrLoginLogin errorAuthentication failed (details in error message)

Usage Examples

Example 1: Basic FTP Connection

// Store the session ID for later use
// Host: "ftp.example.com"
// Port: 21
// Credentials from Vault
// Session ID output: "ftp-session-123"

Use the session ID output from this node in all subsequent FTP operations like Download, Upload, List Directory, etc.

Example 2: Secure FTPS Connection

// For FTPS connections, use port 990 (or custom port)
// FTP Type: FTPS
// Enable "Skip TLS Verification" if the server uses self-signed certificates
// Session ID output: "ftps-session-456"

Example 3: SFTP Connection with Private Key

// For SFTP connections, use port 22
// FTP Type: SFTP
// Provide Private Key file path in options
// Optionally provide Passphrase if the key is encrypted
// Session ID output: "sftp-session-789"

Usage Notes

  • The session ID must be passed to all other FTP nodes to perform operations
  • Always use the Disconnect node to close the session when done to free server resources
  • For versions prior to 23.6.1, TLS verification is automatically skipped for backward compatibility
  • FTPS supports client certificate authentication via Private Key and Certificate options
  • SFTP supports both password and private key authentication
  • Connection timeout is set to 10 seconds
  • The same session can be reused for multiple operations

Tips

  • Store the Session ID output in a flow variable for reuse across multiple FTP operations
  • Use Vault credentials instead of hardcoding usernames and passwords for security
  • Test connections with "Skip TLS Verification" enabled first, then disable it for production
  • For SFTP, ensure your private key file is accessible and has proper permissions
  • Use the Disconnect node in a Try-Catch-Finally pattern to ensure sessions are always closed
  • For FTPS with self-signed certificates, enable "Skip TLS Verification" or add the certificate to your trusted store
  • Monitor connection timeouts in high-latency networks and adjust retry logic accordingly