For the complete documentation index, see llms.txt. This page is also available as Markdown.

UploadFiles

Upload files to an FTP server.

Task version: 1.3.0

Required Frends version: 5.1+

Required .NET version: 471, 6.0, standard2.0

Compatible Agents: Legacy, Crossplatform

Task Parameters

Name
Description

Directory : String

Source directory.

Default: / Example: C:\sourcefiles

FileName : String

File name or file mask of the files to be fetched.

Default: "" Example: my_files*.txt

NotFoundAction : SourceNotFoundAction

What to do if source file is not found. Error = alarm and fail,

Info = alarm info and quit with success status, Ignore = quit

with success status.

Possible values:

  • Error: What to do if source file is not found. Error = alarm and fail,

Info = alarm info and quit with success status, Ignore = quit

with success status.

  • Info: What to do if source file is not found. Error = alarm and fail,

Info = alarm info and quit with success status, Ignore = quit

with success status.

  • Ignore: What to do if source file is not found. Error = alarm and fail,

Info = alarm info and quit with success status, Ignore = quit

with success status.

Default: 0 Example: SourceNotFoundAction.Error

Operation : SourceOperation

What to do with the source file after transfer.

Possible values:

  • Delete: What to do with the source file after transfer.

  • Rename: What to do with the source file after transfer.

  • Move: What to do with the source file after transfer.

  • Nothing: What to do with the source file after transfer.

Default: 0 Example: SourceOperation.Delete

FileNameAfterTransfer : String

Parameter for Rename operation. Set the file name for the source file.

Default: - Example: %SourceFileName%%SourceFileExtension%

DirectoryToMoveAfterTransfer : String

Parameter for Move operation. Set the full file path for source file.

Default: - Example: c:\movedFiles

FilePaths : Object

The paths to the files to transfer, mainly meant to be used with the file trigger with the syntax: #trigger.data.filePaths

Default: - Example: #trigger.data.filePaths

Name
Description

Directory : String

Directory on the server.

Default: / Example: /somedir

FileName : String

File name of the destination file with possible macros.

Default: - Example: myFile%Year%.txt

Action : DestinationAction

Operation to determine what to do if destination file exists.

Possible values:

  • Append: Operation to determine what to do if destination file exists.

  • Overwrite: Operation to determine what to do if destination file exists.

  • Error: Operation to determine what to do if destination file exists.

Default: 2 Example: DestinationAction.Error

Name
Description

Address : String

FTP(S) host address

Default: - Example: my.ftp.server.com

Port : Int32

Port number to use in the connection to the server.

Default: 21 Example: 21

UserName : String

Username to use for authentication to the server. Note that the file endpoint only supports

username for remote shares and the username must be in the format DOMAIN\Username.

Default: - Example: myUsername

🗝Password : String

Password to use in the authentication to the server.

Default: - Example: myPassword

TransportType : FtpTransportType

Type of transfer: 'Ascii' sends files as text and must only be used for sending ASCII text files. 'Binary' (default) sends files as raw data and should be used for sending e.g. UTF-encoded text files

Possible values:

  • Binary: Type of transfer: 'Ascii' sends files as text and must only be used for sending ASCII text files. 'Binary' (default) sends files as raw data and should be used for sending e.g. UTF-encoded text files

  • Ascii: Type of transfer: 'Ascii' sends files as text and must only be used for sending ASCII text files. 'Binary' (default) sends files as raw data and should be used for sending e.g. UTF-encoded text files

Default: 0 Example: FtpTransportType.Binary

Mode : FtpMode

Connection mode to use to connect to the FTP server

Possible values:

  • Passive: Connection mode to use to connect to the FTP server

  • Active: Connection mode to use to connect to the FTP server

Default: 0 Example: FtpMode.Passive

KeepConnectionAliveInterval : Int32

Sends NOOP command to keep connection alive at specified time-interval in seconds. If set to 0 the connection is not kept alive. Default value is 0

Default: 0 Example: 60

ConnectionTimeout : Int32

The length of time, in seconds, until the connection times out. You can use value 0 to indicate that the connection does not time out. Default value is 60 seconds

Default: 60 Example: 60

Encoding : String

If set, this encoding will be used to encode and decode command parameters and server responses, such as file names. Example values: utf-8, utf-16, windows-1252

Default: - Example: utf-8

BufferSize : Int32

Integer value of used buffer size as bytes.

Default value is 4 KB.

Default: 4096 Example: 4096

VerifyOption : VerifyOptions

If set, Task will do checksum check for the transferred file after the transfer. If the checksum fails Task can be configured to retry the transfer.

If Checksum fails the transferred file is removed and Task will throw an error, because the content is most likely corrupted.

Possible values:

  • None: If set, Task will do checksum check for the transferred file after the transfer. If the checksum fails Task can be configured to retry the transfer.

If Checksum fails the transferred file is removed and Task will throw an error, because the content is most likely corrupted.

  • Retry: If set, Task will do checksum check for the transferred file after the transfer. If the checksum fails Task can be configured to retry the transfer.

If Checksum fails the transferred file is removed and Task will throw an error, because the content is most likely corrupted.

  • Throw: If set, Task will do checksum check for the transferred file after the transfer. If the checksum fails Task can be configured to retry the transfer.

If Checksum fails the transferred file is removed and Task will throw an error, because the content is most likely corrupted.

Default: 0 Example: VerifyOptions.None

RetryAttempts : Int32

Value for how many retries the Task will do while uploading the file.

Task will check the checksum of the file and based on that retries if necessary.

Default: 3 Example: 5

UseFTPS : Boolean

Whether to use FTPS or not.

Default: False Example: false

SecureDataChannel : Boolean

Whether the data channel is secured or not.

Default: True Example: true

SslMode : FtpsSslMode

Specifies whether to use Explicit or Implicit SSL

Possible values:

  • None: Specifies whether to use Explicit or Implicit SSL

  • Explicit: Specifies whether to use Explicit or Implicit SSL

  • Implicit: Specifies whether to use Explicit or Implicit SSL

  • Auto: Specifies whether to use Explicit or Implicit SSL

Default: 0 Example: FtpsSslMode.None

EnableClientAuth : Boolean

If enabled the client certificate is searched from user's certificate store

Default: False Example: false

ClientCertificateName : String

Optional. Enables certification search by name from the certification store of current user.

Default: - Example: mycert.crt

ClientCertificateThumbprint : String

Optional. Enables certification search by thumbprint from the certification store of current user.

Default: - Example: a909502dd82ae41433e6f83886b00d4277a32a7b

ValidateAnyCertificate : Boolean

If enabled the any certificate will be considered valid.

Default: False Example: false

ClientCertificatePath : String

Path to client certificate (X509).

Default: - Example: c:\example.cer

CertificateHashStringSHA1 : String

Certificate SHA1 hash string to validate against.

Default: - Example: D911262984DE9CC32A3518A1094CD24249EA5C49

Name
Description

ThrowErrorOnFail : Boolean

Should an exception be thrown when file transfer fails.

Default: True Example: true

RenameSourceFileBeforeTransfer : Boolean

Should the destination file be renamed with temporary file name during file transfer as a locking mechanism.

Default: True Example: true

RenameDestinationFileDuringTransfer : Boolean

Should the destination file be renamed with temporary file name during file transfer as a locking mechanism.

Default: True Example: true

CreateDestinationDirectories : Boolean

Should the destination directories be created if they do not exist. May not work on all servers.

Default: False Example: false

PreserveLastModified : Boolean

Should the Last Modified timestamp be preserved from the source.

Default: False Example: false

OperationLog : Boolean

While enabled all operations logs of executions will be returned with the result.

Default: True Example: true

Name
Description

TransferName : String

Optional descriptive name for the transfer.

Will be included in the file transfer log

entries and also in all error messages in the event log.

Default: "FTPUpload" Example: FTP Upload

WorkDir : String

Directory where temporary files are stored during transfer.

Default: - Example: c:\workDir

ProcessUri : String

The process URI, use #process.uri

Default: #process.uri Example: #process.uri

TaskExecutionID : String

Reference to the Task execution id, use #process.executionid

Default: #process.executionid Example: #process.executionid

Task Result

Name
Description

ActionSkipped : Boolean

True if action was skipped, otherwise false. Example: false

Success : Boolean

True if the transfer was successful, otherwise false. Example: false

UserResultMessage : String

Message of the transfer operations containing a simple representation of what happened in the task. Example: 1 files transferred: file1.txt

SuccessfulTransferCount : Int32

Count of files that has been successfully transferred. Example: 16

FailedTransferCount : Int32

Count of files that have not been transferred. Example: 2

TransferredFileNames : IEnumerable<String>

List of transferred file names. Example: [ "file1.txt", "file2.txt" ]

TransferErrors : Dictionary<String, IList1>`

Dictionary of file names and errors messages of the failed transfers. Example: { { "file1.txt", [ "error1", "error2" ] }, { "file2.txt", [ "error1", "error2" ] } }

TransferredFilePaths : IEnumerable<String>

List of transferred file paths. Example: [ "C:\dir\file1.txt", "C:\dir\file2.txt" ]

OperationsLog : IDictionary<String, String>

Operations logs for the transfer. Example: { { "2022-05-31 16.21.39.00Z", "operation1" }, { "2022-05-31 16.22.39.00Z", "operation2" }, { "2022-05-31 16.23.39.00Z", "operation3" } }

Task Changelog

Changelog is not available for this Task.

Last updated

Was this helpful?