class Amazonite::ApiGateway::GatewayResponse

Overview

A gateway response of a given response type and status code, with optional response parameters and mapping templates.

Included Modules

Defined in:

api_gateway/gateway_response.cr

Constructors

Instance Method Summary

Constructor Detail

def self.new(pull : JSON::PullParser) #

[View source]
def self.new(response_type : GatewayResponseType | Nil = nil, status_code : String | Nil = nil, response_parameters : Hash(String, String) | Nil = nil, response_templates : Hash(String, String) | Nil = nil, default_response : Bool | Nil = nil) #

[View source]
def self.new(*, __pull_for_json_serializable pull : JSON::PullParser) #

[View source]

Instance Method Detail

def ==(other : self) #
Description copied from class Reference

Returns true if this reference is the same as other. Invokes same?.


def default_response : Bool | Nil #

A Boolean flag to indicate whether this GatewayResponse is the default gateway response (true) or not (false). A default gateway response is one generated by API Gateway without any customization by an API developer.


[View source]
def default_response=(default_response : Bool | Nil) #

A Boolean flag to indicate whether this GatewayResponse is the default gateway response (true) or not (false). A default gateway response is one generated by API Gateway without any customization by an API developer.


[View source]
def hash(hasher) #
Description copied from class Reference

See Object#hash(hasher)


def response_parameters : Hash(String, String) | Nil #

Response parameters (paths, query strings and headers) of the GatewayResponse as a string-to-string map of key-value pairs.


[View source]
def response_parameters=(response_parameters : Hash(String, String) | Nil) #

Response parameters (paths, query strings and headers) of the GatewayResponse as a string-to-string map of key-value pairs.


[View source]
def response_templates : Hash(String, String) | Nil #

Response templates of the GatewayResponse as a string-to-string map of key-value pairs.


[View source]
def response_templates=(response_templates : Hash(String, String) | Nil) #

Response templates of the GatewayResponse as a string-to-string map of key-value pairs.


[View source]
def response_type : GatewayResponseType | Nil #

The response type of the associated GatewayResponse.


[View source]
def response_type=(response_type : GatewayResponseType | Nil) #

The response type of the associated GatewayResponse.


[View source]
def status_code : String | Nil #

The HTTP status code for this GatewayResponse.


[View source]
def status_code=(status_code : String | Nil) #

The HTTP status code for this GatewayResponse.


[View source]
def validate! : Nil #

[View source]