Configure the API
- Enter the Amazon API Gateway console and create a new API. Then, create a POST method.
- In the Method Request configuration page, create the following three http-headers: Accept, Content-Type and SOAPAction (note that not all SOAP webservices require a SOAPAction).
- In the Integration Request config page set:
- Integration type: HTTP
- Method: POST
- Endpoint URL: SOAP endpoint of the SOAP service you’re exposing. For this recipe, I’m using the free GetCountries webservice from webservicex.net which simply returns a list of countries.
- Content-handling: passthrough
- Body Mapping Templates: ‘When there are no templates defined (recommended)’
- Content-handling: Passthrough
- Response Body for 200, set response model content-type to: text/xml