Interface IntegrationResponse

All Superinterfaces:
All Known Implementing Classes:

@Generated(value="jsii-pacmak/1.99.0 (build 8f757e4)", date="2024-06-13T18:49:13.720Z") @Stability(Stable) public interface IntegrationResponse extends

 // The code below shows an example of how to instantiate this type.
 // The values are placeholders you should change.
 IntegrationResponse integrationResponse = IntegrationResponse.builder()
         // the properties below are optional
                 "responseParametersKey", "responseParameters"))
                 "responseTemplatesKey", "responseTemplates"))
  • Method Details

    • getStatusCode

      @Stability(Stable) @NotNull String getStatusCode()
      The status code that API Gateway uses to map the integration response to a MethodResponse status code.
    • getContentHandling

      @Stability(Stable) @Nullable default ContentHandling getContentHandling()
      Specifies how to handle request payload content type conversions.

      Default: none the request payload is passed through from the method request to the integration request without modification.

    • getResponseParameters

      @Stability(Stable) @Nullable default Map<String,String> getResponseParameters()
      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:

      • The destination must be an existing response parameter in the MethodResponse property.
      • The source must be an existing method request parameter or a static value. You must enclose static values in single quotation marks and pre-encode these values based on the destination specified in the request.

      See Also:
    • getResponseTemplates

      @Stability(Stable) @Nullable default Map<String,String> getResponseTemplates()
      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.

      See Also:
    • getSelectionPattern

      @Stability(Stable) @Nullable default String getSelectionPattern()
      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.

      See Also:
    • builder

      @Stability(Stable) static IntegrationResponse.Builder builder()
      a IntegrationResponse.Builder of IntegrationResponse