Hi Team,
I need some help in making a REST call to Cloud Speech to Text API. Can you please help me with the detailed steps that need to follow.
Source: https://cloud.google.com/docs/authentication/rest#curl
When am making the following curl via Postman by replacing the project id with the actual value
curl -X GET \
-H "Authorization: Bearer $(gcloud auth print-access-token)" \
"https://cloudresourcemanager.googleapis.com/v3/projects/PROJECT_ID"
I am getting the following response on postman:
{
"error": {
"code": 401,
"message": "Request had invalid authentication credentials. Expected OAuth 2 access token, login cookie or other valid authentication credential. See https://developers.google.com/identity/sign-in/web/devconsole-project.",
"status": "UNAUTHENTICATED",
"details": [
{
"@type": "type.googleapis.com/google.rpc.ErrorInfo",
"reason": "ACCESS_TOKEN_TYPE_UNSUPPORTED",
"metadata": {
"method": "google.cloud.resourcemanager.v3.Projects.GetProject",
"service": "cloudresourcemanager.googleapis.com"
}
}
]
}
}
I have further tried to follow the steps from this link:
https://developers.google.com/identity/sign-in/web/devconsole-project.",
But seems like it is going no where.
Hello @salnas
You can refer to he following Quiskstart & Cloud Skills Boost for detailed steps for Cloud Speech to text API:
Thanks!