Skip to main content
Google Cloud API Gateway is a fully managed service that allows developers to create, secure, and monitor APIs for their applications. It enables seamless management of APIs at scale, integrates with IAM for authentication, and provides features like quota management, monitoring, and logging. The GCPAPIGatewayHandler helps interact with Google Cloud’s API Gateway service to fetch gateway details programmatically.

Example

To create the GCPAPIGatewayHandler object, initialize it with your Google service account credentials (JSON file path or dictionary).
List API Gateways:
Lists all API Gateways available in your GCP project across supported regions.
Convert Gateway to Dictionary (_gateway_to_dict):
Converts a Gateway object into a structured dictionary with useful metadata.
Get Gateway State (_get_gateway_state):
Converts a raw state value (string, int, or enum) into a Gateway.State enum.