gpt4 book ai didi

amazon-web-services - 映射模板 API 网关中的有效 Json

转载 作者:行者123 更新时间:2023-12-04 18:02:18 25 4
gpt4 key购买 nike

我正在使用 AWS API Gateway 和 Lambda,我正在尝试将有效的 Json 对象传递给 Lambda 函数以避免清理函数中的数据。使用此代码:

"params" : "$input.params()",

将导致此数据被发送到 Lambda 函数:

"params" : "{path={}, querystring={src_build=rfsdfsdf}, header={}}",

是否有将 $input.params 作为有效 json 字典的解决方案?

最佳答案

答案可能只是$input.json('$')

enter image description here

我根据来自 API Gateway Developer Guide 的信息回答了这个问题.

关于amazon-web-services - 映射模板 API 网关中的有效 Json,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/32988883/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com