Working with the SFTP Connector

Discover how to automatically and securely transfer documents from Precoro to your SFTP server, simplifying the upload process into your business tools.

TABLE OF CONTENTS

What is an SFTP Connector?

SFTP (Secure File Transfer Protocol) is a safe way to send files over the Internet. It utilizes SSH encryption to protect your data during transmission while allowing you to customize the transfer process. For instance, an SFTP connection enables you to automatically send documents—such as invoices, expenses, and attachments—directly from Precoro to your secure server.

You can easily customize document fields, set download schedules, and select the specific document types you need. Once transferred, these files are ready for seamless upload to your business tools for further processing.

In short, here are the benefits of using the SFTP Connector with Precoro:

  • Protect sensitive data with encrypted file transfers.
  • Schedule automatic downloads of invoices, expenses, and attachments.
  • Customize document types, formats, and fields to suit your needs.
  • Eliminate manual workload and reduce human error.
  • Simplify integration with your accounting tools for seamless workflows.

How the SFTP Integration Works with Precoro

The SFTP connection in Precoro streamlines your document management by automating the transfer of approved documents to your secure server. Here's how the integration works:

  1. Document scanning: The integration script scans for new or updated documents in Precoro that have the status "Approved" or other selected statuses.
  2. File transfer: When new documents are found, the script creates a zip archive or folder within the main directory for these documents. It then transfers the document attachments and metadata from Precoro to a specific folder on your server, such as "Precoro." The zip archive or folder is named using a format like "YYYY-MM-DD hh am/pm" for easy identification.
  3. Handling updated documents: During the next sync cycle, the script checks for any documents that have been updated in Precoro. It re-syncs these updated documents and their attachments, marking them with a flag to indicate that they have been revised.

How to Configure the SFTP Connector

Setting up the SFTP connection with Precoro is straightforward. Follow these steps to get started:

Step 1: Get the API Token

First, you need to create an API token:

  1. Navigate to the Configurations > Integrations page in Precoro.
  2. Click on the API Key section.
  3. Select the Generate API Key button.
  4. Save the generated token for future use.

You can find more details on retrieving the API token in this article.

Step 2: Choose Your SFTP Connection Type

Decide how you want to authenticate with your SFTP server. The integration supports two authentication methods: basic authentication (using a username and password) and SSH key authentication.

For basic authentication, gather the following details:

  • Host: Enter the IP address or URL of your SFTP server.
  • Port: Specify the port your SFTP server is using (commonly, this is port 22).
  • Username: Your SFTP username.
  • Password: Your SFTP password.

For SSH key authentication, you will need your SSH key.

💡If your SFTP server has an IP allow list, ensure that you whitelist the following IP addresses for a successful connection:

  • 34.228.139.29
  • 3.227.99.15

Step 3: Prepare the Setup Details

Prepare a document that outlines the key details for your SFTP integration:

  1. Specify the documents you want to automatically download (e.g., invoices, expenses, and attachments).
  2. Decide how often you want the downloads to occur (e.g., hourly, daily, or weekly).
  3. Choose your preferred file format (options include CSV, Excel, or XML).
  4. List the specific data fields you need and how they should look in the generated file.

Here’s an example of how fields are named in Precoro and how you can customize their appearance in the generated file:

#

Fields in Precoro

Generated File

1

Supplier Invoice Number

Invoice Number

2

Reference QR Invoice (DCF)

Reference QR Invoice

3

Supplier Vendor ID

Vendor ID

4

Gross Total

Invoice Amount TTC

5

Issue Date

Invoice Date

6

Item Description

Comment

7

Department (DCF)

Department

8

Gross Total

Gross Total

Step 4: Contact the Customer Success Team

Once you have the setup details ready, reach out to Precoro’s Customer Success team. They will help you configure the SFTP integration and ensure everything works smoothly based on your provided preferences.

Frequently Asked Questions

What document types are supported by the SFTP connector?

You can download the following document types from Precoro to your SFTP server:

  • Invoices
  • Expenses
  • Attachments related to invoices and expenses
How often can I schedule document downloads?

You can schedule downloads at intervals that suit your workflow, such as:

  • Hourly
  • Daily
  • Weekly
  • Custom intervals
What file formats are supported?

The SFTP integration supports multiple file formats, including:

  • CSV
  • Excel
  • XML
Can I customize the fields in the downloaded documents?

Yes, you can select specific data fields from the documents to ensure they align with your accounting or business tools.