SSH (key-based auth)

Use the Secure Shell protocol to execute commands on a remote server using a private key

Go to site
Explore
/
Apps
/
SSH (key-based auth)

SSH (key-based auth) API Integrations

Build and run workflows using the SSH (key-based auth) API. Use 1000s of open source triggers and actions across 500+ apps. Or write custom code to integrate any app or API in seconds.

const SSH2Promise = require('ssh2-promise')

const { 
  host, 
  port,
  username, 
  privateKey,
} = auths.ssh

const ssh = new SSH2Promise({
  host,
  port,
  username,
  privateKey,
})

await ssh.connect()
console.log("Connection established")

// Replace this with the command you'd like to run
const resp = await ssh.exec("whoami")
console.log(resp)

await ssh.close()

Authentication

SSH (key-based auth) uses API keys for authentication. When you connect your SSH (key-based auth) account, Pipedream securely stores the keys so you can easily authenticate to SSH (key-based auth) APIs in both code and no-code steps.

This app holds details for a specific host or server where you want to run commands using the SSH protocol.

Below, enter the hostname and port of the server you'd like to connect to, your username, and the private key you'd like to use to connect.

This app only supports key pair authentication, not authentication via password. If you need to use a username / password to connect to a host, please use the SSH (password-based auth) app, instead.