@tsed/platform-aws
Version:
Module to support AWS function with Ts.ED
17 lines • 598 B
JavaScript
import { HeaderParams, UsePipe } from "@tsed/common";
import { useDecorators } from "@tsed/core";
import { Description } from "@tsed/schema";
import { ParseApiGatewayPipe } from "../pipes/ParseApiGatewayPipe.js";
/**
* Return the decoded x-apigateway-event
* @decorator
*/
export function AwsEvent() {
return useDecorators(HeaderParams({
expression: "x-apigateway-event",
useConverter: false,
useType: String,
useValidation: false
}), Description("x-apigateway-event serialized Json"), UsePipe(ParseApiGatewayPipe));
}
//# sourceMappingURL=awsEvent.js.map