Open chuckthepiranha opened 3 years ago
So I was able to specify the content type by overriding the headers with a mapping template:
selectionPattern: '2\d{2}'
responseTemplates:
application/xml: |-
#set($inputRoot = $input.path('$'))
#set($context.responseOverride.header.Content-Type = 'application/xml')
No matter what I do, my response shows up as application/json. I am able to change the method response model to application/xml in API Gateway manually and it works so I am assuming I would need to change something in my response parameters... Is there something I am doing wrong? When I try deploying I get this:
errors : [Invalid mapping expression specified: true, Invalid mapping expression specified: integration.response.header.Content-Type]