Integration class
Represents an HTTP, HTTP_PROXY, AWS, AWS_PROXY, or Mock integration.
In the API Gateway console, the built-in Lambda
integration is an AWS integration.
Constructors
-
Integration({List<
String> ? cacheKeyParameters, String? cacheNamespace, String? connectionId, ConnectionType? connectionType, ContentHandlingStrategy? contentHandling, String? credentials, String? httpMethod, Map<String, IntegrationResponse> ? integrationResponses, String? passthroughBehavior, Map<String, String> ? requestParameters, Map<String, String> ? requestTemplates, int? timeoutInMillis, TlsConfig? tlsConfig, IntegrationType? type, String? uri}) -
Integration.fromJson(Map<
String, dynamic> json) -
factory
Properties
-
cacheKeyParameters
→ List<
String> ? -
A list of request parameters whose values API Gateway caches. To be valid
values for
cacheKeyParameters
, these parameters must also be specified for MethodrequestParameters
.final - cacheNamespace → String?
-
Specifies a group of related cached parameters. By default, API Gateway uses
the resource ID as the
cacheNamespace
. You can specify the samecacheNamespace
across resources to return the same cached data for requests to different resources.final - connectionId → String?
-
The (
id
) of the VpcLink used for the integration whenconnectionType=VPC_LINK
and undefined, otherwise.final - connectionType → ConnectionType?
-
The type of the network connection to the integration endpoint. The valid
value is
INTERNET
for connections through the public routable internet orVPC_LINK
for private connections between API Gateway and a network load balancer in a VPC. The default value isINTERNET
.final - contentHandling → ContentHandlingStrategy?
-
Specifies how to handle request payload content type conversions. Supported
values are
CONVERT_TO_BINARY
andCONVERT_TO_TEXT
, with the following behaviors:final - credentials → String?
-
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.final - hashCode → int
-
The hash code for this object.
no setterinherited
- httpMethod → String?
-
Specifies the integration's HTTP method type.
final
-
integrationResponses
→ Map<
String, IntegrationResponse> ? -
Specifies the integration's responses.
final
- passthroughBehavior → String?
-
Specifies how the method request body of an unmapped content type will be
passed through the integration request to the back end without
transformation. A content type is unmapped if no mapping template is defined
in the integration or the content type does not match any of the mapped
content types, as specified in
requestTemplates
. The valid value is one of the following:-
WHEN_NO_MATCH
: passes the method request body through the integration request to the back end without transformation when the method request content type does not match any content type associated with the mapping templates defined in the integration request. -
WHEN_NO_TEMPLATES
: passes the method request body through the integration request to the back end without transformation when no mapping template is defined in the integration request. If a template is defined when this option is selected, the method request of an unmapped content-type will be rejected with an HTTP415 Unsupported Media Type
response. -
NEVER
: rejects the method request with an HTTP415 Unsupported Media Type
response when either the method request content type does not match any content type associated with the mapping templates defined in the integration request or no mapping template is defined in the integration request.
final -
-
requestParameters
→ Map<
String, String> ? -
A key-value map specifying request parameters that are passed from the
method request to the back end. 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 back end. The method request parameter value must match the pattern
of
method.request.{location}.{name}
, wherelocation
isquerystring
,path
, orheader
andname
must be a valid and unique method request parameter name.final -
requestTemplates
→ Map<
String, String> ? -
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.
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- timeoutInMillis → int?
-
Custom timeout between 50 and 29,000 milliseconds. The default value is
29,000 milliseconds or 29 seconds.
final
- tlsConfig → TlsConfig?
-
Specifies the TLS configuration for an integration.
final
- type → IntegrationType?
-
Specifies an API method integration type. The valid value is one of the
following:
final
- uri → String?
-
Specifies Uniform Resource Identifier (URI) of the integration endpoint.
final
Methods
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited