How to modify api gateway response headers and contents

0

I connected a lambda Fast API server to the API gateway. The request is mapped correctly now. I'm trying to use a response mapping template in the API gateway to manipulate the response. I'm not sure how exactly I can do it there.

Jehan
asked 2 months ago147 views
1 Answer
0
Accepted Answer

Hello.

The mapping template syntax is described in the following documentation:
Based on this, the response from Lambda can be processed by API Gateway and returned to the user as a response.
https://docs.aws.amazon.com/apigateway/latest/developerguide/models-mappings.html

I am using an image of a slightly older management console, but I think the following blog will be helpful for setting up.
https://medium.com/@nwosuonyedikachi/how-to-do-input-output-mappings-in-the-api-gateway-for-lambda-functions-on-the-aws-cloud-console-8f4304f25dc2

profile picture
EXPERT
answered 2 months ago
profile picture
EXPERT
reviewed 2 months ago
  • This worked thanks

    #set($context.requestOverride.header.header3 = $header3Value)

You are not logged in. Log in to post an answer.

A good answer clearly answers the question and provides constructive feedback and encourages professional growth in the question asker.

Guidelines for Answering Questions