Interact with an SFTP (SSH File Transfer Protocol) Server using a username and password for auth
Go to siteSFTP (Secure File Transfer Protocol) is a network protocol that provides secure file transfers over secure shell (SSH) connections. It is an extension of the Secure Shell protocol, designed for secure file exchange between hosts. A user can securely transfer files between systems without having to worry about external threats, as the protocol is encrypted and authenticated.
With the SFTP API, you can build applications that securely transfer data, such as files and documents, between two different systems. Some example applications include:
module.exports = defineComponent({
props: {
sftp_password_based_auth: {
type: "app",
app: "sftp_password_based_auth",
}
},
async run({steps, $}) {
const Client = require('ssh2-sftp-client');
const {
host,
username,
password,
} = this.sftp_password_based_auth.$auth
const config = {
host,
username,
password,
}
const sftp = new Client()
await sftp.connect(config)
this.cwd = await sftp.cwd();
return await sftp.end();
},
})
Emit new events when files get created, changed or deleted from a remote directory. See the docs
Uploads a UTF-8 string as a file on an SFTP server
SFTP (password-based auth) uses API keys for authentication. When you connect your SFTP (password-based auth) account, Pipedream securely stores the keys so you can easily authenticate to SFTP (password-based auth) APIs in both code and no-code steps.
Below, enter the hostname of the SFTP server you'd like to connect to, your username, and the password you'd like to use to connect.
This app only supports password-based authentication, not authentication via private key. If you need to use a private key to connect to a host, please use the SFTP (key-based auth) app, instead.