Skip to content

ConnectionProfile

Defined in: src/types/public.ts:283

Connection settings accepted by facade and adapter implementations.

Every ConnectionProfile has a host and a provider (or protocol). Authentication and transport-specific material is layered on via the optional ssh, tls, oauth, and provider-specific blocks (e.g. s3, azure, dropbox).

const profile: ConnectionProfile = {
host: "sftp.example.com",
provider: "sftp",
username: "deploy",
ssh: {
privateKey: { path: "./keys/id_ed25519" },
pinnedHostKeySha256: "SHA256:abc123basesixfourpinFromKnownHosts=",
},
};
const profile: ConnectionProfile = {
host: "ftps.example.com",
provider: "ftps",
username: "deploy",
password: { env: "FTPS_PASSWORD" },
tls: { minVersion: "TLSv1.2" },
};
const profile: ConnectionProfile = {
host: "my-bucket",
provider: "s3",
username: process.env.AWS_ACCESS_KEY_ID,
password: { env: "AWS_SECRET_ACCESS_KEY" },
s3: { region: "us-east-1" },
};
PropertyTypeDescriptionDefined in
hoststringRemote hostname or IP address.src/types/public.ts:289
logger?ZeroTransferLoggerPer-profile logger override.src/types/public.ts:307
password?SecretSourcePassword or deferred secret source for password-based authentication.src/types/public.ts:295
port?numberRemote port; adapters should apply protocol defaults when omitted.src/types/public.ts:291
protocol?"ftp" | "ftps" | "sftp"Protocol to use for this connection, overriding the client default.src/types/public.ts:287
provider?ProviderIdProvider to use for this connection. Prefer this over the compatibility protocol field.src/types/public.ts:285
secure?booleanWhether encrypted transport should be requested for protocols that support it.src/types/public.ts:297
signal?AbortSignalAbort signal used to cancel connection setup or long-running operations.src/types/public.ts:305
ssh?SshProfileSSH settings for SFTP providers.src/types/public.ts:301
timeoutMs?numberOperation or connection timeout in milliseconds.src/types/public.ts:303
tls?TlsProfileTLS settings for encrypted providers such as FTPS.src/types/public.ts:299
username?SecretSourceUsername, account identifier, or deferred secret source for authentication.src/types/public.ts:293