mirror of
https://github.com/LukeHagar/vercel.git
synced 2025-12-10 04:22:12 +00:00
40 lines
920 B
TypeScript
40 lines
920 B
TypeScript
/// <reference types="node" />
|
|
import { Server, IncomingHttpHeaders, OutgoingHttpHeaders } from 'http';
|
|
export interface VercelProxyEvent {
|
|
Action: string;
|
|
body: string;
|
|
}
|
|
export interface VercelProxyRequest {
|
|
isApiGateway?: boolean;
|
|
method: string;
|
|
path: string;
|
|
headers: IncomingHttpHeaders;
|
|
body: Buffer;
|
|
}
|
|
export interface VercelProxyResponse {
|
|
statusCode: number;
|
|
headers: OutgoingHttpHeaders;
|
|
body: string;
|
|
encoding: BufferEncoding;
|
|
}
|
|
export interface ServerLike {
|
|
timeout?: number;
|
|
listen: (
|
|
opts: {
|
|
host?: string;
|
|
port?: number;
|
|
},
|
|
callback: (this: Server | null) => void
|
|
) => Server | void;
|
|
}
|
|
export type LauncherConfiguration = {
|
|
entrypointPath: string;
|
|
bridgePath: string;
|
|
helpersPath: string;
|
|
sourcemapSupportPath: string;
|
|
shouldAddHelpers?: boolean;
|
|
shouldAddSourcemapSupport?: boolean;
|
|
awsLambdaHandler?: string;
|
|
useRequire?: boolean;
|
|
};
|