API Gateway can transform requests and responses using mapping templates. Mapping templates are written in Velocity Template Language (VTL) and allow you to modify the structure and content of the request and response data.
Example Code: Request Transformation with AWS API Gateway
# Mapping Template for Request
{
"httpMethod": "$context.httpMethod",
"body": $input.json('$')
}