I have Google Compute Engine\'s Credentials file , renamed as key.json. The next step is to set the environment variable with name GOOGLE_APPLICATION_CREDENTIALS. But it say
You got the error because you downloaded an OAuth 2.0 Client ID instead of a Service Account key.
If you want to use regular user credentials as the application default, you can now use the gcloud beta auth application-default login command to launch the web sign-in flow. This puts them in the well-known location for application default credentials, so you should unset the GOOGLE_APPLICATION_CREDENTIALS variable if you use this method.