是否有任何解决方案可以让 AWS API Gateway 根据 HTTP 请求正文的数据进行路由,而不使用任何其他 AWS 服务 lambda 等? (我的HTTP请求体只包含环境ID)
我创建了一个解决方案,其中另一个 AWS 服务帮助处理 body 数据。如果可能的话,我正在寻找在这种情况下仅使用 AWS API Gateway 的解决方案。提前感谢您的帮助!
最佳答案
仅使用 API Gateway 无法根据请求正文中的数据进行路由。
您可以使用路径和查询字符串参数进行路由。
参见Working with routes for HTTP APIs
API Gateway selects the route with the most-specific match, using the following priorities:
Full match for a route and method
Match for a route and method with a greedy path variable
The default route
关于amazon-web-services - AWS API Gateway 按请求正文路由,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/75107526/