Table of Contents

Class GatewayResponse

Namespace
Amazon.CDK.AWS.APIGateway
Assembly
Amazon.CDK.AWS.APIGateway.dll

Configure the response received by clients, produced from the API Gateway backend.

public class GatewayResponse : Resource, IGatewayResponse, IResource, IConstruct, IConstruct, IDependable
Inheritance
GatewayResponse
Implements
IResource
IConstruct
IConstruct
IDependable

Examples

// The code below shows an example of how to instantiate this type.
             // The values are placeholders you should change.
             using Amazon.CDK.AWS.APIGateway;

             ResponseType responseType;
             RestApi restApi;

             var gatewayResponse = new GatewayResponse(this, "MyGatewayResponse", new GatewayResponseProps {
                 RestApi = restApi,
                 Type = responseType,

                 // the properties below are optional
                 ResponseHeaders = new Dictionary<string, string> {
                     { "responseHeadersKey", "responseHeaders" }
                 },
                 StatusCode = "statusCode",
                 Templates = new Dictionary<string, string> {
                     { "templatesKey", "templates" }
                 }
             });

Remarks

Resource: AWS::ApiGateway::GatewayResponse

ExampleMetadata: fixture=_generated

Constructors

GatewayResponse(Construct, string, IGatewayResponseProps)

public GatewayResponse(Construct scope, string id, IGatewayResponseProps props)

Parameters

scope Construct
id string
props IGatewayResponseProps