CDK to add Http headers in the integration request

0

I have to add a few HTTP headers mapped to the context values that come from the lambda authorizer as shown below

"context": {
    "company_id": "xxxxx-xxx-xxxxxx",
    "Owner":"xxxxx",
  }

and the headers will be sent to the minimal API.

Can anyone help me with the CDK code(.ts) that sends the custom headers to the .net API?

1 個回答
1

Hi,

Thanks for reaching out. You can refer to this part of the CDK .NET reference for an example on how you can override the request and response parameters in order to add your custom headers. Please search for "Working with models" in the page if the link does not take you there directly.

Please check this out and let us know how you go.

AWS
支援工程師
Ryan_A
已回答 2 年前

您尚未登入。 登入 去張貼答案。

一個好的回答可以清楚地回答問題並提供建設性的意見回饋,同時有助於提問者的專業成長。

回答問題指南