put_gateway_response
async
¶
put_gateway_response(
rest_api_id: String,
response_type: GatewayResponseType,
*,
config_overrides: Optional[AsyncAPIGatewayClientConfig] = None,
status_code: Optional[StatusCode] = None,
response_parameters: Optional[MapOfStringToString] = None,
response_templates: Optional[MapOfStringToString] = None,
) -> GatewayResponse
Creates a customization of a GatewayResponse of a specified response type and status code on the given RestApi.
Parameters:
-
rest_api_id(String) –The string identifier of the associated RestApi.
-
response_type(GatewayResponseType) –The response type of the associated GatewayResponse
-
status_code(Optional[StatusCode], default:None) –The HTTP status code of the GatewayResponse.
-
response_parameters(Optional[MapOfStringToString], default:None) –Response parameters (paths, query strings and headers) of the GatewayResponse as a string-to-string map of key-value pairs.
-
response_templates(Optional[MapOfStringToString], default:None) –Response templates of the GatewayResponse as a string-to-string map of key-value pairs.
Raises:
-
BadRequestException–The submitted request is not valid, for example, the input is incomplete or incorrect. See the accompanying error message for details.
-
ConflictException–The request configuration has conflicts. For details, see the accompanying error message.
-
LimitExceededException–The request exceeded the rate limit. Retry after the specified time period.
-
NotFoundException–The requested resource is not found. Make sure that the request URI is correct.
-
TooManyRequestsException–The request has reached its throttling limit. Retry after the specified time period.
-
UnauthorizedException–The request is denied because the caller has insufficient permissions.
-
UnknownServiceError–The service returned an error code this client does not model.
Source code in docs_src/capo_api_gateway/_services/async_api_gateway.py
5992 5993 5994 5995 5996 5997 5998 5999 6000 6001 6002 6003 6004 6005 6006 6007 6008 6009 6010 6011 6012 6013 6014 6015 6016 6017 6018 6019 6020 6021 6022 6023 6024 6025 6026 6027 6028 6029 6030 6031 6032 6033 6034 6035 6036 6037 6038 6039 6040 6041 6042 6043 6044 6045 6046 6047 6048 6049 6050 6051 6052 6053 6054 6055 6056 6057 6058 6059 6060 | |