UNPKG

456 BTypeScriptView Raw
1/// <reference types="express" />
2import { Request } from '../types';
3import { BodyParser, RequestBody } from './types';
4/**
5 * A special body parser to retain request stream as is.
6 * It will be used by explicitly setting `x-parser` to `'stream'` in the request
7 * body spec.
8 */
9export declare class StreamBodyParser implements BodyParser {
10 name: symbol;
11 supports(mediaType: string): boolean;
12 parse(request: Request): Promise<RequestBody>;
13}