Working on a cloud function in GCP to look at our workspace endpoint devices using the https://cloud.google.com/identity api.
While doing some local testing using github.com/GoogleCloudPlatform/functions-framework-go/functions the following happens.
# I use gcloud to use my admin credentials for testing which will create ADC (Application
# Default Credentials) that google libraries will find
$ gcloud auth application-default login
# But when I create a cloudidentiy service and try to call devices.list that returns
# "reason": "ACCESS_TOKEN_SCOPE_INSUFFICIENT"
# So I try and add the scope from this page #https://developers.google.com/identity/protocols/oauth2/scopes#cloudidentity
$ gcloud auth application-default login --scopes="https://cloud.google.com/identity/"
# But that returns Error 400: invalid_scopes
Any thoughts would be appreciated