ipull
Version:
The only file downloader you'll ever need. For node.js and the browser, CLI and library for fast and reliable file downloads.
22 lines (21 loc) • 1.63 kB
TypeScript
import DownloadEngineNodejs, { DownloadEngineOptionsNodejs } from "./download-engine/engine/download-engine-nodejs.js";
import DownloadEngineMultiDownload, { DownloadEngineMultiDownloadOptions } from "./download-engine/engine/download-engine-multi-download.js";
import { CliProgressDownloadEngineOptions } from "./transfer-visualize/transfer-cli/GlobalCLI.js";
import { DownloadEngineRemote } from "./download-engine/engine/DownloadEngineRemote.js";
export type DownloadFileOptions = DownloadEngineOptionsNodejs & CliProgressDownloadEngineOptions;
/**
* Download one file with CLI progress
*/
export declare function downloadFile(options: DownloadFileOptions): Promise<DownloadEngineNodejs<import("./download-engine/streams/download-engine-write-stream/download-engine-write-stream-nodejs.js").default>>;
/**
* Stream events for a download from remote session, doing so by calling `emitRemoteProgress` with the progress info.
* - Supports CLI progress.
*/
export declare function downloadFileRemote(options?: CliProgressDownloadEngineOptions): DownloadEngineRemote;
export type DownloadSequenceOptions = CliProgressDownloadEngineOptions & DownloadEngineMultiDownloadOptions & {
fetchStrategy?: "localFile" | "fetch";
};
/**
* Download multiple files with CLI progress
*/
export declare function downloadSequence(options?: DownloadSequenceOptions | DownloadEngineNodejs | Promise<DownloadEngineNodejs>, ...downloads: (DownloadEngineNodejs | Promise<DownloadEngineNodejs>)[]): Promise<DownloadEngineMultiDownload<import("./download-engine/engine/download-engine-multi-download.js").DownloadEngineMultiAllowedEngines>>;