I have been using AWS_PROXY
integration from API Gateway to trigger AWS Lambda functions many times and in the event I always receive 'headers'
along with 'body'
and many other parameters.
Now I try to use the Integration Subtype EventBridge-PutEvents
like this.
Type: AWS::ApiGatewayV2::Integration
Properties:
...
IntegrationType: AWS_PROXY
IntegrationSubtype: EventBridge-PutEvents
RequestParameters:
Source: SOME_TEXT
DetailType: SOME_TEXT
Detail: $request.body
It works, but if I try to include in Detail
not just the body, but the headers as well it cries with:
"Invalid source: $request.headers specified for destination: Detail"
How can I pass/map the request.headers
to the EventBridge message (Detail) without creating a custom Lambda in between API Gateway and EventBridge myself?