export type Stat = { filename: string; basename: string; lastmod: string|null; size: number; type: string; mime: string; etag: string|null; props: Record; } export type WebDavClient = { copyFile(remotePath: string, targetRemotePath: string, options?: Record): Promise; createDirectory(dirPath: string, options?: Record): Promise; createReadStream(remoteFileName: string, options?: Record): ReadableStream; createWriteStream(remoteFileName: string, options?: Record, callback?: Function): WritableStream; customRequest(remotePath: string, requestOptions: Record, options?: Record): Promise; deleteFile(remotePath: string, options?: Record): Promise; exists(remotePath: string, options?: Record): Promise; getDirectoryContents(remotePath: string, options?: Record): Promise>; getFileContents(remoteFileName: string, options?: Record): Promise; getFileDownloadLink(remoteFileName: string, options?: Record): string; getFileUploadLink(remoteFileName: string, options?: Record): string; getQuota(options?: Record): Promise; moveFile(remotePath: string, targetRemotePath: string, options?: Record): Promise; putFileContents(remoteFileName: string, data: string|Buffer, options?: Record): Promise; stat(remotePath: string, options?: Record): Promise; } declare module 'webdav' { export function createClient(remoteURL: string, opts?: Record): WebDavClient; }