aws_sdk_apigatewayv2/operation/create_integration/
_create_integration_input.rs

1// Code generated by software.amazon.smithy.rust.codegen.smithy-rs. DO NOT EDIT.
2
3/// <p>Creates a new Integration resource to represent an integration.</p>
4#[non_exhaustive]
5#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::fmt::Debug)]
6pub struct CreateIntegrationInput {
7    /// <p>The API identifier.</p>
8    pub api_id: ::std::option::Option<::std::string::String>,
9    /// <p>The ID of the VPC link for a private integration. Supported only for HTTP APIs.</p>
10    pub connection_id: ::std::option::Option<::std::string::String>,
11    /// <p>The type of the network connection to the integration endpoint. Specify INTERNET for connections through the public routable internet or VPC_LINK for private connections between API Gateway and resources in a VPC. The default value is INTERNET.</p>
12    pub connection_type: ::std::option::Option<crate::types::ConnectionType>,
13    /// <p>Supported only for WebSocket APIs. Specifies how to handle response payload content type conversions. Supported values are CONVERT_TO_BINARY and CONVERT_TO_TEXT, with the following behaviors:</p>
14    /// <p>CONVERT_TO_BINARY: Converts a response payload from a Base64-encoded string to the corresponding binary blob.</p>
15    /// <p>CONVERT_TO_TEXT: Converts a response payload from a binary blob to a Base64-encoded string.</p>
16    /// <p>If this property is not defined, the response payload will be passed through from the integration response to the route response or method response without modification.</p>
17    pub content_handling_strategy: ::std::option::Option<crate::types::ContentHandlingStrategy>,
18    /// <p>Specifies the credentials required for the integration, if any. For AWS integrations, three options are available. To specify an IAM Role for API Gateway to assume, use the role's Amazon Resource Name (ARN). To require that the caller's identity be passed through from the request, specify the string arn:aws:iam::*:user/*. To use resource-based permissions on supported AWS services, specify null.</p>
19    pub credentials_arn: ::std::option::Option<::std::string::String>,
20    /// <p>The description of the integration.</p>
21    pub description: ::std::option::Option<::std::string::String>,
22    /// <p>Specifies the integration's HTTP method type.</p>
23    pub integration_method: ::std::option::Option<::std::string::String>,
24    /// <p>Supported only for HTTP API AWS_PROXY integrations. Specifies the AWS service action to invoke. To learn more, see <a href="https://docs.aws.amazon.com/apigateway/latest/developerguide/http-api-develop-integrations-aws-services-reference.html">Integration subtype reference</a>.</p>
25    pub integration_subtype: ::std::option::Option<::std::string::String>,
26    /// <p>The integration type of an integration. One of the following:</p>
27    /// <p>AWS: for integrating the route or method request with an AWS service action, including the Lambda function-invoking action. With the Lambda function-invoking action, this is referred to as the Lambda custom integration. With any other AWS service action, this is known as AWS integration. Supported only for WebSocket APIs.</p>
28    /// <p>AWS_PROXY: for integrating the route or method request with a Lambda function or other AWS service action. This integration is also referred to as a Lambda proxy integration.</p>
29    /// <p>HTTP: for integrating the route or method request with an HTTP endpoint. This integration is also referred to as the HTTP custom integration. Supported only for WebSocket APIs.</p>
30    /// <p>HTTP_PROXY: for integrating the route or method request with an HTTP endpoint, with the client request passed through as-is. This is also referred to as HTTP proxy integration. For HTTP API private integrations, use an HTTP_PROXY integration.</p>
31    /// <p>MOCK: for integrating the route or method request with API Gateway as a "loopback" endpoint without invoking any backend. Supported only for WebSocket APIs.</p>
32    pub integration_type: ::std::option::Option<crate::types::IntegrationType>,
33    /// <p>For a Lambda integration, specify the URI of a Lambda function.</p>
34    /// <p>For an HTTP integration, specify a fully-qualified URL.</p>
35    /// <p>For an HTTP API private integration, specify the ARN of an Application Load Balancer listener, Network Load Balancer listener, or AWS Cloud Map service. If you specify the ARN of an AWS Cloud Map service, API Gateway uses DiscoverInstances to identify resources. You can use query parameters to target specific resources. To learn more, see <a href="https://docs.aws.amazon.com/cloud-map/latest/api/API_DiscoverInstances.html">DiscoverInstances</a>. For private integrations, all resources must be owned by the same AWS account.</p>
36    pub integration_uri: ::std::option::Option<::std::string::String>,
37    /// <p>Specifies the pass-through behavior for incoming requests based on the Content-Type header in the request, and the available mapping templates specified as the requestTemplates property on the Integration resource. There are three valid values: WHEN_NO_MATCH, WHEN_NO_TEMPLATES, and NEVER. Supported only for WebSocket APIs.</p>
38    /// <p>WHEN_NO_MATCH passes the request body for unmapped content types through to the integration backend without transformation.</p>
39    /// <p>NEVER rejects unmapped content types with an HTTP 415 Unsupported Media Type response.</p>
40    /// <p>WHEN_NO_TEMPLATES allows pass-through when the integration has no content types mapped to templates. However, if there is at least one content type defined, unmapped content types will be rejected with the same HTTP 415 Unsupported Media Type response.</p>
41    pub passthrough_behavior: ::std::option::Option<crate::types::PassthroughBehavior>,
42    /// <p>Specifies the format of the payload sent to an integration. Required for HTTP APIs. Supported values for Lambda proxy integrations are 1.0 and 2.0. For all other integrations, 1.0 is the only supported value. To learn more, see <a href="https://docs.aws.amazon.com/apigateway/latest/developerguide/http-api-develop-integrations-lambda.html">Working with AWS Lambda proxy integrations for HTTP APIs</a>.</p>
43    pub payload_format_version: ::std::option::Option<::std::string::String>,
44    /// <p>For WebSocket APIs, a key-value map specifying request parameters that are passed from the method request to the backend. The key is an integration request parameter name and the associated value is a method request parameter value or static value that must be enclosed within single quotes and pre-encoded as required by the backend. The method request parameter value must match the pattern of method.request.<replaceable>
45    /// {location}
46    /// </replaceable>.<replaceable>
47    /// {name}
48    /// </replaceable> , where <replaceable>
49    /// {location}
50    /// </replaceable> is querystring, path, or header; and <replaceable>
51    /// {name}
52    /// </replaceable> must be a valid and unique method request parameter name.</p>
53    /// <p>For HTTP API integrations with a specified integrationSubtype, request parameters are a key-value map specifying parameters that are passed to AWS_PROXY integrations. You can provide static values, or map request data, stage variables, or context variables that are evaluated at runtime. To learn more, see <a href="https://docs.aws.amazon.com/apigateway/latest/developerguide/http-api-develop-integrations-aws-services.html">Working with AWS service integrations for HTTP APIs</a>.</p>
54    /// <p>For HTTP API integrations without a specified integrationSubtype request parameters are a key-value map specifying how to transform HTTP requests before sending them to the backend. The key should follow the pattern &lt;action&gt;:&lt;header|querystring|path&gt;.&lt;location&gt; where action can be append, overwrite or remove. For values, you can provide static values, or map request data, stage variables, or context variables that are evaluated at runtime. To learn more, see <a href="https://docs.aws.amazon.com/apigateway/latest/developerguide/http-api-parameter-mapping.html">Transforming API requests and responses</a>.</p>
55    pub request_parameters: ::std::option::Option<::std::collections::HashMap<::std::string::String, ::std::string::String>>,
56    /// <p>Represents a map of Velocity templates that are applied on the request payload based on the value of the Content-Type header sent by the client. The content type value is the key in this map, and the template (as a String) is the value. Supported only for WebSocket APIs.</p>
57    pub request_templates: ::std::option::Option<::std::collections::HashMap<::std::string::String, ::std::string::String>>,
58    /// <p>Supported only for HTTP APIs. You use response parameters to transform the HTTP response from a backend integration before returning the response to clients. Specify a key-value map from a selection key to response parameters. The selection key must be a valid HTTP status code within the range of 200-599. Response parameters are a key-value map. The key must match pattern &lt;action&gt;:&lt;header&gt;.&lt;location&gt; or overwrite.statuscode. The action can be append, overwrite or remove. The value can be a static value, or map to response data, stage variables, or context variables that are evaluated at runtime. To learn more, see <a href="https://docs.aws.amazon.com/apigateway/latest/developerguide/http-api-parameter-mapping.html">Transforming API requests and responses</a>.</p>
59    pub response_parameters: ::std::option::Option<
60        ::std::collections::HashMap<::std::string::String, ::std::collections::HashMap<::std::string::String, ::std::string::String>>,
61    >,
62    /// <p>The template selection expression for the integration.</p>
63    pub template_selection_expression: ::std::option::Option<::std::string::String>,
64    /// <p>Custom timeout between 50 and 29,000 milliseconds for WebSocket APIs and between 50 and 30,000 milliseconds for HTTP APIs. The default timeout is 29 seconds for WebSocket APIs and 30 seconds for HTTP APIs.</p>
65    pub timeout_in_millis: ::std::option::Option<i32>,
66    /// <p>The TLS configuration for a private integration. If you specify a TLS configuration, private integration traffic uses the HTTPS protocol. Supported only for HTTP APIs.</p>
67    pub tls_config: ::std::option::Option<crate::types::TlsConfigInput>,
68}
69impl CreateIntegrationInput {
70    /// <p>The API identifier.</p>
71    pub fn api_id(&self) -> ::std::option::Option<&str> {
72        self.api_id.as_deref()
73    }
74    /// <p>The ID of the VPC link for a private integration. Supported only for HTTP APIs.</p>
75    pub fn connection_id(&self) -> ::std::option::Option<&str> {
76        self.connection_id.as_deref()
77    }
78    /// <p>The type of the network connection to the integration endpoint. Specify INTERNET for connections through the public routable internet or VPC_LINK for private connections between API Gateway and resources in a VPC. The default value is INTERNET.</p>
79    pub fn connection_type(&self) -> ::std::option::Option<&crate::types::ConnectionType> {
80        self.connection_type.as_ref()
81    }
82    /// <p>Supported only for WebSocket APIs. Specifies how to handle response payload content type conversions. Supported values are CONVERT_TO_BINARY and CONVERT_TO_TEXT, with the following behaviors:</p>
83    /// <p>CONVERT_TO_BINARY: Converts a response payload from a Base64-encoded string to the corresponding binary blob.</p>
84    /// <p>CONVERT_TO_TEXT: Converts a response payload from a binary blob to a Base64-encoded string.</p>
85    /// <p>If this property is not defined, the response payload will be passed through from the integration response to the route response or method response without modification.</p>
86    pub fn content_handling_strategy(&self) -> ::std::option::Option<&crate::types::ContentHandlingStrategy> {
87        self.content_handling_strategy.as_ref()
88    }
89    /// <p>Specifies the credentials required for the integration, if any. For AWS integrations, three options are available. To specify an IAM Role for API Gateway to assume, use the role's Amazon Resource Name (ARN). To require that the caller's identity be passed through from the request, specify the string arn:aws:iam::*:user/*. To use resource-based permissions on supported AWS services, specify null.</p>
90    pub fn credentials_arn(&self) -> ::std::option::Option<&str> {
91        self.credentials_arn.as_deref()
92    }
93    /// <p>The description of the integration.</p>
94    pub fn description(&self) -> ::std::option::Option<&str> {
95        self.description.as_deref()
96    }
97    /// <p>Specifies the integration's HTTP method type.</p>
98    pub fn integration_method(&self) -> ::std::option::Option<&str> {
99        self.integration_method.as_deref()
100    }
101    /// <p>Supported only for HTTP API AWS_PROXY integrations. Specifies the AWS service action to invoke. To learn more, see <a href="https://docs.aws.amazon.com/apigateway/latest/developerguide/http-api-develop-integrations-aws-services-reference.html">Integration subtype reference</a>.</p>
102    pub fn integration_subtype(&self) -> ::std::option::Option<&str> {
103        self.integration_subtype.as_deref()
104    }
105    /// <p>The integration type of an integration. One of the following:</p>
106    /// <p>AWS: for integrating the route or method request with an AWS service action, including the Lambda function-invoking action. With the Lambda function-invoking action, this is referred to as the Lambda custom integration. With any other AWS service action, this is known as AWS integration. Supported only for WebSocket APIs.</p>
107    /// <p>AWS_PROXY: for integrating the route or method request with a Lambda function or other AWS service action. This integration is also referred to as a Lambda proxy integration.</p>
108    /// <p>HTTP: for integrating the route or method request with an HTTP endpoint. This integration is also referred to as the HTTP custom integration. Supported only for WebSocket APIs.</p>
109    /// <p>HTTP_PROXY: for integrating the route or method request with an HTTP endpoint, with the client request passed through as-is. This is also referred to as HTTP proxy integration. For HTTP API private integrations, use an HTTP_PROXY integration.</p>
110    /// <p>MOCK: for integrating the route or method request with API Gateway as a "loopback" endpoint without invoking any backend. Supported only for WebSocket APIs.</p>
111    pub fn integration_type(&self) -> ::std::option::Option<&crate::types::IntegrationType> {
112        self.integration_type.as_ref()
113    }
114    /// <p>For a Lambda integration, specify the URI of a Lambda function.</p>
115    /// <p>For an HTTP integration, specify a fully-qualified URL.</p>
116    /// <p>For an HTTP API private integration, specify the ARN of an Application Load Balancer listener, Network Load Balancer listener, or AWS Cloud Map service. If you specify the ARN of an AWS Cloud Map service, API Gateway uses DiscoverInstances to identify resources. You can use query parameters to target specific resources. To learn more, see <a href="https://docs.aws.amazon.com/cloud-map/latest/api/API_DiscoverInstances.html">DiscoverInstances</a>. For private integrations, all resources must be owned by the same AWS account.</p>
117    pub fn integration_uri(&self) -> ::std::option::Option<&str> {
118        self.integration_uri.as_deref()
119    }
120    /// <p>Specifies the pass-through behavior for incoming requests based on the Content-Type header in the request, and the available mapping templates specified as the requestTemplates property on the Integration resource. There are three valid values: WHEN_NO_MATCH, WHEN_NO_TEMPLATES, and NEVER. Supported only for WebSocket APIs.</p>
121    /// <p>WHEN_NO_MATCH passes the request body for unmapped content types through to the integration backend without transformation.</p>
122    /// <p>NEVER rejects unmapped content types with an HTTP 415 Unsupported Media Type response.</p>
123    /// <p>WHEN_NO_TEMPLATES allows pass-through when the integration has no content types mapped to templates. However, if there is at least one content type defined, unmapped content types will be rejected with the same HTTP 415 Unsupported Media Type response.</p>
124    pub fn passthrough_behavior(&self) -> ::std::option::Option<&crate::types::PassthroughBehavior> {
125        self.passthrough_behavior.as_ref()
126    }
127    /// <p>Specifies the format of the payload sent to an integration. Required for HTTP APIs. Supported values for Lambda proxy integrations are 1.0 and 2.0. For all other integrations, 1.0 is the only supported value. To learn more, see <a href="https://docs.aws.amazon.com/apigateway/latest/developerguide/http-api-develop-integrations-lambda.html">Working with AWS Lambda proxy integrations for HTTP APIs</a>.</p>
128    pub fn payload_format_version(&self) -> ::std::option::Option<&str> {
129        self.payload_format_version.as_deref()
130    }
131    /// <p>For WebSocket APIs, a key-value map specifying request parameters that are passed from the method request to the backend. The key is an integration request parameter name and the associated value is a method request parameter value or static value that must be enclosed within single quotes and pre-encoded as required by the backend. The method request parameter value must match the pattern of method.request.<replaceable>
132    /// {location}
133    /// </replaceable>.<replaceable>
134    /// {name}
135    /// </replaceable> , where <replaceable>
136    /// {location}
137    /// </replaceable> is querystring, path, or header; and <replaceable>
138    /// {name}
139    /// </replaceable> must be a valid and unique method request parameter name.</p>
140    /// <p>For HTTP API integrations with a specified integrationSubtype, request parameters are a key-value map specifying parameters that are passed to AWS_PROXY integrations. You can provide static values, or map request data, stage variables, or context variables that are evaluated at runtime. To learn more, see <a href="https://docs.aws.amazon.com/apigateway/latest/developerguide/http-api-develop-integrations-aws-services.html">Working with AWS service integrations for HTTP APIs</a>.</p>
141    /// <p>For HTTP API integrations without a specified integrationSubtype request parameters are a key-value map specifying how to transform HTTP requests before sending them to the backend. The key should follow the pattern &lt;action&gt;:&lt;header|querystring|path&gt;.&lt;location&gt; where action can be append, overwrite or remove. For values, you can provide static values, or map request data, stage variables, or context variables that are evaluated at runtime. To learn more, see <a href="https://docs.aws.amazon.com/apigateway/latest/developerguide/http-api-parameter-mapping.html">Transforming API requests and responses</a>.</p>
142    pub fn request_parameters(&self) -> ::std::option::Option<&::std::collections::HashMap<::std::string::String, ::std::string::String>> {
143        self.request_parameters.as_ref()
144    }
145    /// <p>Represents a map of Velocity templates that are applied on the request payload based on the value of the Content-Type header sent by the client. The content type value is the key in this map, and the template (as a String) is the value. Supported only for WebSocket APIs.</p>
146    pub fn request_templates(&self) -> ::std::option::Option<&::std::collections::HashMap<::std::string::String, ::std::string::String>> {
147        self.request_templates.as_ref()
148    }
149    /// <p>Supported only for HTTP APIs. You use response parameters to transform the HTTP response from a backend integration before returning the response to clients. Specify a key-value map from a selection key to response parameters. The selection key must be a valid HTTP status code within the range of 200-599. Response parameters are a key-value map. The key must match pattern &lt;action&gt;:&lt;header&gt;.&lt;location&gt; or overwrite.statuscode. The action can be append, overwrite or remove. The value can be a static value, or map to response data, stage variables, or context variables that are evaluated at runtime. To learn more, see <a href="https://docs.aws.amazon.com/apigateway/latest/developerguide/http-api-parameter-mapping.html">Transforming API requests and responses</a>.</p>
150    pub fn response_parameters(
151        &self,
152    ) -> ::std::option::Option<
153        &::std::collections::HashMap<::std::string::String, ::std::collections::HashMap<::std::string::String, ::std::string::String>>,
154    > {
155        self.response_parameters.as_ref()
156    }
157    /// <p>The template selection expression for the integration.</p>
158    pub fn template_selection_expression(&self) -> ::std::option::Option<&str> {
159        self.template_selection_expression.as_deref()
160    }
161    /// <p>Custom timeout between 50 and 29,000 milliseconds for WebSocket APIs and between 50 and 30,000 milliseconds for HTTP APIs. The default timeout is 29 seconds for WebSocket APIs and 30 seconds for HTTP APIs.</p>
162    pub fn timeout_in_millis(&self) -> ::std::option::Option<i32> {
163        self.timeout_in_millis
164    }
165    /// <p>The TLS configuration for a private integration. If you specify a TLS configuration, private integration traffic uses the HTTPS protocol. Supported only for HTTP APIs.</p>
166    pub fn tls_config(&self) -> ::std::option::Option<&crate::types::TlsConfigInput> {
167        self.tls_config.as_ref()
168    }
169}
170impl CreateIntegrationInput {
171    /// Creates a new builder-style object to manufacture [`CreateIntegrationInput`](crate::operation::create_integration::CreateIntegrationInput).
172    pub fn builder() -> crate::operation::create_integration::builders::CreateIntegrationInputBuilder {
173        crate::operation::create_integration::builders::CreateIntegrationInputBuilder::default()
174    }
175}
176
177/// A builder for [`CreateIntegrationInput`](crate::operation::create_integration::CreateIntegrationInput).
178#[derive(::std::clone::Clone, ::std::cmp::PartialEq, ::std::default::Default, ::std::fmt::Debug)]
179#[non_exhaustive]
180pub struct CreateIntegrationInputBuilder {
181    pub(crate) api_id: ::std::option::Option<::std::string::String>,
182    pub(crate) connection_id: ::std::option::Option<::std::string::String>,
183    pub(crate) connection_type: ::std::option::Option<crate::types::ConnectionType>,
184    pub(crate) content_handling_strategy: ::std::option::Option<crate::types::ContentHandlingStrategy>,
185    pub(crate) credentials_arn: ::std::option::Option<::std::string::String>,
186    pub(crate) description: ::std::option::Option<::std::string::String>,
187    pub(crate) integration_method: ::std::option::Option<::std::string::String>,
188    pub(crate) integration_subtype: ::std::option::Option<::std::string::String>,
189    pub(crate) integration_type: ::std::option::Option<crate::types::IntegrationType>,
190    pub(crate) integration_uri: ::std::option::Option<::std::string::String>,
191    pub(crate) passthrough_behavior: ::std::option::Option<crate::types::PassthroughBehavior>,
192    pub(crate) payload_format_version: ::std::option::Option<::std::string::String>,
193    pub(crate) request_parameters: ::std::option::Option<::std::collections::HashMap<::std::string::String, ::std::string::String>>,
194    pub(crate) request_templates: ::std::option::Option<::std::collections::HashMap<::std::string::String, ::std::string::String>>,
195    pub(crate) response_parameters: ::std::option::Option<
196        ::std::collections::HashMap<::std::string::String, ::std::collections::HashMap<::std::string::String, ::std::string::String>>,
197    >,
198    pub(crate) template_selection_expression: ::std::option::Option<::std::string::String>,
199    pub(crate) timeout_in_millis: ::std::option::Option<i32>,
200    pub(crate) tls_config: ::std::option::Option<crate::types::TlsConfigInput>,
201}
202impl CreateIntegrationInputBuilder {
203    /// <p>The API identifier.</p>
204    /// This field is required.
205    pub fn api_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
206        self.api_id = ::std::option::Option::Some(input.into());
207        self
208    }
209    /// <p>The API identifier.</p>
210    pub fn set_api_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
211        self.api_id = input;
212        self
213    }
214    /// <p>The API identifier.</p>
215    pub fn get_api_id(&self) -> &::std::option::Option<::std::string::String> {
216        &self.api_id
217    }
218    /// <p>The ID of the VPC link for a private integration. Supported only for HTTP APIs.</p>
219    pub fn connection_id(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
220        self.connection_id = ::std::option::Option::Some(input.into());
221        self
222    }
223    /// <p>The ID of the VPC link for a private integration. Supported only for HTTP APIs.</p>
224    pub fn set_connection_id(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
225        self.connection_id = input;
226        self
227    }
228    /// <p>The ID of the VPC link for a private integration. Supported only for HTTP APIs.</p>
229    pub fn get_connection_id(&self) -> &::std::option::Option<::std::string::String> {
230        &self.connection_id
231    }
232    /// <p>The type of the network connection to the integration endpoint. Specify INTERNET for connections through the public routable internet or VPC_LINK for private connections between API Gateway and resources in a VPC. The default value is INTERNET.</p>
233    pub fn connection_type(mut self, input: crate::types::ConnectionType) -> Self {
234        self.connection_type = ::std::option::Option::Some(input);
235        self
236    }
237    /// <p>The type of the network connection to the integration endpoint. Specify INTERNET for connections through the public routable internet or VPC_LINK for private connections between API Gateway and resources in a VPC. The default value is INTERNET.</p>
238    pub fn set_connection_type(mut self, input: ::std::option::Option<crate::types::ConnectionType>) -> Self {
239        self.connection_type = input;
240        self
241    }
242    /// <p>The type of the network connection to the integration endpoint. Specify INTERNET for connections through the public routable internet or VPC_LINK for private connections between API Gateway and resources in a VPC. The default value is INTERNET.</p>
243    pub fn get_connection_type(&self) -> &::std::option::Option<crate::types::ConnectionType> {
244        &self.connection_type
245    }
246    /// <p>Supported only for WebSocket APIs. Specifies how to handle response payload content type conversions. Supported values are CONVERT_TO_BINARY and CONVERT_TO_TEXT, with the following behaviors:</p>
247    /// <p>CONVERT_TO_BINARY: Converts a response payload from a Base64-encoded string to the corresponding binary blob.</p>
248    /// <p>CONVERT_TO_TEXT: Converts a response payload from a binary blob to a Base64-encoded string.</p>
249    /// <p>If this property is not defined, the response payload will be passed through from the integration response to the route response or method response without modification.</p>
250    pub fn content_handling_strategy(mut self, input: crate::types::ContentHandlingStrategy) -> Self {
251        self.content_handling_strategy = ::std::option::Option::Some(input);
252        self
253    }
254    /// <p>Supported only for WebSocket APIs. Specifies how to handle response payload content type conversions. Supported values are CONVERT_TO_BINARY and CONVERT_TO_TEXT, with the following behaviors:</p>
255    /// <p>CONVERT_TO_BINARY: Converts a response payload from a Base64-encoded string to the corresponding binary blob.</p>
256    /// <p>CONVERT_TO_TEXT: Converts a response payload from a binary blob to a Base64-encoded string.</p>
257    /// <p>If this property is not defined, the response payload will be passed through from the integration response to the route response or method response without modification.</p>
258    pub fn set_content_handling_strategy(mut self, input: ::std::option::Option<crate::types::ContentHandlingStrategy>) -> Self {
259        self.content_handling_strategy = input;
260        self
261    }
262    /// <p>Supported only for WebSocket APIs. Specifies how to handle response payload content type conversions. Supported values are CONVERT_TO_BINARY and CONVERT_TO_TEXT, with the following behaviors:</p>
263    /// <p>CONVERT_TO_BINARY: Converts a response payload from a Base64-encoded string to the corresponding binary blob.</p>
264    /// <p>CONVERT_TO_TEXT: Converts a response payload from a binary blob to a Base64-encoded string.</p>
265    /// <p>If this property is not defined, the response payload will be passed through from the integration response to the route response or method response without modification.</p>
266    pub fn get_content_handling_strategy(&self) -> &::std::option::Option<crate::types::ContentHandlingStrategy> {
267        &self.content_handling_strategy
268    }
269    /// <p>Specifies the credentials required for the integration, if any. For AWS integrations, three options are available. To specify an IAM Role for API Gateway to assume, use the role's Amazon Resource Name (ARN). To require that the caller's identity be passed through from the request, specify the string arn:aws:iam::*:user/*. To use resource-based permissions on supported AWS services, specify null.</p>
270    pub fn credentials_arn(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
271        self.credentials_arn = ::std::option::Option::Some(input.into());
272        self
273    }
274    /// <p>Specifies the credentials required for the integration, if any. For AWS integrations, three options are available. To specify an IAM Role for API Gateway to assume, use the role's Amazon Resource Name (ARN). To require that the caller's identity be passed through from the request, specify the string arn:aws:iam::*:user/*. To use resource-based permissions on supported AWS services, specify null.</p>
275    pub fn set_credentials_arn(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
276        self.credentials_arn = input;
277        self
278    }
279    /// <p>Specifies the credentials required for the integration, if any. For AWS integrations, three options are available. To specify an IAM Role for API Gateway to assume, use the role's Amazon Resource Name (ARN). To require that the caller's identity be passed through from the request, specify the string arn:aws:iam::*:user/*. To use resource-based permissions on supported AWS services, specify null.</p>
280    pub fn get_credentials_arn(&self) -> &::std::option::Option<::std::string::String> {
281        &self.credentials_arn
282    }
283    /// <p>The description of the integration.</p>
284    pub fn description(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
285        self.description = ::std::option::Option::Some(input.into());
286        self
287    }
288    /// <p>The description of the integration.</p>
289    pub fn set_description(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
290        self.description = input;
291        self
292    }
293    /// <p>The description of the integration.</p>
294    pub fn get_description(&self) -> &::std::option::Option<::std::string::String> {
295        &self.description
296    }
297    /// <p>Specifies the integration's HTTP method type.</p>
298    pub fn integration_method(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
299        self.integration_method = ::std::option::Option::Some(input.into());
300        self
301    }
302    /// <p>Specifies the integration's HTTP method type.</p>
303    pub fn set_integration_method(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
304        self.integration_method = input;
305        self
306    }
307    /// <p>Specifies the integration's HTTP method type.</p>
308    pub fn get_integration_method(&self) -> &::std::option::Option<::std::string::String> {
309        &self.integration_method
310    }
311    /// <p>Supported only for HTTP API AWS_PROXY integrations. Specifies the AWS service action to invoke. To learn more, see <a href="https://docs.aws.amazon.com/apigateway/latest/developerguide/http-api-develop-integrations-aws-services-reference.html">Integration subtype reference</a>.</p>
312    pub fn integration_subtype(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
313        self.integration_subtype = ::std::option::Option::Some(input.into());
314        self
315    }
316    /// <p>Supported only for HTTP API AWS_PROXY integrations. Specifies the AWS service action to invoke. To learn more, see <a href="https://docs.aws.amazon.com/apigateway/latest/developerguide/http-api-develop-integrations-aws-services-reference.html">Integration subtype reference</a>.</p>
317    pub fn set_integration_subtype(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
318        self.integration_subtype = input;
319        self
320    }
321    /// <p>Supported only for HTTP API AWS_PROXY integrations. Specifies the AWS service action to invoke. To learn more, see <a href="https://docs.aws.amazon.com/apigateway/latest/developerguide/http-api-develop-integrations-aws-services-reference.html">Integration subtype reference</a>.</p>
322    pub fn get_integration_subtype(&self) -> &::std::option::Option<::std::string::String> {
323        &self.integration_subtype
324    }
325    /// <p>The integration type of an integration. One of the following:</p>
326    /// <p>AWS: for integrating the route or method request with an AWS service action, including the Lambda function-invoking action. With the Lambda function-invoking action, this is referred to as the Lambda custom integration. With any other AWS service action, this is known as AWS integration. Supported only for WebSocket APIs.</p>
327    /// <p>AWS_PROXY: for integrating the route or method request with a Lambda function or other AWS service action. This integration is also referred to as a Lambda proxy integration.</p>
328    /// <p>HTTP: for integrating the route or method request with an HTTP endpoint. This integration is also referred to as the HTTP custom integration. Supported only for WebSocket APIs.</p>
329    /// <p>HTTP_PROXY: for integrating the route or method request with an HTTP endpoint, with the client request passed through as-is. This is also referred to as HTTP proxy integration. For HTTP API private integrations, use an HTTP_PROXY integration.</p>
330    /// <p>MOCK: for integrating the route or method request with API Gateway as a "loopback" endpoint without invoking any backend. Supported only for WebSocket APIs.</p>
331    /// This field is required.
332    pub fn integration_type(mut self, input: crate::types::IntegrationType) -> Self {
333        self.integration_type = ::std::option::Option::Some(input);
334        self
335    }
336    /// <p>The integration type of an integration. One of the following:</p>
337    /// <p>AWS: for integrating the route or method request with an AWS service action, including the Lambda function-invoking action. With the Lambda function-invoking action, this is referred to as the Lambda custom integration. With any other AWS service action, this is known as AWS integration. Supported only for WebSocket APIs.</p>
338    /// <p>AWS_PROXY: for integrating the route or method request with a Lambda function or other AWS service action. This integration is also referred to as a Lambda proxy integration.</p>
339    /// <p>HTTP: for integrating the route or method request with an HTTP endpoint. This integration is also referred to as the HTTP custom integration. Supported only for WebSocket APIs.</p>
340    /// <p>HTTP_PROXY: for integrating the route or method request with an HTTP endpoint, with the client request passed through as-is. This is also referred to as HTTP proxy integration. For HTTP API private integrations, use an HTTP_PROXY integration.</p>
341    /// <p>MOCK: for integrating the route or method request with API Gateway as a "loopback" endpoint without invoking any backend. Supported only for WebSocket APIs.</p>
342    pub fn set_integration_type(mut self, input: ::std::option::Option<crate::types::IntegrationType>) -> Self {
343        self.integration_type = input;
344        self
345    }
346    /// <p>The integration type of an integration. One of the following:</p>
347    /// <p>AWS: for integrating the route or method request with an AWS service action, including the Lambda function-invoking action. With the Lambda function-invoking action, this is referred to as the Lambda custom integration. With any other AWS service action, this is known as AWS integration. Supported only for WebSocket APIs.</p>
348    /// <p>AWS_PROXY: for integrating the route or method request with a Lambda function or other AWS service action. This integration is also referred to as a Lambda proxy integration.</p>
349    /// <p>HTTP: for integrating the route or method request with an HTTP endpoint. This integration is also referred to as the HTTP custom integration. Supported only for WebSocket APIs.</p>
350    /// <p>HTTP_PROXY: for integrating the route or method request with an HTTP endpoint, with the client request passed through as-is. This is also referred to as HTTP proxy integration. For HTTP API private integrations, use an HTTP_PROXY integration.</p>
351    /// <p>MOCK: for integrating the route or method request with API Gateway as a "loopback" endpoint without invoking any backend. Supported only for WebSocket APIs.</p>
352    pub fn get_integration_type(&self) -> &::std::option::Option<crate::types::IntegrationType> {
353        &self.integration_type
354    }
355    /// <p>For a Lambda integration, specify the URI of a Lambda function.</p>
356    /// <p>For an HTTP integration, specify a fully-qualified URL.</p>
357    /// <p>For an HTTP API private integration, specify the ARN of an Application Load Balancer listener, Network Load Balancer listener, or AWS Cloud Map service. If you specify the ARN of an AWS Cloud Map service, API Gateway uses DiscoverInstances to identify resources. You can use query parameters to target specific resources. To learn more, see <a href="https://docs.aws.amazon.com/cloud-map/latest/api/API_DiscoverInstances.html">DiscoverInstances</a>. For private integrations, all resources must be owned by the same AWS account.</p>
358    pub fn integration_uri(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
359        self.integration_uri = ::std::option::Option::Some(input.into());
360        self
361    }
362    /// <p>For a Lambda integration, specify the URI of a Lambda function.</p>
363    /// <p>For an HTTP integration, specify a fully-qualified URL.</p>
364    /// <p>For an HTTP API private integration, specify the ARN of an Application Load Balancer listener, Network Load Balancer listener, or AWS Cloud Map service. If you specify the ARN of an AWS Cloud Map service, API Gateway uses DiscoverInstances to identify resources. You can use query parameters to target specific resources. To learn more, see <a href="https://docs.aws.amazon.com/cloud-map/latest/api/API_DiscoverInstances.html">DiscoverInstances</a>. For private integrations, all resources must be owned by the same AWS account.</p>
365    pub fn set_integration_uri(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
366        self.integration_uri = input;
367        self
368    }
369    /// <p>For a Lambda integration, specify the URI of a Lambda function.</p>
370    /// <p>For an HTTP integration, specify a fully-qualified URL.</p>
371    /// <p>For an HTTP API private integration, specify the ARN of an Application Load Balancer listener, Network Load Balancer listener, or AWS Cloud Map service. If you specify the ARN of an AWS Cloud Map service, API Gateway uses DiscoverInstances to identify resources. You can use query parameters to target specific resources. To learn more, see <a href="https://docs.aws.amazon.com/cloud-map/latest/api/API_DiscoverInstances.html">DiscoverInstances</a>. For private integrations, all resources must be owned by the same AWS account.</p>
372    pub fn get_integration_uri(&self) -> &::std::option::Option<::std::string::String> {
373        &self.integration_uri
374    }
375    /// <p>Specifies the pass-through behavior for incoming requests based on the Content-Type header in the request, and the available mapping templates specified as the requestTemplates property on the Integration resource. There are three valid values: WHEN_NO_MATCH, WHEN_NO_TEMPLATES, and NEVER. Supported only for WebSocket APIs.</p>
376    /// <p>WHEN_NO_MATCH passes the request body for unmapped content types through to the integration backend without transformation.</p>
377    /// <p>NEVER rejects unmapped content types with an HTTP 415 Unsupported Media Type response.</p>
378    /// <p>WHEN_NO_TEMPLATES allows pass-through when the integration has no content types mapped to templates. However, if there is at least one content type defined, unmapped content types will be rejected with the same HTTP 415 Unsupported Media Type response.</p>
379    pub fn passthrough_behavior(mut self, input: crate::types::PassthroughBehavior) -> Self {
380        self.passthrough_behavior = ::std::option::Option::Some(input);
381        self
382    }
383    /// <p>Specifies the pass-through behavior for incoming requests based on the Content-Type header in the request, and the available mapping templates specified as the requestTemplates property on the Integration resource. There are three valid values: WHEN_NO_MATCH, WHEN_NO_TEMPLATES, and NEVER. Supported only for WebSocket APIs.</p>
384    /// <p>WHEN_NO_MATCH passes the request body for unmapped content types through to the integration backend without transformation.</p>
385    /// <p>NEVER rejects unmapped content types with an HTTP 415 Unsupported Media Type response.</p>
386    /// <p>WHEN_NO_TEMPLATES allows pass-through when the integration has no content types mapped to templates. However, if there is at least one content type defined, unmapped content types will be rejected with the same HTTP 415 Unsupported Media Type response.</p>
387    pub fn set_passthrough_behavior(mut self, input: ::std::option::Option<crate::types::PassthroughBehavior>) -> Self {
388        self.passthrough_behavior = input;
389        self
390    }
391    /// <p>Specifies the pass-through behavior for incoming requests based on the Content-Type header in the request, and the available mapping templates specified as the requestTemplates property on the Integration resource. There are three valid values: WHEN_NO_MATCH, WHEN_NO_TEMPLATES, and NEVER. Supported only for WebSocket APIs.</p>
392    /// <p>WHEN_NO_MATCH passes the request body for unmapped content types through to the integration backend without transformation.</p>
393    /// <p>NEVER rejects unmapped content types with an HTTP 415 Unsupported Media Type response.</p>
394    /// <p>WHEN_NO_TEMPLATES allows pass-through when the integration has no content types mapped to templates. However, if there is at least one content type defined, unmapped content types will be rejected with the same HTTP 415 Unsupported Media Type response.</p>
395    pub fn get_passthrough_behavior(&self) -> &::std::option::Option<crate::types::PassthroughBehavior> {
396        &self.passthrough_behavior
397    }
398    /// <p>Specifies the format of the payload sent to an integration. Required for HTTP APIs. Supported values for Lambda proxy integrations are 1.0 and 2.0. For all other integrations, 1.0 is the only supported value. To learn more, see <a href="https://docs.aws.amazon.com/apigateway/latest/developerguide/http-api-develop-integrations-lambda.html">Working with AWS Lambda proxy integrations for HTTP APIs</a>.</p>
399    pub fn payload_format_version(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
400        self.payload_format_version = ::std::option::Option::Some(input.into());
401        self
402    }
403    /// <p>Specifies the format of the payload sent to an integration. Required for HTTP APIs. Supported values for Lambda proxy integrations are 1.0 and 2.0. For all other integrations, 1.0 is the only supported value. To learn more, see <a href="https://docs.aws.amazon.com/apigateway/latest/developerguide/http-api-develop-integrations-lambda.html">Working with AWS Lambda proxy integrations for HTTP APIs</a>.</p>
404    pub fn set_payload_format_version(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
405        self.payload_format_version = input;
406        self
407    }
408    /// <p>Specifies the format of the payload sent to an integration. Required for HTTP APIs. Supported values for Lambda proxy integrations are 1.0 and 2.0. For all other integrations, 1.0 is the only supported value. To learn more, see <a href="https://docs.aws.amazon.com/apigateway/latest/developerguide/http-api-develop-integrations-lambda.html">Working with AWS Lambda proxy integrations for HTTP APIs</a>.</p>
409    pub fn get_payload_format_version(&self) -> &::std::option::Option<::std::string::String> {
410        &self.payload_format_version
411    }
412    /// Adds a key-value pair to `request_parameters`.
413    ///
414    /// To override the contents of this collection use [`set_request_parameters`](Self::set_request_parameters).
415    ///
416    /// <p>For WebSocket APIs, a key-value map specifying request parameters that are passed from the method request to the backend. The key is an integration request parameter name and the associated value is a method request parameter value or static value that must be enclosed within single quotes and pre-encoded as required by the backend. The method request parameter value must match the pattern of method.request.<replaceable>
417    /// {location}
418    /// </replaceable>.<replaceable>
419    /// {name}
420    /// </replaceable> , where <replaceable>
421    /// {location}
422    /// </replaceable> is querystring, path, or header; and <replaceable>
423    /// {name}
424    /// </replaceable> must be a valid and unique method request parameter name.</p>
425    /// <p>For HTTP API integrations with a specified integrationSubtype, request parameters are a key-value map specifying parameters that are passed to AWS_PROXY integrations. You can provide static values, or map request data, stage variables, or context variables that are evaluated at runtime. To learn more, see <a href="https://docs.aws.amazon.com/apigateway/latest/developerguide/http-api-develop-integrations-aws-services.html">Working with AWS service integrations for HTTP APIs</a>.</p>
426    /// <p>For HTTP API integrations without a specified integrationSubtype request parameters are a key-value map specifying how to transform HTTP requests before sending them to the backend. The key should follow the pattern &lt;action&gt;:&lt;header|querystring|path&gt;.&lt;location&gt; where action can be append, overwrite or remove. For values, you can provide static values, or map request data, stage variables, or context variables that are evaluated at runtime. To learn more, see <a href="https://docs.aws.amazon.com/apigateway/latest/developerguide/http-api-parameter-mapping.html">Transforming API requests and responses</a>.</p>
427    pub fn request_parameters(
428        mut self,
429        k: impl ::std::convert::Into<::std::string::String>,
430        v: impl ::std::convert::Into<::std::string::String>,
431    ) -> Self {
432        let mut hash_map = self.request_parameters.unwrap_or_default();
433        hash_map.insert(k.into(), v.into());
434        self.request_parameters = ::std::option::Option::Some(hash_map);
435        self
436    }
437    /// <p>For WebSocket APIs, a key-value map specifying request parameters that are passed from the method request to the backend. The key is an integration request parameter name and the associated value is a method request parameter value or static value that must be enclosed within single quotes and pre-encoded as required by the backend. The method request parameter value must match the pattern of method.request.<replaceable>
438    /// {location}
439    /// </replaceable>.<replaceable>
440    /// {name}
441    /// </replaceable> , where <replaceable>
442    /// {location}
443    /// </replaceable> is querystring, path, or header; and <replaceable>
444    /// {name}
445    /// </replaceable> must be a valid and unique method request parameter name.</p>
446    /// <p>For HTTP API integrations with a specified integrationSubtype, request parameters are a key-value map specifying parameters that are passed to AWS_PROXY integrations. You can provide static values, or map request data, stage variables, or context variables that are evaluated at runtime. To learn more, see <a href="https://docs.aws.amazon.com/apigateway/latest/developerguide/http-api-develop-integrations-aws-services.html">Working with AWS service integrations for HTTP APIs</a>.</p>
447    /// <p>For HTTP API integrations without a specified integrationSubtype request parameters are a key-value map specifying how to transform HTTP requests before sending them to the backend. The key should follow the pattern &lt;action&gt;:&lt;header|querystring|path&gt;.&lt;location&gt; where action can be append, overwrite or remove. For values, you can provide static values, or map request data, stage variables, or context variables that are evaluated at runtime. To learn more, see <a href="https://docs.aws.amazon.com/apigateway/latest/developerguide/http-api-parameter-mapping.html">Transforming API requests and responses</a>.</p>
448    pub fn set_request_parameters(
449        mut self,
450        input: ::std::option::Option<::std::collections::HashMap<::std::string::String, ::std::string::String>>,
451    ) -> Self {
452        self.request_parameters = input;
453        self
454    }
455    /// <p>For WebSocket APIs, a key-value map specifying request parameters that are passed from the method request to the backend. The key is an integration request parameter name and the associated value is a method request parameter value or static value that must be enclosed within single quotes and pre-encoded as required by the backend. The method request parameter value must match the pattern of method.request.<replaceable>
456    /// {location}
457    /// </replaceable>.<replaceable>
458    /// {name}
459    /// </replaceable> , where <replaceable>
460    /// {location}
461    /// </replaceable> is querystring, path, or header; and <replaceable>
462    /// {name}
463    /// </replaceable> must be a valid and unique method request parameter name.</p>
464    /// <p>For HTTP API integrations with a specified integrationSubtype, request parameters are a key-value map specifying parameters that are passed to AWS_PROXY integrations. You can provide static values, or map request data, stage variables, or context variables that are evaluated at runtime. To learn more, see <a href="https://docs.aws.amazon.com/apigateway/latest/developerguide/http-api-develop-integrations-aws-services.html">Working with AWS service integrations for HTTP APIs</a>.</p>
465    /// <p>For HTTP API integrations without a specified integrationSubtype request parameters are a key-value map specifying how to transform HTTP requests before sending them to the backend. The key should follow the pattern &lt;action&gt;:&lt;header|querystring|path&gt;.&lt;location&gt; where action can be append, overwrite or remove. For values, you can provide static values, or map request data, stage variables, or context variables that are evaluated at runtime. To learn more, see <a href="https://docs.aws.amazon.com/apigateway/latest/developerguide/http-api-parameter-mapping.html">Transforming API requests and responses</a>.</p>
466    pub fn get_request_parameters(&self) -> &::std::option::Option<::std::collections::HashMap<::std::string::String, ::std::string::String>> {
467        &self.request_parameters
468    }
469    /// Adds a key-value pair to `request_templates`.
470    ///
471    /// To override the contents of this collection use [`set_request_templates`](Self::set_request_templates).
472    ///
473    /// <p>Represents a map of Velocity templates that are applied on the request payload based on the value of the Content-Type header sent by the client. The content type value is the key in this map, and the template (as a String) is the value. Supported only for WebSocket APIs.</p>
474    pub fn request_templates(
475        mut self,
476        k: impl ::std::convert::Into<::std::string::String>,
477        v: impl ::std::convert::Into<::std::string::String>,
478    ) -> Self {
479        let mut hash_map = self.request_templates.unwrap_or_default();
480        hash_map.insert(k.into(), v.into());
481        self.request_templates = ::std::option::Option::Some(hash_map);
482        self
483    }
484    /// <p>Represents a map of Velocity templates that are applied on the request payload based on the value of the Content-Type header sent by the client. The content type value is the key in this map, and the template (as a String) is the value. Supported only for WebSocket APIs.</p>
485    pub fn set_request_templates(
486        mut self,
487        input: ::std::option::Option<::std::collections::HashMap<::std::string::String, ::std::string::String>>,
488    ) -> Self {
489        self.request_templates = input;
490        self
491    }
492    /// <p>Represents a map of Velocity templates that are applied on the request payload based on the value of the Content-Type header sent by the client. The content type value is the key in this map, and the template (as a String) is the value. Supported only for WebSocket APIs.</p>
493    pub fn get_request_templates(&self) -> &::std::option::Option<::std::collections::HashMap<::std::string::String, ::std::string::String>> {
494        &self.request_templates
495    }
496    /// Adds a key-value pair to `response_parameters`.
497    ///
498    /// To override the contents of this collection use [`set_response_parameters`](Self::set_response_parameters).
499    ///
500    /// <p>Supported only for HTTP APIs. You use response parameters to transform the HTTP response from a backend integration before returning the response to clients. Specify a key-value map from a selection key to response parameters. The selection key must be a valid HTTP status code within the range of 200-599. Response parameters are a key-value map. The key must match pattern &lt;action&gt;:&lt;header&gt;.&lt;location&gt; or overwrite.statuscode. The action can be append, overwrite or remove. The value can be a static value, or map to response data, stage variables, or context variables that are evaluated at runtime. To learn more, see <a href="https://docs.aws.amazon.com/apigateway/latest/developerguide/http-api-parameter-mapping.html">Transforming API requests and responses</a>.</p>
501    pub fn response_parameters(
502        mut self,
503        k: impl ::std::convert::Into<::std::string::String>,
504        v: ::std::collections::HashMap<::std::string::String, ::std::string::String>,
505    ) -> Self {
506        let mut hash_map = self.response_parameters.unwrap_or_default();
507        hash_map.insert(k.into(), v);
508        self.response_parameters = ::std::option::Option::Some(hash_map);
509        self
510    }
511    /// <p>Supported only for HTTP APIs. You use response parameters to transform the HTTP response from a backend integration before returning the response to clients. Specify a key-value map from a selection key to response parameters. The selection key must be a valid HTTP status code within the range of 200-599. Response parameters are a key-value map. The key must match pattern &lt;action&gt;:&lt;header&gt;.&lt;location&gt; or overwrite.statuscode. The action can be append, overwrite or remove. The value can be a static value, or map to response data, stage variables, or context variables that are evaluated at runtime. To learn more, see <a href="https://docs.aws.amazon.com/apigateway/latest/developerguide/http-api-parameter-mapping.html">Transforming API requests and responses</a>.</p>
512    pub fn set_response_parameters(
513        mut self,
514        input: ::std::option::Option<
515            ::std::collections::HashMap<::std::string::String, ::std::collections::HashMap<::std::string::String, ::std::string::String>>,
516        >,
517    ) -> Self {
518        self.response_parameters = input;
519        self
520    }
521    /// <p>Supported only for HTTP APIs. You use response parameters to transform the HTTP response from a backend integration before returning the response to clients. Specify a key-value map from a selection key to response parameters. The selection key must be a valid HTTP status code within the range of 200-599. Response parameters are a key-value map. The key must match pattern &lt;action&gt;:&lt;header&gt;.&lt;location&gt; or overwrite.statuscode. The action can be append, overwrite or remove. The value can be a static value, or map to response data, stage variables, or context variables that are evaluated at runtime. To learn more, see <a href="https://docs.aws.amazon.com/apigateway/latest/developerguide/http-api-parameter-mapping.html">Transforming API requests and responses</a>.</p>
522    pub fn get_response_parameters(
523        &self,
524    ) -> &::std::option::Option<
525        ::std::collections::HashMap<::std::string::String, ::std::collections::HashMap<::std::string::String, ::std::string::String>>,
526    > {
527        &self.response_parameters
528    }
529    /// <p>The template selection expression for the integration.</p>
530    pub fn template_selection_expression(mut self, input: impl ::std::convert::Into<::std::string::String>) -> Self {
531        self.template_selection_expression = ::std::option::Option::Some(input.into());
532        self
533    }
534    /// <p>The template selection expression for the integration.</p>
535    pub fn set_template_selection_expression(mut self, input: ::std::option::Option<::std::string::String>) -> Self {
536        self.template_selection_expression = input;
537        self
538    }
539    /// <p>The template selection expression for the integration.</p>
540    pub fn get_template_selection_expression(&self) -> &::std::option::Option<::std::string::String> {
541        &self.template_selection_expression
542    }
543    /// <p>Custom timeout between 50 and 29,000 milliseconds for WebSocket APIs and between 50 and 30,000 milliseconds for HTTP APIs. The default timeout is 29 seconds for WebSocket APIs and 30 seconds for HTTP APIs.</p>
544    pub fn timeout_in_millis(mut self, input: i32) -> Self {
545        self.timeout_in_millis = ::std::option::Option::Some(input);
546        self
547    }
548    /// <p>Custom timeout between 50 and 29,000 milliseconds for WebSocket APIs and between 50 and 30,000 milliseconds for HTTP APIs. The default timeout is 29 seconds for WebSocket APIs and 30 seconds for HTTP APIs.</p>
549    pub fn set_timeout_in_millis(mut self, input: ::std::option::Option<i32>) -> Self {
550        self.timeout_in_millis = input;
551        self
552    }
553    /// <p>Custom timeout between 50 and 29,000 milliseconds for WebSocket APIs and between 50 and 30,000 milliseconds for HTTP APIs. The default timeout is 29 seconds for WebSocket APIs and 30 seconds for HTTP APIs.</p>
554    pub fn get_timeout_in_millis(&self) -> &::std::option::Option<i32> {
555        &self.timeout_in_millis
556    }
557    /// <p>The TLS configuration for a private integration. If you specify a TLS configuration, private integration traffic uses the HTTPS protocol. Supported only for HTTP APIs.</p>
558    pub fn tls_config(mut self, input: crate::types::TlsConfigInput) -> Self {
559        self.tls_config = ::std::option::Option::Some(input);
560        self
561    }
562    /// <p>The TLS configuration for a private integration. If you specify a TLS configuration, private integration traffic uses the HTTPS protocol. Supported only for HTTP APIs.</p>
563    pub fn set_tls_config(mut self, input: ::std::option::Option<crate::types::TlsConfigInput>) -> Self {
564        self.tls_config = input;
565        self
566    }
567    /// <p>The TLS configuration for a private integration. If you specify a TLS configuration, private integration traffic uses the HTTPS protocol. Supported only for HTTP APIs.</p>
568    pub fn get_tls_config(&self) -> &::std::option::Option<crate::types::TlsConfigInput> {
569        &self.tls_config
570    }
571    /// Consumes the builder and constructs a [`CreateIntegrationInput`](crate::operation::create_integration::CreateIntegrationInput).
572    pub fn build(
573        self,
574    ) -> ::std::result::Result<crate::operation::create_integration::CreateIntegrationInput, ::aws_smithy_types::error::operation::BuildError> {
575        ::std::result::Result::Ok(crate::operation::create_integration::CreateIntegrationInput {
576            api_id: self.api_id,
577            connection_id: self.connection_id,
578            connection_type: self.connection_type,
579            content_handling_strategy: self.content_handling_strategy,
580            credentials_arn: self.credentials_arn,
581            description: self.description,
582            integration_method: self.integration_method,
583            integration_subtype: self.integration_subtype,
584            integration_type: self.integration_type,
585            integration_uri: self.integration_uri,
586            passthrough_behavior: self.passthrough_behavior,
587            payload_format_version: self.payload_format_version,
588            request_parameters: self.request_parameters,
589            request_templates: self.request_templates,
590            response_parameters: self.response_parameters,
591            template_selection_expression: self.template_selection_expression,
592            timeout_in_millis: self.timeout_in_millis,
593            tls_config: self.tls_config,
594        })
595    }
596}