@Stability(value=Stable) public static final class IntegrationResponse.Builder extends Object implements software.amazon.jsii.Builder<IntegrationResponse>
IntegrationResponse| Constructor and Description |
|---|
Builder() |
| Modifier and Type | Method and Description |
|---|---|
IntegrationResponse |
build()
Builds the configured instance.
|
IntegrationResponse.Builder |
contentHandling(ContentHandling contentHandling)
Sets the value of
IntegrationResponse.getContentHandling() |
IntegrationResponse.Builder |
responseParameters(Map<String,String> responseParameters)
Sets the value of
IntegrationResponse.getResponseParameters() |
IntegrationResponse.Builder |
responseTemplates(Map<String,String> responseTemplates)
Sets the value of
IntegrationResponse.getResponseTemplates() |
IntegrationResponse.Builder |
selectionPattern(String selectionPattern)
Sets the value of
IntegrationResponse.getSelectionPattern() |
IntegrationResponse.Builder |
statusCode(String statusCode)
Sets the value of
IntegrationResponse.getStatusCode() |
@Stability(value=Stable) public IntegrationResponse.Builder statusCode(String statusCode)
IntegrationResponse.getStatusCode()statusCode - The status code that API Gateway uses to map the integration response to a MethodResponse status code. This parameter is required.this@Stability(value=Stable) public IntegrationResponse.Builder contentHandling(ContentHandling contentHandling)
IntegrationResponse.getContentHandling()contentHandling - Specifies how to handle request payload content type conversions.this@Stability(value=Stable) public IntegrationResponse.Builder responseParameters(Map<String,String> responseParameters)
IntegrationResponse.getResponseParameters()responseParameters - The response parameters from the backend response that API Gateway sends to the method response.
Use the destination as the key and the source as the value:
this@Stability(value=Stable) public IntegrationResponse.Builder responseTemplates(Map<String,String> responseTemplates)
IntegrationResponse.getResponseTemplates()responseTemplates - The templates that are used to transform the integration response body.
Specify templates as key-value pairs, with a content type as the key and
a template as the value.this@Stability(value=Stable) public IntegrationResponse.Builder selectionPattern(String selectionPattern)
IntegrationResponse.getSelectionPattern()selectionPattern - Specifies the regular expression (regex) pattern used to choose an integration response based on the response from the back end.
For example, if the success response returns nothing and the error response returns some string, you
could use the .+ regex to match error response. However, make sure that the error response does not contain any
newline (\n) character in such cases. If the back end is an AWS Lambda function, the AWS Lambda function error
header is matched. For all other HTTP and AWS back ends, the HTTP status code is matched.this@Stability(value=Stable) public IntegrationResponse build()
build in interface software.amazon.jsii.Builder<IntegrationResponse>IntegrationResponseNullPointerException - if any required attribute was not providedCopyright © 2022. All rights reserved.