Execution failed due to configuration error: Invalid VpcLink id 96czbs referenced in integration.

0

I have created a VPC link in API Gateway to integrate API with a private ALB. While testing, it throws the error as below, Invalid VpcLink id 96czbs referenced in integration. Execution failed due to configuration error: Invalid VpcLink id 96czbs referenced in integration Method completed with status: 500

However, the get vpc link detail command (aws apigatewayv2 get-vpc-link --vpc-link-id 96czbs --region ap-south-1) output the complete details of the vpc link including the status as below, "VpcLinkId": "96czbs", "VpcLinkStatus": "AVAILABLE", "VpcLinkStatusMessage": "VPC link is ready to route traffic",

Please advise what could be the reason for this error. Thanks!

NGuru
已提问 2 个月前349 查看次数
1 回答
0
已接受的回答

Hello,

Please note that there are essentially following reasons why you should get this error:

  1. VPC links needs about 10 minutes to become available after creation. When the VPC links are not truly available, API returns this error.
  2. If you are using stage variables in VPC link settings, and the stage variables are not set correctly.
  3. If you are using HTTP VPC Link in REST API configurations or vice-versa.

I would like to mention that the VPC Link for HTTP API and REST API are different. They can't be used interchangeably i.e HTTP VPC Links are only for HTTP APIs and REST VPC Links are supposed to be only used with the REST API.

If VPC link is created for HTTP API, then to use VPC Links with REST API, you will have to create a new VPC Link for REST API and use that VPC Link ID in your REST API integration. Please refer the below documentation

[+] https://docs.aws.amazon.com/apigateway/latest/developerguide/getting-started-with-private-integration.html

If you still observe the issue, you can raise a case to AWS support team as they can guide you with the configurations

Thanks

AWS
已回答 2 个月前
  • Thank you, Sowjanya for your response.

您未登录。 登录 发布回答。

一个好的回答可以清楚地解答问题和提供建设性反馈,并能促进提问者的职业发展。

回答问题的准则