Enabling the Network Management API

Before you can run Connectivity Tests, you must enable the Network Management API.

Enabling the API is required in order to use the API itself, the gcloud command-line tool, or the Google Cloud Console.

You can check API status or enable the API by using a gcloud command or by using the Google Cloud Console. You can also authorize users to access the API.

Enabling the API

Use one of the following methods to enable the API.

Console

When you load Connectivity Tests in the Google Cloud Console for the first time for a specific project, click the button that asks you to enable the Network Management API. You must enable the API in order to run Connectivity Tests.

gcloud

  1. If you have not already installed the Cloud SDK on your workstation, see the Cloud SDK documentation to do so.

  2. To check if the Network Management API is enabled, run the following command on your workstation:

    gcloud services list
    

    If networkmanagement.googleapis.com appears in the command output, the API is enabled.

  3. If the API is not enabled, run the following command to enable it. For more information, see gcloud services.

    gcloud services enable networkmanagement.googleapis.com
    

Authorizing use of the API

Access to the Network Management API is controlled by Identity and Access Management roles and permissions. Permissions for related methods are clustered into roles, which you can then grant to users.

For more information, see the following documents:

Using the API Explorer

É possível testar comandos da API Network Management usando o APIs Explorer. No documento de referência da API Network Management, use a coluna Try this API para explorar os campos da API e executar um teste.