aws / aws/aws-cdk

(aws-apigatewayv2): allow to get routes/endpoints programmatically

Open
#20,627 0 comments 0 reactions 0 assignees View on GitHub
@aws-cdk/aws-apigatewayv2 effort/small feature-request p2
Dominant language
TypeScript
Stars
12.9k
Forks
4.6k
Avg merge
2d 3h
Merged PRs (30d)
83

Description

### Describe the feature

With a REST api we can do

```ts
import * as apigateway from "aws-cdk-lib/aws-apigateway";
const someEndpoint = apigateway.Resource.fromResourceAttributes(this, "someEndpoint", {
path: "/channels",
resourceId: "someId",
restApi: apiGW,
});
```

It would be great if we could do the same with the http api. I have a route declared in stack A and now I need to get this route in stack b.

### Use Case

I have a route declared in stack A and now I need to get this route in stack b.

### Proposed Solution

_No response_

### Other Information

_No response_

### Acknowledgements

- [ ] I may be able to implement this feature request
- [ ] This feature might incur a breaking change

### CDK version used

2.27.0 (build 8e89048)

### Environment details (OS name and version, etc.)

Mac OS

Contributor guide

Open the contributing guide

Research direction

Start at the aws-apigateway Resource.fromResourceAttributes entry point and compare how its resource reference is represented with the aws-apigatewayv2 route constructs. Trace how a route declared in stack A could be referenced from stack B; done means the HTTP API exposes an equivalent programmatic route reference for that cross-stack use case.

Written by the indexing model from the issue text.

Assessment

Tech stack
aws, typescript
Domain
api, cloud
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
30/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.