# SFTP

Writes files to an SFTP server.

In order to have a different path for each object you should use function interpolations described [here](/platform/1.14/connectors/bloblang.md).

***

## Configuration

| Name          | Type        | Optional | Secret | Description                                                                                                                                                                                                                                                        |
| ------------- | ----------- | -------- | ------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| address       | string      | no       | no     | The address of the server to connect to.                                                                                                                                                                                                                           |
| path          | string      | no       | no     | The file to save the messages to on the server.                                                                                                                                                                                                                    |
| codec         | string      | yes      | no     | The way in which the bytes of messages should be written out into the output data stream. It's possible to write lines using a custom delimiter with the `delim:x` codec, where x is the character sequence custom delimiter. The value defaults to `"all-bytes"`. |
| credentials   | credentials | no       | no     | The credentials to use to log into the target server.                                                                                                                                                                                                              |
| max_in_flight | int         | yes      | no     | The maximum number of messages to have in flight at a given time. Increase this to improve throughput. The value defaults to `64`.                                                                                                                                 |

### Credentials

| Name     | Type   | Optional | Secret | Description                                                                              |
| -------- | ------ | -------- | ------ | ---------------------------------------------------------------------------------------- |
| username | string | yes      | no     | The username to connect to the SFTP server. The value defaults to `""`.                  |
| password | string | yes      | yes    | The password for the username to connect to the SFTP server. The value defaults to `""`. |
