Class: AWSCDK::APIGateway::CfnGatewayResponseProps
- Inherits:
-
Jsii::Struct
- Object
- Jsii::Struct
- AWSCDK::APIGateway::CfnGatewayResponseProps
- Defined in:
- api_gateway/cfn_gateway_response_props.rb
Overview
Properties for defining a CfnGatewayResponse.
Instance Attribute Summary collapse
-
#response_parameters ⇒ AWSCDK::IResolvable, ...
readonly
Response parameters (paths, query strings and headers) of the GatewayResponse as a string-to-string map of key-value pairs.
-
#response_templates ⇒ AWSCDK::IResolvable, ...
readonly
Response templates of the GatewayResponse as a string-to-string map of key-value pairs.
-
#response_type ⇒ String
readonly
The response type of the associated GatewayResponse.
-
#rest_api_id ⇒ String, AWSCDK::Interfaces::AWSApigateway::IRestAPIRef
readonly
The string identifier of the associated RestApi.
-
#status_code ⇒ String?
readonly
The HTTP status code for this GatewayResponse.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(response_type:, rest_api_id:, response_parameters: nil, response_templates: nil, status_code: nil) ⇒ CfnGatewayResponseProps
constructor
A new instance of CfnGatewayResponseProps.
- #to_jsii ⇒ Object
Constructor Details
#initialize(response_type:, rest_api_id:, response_parameters: nil, response_templates: nil, status_code: nil) ⇒ CfnGatewayResponseProps
Returns a new instance of CfnGatewayResponseProps.
14 15 16 17 18 19 20 21 22 23 24 25 |
# File 'api_gateway/cfn_gateway_response_props.rb', line 14 def initialize(response_type:, rest_api_id:, response_parameters: nil, response_templates: nil, status_code: nil) @response_type = response_type Jsii::Type.check_type(@response_type, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "responseType") @rest_api_id = rest_api_id Jsii::Type.check_type(@rest_api_id, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3sicHJpbWl0aXZlIjoic3RyaW5nIn0seyJmcW4iOiJhd3MtY2RrLWxpYi5pbnRlcmZhY2VzLmF3c19hcGlnYXRld2F5LklSZXN0QXBpUmVmIn1dfX0=")), "restApiId") @response_parameters = response_parameters Jsii::Type.check_type(@response_parameters, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3siZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifSx7ImNvbGxlY3Rpb24iOnsiZWxlbWVudHR5cGUiOnsicHJpbWl0aXZlIjoic3RyaW5nIn0sImtpbmQiOiJtYXAifX1dfX0=")), "responseParameters") unless @response_parameters.nil? @response_templates = response_templates Jsii::Type.check_type(@response_templates, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3siZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifSx7ImNvbGxlY3Rpb24iOnsiZWxlbWVudHR5cGUiOnsicHJpbWl0aXZlIjoic3RyaW5nIn0sImtpbmQiOiJtYXAifX1dfX0=")), "responseTemplates") unless @response_templates.nil? @status_code = status_code Jsii::Type.check_type(@status_code, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "statusCode") unless @status_code.nil? end |
Instance Attribute Details
#response_parameters ⇒ AWSCDK::IResolvable, ... (readonly)
Response parameters (paths, query strings and headers) of the GatewayResponse as a string-to-string map of key-value pairs.
41 42 43 |
# File 'api_gateway/cfn_gateway_response_props.rb', line 41 def response_parameters @response_parameters end |
#response_templates ⇒ AWSCDK::IResolvable, ... (readonly)
Response templates of the GatewayResponse as a string-to-string map of key-value pairs.
46 47 48 |
# File 'api_gateway/cfn_gateway_response_props.rb', line 46 def response_templates @response_templates end |
#response_type ⇒ String (readonly)
The response type of the associated GatewayResponse.
31 32 33 |
# File 'api_gateway/cfn_gateway_response_props.rb', line 31 def response_type @response_type end |
#rest_api_id ⇒ String, AWSCDK::Interfaces::AWSApigateway::IRestAPIRef (readonly)
The string identifier of the associated RestApi.
36 37 38 |
# File 'api_gateway/cfn_gateway_response_props.rb', line 36 def rest_api_id @rest_api_id end |
#status_code ⇒ String? (readonly)
The HTTP status code for this GatewayResponse.
51 52 53 |
# File 'api_gateway/cfn_gateway_response_props.rb', line 51 def status_code @status_code end |
Class Method Details
.jsii_properties ⇒ Object
53 54 55 56 57 58 59 60 61 |
# File 'api_gateway/cfn_gateway_response_props.rb', line 53 def self.jsii_properties { :response_type => "responseType", :rest_api_id => "restApiId", :response_parameters => "responseParameters", :response_templates => "responseTemplates", :status_code => "statusCode", } end |
Instance Method Details
#to_jsii ⇒ Object
63 64 65 66 67 68 69 70 71 72 73 |
# File 'api_gateway/cfn_gateway_response_props.rb', line 63 def to_jsii result = {} result.merge!({ "responseType" => @response_type, "restApiId" => @rest_api_id, "responseParameters" => @response_parameters, "responseTemplates" => @response_templates, "statusCode" => @status_code, }) result.compact end |