Search documentation...

K

SFTP

Transfer data at scale from your warehouse to your apps through SFTP

Setup

To get started, you will need your hostname, port, credentials. This user needs to have access to the target directory and file with write privileges. A "permission denied" error message during a sync indicates the user may not have write permissions for both the directory and the file.

You'll need to allowlist Hightouch's IP addresses to allow our systems to contact your SFTP server. Reference our docs to determine which IPs you need to allowlist.

Supported Authentication Methods

We support three authentication methods:
  • Username + password
  • Username + SSH private key
  • Username + SSH private key + passphrase
We support two formats for the SSH private key:
  • OpenSSH
  • RSA
Provide the full private key for the user, including the header and footer.
For example:
-----BEGIN OPENSSH PRIVATE KEY-----
<private key body>
<private key body>
<private key body>
-----END OPENSSH PRIVATE KEY-----

Syncing

Sync Modes

  • All - All Mode creates a CSV file with all the rows in the query results, every time the sync is run.
  • Insert - Insert mode creates a CSV file with the rows that were added since the last sync.

File Name

The file name field will allow you to specify which directory and the name of the file that you want to name your results. The parent directory for the file must exist. In the screenshot below, we've specified that we want to put the file in the upload directory and the file name is results.csv.
You can also timestamp variables in the file name, surrounding each with {}. We currently support these timestamp variables: YYYY, MM, DD, HH, mm, ss, and ms. All dates and times will be UTC.
For example: upload/{YYYY}-{MM}-{DD}-{HH}-{mm}-result.csv.
You can also set a File Name Timestamp Offset. By default, the date/time used to generate the file name (above) is the date/time that the sync takes place; you can enter a number of seconds to offset this (offset can be positive or negative).
Ex. To set the date in the file name to 24 hours before the sync takes place, input -86400. The default offset is 0.

Columns to Sync

For this destination, we give you the ability to export all columns as they are represented in your model.
If you need remap the fields that you're exporting, maybe because you don't want to alter your model, you can manually map fields. Only the fields that you map will be exported in this instance. In this example, we're just exporting id, email and location. These fields are mapped to the new fields in the csv as user_id, user_email and user_location respectfully. All other columns from your results are ignored.

CSV Header

We provide you the option to include a CSV header with your exported results.

Byte Order Mark

We provide you the option to prepend a byte order mark (BOM) to the exported file. The BOM is <U+FEFF>.

Encoding

By default, the file will be saved in ASCII encoding. If there are any non-ASCII characters in your results, the file will be saved with utf-8 encoding. If the BOM option is enabled, the file will be saved with utf-8 encoding with BOM.

Other Considerations

This destination will not respect any sorting that you have in your model. It will export results file sorted by ID. You will need to ensure that the file that you transmit is removed from the folder before the next sync runs. This ensures that you don't encounter an error when Hightouch detects that the file already exists.

    Need help?

    Our team is relentlessly focused on your success. We're ready to jump on a call to help unblock you.

    • Connection issues with your data warehouse?
    • Confusing API responses from destination systems?
    • Unsupported destination objects or modes?
    • Help with complex SQL queries?

    or

    Feature Requests?

    If you see something that's missing from our app, let us know and we'll work with you to build it!

    We want to hear your suggestions for new sources, destinations, and other features that would help you activate your data.

On this page

SetupSupported Authentication MethodsSyncingSync ModesFile NameColumns to SyncCSV HeaderByte Order MarkEncodingOther Considerations

Was this page helpful?