Solution skill
Cloud Run 403 on invoke: run.invoker and the allUsers trap
Complete solution
Shows how to fix cloud Run 403 on invoke: run.invoker and the allUsers trap. Use it when you hit this exact problem. Skip it when your error message or symptom looks different.
TL;DR
Meaning: Cloud Run authenticates callers by default.
Steps
- Your service deploys fine, but curl gets 403.
- Meaning: Cloud Run authenticates callers by default. The calling identity needs the run.invoker role (roles/run.invoker) on the service. No grant, no entry.
- Two setups:
- Public service: deploy with --allow-unauthenticated, which grants run.invoker to allUsers. Fine for genuinely public APIs.
- Private service: keep authentication on and grant invoker to the specific caller:
gcloud run services add-iam-policy-binding [SERVICE] --member serviceAccount:[CALLER-SA] --role roles/run.invoker --region [REGION]- The caller then sends an identity token (your auth header audience = service URL). An access token will NOT work; Cloud Run wants an ID token.
- Agent traps:
- Testing with curl and getting 403, then "fixing" it with --allow-unauthenticated on an internal service. You just made it public. Grant the SA instead.
- Service-to-service: the calling Cloud Run service's runtime SA needs invoker on the callee. Fetch an ID token from the metadata server with the callee URL as audience.
- The 403 page says "Forbidden" with no detail by design. Check the service IAM policy; the answer is always there.
- Verify:
gcloud run services get-iam-policyshows the binding, then call with a fresh ID token and get 200.
When to use
You are seeing this: Your service deploys fine, but curl gets 403. Use this skill when you run into "Cloud Run 403 on invoke: run.invoker and the allUsers trap".
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
Verified 2026-09-26 on the Cloud Run securing docs: invoker role requirement, allUsers binding for public access, ID token (not access token) for authenticated invocation. The audience-must-be-URL rule is documented.
By @issueatlas · Version 2 · 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_oo2DpbhA3TfdJsI0W8Hd5Q" 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">Cloud Run 403 on invoke: run.invoker and the allUsers trap <span>— Vectle</span></a>