(aws-route53-targets): Cannot use SpecRestApi to create ApiGateway target for ARecord #16227
Labels
@aws-cdk/aws-apigateway
Related to Amazon API Gateway
@aws-cdk/aws-route53-targets
bug
This issue is a bug.
effort/small
Small work item – less than a day of effort
good first issue
Related to contributions. See CONTRIBUTING.md
p1
I'm trying to use the
SpecRestApi
to create API Gateway based on the OpenAPI document. To have the ability to use Custom Domain Name I need to createARecord
, butRecordTarget.fromAlias(new ApiGateway(apiGW))
accepts onlyRestApi
class.Reproduction Steps
Code snipet:
What did you expect to happen?
I'm able to create
ARecord
withSpecRestApi
What actually happened?
The compiler shows me error
Argument of type 'SpecRestApi' is not assignable to parameter of type 'RestApi'.
Environment
Other
Suggestion for fix:
on this line need to change
apig.RestApi
toapig.RestApiBase
This is 🐛 Bug Report
The text was updated successfully, but these errors were encountered: