aws/aws-cdk

awsapigatewayv2: Expose disableExecuteApiEndpoint option in WebSocketApi configuration

Open

#35.516 geöffnet am 17. Sept. 2025

Auf GitHub ansehen
 (3 Kommentare) (0 Reaktionen) (0 zugewiesene Personen)TypeScript (3.530 Forks)batch import
@aws-cdk/aws-apigatewayv2effort/mediumfeature-requestgood first issuep2

Repository-Metriken

Stars
 (10.710 Stars)
PR-Merge-Metriken
 (Durchschn. Merge 14T 11h) (68 gemergte PRs in 30 T)

Beschreibung

Describe the feature

The CfnApi construct has a disableExecuteApiEndpoint option: https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_apigatewayv2.CfnApi.html#disableexecuteapiendpoint

The WebSocketApi does not expose this option and does not expose the underlying CfnApi resource for further configuration. This makes it impossible to disable the default endpoint.

WebSocketApi docs: https://docs.aws.amazon.com/cdk/api/v2/docs/aws-cdk-lib.aws_apigatewayv2.WebSocketApi.html

Relevant WebSocketApi code: https://github.com/aws/aws-cdk/blob/v2.214.0/packages/aws-cdk-lib/aws-apigatewayv2/lib/websocket/api.ts#L158

Use Case

For security reasons, I would like to remove the default endpoint in my WebSocketApi.

Proposed Solution

Please expose this option for use with WebSocketApi constructs.

Other Information

No response

Acknowledgements

  • I may be able to implement this feature request
  • This feature might incur a breaking change

AWS CDK Library version (aws-cdk-lib)

2.191.0

AWS CDK CLI version

2.1011.0

Environment details (OS name and version, etc.)

any

Contributor Guide