11import { RequestListener } from "http" ;
22import { Handler } from "aws-lambda" ;
33import Logger from "./logger" ;
4+ import Framework from "./frameworks" ;
45
56type EventSources = "AWS_SNS" | "AWS_DYNAMODB" ;
67
@@ -18,12 +19,23 @@ interface BinarySettings {
1819 isBinary ?: Function | boolean ;
1920 contentTypes ?: string [ ] ;
2021}
22+
23+ interface LogSettings {
24+ level : string ;
25+ }
26+
2127interface ConfigureParams {
2228 app : RequestListener ;
29+ logSettings ?: LogSettings ;
30+ log ?: Logger ;
31+ framework ?: Framework ;
2332 binaryMimeTypes ?: string [ ] ;
2433 binarySettings ?: BinarySettings ;
34+ resolutionMode ?: string ;
35+ eventSourceName ?: string ;
2536 eventSource ?: EventSource ; // TODO:
2637 eventSourceRoutes ?: { [ key in EventSources ] ?: string } ;
38+ respondWithErrors ?: boolean ;
2739}
2840
2941interface BinarySettings {
@@ -37,7 +49,9 @@ interface ConfigureResult<TEvent = any, TResult = any> {
3749 proxy : ( proxyParams : ProxyParams ) => Promise < Object > ;
3850}
3951
40- declare function configure < TEvent = any , TResult = any > ( configureParams : ConfigureParams ) : Handler < TEvent , TResult > & ConfigureResult < TEvent , TResult > ;
52+ declare function configure < TEvent = any , TResult = any > (
53+ configureParams : ConfigureParams
54+ ) : Handler < TEvent , TResult > & ConfigureResult < TEvent , TResult > ;
4155
4256// declare function proxy(proxyParams: ProxyParams): Promise<any>
4357
0 commit comments