Show / Hide Table of Contents

Class Cors

Inheritance
object
Cors
Namespace: Amazon.CDK.AWS.APIGateway
Assembly: Amazon.CDK.Lib.dll
Syntax (csharp)
public class Cors : DeputyBase
Syntax (vb)
Public Class Cors Inherits DeputyBase
Remarks

ExampleMetadata: infused

Examples
new RestApi(this, "api", new RestApiProps {
                DefaultCorsPreflightOptions = new CorsOptions {
                    AllowOrigins = Cors.ALL_ORIGINS,
                    AllowMethods = Cors.ALL_METHODS
                }
            });

Synopsis

Properties

ALL_METHODS

All HTTP methods.

ALL_ORIGINS

All origins.

DEFAULT_HEADERS

The set of default headers allowed for CORS and useful for API Gateway.

Properties

ALL_METHODS

All HTTP methods.

public static string[] ALL_METHODS { get; }
Property Value

string[]

Remarks

ExampleMetadata: infused

ALL_ORIGINS

All origins.

public static string[] ALL_ORIGINS { get; }
Property Value

string[]

Remarks

ExampleMetadata: infused

DEFAULT_HEADERS

The set of default headers allowed for CORS and useful for API Gateway.

public static string[] DEFAULT_HEADERS { get; }
Property Value

string[]

Remarks

ExampleMetadata: infused

Back to top Generated by DocFX