API

Common API

Overview

These public interfaces are shared across various SSIS+ components. They are provided for implementing advanced functionality in your scripts. In order for you to use these interfaces in your project, you have to reference CozyRoc.SSISPlus.dll library.

IFileInfo (1.2 SR-2)

This interface is used to retrieve extended remote file information.

Name property (string)
Returns file name.
Size property (long)
Returns file size.
ModifiedTime property (DateTime)
Returns file modification time.
IsDirectory property (bool)
Returns true if directory.

IFtpClient (1.3)

This interface is used to access services provided by SFTP and FTPS servers.

SetWorkingDirectory method

Sets current remote working directory. These are the method parameters:

  • path (string) - remote directory path.
GetWorkingDirectory method

Get current remote working directory. The method result is the remote path.

IsDirectory method

Returns true if specified remote path is directory. These are the method parameters:

  • path (string) - remote path.
SendFile method

Uploads files to remote server. These are the method parameters:

  • src (string) - path to source local file(s).
  • dest (string) - path to destination remote directory.
  • overwrite (bool) - set to true, if you want to overwrite existing remote files.
SendStream method

Uploads stream of data to remote server. These are the method parameters:

  • src (Stream) - stream of data to upload.
  • dest (string) - path to destination remote file.
ReceiveFile method

Downloads files from remote server. These are the method parameters:

  • src (string) - path to source remote file(s).
  • dest (string) - path to destination local directory.
  • overwrite (bool) - set to true, if you want to overwrite existing local files.
ReceiveStream method

Downloads stream of data from remote server. The method result is Stream to source remote file. These are the method parameters:

  • src (string) - path to source remote file.
SetFileTime method

Sets remote file modified time. These are the method parameters:

  • file (string) - path to remote file.
  • time (DateTime) - new time of remote file.
CreateDirectory method

Creates remote directory. These are the method parameters:

  • directory (string) - remote directory path.
DeleteDirectory method

Deletes remote directory. These are the method parameters:

  • directory (string) - remote directory path.
DeleteFile method

Deletes remote file. These are the method parameters:

  • file (string) - path to remote file.
RenameFile method

Renames remote file. These are the method parameters:

  • oldFile (string) - path to remote file to rename.
  • newFile (string) - new file name path.
GetListing method

Gets listing of remote files. The method result is array of IFileInfo objects. These are the method parameters:

  • searchPath (string) - path to remote directory you want to retrieve the listing for.
  • isWildcard (bool) - specifies if searchPath contains wildcard expression or it is simply a remote path.
  • includeDir (bool) - specifies if result listing contains remote directories.

FTPS API

Overview

These public interfaces are used in FTPS components. They are provided for implementing advanced functionality in your scripts. In order for you to use these interfaces in your project, you have to reference CozyRoc.SSISPlus.dll library.

IFtpsClientConnection

When you call FTPS Connection Manager AcquireConnection method, it returns object implementing IFtpsClientConnection interface. This is the interface used for interaction with FTPS Server.

Connect method

Connects to FTPS server. The result is IFtpClient object.

Close method

Closes the connection to a FTPS Server. Use always after you finish working with the server. You may also dispose the returned object from Connect method as alternative.

IsConnected method

Returns true if connected to the server.

ConnectionType property (int)

Specify connection type. This property has the options listed in the following table.

Value Description
0 Unsecured FTP connection.
1 Use Explicit SSL FTPS.
2 Use Implicit SSL FTPS.
3 Use Explicit TLS FTPS (1.3 SR-1).
4 Use Implicit TLS FTPS (1.3 SR-1).
ServerHost property (string)

Specify the name or IP address of the FTPS server.

ServerPort property (int)

Specify the port number on the FTPS server to use for the connection. The default value of this property is 21.

ServerUser property (string)

Specify user name to access the FTPS server.

ServerPassword property (string)

Specify user password to access the FTPS server.

ServerTimeout property (int)

Specify the number of seconds before timing out session connect. The default value of this property is 60.

ProxyType property (int)

Specify proxy type. This property has the options listed in the following table.

Value Description
0 Proxy not specified.
1 Use SOCKS4 proxy type.
2 Use SOCKS5 proxy type.
3 Use HTTP proxy type.
4 Use FTP w/ SITE proxy type. Available only for unsecured connection type.
5 Use FTP w/ OPEN proxy type. Available only for unsecured connection type.
6 Use FTP w/ USER proxy type. Available only for unsecured connection type (1.3 SR-1).
ProxyHost property (string)

Specify the name or IP address of the proxy server.

ProxyPort property (int)

Specify the port number on the proxy server to use for the connection. The default value of this property is 80.

ProxyUser property (string)

Specify user name to access the proxy server.

ProxyPassword property (string)

Specify password to access the proxy server.

Jabber API

Overview

These public interfaces are used in Jabber related services components. They are provided for implementing advanced functionality in your scripts. In order for you to use these interfaces in your project, you have to reference CozyRoc.SSISPlus.dll library.

IJabberConnection

When you call Jabber Connection Manager AcquireConnection method, it returns object implementing IJabberConnection interface. This is the interface used for interaction with Jabber Server. The Jabber Connection Manager is based on jabber-net library.

Connect method

Connects to Jabber server. The result is JabberClient object.

Close method

Closes the connection to a Jabber Server. Use always after you finish working with the server.

IsConnected method

Returns true if connected to the server.

ServerUser property (string)

Specify user name in email-like format to connect Jabber server.

ServerPassword property (string)

Specify user password to access the Jabber server.

ServerTimeout property (int)

Specify the number of seconds before timing out session connect. The default value of this property is 30.

NetworkHost property (string)

Specify the network host of the Jabber server. Set this property if you have issues resolving the domain name of the Jabber server.

ServerPort property (int)

Specify the port number on the Jabber server to use for the connection. The default value of this property is 5222.

UsePlainText property (bool)

Set to true to use plain text authentication when connecting to the Jabber server.

UseSSL property (bool)

Set to true to use secure-sockets layer when connecting to the Jabber server.

ConnectionType property (int)

Specify connection type to Jabber server. This property has the options listed in the following table

Value Description
0 Use "Normal" XMPP socket.
1 Use XMPP protocol extension that enables access to a Jabber server from behind firewalls which do not allow outgoing sockets on port 5222, via HTTP requests
2 Use a transport protocol specification that emulates a bidirectional stream between two entities (such as a client and a server) by efficiently using multiple synchronous HTTP request/response pairs without requiring the use of polling or asynchronous chunking.
PollingURL property (string)

Contains the URL to poll on, or bind to. Related to ConnectionType property.

RetainSameConnection property (bool)

Set to true to use same connection to Jabber server. This implies the connection to Jabber server will stay alive during the package execution. The default value of this property is true.

ProxyType property (int)

Specify proxy type. This property has the options listed in the following table.

Value Description
0 Proxy not specified
1 Use SOCKS4 proxy type.
2 Use SOCKS5 proxy type.
3 Use HTTP CONNECT proxy type.
ProxyHost property (string)

Specify the name or IP address of the proxy server.

ProxyPort property (int)

Specify the port number on the proxy server to use for the connection. The default value of this property is 80.

ProxyUser property (string)

Specify user name to access the proxy server.

ProxyPassword property (string)

Specify password to access the proxy server.

Amazon API

Overview

These public interfaces are used in Amazon related services components. They are provided for implementing advanced functionality in your scripts. In order for you to use these interfaces in your project, you have to reference CozyRoc.SSISPlus.dll library.

IAmazonS3Connection

When you call Amazon S3 Connection Manager AcquireConnection method, it returns object implementing IAmazonS3Connection interface. This is the interface used for interaction with Amazon S3 service.

GetBucketsList method

Retrieves list of available buckets. The method result is array of strings.

GetBucketContent method

Retrieves list of available objects in a bucket. The method result is array of strings. These are the method parameters:

  • bucket (string) - name of bucket.
GetObject method

Downloads object from Amazon S3 service. The method result is Stream to object. These are the method parameters:

  • bucket (string) - name of bucket.
  • name (string) - name of object.
SendObject method

Uploads object to Amazon S3 service. These are the method parameters:

  • bucket (string) - name of bucket.
  • name (string) - name of object.
  • stream (Stream) - stream to uploaded object.
  • contentType (string) - MIME content type of object.
  • acl (string) - access control of object. This parameter has the options listed in the following table (from Amazon S3 documentation).
    Value Description
    private Owner gets FULL_CONTROL.
    public-read Owner gets FULL_CONTROL and the anonymous principal is granted READ access.
    public-read-write Owner gets FULL_CONTROL, the anonymous principal is granted READ and WRITE access.
    authenticated-read Owner gets FULL_CONTROL, and any principal authenticated as a registered Amazon S3 user is granted READ access.
RemoveObject method

Removes object from Amazon S3 service. These are the method parameters:

  • bucket (string) - name of bucket.
  • name (string) - name of object.
ServerHost property (string)

Specify the name or IP address of the Amazon S3 service.

ServerSecure property (bool)

Specify to establish secure HTTPS connection with Amazon S3 service on port 443.

ServerRegularCalling property (bool)

Specify to connect to Amazon S3 service, using regular calling format. Set to false, when connecting to EU Amazon S3 service.

ServerUser property (string)

Specify access key for Amazon S3 service.

ServerPassword property (string)

Specify secret key for Amazon S3 service.

ServerTimeout property (int)

Specify the number of seconds before timing out session connect. The default value of this property is 100.

UseProxy property (bool)

Set to true to use proxy.

ProxyHost property (string)

Specify the name or IP address of the proxy server.

ProxyPort property (int)

Specify the port number on the proxy server to use for the connection. The default value of this property is 80.

ProxyUser property (string)

Specify user name to access the proxy server.

ProxyPassword property (string)

Specify password to access the proxy server.

SSH API

Overview

These public interfaces are used in the SSH components. They are provided for implementing advanced functionality in your scripts. In order for you to use these interfaces in your project, you have to reference CozyRoc.SSISPlus.dll library.

ISshClientConnection

SSH Connection Manager component is based on Tamir Gal's SharpSsh secure communications library. When SSIS ConnectionManager.AcquireConnection method is called, it returns object implementing ISshClientConnection interface. This is the interface used for configuration and connection to secure SSH-enabled server.

Connect method

When called, connects to remote server, returning Channel object. This method has one parameter, which can be one of the options listed in the following table.

Value Result Channel
session ChannelSession
shell ChannelShell
exec ChannelExec
x11 ChannelX11
direct-tcpip ChannelDirectTCPIP
forwarded-tcpip ChannelForwardedTCPIP
sftp Starting from SSIS+ 1.3 the returned object implements IFtpClient interface and it is the recommended way for interacting with the remote server. You can still get access to the low-level backend object by casting the returned object to ChannelSftp.
subsystem ChannelSubsystem
Close method

Closes connection to remote server.

IsConnected method

Returns true if there is open connection to remote server.

ServerHost property (string)

Specify the name or IP address of the SSH server.

ServerPort property (int)

Specify the port number on the SSH server to use for the connection. The default value of this property is 22.

ServerUser property (string)

Specify user name to access the SSH server.

ServerPassword property (string)

Specify password to access the SSH server.

ServerTimeout property (int)

Specify the number of seconds before timing out session connect. The default value of this property is 60.

ProxyType property (int)

Specify proxy type. This property has the options listed in the following table.

Value Description
0 Proxy not specified
1 Use tunnel (HTTP) proxy type.
2 Use SOCKS4 proxy type.
3 Use SOCKS5 proxy type.
ProxyHost property (string)

Specify the name or IP address of the proxy server.

ProxyPort property (int)

Specify the port number on the proxy server to use for the connection. The default value of this property is 80.

ProxyUser property (string)

Specify user name to access the proxy server.

ProxyPassword property (string)

Specify password to access the proxy server.

Package API

Overview

Package Connection Manager component provides access to a package. When SSIS ConnectionManager.AcquireConnection method is called, it returns object implementing IPackageConnection interface. In order for you to use this interface in your project, you have to reference CozyRoc.SSISPlus.dll library.

IPackageConnection interface

GetPackage method

Gets access to the Package object.

Execute method

Prepares and executes package.

WaitToFinish method

Waits for package to complete execution and performs cleanup.

Location property (int)

Specify the type of package storage location. This property has the options listed in the following table.

Value Description
0 Connection to current package.
1 Package is stored in SQL Server.
2 Package is stored on a file share.
3 Package is stored in SSIS Package Store.
DecryptPassword property (string)

Specify the password to use to decrypt package.

ServerName property (string)

Specify name of the server where the package is stored.

ServerUser property (string)

Specify user name to access the SQL server. Applies only when package location is specified to SQL Server.

ServerPassword property (string)

Specify password to access the SQL server. Applies only when package location is specified to SQL Server.

PackagePath property (string)

Specify path to package.

Syndicate content