API Gateway V2

@aws-lite/apigatewayv2

Maintained by: @architect

Install

npm i @aws-lite/apigatewayv2

Optionally install types:

npm i -D @aws-lite/apigatewayv2-types

Methods

CreateDeployment

Canonical AWS API doc

Properties

ApiId (string) [required]

API ID

Description (string)

Deployment description

StageName (string)

Stage name

Example

await aws.APIGatewayV2.CreateDeployment({
  ApiId: String, // required
  Description: String,
  StageName: String,
})

CreateDomainName

Canonical AWS API doc

Properties

DomainName (string) [required]

The domain name

DomainNameConfigurations (array)

Array of DomainNameConfiguration objects

More details (AWS)
Tags (object)

Record containing tags associated with the domain name

Example

await aws.APIGatewayV2.CreateDomainName({
  DomainName: String, // required
  DomainNameConfigurations: Array,
  MutualTlsAuthentication: Object,
  Tags: Object,
})

DeleteApiMapping

Canonical AWS API doc

Properties

ApiMappingId (string) [required]

ID of the API mapping

DomainName (string) [required]

The domain name

Example

await aws.APIGatewayV2.DeleteApiMapping({
  ApiMappingId: String, // required
  DomainName: String, // required
})

DeleteDomainName

Canonical AWS API doc

Properties

DomainName (string) [required]

The domain name

Example

await aws.APIGatewayV2.DeleteDomainName({
  DomainName: String, // required
})

GetApiMappings

Canonical AWS API doc

Properties

DomainName (string) [required]

The domain name

MaxResults (number)

Maximum number of items to evaluate and return

NextToken (string)

Pagination cursor token to be used if NextToken was returned in a previous response

paginate (boolean)

Enable automatic result pagination; use this instead of making your own individual pagination requests

Example

await aws.APIGatewayV2.GetApiMappings({
  DomainName: String, // required
  MaxResults: Number,
  NextToken: String,
  paginate: Boolean,
})

GetDeployment

Canonical AWS API doc

Properties

ApiId (string) [required]

API ID

MaxResults (number)

Maximum number of items to evaluate and return

NextToken (string)

Pagination cursor token to be used if NextToken was returned in a previous response

Example

await aws.APIGatewayV2.GetDeployment({
  ApiId: String, // required
  MaxResults: Number,
  NextToken: String,
})

GetDeployments

Canonical AWS API doc

Properties

ApiId (string) [required]

API ID

MaxResults (number)

Maximum number of items to evaluate and return

NextToken (string)

Pagination cursor token to be used if NextToken was returned in a previous response

paginate (boolean)

Enable automatic result pagination; use this instead of making your own individual pagination requests

Example

await aws.APIGatewayV2.GetDeployments({
  ApiId: String, // required
  MaxResults: Number,
  NextToken: String,
  paginate: Boolean,
})

UpdateStage

Canonical AWS API doc

Properties

ApiId (string) [required]

API ID

StageName (string) [required]

Stage name

AccessLogSettings (object)

Access log settings for the stage

More details (AWS)
DeploymentId (string)

Deployment ID for the API stage; cannot be updated if autoDeploy is enabled

Description (string)

Deployment description

RouteSettings (object)

Route settings for the stage

More details (AWS)

Example

await aws.APIGatewayV2.UpdateStage({
  ApiId: String, // required
  StageName: String, // required
  AccessLogSettings: Object,
  AutoDeploy: Boolean,
  ClientCertificateId: String,
  DefaultRouteSettings: Object,
  DeploymentId: String,
  Description: String,
  RouteSettings: Object,
  StageVariables: Object,
})

Methods yet to be implemented

Please help out by opening a PR!

aws-lite is an Apache 2.0-licensed open source project under the umbrella of OpenJS Foundation Architect. aws-lite is not in any way affiliated with Amazon Web Services, Inc. (AWS). All names and trademarks are the property of their respective owners.