interface APIArgs {
    additionalRoutes?: any;
    apiKeySource?: APIKeySource;
    deploymentArgs?: DeploymentArgs;
    gatewayResponses?: Record<string, SwaggerGatewayResponse>;
    requestValidator?: RequestValidator;
    restApiArgs?: any;
    routes?: Route[];
    stageArgs?: StageArgs;
    stageName?: any;
    staticRoutesBucket?: any;
    swaggerString?: any;
}

Properties

additionalRoutes?: any

Routes to use to initialize the APIGateway. These will be used to create the Swagger specification for the API.

Either [swaggerString] or [routes] or [additionalRoutes] must be specified. [routes] can be provided along with [additionalRoutes].

apiKeySource?: APIKeySource

The source for the apikey. This can either be a HEADER or AUTHORIZER. If [apiKeyRequired] is set to true on a route, and this is not defined the value will default to HEADER.

deploymentArgs?: DeploymentArgs

Additional optional args that can be passed along to the aws.apigateway.Deployment created by the awsx.apigateway.API.

gatewayResponses?: Record<string, SwaggerGatewayResponse>

Define custom gateway responses for the API. This can be used to properly enable CORS for Lambda Authorizers.

requestValidator?: RequestValidator

Request Validator specifies the validator to use at the API level. Note method level validators override this.

restApiArgs?: any

Additional optional args that can be passed along to the aws.apigateway.RestApi created by the awsx.apigateway.API.

routes?: Route[]

Routes to use to initialize the APIGateway. These will be used to create the Swagger specification for the API.

Either [swaggerString] or [routes] or [additionalRoutes] must be specified. [routes] can be provided along with [additionalRoutes].

stageArgs?: StageArgs

Additional optional args that can be passed along to the aws.apigateway.Stage created by the awsx.apigateway.API.

stageName?: any

The stage name for your API. This will get added as a base path to your API url.

staticRoutesBucket?: any

Bucket to use for placing resources for static resources. If not provided a default one will be created on your behalf if any [StaticRoute]s are provided.

swaggerString?: any

A Swagger specification already in string form to use to initialize the APIGateway. Note that you must manually provide permission for any route targets to be invoked by API Gateway when using [swaggerString].

Either [swaggerString] or [routes] must be specified.

Generated using TypeDoc