x-amazon-apigateway-integration. responseParameters 物件 - Amazon API Gateway

本文為英文版的機器翻譯版本,如內容有任何歧義或不一致之處,概以英文版為準。

x-amazon-apigateway-integration. responseParameters 物件

指定從整合方法回應參數對應到方法回應參數。您可以將 headerbody 或靜態值映射到 header 類型的方法回應。僅支援 REST API。

屬性
屬性名稱 類型 描述
method.response.header.<param-name> string

具名參數值可從 headerbody 類型的整合回應參數產生。

x-amazon-apigateway-integration.responseParameters 範例

下列範列會將整合回應的 bodyheader 參數對應到方法回應的兩個 header 參數。

"responseParameters" : { "method.response.header.Location" : "integration.response.body.redirect.url", "method.response.header.x-user-id" : "integration.response.header.x-userid" }