///
///
///
import { Readable } from "stream";
/**
* https://nodejs.org/api/buffer.html#buffer_buffers_and_character_encodings
*/
type SupportedEncodings = "utf8" | "base64";
export declare function streamToString(stream: Readable, streamSize?: number, encoding?: SupportedEncodings): Promise;
export declare function streamToBuffer(stream: Readable): Promise;
export declare function streamToSha256(stream: Readable): Promise;
export declare function streamToSha1(stream: Readable): Promise;
/**
* Reads up to 2 megabytes from the stream and tries to JSON.parse the result.
* Will reject if an error occurs from within the stream or when parsing cannot be done.
*/
export declare function streamToJson(stream: Readable): Promise;
export {};