public class PutIntegrationResult extends Object implements Serializable, Cloneable
Represents a HTTP, AWS, or Mock integration.
Constructor and Description |
---|
PutIntegrationResult() |
Modifier and Type | Method and Description |
---|---|
PutIntegrationResult |
addIntegrationResponsesEntry(String key,
IntegrationResponse value) |
PutIntegrationResult |
addRequestParametersEntry(String key,
String value) |
PutIntegrationResult |
addRequestTemplatesEntry(String key,
String value) |
PutIntegrationResult |
clearIntegrationResponsesEntries()
Removes all the entries added into IntegrationResponses.
|
PutIntegrationResult |
clearRequestParametersEntries()
Removes all the entries added into RequestParameters.
|
PutIntegrationResult |
clearRequestTemplatesEntries()
Removes all the entries added into RequestTemplates.
|
PutIntegrationResult |
clone() |
boolean |
equals(Object obj) |
List<String> |
getCacheKeyParameters()
Specifies the integration's cache key parameters.
|
String |
getCacheNamespace()
Specifies the integration's cache namespace.
|
String |
getCredentials()
Specifies the credentials required for the integration, if any.
|
String |
getHttpMethod()
Specifies the integration's HTTP method type.
|
Map<String,IntegrationResponse> |
getIntegrationResponses()
Specifies the integration's responses.
|
String |
getPassthroughBehavior()
Specifies the pass-through behavior for incoming requests based on the
Content-Type header in the request, and the available requestTemplates
defined on the Integration.
|
Map<String,String> |
getRequestParameters()
Represents requests parameters that are sent with the backend request.
|
Map<String,String> |
getRequestTemplates()
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.
|
String |
getType()
Specifies the integration's type.
|
String |
getUri()
Specifies the integration's Uniform Resource Identifier (URI).
|
int |
hashCode() |
void |
setCacheKeyParameters(Collection<String> cacheKeyParameters)
Specifies the integration's cache key parameters.
|
void |
setCacheNamespace(String cacheNamespace)
Specifies the integration's cache namespace.
|
void |
setCredentials(String credentials)
Specifies the credentials required for the integration, if any.
|
void |
setHttpMethod(String httpMethod)
Specifies the integration's HTTP method type.
|
void |
setIntegrationResponses(Map<String,IntegrationResponse> integrationResponses)
Specifies the integration's responses.
|
void |
setPassthroughBehavior(String passthroughBehavior)
Specifies the pass-through behavior for incoming requests based on the
Content-Type header in the request, and the available requestTemplates
defined on the Integration.
|
void |
setRequestParameters(Map<String,String> requestParameters)
Represents requests parameters that are sent with the backend request.
|
void |
setRequestTemplates(Map<String,String> requestTemplates)
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.
|
void |
setType(IntegrationType type)
Specifies the integration's type.
|
void |
setType(String type)
Specifies the integration's type.
|
void |
setUri(String uri)
Specifies the integration's Uniform Resource Identifier (URI).
|
String |
toString()
Returns a string representation of this object; useful for testing and
debugging.
|
PutIntegrationResult |
withCacheKeyParameters(Collection<String> cacheKeyParameters)
Specifies the integration's cache key parameters.
|
PutIntegrationResult |
withCacheKeyParameters(String... cacheKeyParameters)
Specifies the integration's cache key parameters.
|
PutIntegrationResult |
withCacheNamespace(String cacheNamespace)
Specifies the integration's cache namespace.
|
PutIntegrationResult |
withCredentials(String credentials)
Specifies the credentials required for the integration, if any.
|
PutIntegrationResult |
withHttpMethod(String httpMethod)
Specifies the integration's HTTP method type.
|
PutIntegrationResult |
withIntegrationResponses(Map<String,IntegrationResponse> integrationResponses)
Specifies the integration's responses.
|
PutIntegrationResult |
withPassthroughBehavior(String passthroughBehavior)
Specifies the pass-through behavior for incoming requests based on the
Content-Type header in the request, and the available requestTemplates
defined on the Integration.
|
PutIntegrationResult |
withRequestParameters(Map<String,String> requestParameters)
Represents requests parameters that are sent with the backend request.
|
PutIntegrationResult |
withRequestTemplates(Map<String,String> requestTemplates)
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.
|
PutIntegrationResult |
withType(IntegrationType type)
Specifies the integration's type.
|
PutIntegrationResult |
withType(String type)
Specifies the integration's type.
|
PutIntegrationResult |
withUri(String uri)
Specifies the integration's Uniform Resource Identifier (URI).
|
public void setType(String type)
Specifies the integration's type. The valid value is HTTP
,
AWS
, or MOCK
.
type
- Specifies the integration's type. The valid value is
HTTP
, AWS
, or MOCK
.IntegrationType
public String getType()
Specifies the integration's type. The valid value is HTTP
,
AWS
, or MOCK
.
HTTP
, AWS
, or MOCK
.IntegrationType
public PutIntegrationResult withType(String type)
Specifies the integration's type. The valid value is HTTP
,
AWS
, or MOCK
.
type
- Specifies the integration's type. The valid value is
HTTP
, AWS
, or MOCK
.IntegrationType
public void setType(IntegrationType type)
Specifies the integration's type. The valid value is HTTP
,
AWS
, or MOCK
.
type
- Specifies the integration's type. The valid value is
HTTP
, AWS
, or MOCK
.IntegrationType
public PutIntegrationResult withType(IntegrationType type)
Specifies the integration's type. The valid value is HTTP
,
AWS
, or MOCK
.
type
- Specifies the integration's type. The valid value is
HTTP
, AWS
, or MOCK
.IntegrationType
public void setHttpMethod(String httpMethod)
Specifies the integration's HTTP method type.
httpMethod
- Specifies the integration's HTTP method type.public String getHttpMethod()
Specifies the integration's HTTP method type.
public PutIntegrationResult withHttpMethod(String httpMethod)
Specifies the integration's HTTP method type.
httpMethod
- Specifies the integration's HTTP method type.public void setUri(String uri)
Specifies the integration's Uniform Resource Identifier (URI). For HTTP
integrations, the URI must be a fully formed, encoded HTTP(S) URL
according to the RFC-3986 specification. For AWS integrations, the URI
should be of the form
arn:aws:apigateway:{region}:{subdomain.service|service}:{path|action}/{service_api}
. Region
, subdomain
and service
are used to determine the right endpoint. For AWS services that use the
Action=
query string parameter, service_api
should be a valid action for the desired service. For RESTful AWS service
APIs, path
is used to indicate that the remaining substring
in the URI should be treated as the path to the resource, including the
initial /
.
uri
- Specifies the integration's Uniform Resource Identifier (URI). For
HTTP integrations, the URI must be a fully formed, encoded HTTP(S)
URL according to the RFC-3986 specification. For AWS integrations,
the URI should be of the form
arn:aws:apigateway:{region}:{subdomain.service|service}:{path|action}/{service_api}
. Region
, subdomain
and
service
are used to determine the right endpoint. For
AWS services that use the Action=
query string
parameter, service_api
should be a valid action for
the desired service. For RESTful AWS service APIs,
path
is used to indicate that the remaining substring
in the URI should be treated as the path to the resource,
including the initial /
.public String getUri()
Specifies the integration's Uniform Resource Identifier (URI). For HTTP
integrations, the URI must be a fully formed, encoded HTTP(S) URL
according to the RFC-3986 specification. For AWS integrations, the URI
should be of the form
arn:aws:apigateway:{region}:{subdomain.service|service}:{path|action}/{service_api}
. Region
, subdomain
and service
are used to determine the right endpoint. For AWS services that use the
Action=
query string parameter, service_api
should be a valid action for the desired service. For RESTful AWS service
APIs, path
is used to indicate that the remaining substring
in the URI should be treated as the path to the resource, including the
initial /
.
arn:aws:apigateway:{region}:{subdomain.service|service}:{path|action}/{service_api}
. Region
, subdomain
and
service
are used to determine the right endpoint.
For AWS services that use the Action=
query string
parameter, service_api
should be a valid action for
the desired service. For RESTful AWS service APIs,
path
is used to indicate that the remaining
substring in the URI should be treated as the path to the
resource, including the initial /
.public PutIntegrationResult withUri(String uri)
Specifies the integration's Uniform Resource Identifier (URI). For HTTP
integrations, the URI must be a fully formed, encoded HTTP(S) URL
according to the RFC-3986 specification. For AWS integrations, the URI
should be of the form
arn:aws:apigateway:{region}:{subdomain.service|service}:{path|action}/{service_api}
. Region
, subdomain
and service
are used to determine the right endpoint. For AWS services that use the
Action=
query string parameter, service_api
should be a valid action for the desired service. For RESTful AWS service
APIs, path
is used to indicate that the remaining substring
in the URI should be treated as the path to the resource, including the
initial /
.
uri
- Specifies the integration's Uniform Resource Identifier (URI). For
HTTP integrations, the URI must be a fully formed, encoded HTTP(S)
URL according to the RFC-3986 specification. For AWS integrations,
the URI should be of the form
arn:aws:apigateway:{region}:{subdomain.service|service}:{path|action}/{service_api}
. Region
, subdomain
and
service
are used to determine the right endpoint. For
AWS services that use the Action=
query string
parameter, service_api
should be a valid action for
the desired service. For RESTful AWS service APIs,
path
is used to indicate that the remaining substring
in the URI should be treated as the path to the resource,
including the initial /
.public void setCredentials(String credentials)
Specifies the credentials required for the integration, if any. For AWS
integrations, three options are available. To specify an IAM Role for
Amazon 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.
credentials
- Specifies the credentials required for the integration, if any.
For AWS integrations, three options are available. To specify an
IAM Role for Amazon 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.public String getCredentials()
Specifies the credentials required for the integration, if any. For AWS
integrations, three options are available. To specify an IAM Role for
Amazon 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.
arn:aws:iam::\*:user/\*
. To use resource-based
permissions on supported AWS services, specify null.public PutIntegrationResult withCredentials(String credentials)
Specifies the credentials required for the integration, if any. For AWS
integrations, three options are available. To specify an IAM Role for
Amazon 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.
credentials
- Specifies the credentials required for the integration, if any.
For AWS integrations, three options are available. To specify an
IAM Role for Amazon 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.public Map<String,String> getRequestParameters()
Represents requests parameters that are sent with the backend request.
Request parameters are represented as a key/value map, with a destination
as the key and a source as the value. A source must match an existing
method request parameter, or a static value. Static values must be
enclosed with single quotes, and be pre-encoded based on their
destination in the request. The destination must match the pattern
integration.request.{location}.{name}
, where
location
is either querystring, path, or header.
name
must be a valid, unique parameter name.
integration.request.{location}.{name}
, where
location
is either querystring, path, or header.
name
must be a valid, unique parameter name.public void setRequestParameters(Map<String,String> requestParameters)
Represents requests parameters that are sent with the backend request.
Request parameters are represented as a key/value map, with a destination
as the key and a source as the value. A source must match an existing
method request parameter, or a static value. Static values must be
enclosed with single quotes, and be pre-encoded based on their
destination in the request. The destination must match the pattern
integration.request.{location}.{name}
, where
location
is either querystring, path, or header.
name
must be a valid, unique parameter name.
requestParameters
- Represents requests parameters that are sent with the backend
request. Request parameters are represented as a key/value map,
with a destination as the key and a source as the value. A source
must match an existing method request parameter, or a static
value. Static values must be enclosed with single quotes, and be
pre-encoded based on their destination in the request. The
destination must match the pattern
integration.request.{location}.{name}
, where
location
is either querystring, path, or header.
name
must be a valid, unique parameter name.public PutIntegrationResult withRequestParameters(Map<String,String> requestParameters)
Represents requests parameters that are sent with the backend request.
Request parameters are represented as a key/value map, with a destination
as the key and a source as the value. A source must match an existing
method request parameter, or a static value. Static values must be
enclosed with single quotes, and be pre-encoded based on their
destination in the request. The destination must match the pattern
integration.request.{location}.{name}
, where
location
is either querystring, path, or header.
name
must be a valid, unique parameter name.
requestParameters
- Represents requests parameters that are sent with the backend
request. Request parameters are represented as a key/value map,
with a destination as the key and a source as the value. A source
must match an existing method request parameter, or a static
value. Static values must be enclosed with single quotes, and be
pre-encoded based on their destination in the request. The
destination must match the pattern
integration.request.{location}.{name}
, where
location
is either querystring, path, or header.
name
must be a valid, unique parameter name.public PutIntegrationResult addRequestParametersEntry(String key, String value)
public PutIntegrationResult clearRequestParametersEntries()
public Map<String,String> getRequestTemplates()
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.
public void setRequestTemplates(Map<String,String> requestTemplates)
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.
requestTemplates
- 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.public PutIntegrationResult withRequestTemplates(Map<String,String> requestTemplates)
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.
requestTemplates
- 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.public PutIntegrationResult addRequestTemplatesEntry(String key, String value)
public PutIntegrationResult clearRequestTemplatesEntries()
public void setPassthroughBehavior(String passthroughBehavior)
Specifies the pass-through behavior for incoming requests based on the
Content-Type header in the request, and the available requestTemplates
defined on the Integration. There are three valid values:
WHEN_NO_MATCH
, WHEN_NO_TEMPLATES
, and
NEVER
.
WHEN_NO_MATCH
passes the request body for unmapped content
types through to the Integration backend without transformation.
NEVER
rejects unmapped content types with an HTTP 415
'Unsupported Media Type' response.
WHEN_NO_TEMPLATES
will allow 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 415 response.
passthroughBehavior
- Specifies the pass-through behavior for incoming requests based on
the Content-Type header in the request, and the available
requestTemplates defined on the Integration. There are three valid
values: WHEN_NO_MATCH
, WHEN_NO_TEMPLATES
, and NEVER
.
WHEN_NO_MATCH
passes the request body for unmapped
content types through to the Integration backend without
transformation.
NEVER
rejects unmapped content types with an HTTP 415
'Unsupported Media Type' response.
WHEN_NO_TEMPLATES
will allow 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 415 response.
public String getPassthroughBehavior()
Specifies the pass-through behavior for incoming requests based on the
Content-Type header in the request, and the available requestTemplates
defined on the Integration. There are three valid values:
WHEN_NO_MATCH
, WHEN_NO_TEMPLATES
, and
NEVER
.
WHEN_NO_MATCH
passes the request body for unmapped content
types through to the Integration backend without transformation.
NEVER
rejects unmapped content types with an HTTP 415
'Unsupported Media Type' response.
WHEN_NO_TEMPLATES
will allow 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 415 response.
WHEN_NO_MATCH
,
WHEN_NO_TEMPLATES
, and NEVER
.
WHEN_NO_MATCH
passes the request body for unmapped
content types through to the Integration backend without
transformation.
NEVER
rejects unmapped content types with an HTTP
415 'Unsupported Media Type' response.
WHEN_NO_TEMPLATES
will allow 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 415 response.
public PutIntegrationResult withPassthroughBehavior(String passthroughBehavior)
Specifies the pass-through behavior for incoming requests based on the
Content-Type header in the request, and the available requestTemplates
defined on the Integration. There are three valid values:
WHEN_NO_MATCH
, WHEN_NO_TEMPLATES
, and
NEVER
.
WHEN_NO_MATCH
passes the request body for unmapped content
types through to the Integration backend without transformation.
NEVER
rejects unmapped content types with an HTTP 415
'Unsupported Media Type' response.
WHEN_NO_TEMPLATES
will allow 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 415 response.
passthroughBehavior
- Specifies the pass-through behavior for incoming requests based on
the Content-Type header in the request, and the available
requestTemplates defined on the Integration. There are three valid
values: WHEN_NO_MATCH
, WHEN_NO_TEMPLATES
, and NEVER
.
WHEN_NO_MATCH
passes the request body for unmapped
content types through to the Integration backend without
transformation.
NEVER
rejects unmapped content types with an HTTP 415
'Unsupported Media Type' response.
WHEN_NO_TEMPLATES
will allow 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 415 response.
public void setCacheNamespace(String cacheNamespace)
Specifies the integration's cache namespace.
cacheNamespace
- Specifies the integration's cache namespace.public String getCacheNamespace()
Specifies the integration's cache namespace.
public PutIntegrationResult withCacheNamespace(String cacheNamespace)
Specifies the integration's cache namespace.
cacheNamespace
- Specifies the integration's cache namespace.public List<String> getCacheKeyParameters()
Specifies the integration's cache key parameters.
public void setCacheKeyParameters(Collection<String> cacheKeyParameters)
Specifies the integration's cache key parameters.
cacheKeyParameters
- Specifies the integration's cache key parameters.public PutIntegrationResult withCacheKeyParameters(String... cacheKeyParameters)
Specifies the integration's cache key parameters.
NOTE: This method appends the values to the existing list (if
any). Use setCacheKeyParameters(java.util.Collection)
or
withCacheKeyParameters(java.util.Collection)
if you want to
override the existing values.
cacheKeyParameters
- Specifies the integration's cache key parameters.public PutIntegrationResult withCacheKeyParameters(Collection<String> cacheKeyParameters)
Specifies the integration's cache key parameters.
cacheKeyParameters
- Specifies the integration's cache key parameters.public Map<String,IntegrationResponse> getIntegrationResponses()
Specifies the integration's responses.
public void setIntegrationResponses(Map<String,IntegrationResponse> integrationResponses)
Specifies the integration's responses.
integrationResponses
- Specifies the integration's responses.public PutIntegrationResult withIntegrationResponses(Map<String,IntegrationResponse> integrationResponses)
Specifies the integration's responses.
integrationResponses
- Specifies the integration's responses.public PutIntegrationResult addIntegrationResponsesEntry(String key, IntegrationResponse value)
public PutIntegrationResult clearIntegrationResponsesEntries()
public String toString()
toString
in class Object
Object.toString()
public PutIntegrationResult clone()
Copyright © 2013 Amazon Web Services, Inc. All Rights Reserved.