GCLOUD_AUTH_APPLICATION-DEFAULT_LOGIN(1)

NAME

gcloud auth application-default login - acquire new user credentials to use for Application Default Credentials

SYNOPSIS

gcloud auth application-default login [--client-id-file=CLIENT_ID_FILE] [--no-launch-browser] [--scopes=SCOPES,[SCOPES,...]] [GCLOUD_WIDE_FLAG ...]

DESCRIPTION
Obtains user access credentials via a web flow and puts them in the well-known location for Application Default Credentials to use them as a proxy for a service account. This command is useful for when you are developing code that would normally use a service account, but you need to run the code in a local development environment, and it is easier to provide user credentials. The credentials will apply to all API calls that make use of the Application Default Credentials client library. This command has no effect on the user account(s) set up by the gcloud auth login command. Any credentials previously generated by this command will be overwritten.

FLAGS

    --client-id-file=CLIENT_ID_FILE
        A file containing your own client id to use to login.

    --launch-browser
        Launch a browser for authorization. If not enabled or DISPLAY variable is not set, prints a URL to standard output to be copied. Enabled by default, use --no-launch-browser to disable.

    --scopes=SCOPES,[SCOPES,...]
        The names of the scopes to authorize for. By default https://www.googleapis.com/auth/userinfo.email, https://www.googleapis.com/auth/cloud-platform scopes are used. The list of possible scopes can be found at: https://developers.google.com/identity/protocols/googlescopes.

GCLOUD WIDE FLAGS
These flags are available to all commands: --account, --configuration, --flatten, --format, --help, --log-http, --project, --quiet, --trace-token, --user-output-enabled, --verbosity. Run $ gcloud help for details.

EXAMPLES
If you want your local application to temporarily use your own user credentials for API access, run:
    $ gcloud auth application-default login