create_integration_response
¶
create_integration_response(
api_id: __string,
integration_id: __string,
*,
config_overrides: Optional[ApiGatewayV2ClientConfig] = None,
content_handling_strategy: Optional[ContentHandlingStrategy] = None,
integration_response_key: Optional[SelectionKey] = None,
response_parameters: Optional[IntegrationParameters] = None,
response_templates: Optional[TemplateMap] = None,
template_selection_expression: Optional[SelectionExpression] = None,
) -> CreateIntegrationResponseResponse
Creates an IntegrationResponses.
Parameters:
-
api_id(__string) –The API identifier.
-
content_handling_strategy(Optional[ContentHandlingStrategy], default:None) –Specifies how to handle response payload content type conversions. Supported values are CONVERT_TO_BINARY and CONVERT_TO_TEXT, with the following behaviors:
CONVERT_TO_BINARY: Converts a response payload from a Base64-encoded string to the corresponding binary blob.
CONVERT_TO_TEXT: Converts a response payload from a binary blob to a Base64-encoded string.
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.
-
integration_id(__string) –The integration ID.
-
integration_response_key(Optional[SelectionKey], default:None) –The integration response key.
-
response_parameters(Optional[IntegrationParameters], default:None) –A key-value map specifying response parameters that are passed to the method response from the backend. The key is a method response header parameter name and the mapped value is an integration response header value, a static value enclosed within a pair of single quotes, or a JSON expression from the integration response body. The mapping key must match the pattern of method.response.header.{name}, where {name} is a valid and unique header name. The mapped non-static value must match the pattern of integration.response.header.{name} or integration.response.body.{JSON-expression}, where {name} is a valid and unique response header name and {JSON-expression} is a valid JSON expression without the $ prefix.
-
response_templates(Optional[TemplateMap], default:None) –The collection of response templates for the integration response as a string-to-string map of key-value pairs. Response templates are represented as a key/value map, with a content-type as the key and a template as the value.
-
template_selection_expression(Optional[SelectionExpression], default:None) –The template selection expression for the integration response. Supported only for WebSocket APIs.
Raises:
-
BadRequestException–The request is not valid, for example, the input is incomplete or incorrect. See the accompanying error message for details.
-
ConflictException–The requested operation would cause a conflict with the current state of a service resource associated with the request. Resolve the conflict before retrying this request. See the accompanying error message for details.
-
NotFoundException–The resource specified in the request was not found. See the message field for more information.
-
TooManyRequestsException–A limit has been exceeded. See the accompanying error message for details.
-
UnknownServiceError–The service returned an error code this client does not model.
Source code in docs_src/capo_apigatewayv2/_services/api_gateway_v2.py
968 969 970 971 972 973 974 975 976 977 978 979 980 981 982 983 984 985 986 987 988 989 990 991 992 993 994 995 996 997 998 999 1000 1001 1002 1003 1004 1005 1006 1007 1008 1009 1010 1011 1012 1013 1014 1015 1016 1017 1018 1019 1020 1021 1022 1023 1024 1025 1026 1027 1028 1029 1030 1031 1032 1033 1034 1035 1036 1037 1038 1039 1040 1041 1042 1043 1044 1045 1046 1047 | |