Is it possible to add a custom Header with AWS Lambda (HTTP API)

1k Views Asked by At

I'm using a custom authentication with AWS Lambda on my API Gateway HTTP API. Currently, if auth pass, it will return like this:

return {
    'isAuthorized': True,
    'context': {
        'userId': user_id
    }
}

I'm aware that with REST API its possible to use mappers and set a custom headers. But is it viable with HTTP API? I want to pass to my application a header X-AUTH-USER-ID with the value of context.userId

0

There are 0 best solutions below