import pysftp
from .aliases import PathLike
from .auth import LikeSSHAuth
from _typeshed import Incomplete
from paramiko.hostkeys import HostKeys
from typing import BinaryIO

class PortHostKeys(HostKeys):
    port: Incomplete
    def __init__(self, filename: PathLike, port: int) -> None: ...

class SFTPConnection(pysftp.Connection):
    def __init__(self, authinfo: LikeSSHAuth) -> None: ...

def sftp_open(client: pysftp.Connection, remotepath: PathLike, mode: str = ...): ...
def sftp_download(client: pysftp.Connection, remotepath: PathLike, localpath: PathLike) -> None: ...
def sftp_download_bytes(client: pysftp.Connection, remotepath: PathLike) -> BinaryIO: ...
def sftp_upload_bytes(client: pysftp.Connection, data: BinaryIO, remotepath: PathLike, mode: str = ...) -> None: ...
