To use the Cloud Quotas API, you must first enable it for your Google Cloud project. This document describes how to enable the Cloud Quotas API.
Enable the API
You can enable the Cloud Quotas API by using the Google Cloud console or the Google Cloud CLI.
Console
Go to the Google Cloud console API Library page.
Select the Google Cloud project that you want to access the API.
On the API Library page, enable Cloud Quotas API.
Make sure that your user account has the required IAM roles.
gcloud
Before you begin
Authenticate to the gcloud CLI before you use it to enable APIs. For more information about the authentication process, see Authorize the gcloud CLI.
Enable the API
Run the
gcloud services enable
command and specify the Cloud Quotas API:gcloud services enable cloudquotas.googleapis.com --project=PROJECT_ID
Replace
PROJECT_ID
with the ID of the project that needs access to the Cloud Quotas API. You can find your project ID on the Welcome page of the Google Cloud console.To confirm that the Cloud Quotas API is enabled in your project, run the
gcloud services list
command and filter forcloudquotas.googleapis.com
by passing the output to a command such asgrep
or using a gcloud CLIfilter
:gcloud services list --filter="cloudquotas.googleapis.com"
What's next
About the Cloud Quotas API
Cloud Quotas API reference