When we add an API to the developer portal, where the defined integration type within AWS API Gateway is VPC Link, aka private endpoint, it is not possible to send a test request to that API (Try me now! button) because a curl command is automatically generated using the API's public endpoint. In this case the request needs to be internal, meaning that the target request should be the VPC Link endpoint, along with the Host header specifying the API public identifier endpoint.
The information concerning vpc link, stage, resources and public api endpoint is already defined within AWS API Gateway, meaning that a possible solution could be to include this information, along with the VPC link info, into the exported openapi/swagger file and extend the logic that auto generates the curl command.
This is not as simple as updating the curl command, because there's a connectivity issue, meaning that the existing logic behind AWS API Gateway, to use VPC Links, would need to be added to the DEV Portal.
When we add an API to the developer portal, where the defined integration type within AWS API Gateway is VPC Link, aka private endpoint, it is not possible to send a test request to that API (Try me now! button) because a curl command is automatically generated using the API's public endpoint. In this case the request needs to be internal, meaning that the target request should be the VPC Link endpoint, along with the Host header specifying the API public identifier endpoint.
Example:
The information concerning vpc link, stage, resources and public api endpoint is already defined within AWS API Gateway, meaning that a possible solution could be to include this information, along with the VPC link info, into the exported openapi/swagger file and extend the logic that auto generates the curl command.
This is not as simple as updating the curl command, because there's a connectivity issue, meaning that the existing logic behind AWS API Gateway, to use VPC Links, would need to be added to the DEV Portal.