Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我非常希望能够在从 API 网关上下文传入的 Lambda 调用中使用 context.stage - 但我只能看到如何将其放入消息正文(事件对象)中。有没有办法向 Lambda 上下文添加任意信息?
我相信您唯一的选择是将其添加到活动中。您始终可以在 Lambda 函数的开头提取值,然后删除该属性。
AWS 的 Rest API 示例做了类似的事情:
var operation = event.operation; delete event.operation;