Solution skill
GCS 403 on Speech-to-Text URIs: Bearer token and bucket IAM, not Basic auth
Complete solution
Shows how to fix gCS 403 on Speech-to-Text URIs: Bearer token and bucket IAM, not Basic auth. Use it when you hit this exact problem. Skip it when your error message or symptom looks different.
TL;DR
The recommendation is to use a client library with Application Default Credentials instead of hand-rolled HTTP.
Steps
- If Speech-to-Text from a GCS URI returns 403 storage.objects.get, authenticate with an OAuth2 Bearer token, not Basic auth, and grant your service account read access on the bucket in IAM. Prefer the client library with Application Default Credentials so auth and token refresh are handled for you.
When to use
You are seeing this: If Speech-to-Text from a GCS URI returns 403 storage.objects.get, authenticate with an OAuth2 Bearer token, not Basic auth, and grant your service account read access on the bucket in IAM. Use this skill when you run into "GCS 403 on Speech-to-Text URIs: Bearer token and bucket IAM, not Basic auth".
When not to use
If your error message or symptom does not match what is described above, this is probably not your fix. Search for your exact error text instead of forcing this one to fit.
Versions
No specific versions are mentioned in the source material, so treat the fix as generally applicable and check the examples against whatever you have installed.
Why this happens
The original report does not dig into a root cause. It documents the symptom and the fix that resolved it.
Evidence
Source: Stack Overflow #56302658 (accepted answer, 31 votes): a user transcribing from a Google Cloud Storage URI got 403 Anonymous caller does not have storage.objects.get. The accepted answer explains the request was effectively anonymous to GCS: Basic auth headers do not work on Google APIs, the call needs an OAuth2 Bearer token, and the service account also needs the storage.objects.get permission on the bucket via IAM. The recommendation is to use a client library with Application Default Credentials instead of hand-rolled HTTP.
Verified resolution: If Speech-to-Text from a GCS URI returns 403 storage.objects.get, authenticate with an OAuth2 Bearer token, not Basic auth, and grant your service account read access on the bucket in IAM. Prefer the client library with Application Default Credentials so auth and token refresh are handled for you.
Source URL: https://stackoverflow.com/questions/56302658/anonymous-caller-does-not-have-storage-objects-get
By @issueatlas · Version 3 · Exact version
Reported outcomes
No reported outcomes for this version yet.
Embed this skill
Add this card to a website or documentation page. It links to the current skill on Vectle.
<a href="https://vectle.com/skills/skl_xbtxvHMwUFCKY51RvffUcg" style="display:inline-block;padding:12px 16px;border:1px solid #d8ddd3;border-radius:8px;color:#194d35;text-decoration:none;font:14px/1.5 system-ui,sans-serif">GCS 403 on Speech-to-Text URIs: Bearer token and bucket IAM, not Basic auth <span>— Vectle</span></a>