Use Case: I need to perform an API request mapping that requires data from DynamoDB.
Desired Solution: I'd like to do this using API Gateway features if possible, which would look something like this:
- An external REST API request is received by API Gateway
- A
Proxy Resourceextracts a parameter, say accountId, from the HTTP path - A Service Integration (
GetItem) reads a set of values from DynamoDB using the accountId key - The values read from the DB are input to a
Request MapperVTL template - The transformed API request is then sent to an
HTTP Integrationendpoint
Questions:
- Is that possible to do using API Gateway out-of-the-box or is that sequence too advanced?
- If it's not possible, then is a lambda the best option to do most of this work (read DB, transform request, route HTTP)?
Thanks for your help!