2023-01-27 03:22:44 -08:00
|
|
|
import type { ICredentialType, INodeProperties } from 'n8n-workflow';
|
2020-08-04 00:01:13 -07:00
|
|
|
|
|
|
|
export class Sftp implements ICredentialType {
|
|
|
|
name = 'sftp';
|
2022-12-02 12:54:28 -08:00
|
|
|
|
2020-08-04 00:01:13 -07:00
|
|
|
displayName = 'SFTP';
|
2022-12-02 12:54:28 -08:00
|
|
|
|
2020-09-21 02:11:02 -07:00
|
|
|
documentationUrl = 'ftp';
|
2022-12-02 12:54:28 -08:00
|
|
|
|
2021-06-12 09:39:55 -07:00
|
|
|
properties: INodeProperties[] = [
|
2020-08-04 00:01:13 -07:00
|
|
|
{
|
|
|
|
displayName: 'Host',
|
|
|
|
name: 'host',
|
|
|
|
required: true,
|
2021-06-12 09:39:55 -07:00
|
|
|
type: 'string',
|
2020-08-04 00:01:13 -07:00
|
|
|
default: '',
|
|
|
|
},
|
|
|
|
{
|
|
|
|
displayName: 'Port',
|
|
|
|
name: 'port',
|
|
|
|
required: true,
|
2021-06-12 09:39:55 -07:00
|
|
|
type: 'number',
|
2020-08-04 00:01:13 -07:00
|
|
|
default: 22,
|
|
|
|
},
|
|
|
|
{
|
|
|
|
displayName: 'Username',
|
|
|
|
name: 'username',
|
|
|
|
required: true,
|
2021-06-12 09:39:55 -07:00
|
|
|
type: 'string',
|
2020-08-04 00:01:13 -07:00
|
|
|
default: '',
|
|
|
|
},
|
|
|
|
{
|
|
|
|
displayName: 'Password',
|
|
|
|
name: 'password',
|
2021-06-12 09:39:55 -07:00
|
|
|
type: 'string',
|
2020-08-04 00:01:13 -07:00
|
|
|
typeOptions: {
|
|
|
|
password: true,
|
|
|
|
},
|
|
|
|
default: '',
|
|
|
|
},
|
2020-11-12 10:23:55 -08:00
|
|
|
{
|
|
|
|
displayName: 'Private Key',
|
|
|
|
name: 'privateKey',
|
2021-06-12 09:39:55 -07:00
|
|
|
type: 'string',
|
2020-11-12 10:23:55 -08:00
|
|
|
default: '',
|
2022-07-24 08:36:17 -07:00
|
|
|
description:
|
|
|
|
'String that contains a private key for either key-based or hostbased user authentication (OpenSSH format)',
|
2020-11-12 10:23:55 -08:00
|
|
|
},
|
|
|
|
{
|
|
|
|
displayName: 'Passphrase',
|
|
|
|
name: 'passphrase',
|
|
|
|
typeOptions: {
|
|
|
|
password: true,
|
|
|
|
},
|
2021-06-12 09:39:55 -07:00
|
|
|
type: 'string',
|
2020-11-12 10:23:55 -08:00
|
|
|
default: '',
|
2022-04-13 23:32:27 -07:00
|
|
|
description: 'For an encrypted private key, this is the passphrase used to decrypt it',
|
2020-11-12 10:23:55 -08:00
|
|
|
},
|
2020-08-04 00:01:13 -07:00
|
|
|
];
|
|
|
|
}
|