A company runs a private Amazon API Gateway with two REST APIs in the same VPC. The BuyStock API calls the CheckFunds API to verify funds before a purchase. VPC flow logs show the BuyStock API calling CheckFunds over the internet instead of through the VPC. A solutions architect must ensure the APIs communicate through the VPC with the FEWEST code changes. Which solution meets this requirement?
Choose an answer
Tap an option to check your answer.
Correct answer: Use an interface endpoint..
Why this is the answer
Using an interface endpoint (AWS PrivateLink) allows private communication between services within your VPC and supported AWS services, including API Gateway. This ensures the BuyStock API can call the CheckFunds API privately without traversing the internet, directly addressing the problem of internet-based communication and minimizing code changes as the API endpoint remains the same. Adding an X-API-Key header is for authorization, not for controlling network traffic paths. A gateway endpoint is used for S3 and DynamoDB, not for API Gateway. Adding an SQS queue introduces asynchronous communication and significant architectural changes, which is not the "fewest code changes" solution for direct API-to-API communication.
Pass your exam — without the endless answer hunt
Get every verified question and explanation for this exam in one place, and save hours of prep. 1,000+ certifications · 20+ languages · free to start.
Pass your exam faster → No card needed