You can call APIs in API Gateway over a virtual private cloud (VPC) from a VPC or from Function Compute.
Access API Gateway from a VPC
API Gateway supports access over the Internet or a VPC:
-
Enable VPC-based access for a serverless instance: Serverless instances support VPC-based access. All VPCs in the same region as the instance can access it.
-
Enable VPC access for a dedicated instance: You can authorize only one VPC in the same region to access a dedicated instance. Other VPCs in the same region are blocked, which enhances security.
Access API Gateway from Function Compute over an internal network
Function Compute can access API Gateway over a VPC in the following scenarios:
-
Scenario 1: API Gateway and Function Compute are deployed in the same region.
-
Scenario 2: API Gateway and Function Compute are deployed in different regions.
This feature is available only for dedicated instances.
Configuration rules:
-
Access must go through a VPC.
-
For more information, see Access API Gateway from a VPC.
-
For more information about VPC-based access from Function Compute, see Configure network settings.